preprocessor/9650: string literal contactenation doesn't work with #include

frey waid waid@cisco.com
Mon Feb 10 22:59:00 GMT 2003


that's what i was doing before.  so i had this:

#include COMP_INC(comp,file)

#define COMP_INC(comp,file)   #comp "/include/" #file

do you have another method in mind?

frey

neil@gcc.gnu.org wrote:
> 
> Synopsis: string literal contactenation doesn't work with #include
> 
> State-Changed-From-To: open->closed
> State-Changed-By: neil
> State-Changed-When: Mon Feb 10 22:57:32 2003
> State-Changed-Why:
>     Not a bug.
> 
>     In standard C/C++  such concatenation does not happen.  It appears it was an undocumented feature of some previous versions of GCC.
> 
>     If you really miss it, you can probably get what you want through the # operator via indirect macro expansion.
> 
> http://gcc.gnu.org/cgi-bin/gnatsweb.pl?cmd=view%20audit-trail&database=gcc&pr=9650



More information about the Gcc-bugs mailing list