I'm trying to define a macro GCC_447_OR_LESS
(below) that I can use to check for instead of using the great a big ugly macro
#ifdef __linux__
// Test for GCC 4.4.7 or less
#if __GNUC__ < 4 || \
__GNUC__ == 4 && ( __GNUC_MINOR__ < 4 || \
( __GNUC_MINOR__ == 4 && __GNUC_PATCHLEVEL__ <= 7 ) ) \
#define GCC_447_OR_LESS
#endif
#endif
However I'm getting the error
error: missing binary operator before token "#"
#define GCC_447_OR_LESS
^
I can't explain what's going on. Can't a #define be used within #if in the way I used it?