Ok, very interesting stuff.

The problem is not a problem with the pre-processor.

SOME __attributes__ are substituted just fine.

For some reason, on my architecture the replacement does not happen for certain __attributes__.

https://gcc.gnu.org/onlinedocs/gcc-4.0.0/gcc/Function-Attributes.html

1. # define NoDbgRegParms                               <--compiles
2. # define NoDbgRegParms __attribute__ ((regparm (0)))   <--function type mismatch error due to NoDbgRegParms not being replaced
3. # define NoDbgRegParms __attribute__ ((deprecated))    <--This spit out a bunch of warnings (as expected) but it compiled! yay!
4. #define NoDbgRegParms __attribute__ ((noinline))     <--function type mismatch error due to NoDbgRegParms not being replaced
5. #define NoDbgRegParms __attribute__ ((always_inline))  <-- error: inlining failed in call to always_inline 'printNameOfClasscount': recursive inlining


regparm (number)
On the Intel 386, the regparm attribute causes the compiler to pass up to number integer arguments in registers EAX, EDX, and ECX instead of on the stack. Functions that take a variable number of arguments will continue to be passed all of their arguments on the stack.

I am running an AMD processor.

I will research this some more.

cheers.

tty.