I found this while reading some source code.
#define MACRO(x) if((void) 0, (x)); else some_func();
I don't fully understand the reasons behind that operator comma and the void cast. This has probably something to do with macro protection, I know that (void)0
is used sometimes to protect cascading else
s in macros such as in if(...) then foo(); else (void)0
.
Any ideas of why operator comma is there?
edit: I'm starting to think this has something to do with the owl (0,0)
.