http://gcc.gnu.org/bugzilla/show_bug.cgi?id=48981
--- Comment #5 from Dmitry Gorbachev <d.g.gorbachev at gmail dot com> 2011-05-14 00:51:44 UTC --- (In reply to comment #4) Then this comment in gengtype.c becomes no longer valid, and confusing: /* Record the definition of a generic VEC structure, as if we had expanded the macros in vec.h: > typedef struct VEC_<type>_base GTY(()) { > unsigned num; > unsigned alloc; > - <type> GTY((length ("%h.num"))) vec[1]; > + <type> GTY((length ("%h.prefix.num"))) vec[1]; > } VEC_<type>_base > > where the GTY(()) tags are only present if is_scalar is _false_. */ In vec.h: > +#ifndef GTY > +#define GTY(x) /* nothing - marker for gengtype */ > +#endif It could be fixed by changing the #include order in vec.c: #include "system.h" +#include "coretypes.h" #include "ggc.h" #include "vec.h" -#include "coretypes.h" #include "diagnostic-core.h" #include "hashtab.h"