commit d0a07ed71c4a61416e65c80be3ffae6de1e4b169 parent 958cbad84828c223f319d7875863b0996f3922f7 Author: Michael Savage <mikejsavage@gmail.com> Date: Sun Jun 25 15:14:22 +0300 PRAGMA_DISABLE_OPTIMISATIONS for clang Diffstat:
platform_pragmas.h | | | 5 | ++++- |
diff --git a/platform_pragmas.h b/platform_pragmas.h @@ -5,11 +5,14 @@ #if COMPILER_MSVC #define PRAGMA_DISABLE_OPTIMISATIONS() __pragma( optimize( "", off ) ) #define PRAGMA_ENABLE_OPTIMISATIONS() __pragma( optimize( "", on ) ) -#elif COMPILER_GCCORCLANG +#elif COMPILER_GCC #define PRAGMA_DISABLE_OPTIMISATIONS() \ _Pragma( "GCC push_options" ) \ _Pragma( "GCC optimize (\"O0\")" ) #define PRAGMA_ENABLE_OPTIMISATIONS() _Pragma( "GCC pop_options" ) +#elif COMPILER_CLANG +#define PRAGMA_DISABLE_OPTIMISATIONS() _Pragma( "clang optimize off" ) +#define PRAGMA_ENABLE_OPTIMISATIONS() _Pragma( "clang optimize on" ) #else #error new compiler #endif