it’s possible to write something like this?
#define ISWINDOWS() (#if defined(_WIN32) || defined(_WIN64) \
1 \
#elif \
0 \
#endif)
and then:
void foo() {
if(ISWINDOWS()) {
// ..
} else {
// ...
}
}
You cannot define a macro within a macro. You can do this, but its probably not what you want: