preprocessor/7457: failure preprocessing ## directive

neil@gcc.gnu.org neil@gcc.gnu.org
Wed Jul 31 17:16:00 GMT 2002


Synopsis: failure preprocessing ## directive

State-Changed-From-To: open->closed
State-Changed-By: neil
State-Changed-When: Wed Jul 31 15:20:59 2002
State-Changed-Why:
    Not a bug - please understand what ## means.
    
    It means: "take the spelling of the LHS, and the spelling
    of the RHS, and concatenate the two to form a new token.  If the concatenation does not form a valid token, anything goes.".  You are trying to create a token
    
       "libdrv"".so"
    
    which is not a token (it's two tokens).  However, if you just drop the !@#$%^& ##, then you're OK: two strings
    concatenate to become one string by the rules of C (post
    macro expansion and preprocessing).
    
    Please read a good description of what ## does.
    
    Yes, GCC is getting more picky.  That's a good thing.

http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=7457



More information about the Gcc-bugs mailing list