If you enter the DISBALE_DEBUG
#ifdef
branch, the Dbg
macro will be defined as a variadic macro which just consumes its variadic arguments and does nothing with them. I.e., a call such as
Dbg("\n %s %s %d %d \n", __FILE__, __FUNCTION__, __LINE__, mode);
will resolve to
(0);
which, as the compiler accurately warns you about, has no effect.
If you enter the #else
branch, on the other hand, the Dbg
macro will just be a replacement, by the pre-processor, with print
, meaning
Dbg("\n %s %s %d %d \n", __FILE__, __FUNCTION__, __LINE__, mode);
resolves to
print("\n %s %s %d %d \n", __FILE__, __FUNCTION__, __LINE__, mode);
Now, given the information in your question, it is unclear what print(...)
will resolve to, as it is not a standard function in C++ nor C. It's likely another variadic macro or a variadic function.