Re: [Ctool-develop] testing the gcc test suite
Brought to you by:
flisakow
From: Shaun F. <fli...@so...> - 2003-09-07 20:59:47
|
On Friday, September 5, 2003, at 09:22 AM, Stefan Seefeld wrote: > > Now 89.66% of the accept0 tests pass (yay !). The rest seems to stem > from a parse error in /usr/include/stdio.h, specifically at a line > like: > > extern char *tempnam (__const char *__dir, __const char *__pfx) > __attribute__ ((__malloc__)); > > While the scanner supports '__attribute__', the grammar doesn't look > as if it allows it at that particular place. As I don't quite > undererstand the grammar (yet), I don't know what change to make > to gram.y to add an optional attribute to a function declaration > like the above. > It might be a one-line fix... > It looks to me like __attribute__ is already accepted at the proper spot (after any declarator), in gram.y: decl: declarator [opt_gcc_attrib] I would guess the problem might stem from lexer.l not having an entry for __malloc__, you would need a line like the other supported flags have, see __format__, __noreturn__ etc. while in the <GCC_ATTRIB> state. Thanks, Shaun |