I want to use a macro (say MACRO1) used as a argument to other macro (say MACRO2). I know that this works when MACRO1 is defined for a value as shown below.
#define MACRO1 5000
#define MACRO2 MACRO1*MACRO1
But in my case, MACRO1 is a variable name i.e.
#define MACRO1 my_var
And I want to create a other variable which has ‘_count’ appended in name defined for MACRO1 like
#define MACRO2 MACRO1 # _count
But above line is not getting preprocessed as expected. It is returning ‘MACRO1_count’ where as I need ‘my_var_count’.