Closed iphydf closed 6 months ago
#if ?
It's if (LOG_LEVEL_INFO >= LOG_LEVEL_TRACE)
which comes from a logging macro.
if LOG_LEVEL_INFO and LOG_LEVEL_TRACE are macros then
#if (LOG_LEVEL_INFO >= LOG_LEVEL_TRACE)
#endif
They are enums, not macros. Also this is from a macro expansion like LOGGER_TRACE(msg, ...)
.
At command like
cake -Wno-conditional-constant
or
enum {A, B};
int main(){
#pragma cake diagnostic push
#pragma cake diagnostic ignored "-Wconditional-constant"
if (B > A){}
#pragma cake diagnostic pop
}
If I try the first option, I get:
1.278 unknown warning '-Wno-conditional-constant'
1.278 0 files in 0.00 seconds
1.278 0 errors 0 warnings 0 notes
The second option isn't an option for me.
it should work I will check later.
I get:
But I don't seem to be able to disable it with
-Wno-conditional-constant
.