[ACCEPTED]-How to define a define in C?-c-preprocessor
No; preprocessing is performed in a single 7 pass. If you want or need more advanced 6 behavior, consider using another tool to 5 preprocess the source, like m4.
Further, the 4
# in the replacement list (at the beginning 3 of
#define FIDN... would be parsed as the
# (stringize) operator: the 2 operand of this operator must be a named 1 macro parameter, which
define is not.
No while defining macros u should take care 5 of one thing that macro should not call 4 itself (reccursively) either directly or 3 indirectly.
I know two static variables consuming 2 8 bytes will be expansive for u.
I have solution 1 over it
#define FID_STRS2(x) #x #define FID_STRE(x) FID_STRS2(x) #define FID_DECL(n, v) static int FIDN_##n = v;static const char *FIDS_##n = FID_STRE(v)
Just rename them going reccursive
More Related questions