I have some C++ code, and want to perform an action if the __APPLE__ or __linux macros are defined.
__APPLE__
__linux
If I did it as a normal if
if
In my C++ there is.
#if defined(__APPLE__) || defined(__linux) // ... #endif
You can't in a single #ifdef would a single #if do instead?
#ifdef
#if
#if defined(__APPLE__) || defined(__linux)
this also works if you prefer
#if defined __APPLE__ || defined __linux