http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53370
Bug #: 53370 Summary: Unbalanced parenthesis when using __attribute__ Classification: Unclassified Product: gcc Version: 4.5.2 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: matias.fontan...@gmail.com When using __attribute__((packed(N))), an unbalanced amount of parenthesis can be used and no compilation error is detected. The documentation states: "Note that __attribute__ spelled with two underscores before and two after, and there are always two sets of parentheses surrounding the contents." So this looks like a bug. To reproduce this error, compile this: int main() { __attribute__((aligned(16)) char arr[5]; } Which contains three '(' and two ')' and still compiles. Note that gcc does detect this error, g++ does not.