to make my question precise i would like to create a macro that accepts as variable ++ and pastes it with another variable. In code:
#define MYMACRO(A, OP) /* .... */
and then if i write in the source file
MYMACRO(this->var, ++)
the preprocessor should paste in the code
this->var++;
When i am trying to define the macro as A##OP , it provides the following error:
pasting "++" and "var" does not give a valid preprocessing token
Is it possible to do what i am trying?
thanks in advance for the answer