Definitions
The Definitions header provides platform and compiler detection macros used throughout the library.
These macros enable conditional compilation for different operating systems, architectures, and compilers.
Platform Detection
The following macros are defined automatically:
ERBSLAND_OS_WINDOWSDefined on Windows platforms (
_WIN32or_WIN64).ERBSLAND_OS_MACOSDefined on Apple platforms.
ERBSLAND_OS_LINUXDefined on Linux platforms.
Short namespace aliases EL_OS_WINDOWS, EL_OS_MACOS, and EL_OS_LINUX are also provided when the short
namespace is enabled.
Architecture Detection
ERBSLAND_ARCH_64Defined on 64-bit architectures (
_WIN64,__x86_64__, or__ppc64__).ERBSLAND_ARCH_32Defined on 32-bit architectures.
Compiler Detection
ERBSLAND_COMPILER_CLANGDefined when compiling with Clang.
ERBSLAND_COMPILER_GCCDefined when compiling with GCC or compatible compilers.
ERBSLAND_COMPILER_MSVCDefined when compiling with Microsoft Visual C++.
wchar_t Size
ERBSLAND_WCHAR_16BITDefined on Windows, where
wchar_tis 16 bits.ERBSLAND_WCHAR_32BITDefined on all other platforms, where
wchar_tis 32 bits.
Short Namespace
The header also sets up the el short namespace alias for erbsland.
This can be disabled with ERBSLAND_NO_SHORT_NAMESPACE or customized with ERBSLAND_SHORT_NAMESPACE to use a
different namespace name.