[patch] Fix uninitialized Dwarf_Frame->regs

Roland McGrath roland at hack.frob.com
Mon Oct 8 21:33:10 UTC 2012


> static_assert is C++0x keyword (GDB has gdb_static_assert); but system.h is
> not exported so I found it OK.

I think it's potentially confusing to define a macro that is the same
identifier as a keyword.  This also might cause some trouble with the
C++-heavy code on the dwarf branch.  So let's use a different name.

> +#define static_assert(expr)					\
> +  extern int __attribute__ ((unused))				\
> +    never_defined_just_used_for_checking[(expr) ? 1 : -1]

The usual style is to put the attribute at the end of the decl.


Thanks,
Roland


More information about the elfutils-devel mailing list