Quote:Original post by chollida1
Really, well that's great!!!
Can you show me how to get this to work with BOOST_PP_CAT.
#ifdef _WIN32
#define message(x) #pragma message "hello"
#else
#define message(x) #warningmessage "hello"
#endif
I also tried putting '#' in my definitions and the BOOST_PP_CAT causes preprocessor to error, Since you say its possible, how do you get '#' in preprocessor macros?? I'd love this feature:)
Bye the way you usually seem like a nice guy/girl, what's up with the terse answer:)
Cheers
CHris
As far as I know, there isn't a real good solution for this. The closest thing I have done to this is something along the lines of
#ifdef ENABLE_DEBUG_FILE_MESSAGES
#define DEBUG_FILE_PRAGMA message( "Parsing " __FILE__ )
#else
#define DEBUG_FILE_PRAGMA
#endif
and then put the following line at the top of my files after the includes
#pragma DEBUG_FILE_PRAGMA
Then I can toggle on the ability to display all header the files that are being parsed when compiling a cpp file.