RE: pasting x amd x does not give a valid preprocessing token

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Divya,

> pasting "version" and "." does not give a valid preprocessing token.

That is correct. "version." is not a valid preprocessing token.  It is two tokens, "version" and ".".  Preprocessor pasting REQUIRES that the resulting token is a single valid token.

In the case you are working with, you probably want this, which relies on string literal concatenation:

#define NAME_STRING "lib" stringify(TARGET) ".so"

HTH,
--Eljay


[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux