this is the actual macro:
#ifdef DEBUG
#define debug(funcname, format, ...) \
printf(BOLD UNDERLINED REVERSE \
"DEBUG IN " __FILE__ \
" LINE " __LINE__ ":" \
RESET UNDERLINED REVERSE \
"In " funcname \
RESET REVERSE format RESET, ##__VA_ARGS__)
#else
#define debug(funcname, format, ...)
#endif
Where all the constant used are well defined string constants. I call it with something like:
char message[] = "Hello StackOverflow !\n";
debug("main()", "Message: %s\n", message);
But I get the message
error: expected ‘)’ before numeric constant
debug("main()", "Message: ", message);
poiting at the closing parenthese.
It is weird because I first tested the macro, and now that the project has advanced with the team it doesn't work...