mdbx: check for GCC/clang in debug-includes (insignificant internals).

This commit is contained in:
Leonid Yuriev 2022-01-04 13:41:25 +03:00
parent f836c928a8
commit 070ba5ded4
2 changed files with 12 additions and 0 deletions

View File

@ -1,3 +1,5 @@
#if defined(__GNUC__) && !defined(__LCC__)
#pragma push_macro("mdbx_trace") #pragma push_macro("mdbx_trace")
#pragma push_macro("mdbx_debug") #pragma push_macro("mdbx_debug")
#pragma push_macro("mdbx_verbose") #pragma push_macro("mdbx_verbose")
@ -33,4 +35,8 @@
#undef mdbx_assert #undef mdbx_assert
#define mdbx_assert(env, expr) mdbx_ensure(env, expr) #define mdbx_assert(env, expr) mdbx_ensure(env, expr)
#if !defined(__clang__)
#pragma GCC optimize("-O0") #pragma GCC optimize("-O0")
#endif
#endif /* GCC only */

View File

@ -1,3 +1,5 @@
#if defined(__GNUC__) && !defined(__LCC__)
#pragma pop_macro("mdbx_trace") #pragma pop_macro("mdbx_trace")
#pragma pop_macro("mdbx_debug") #pragma pop_macro("mdbx_debug")
#pragma pop_macro("mdbx_verbose") #pragma pop_macro("mdbx_verbose")
@ -6,4 +8,8 @@
#pragma pop_macro("mdbx_error") #pragma pop_macro("mdbx_error")
#pragma pop_macro("mdbx_assert") #pragma pop_macro("mdbx_assert")
#if !defined(__clang__)
#pragma GCC reset_options #pragma GCC reset_options
#endif
#endif /* GCC only */