GCC CPP not expanding macro correctly?

Neil Booth neil@daikokuya.co.uk
Thu Apr 24 07:12:00 GMT 2003


Segher Boessenkool wrote:-

> Try this:
> 
> -- 8< --
> #define FIRST() FUNC
> #define SECOND() ()
> #define FUNC() 0
> #define CLUNK(x, y) x y
> int main() {
>    return CLUNK(FIRST(), SECOND());
> }
> -- 8< --
> 
> Yes it's ugly, and it fails on some compilers.  Not on GCC, though ;)

What does it fail on?

Neil.



More information about the Gcc mailing list