[PATCH v8 8/9] compiler.h, bug.h: Prevent double error messages with BUILD_BUG{,_ON}

2013-01-01 Thread danielfsantos
Prior to the introduction of __attribute__((error("msg"))) in gcc 4.3, creating compile-time errors required a little trickery. BUILD_BUG{,_ON} uses this attribute when available to generate compile-time errors, but also uses the negative-sized array trick for older compilers, resulting in two

[PATCH v8 8/9] compiler.h, bug.h: Prevent double error messages with BUILD_BUG{,_ON}

2013-01-01 Thread danielfsantos
Prior to the introduction of __attribute__((error(msg))) in gcc 4.3, creating compile-time errors required a little trickery. BUILD_BUG{,_ON} uses this attribute when available to generate compile-time errors, but also uses the negative-sized array trick for older compilers, resulting in two error