Add DEBUG constexpr

Enable checking use of a constexpr rather than ifdef for checking if in
DEBUG.
This commit is contained in:
Matthew Parkinson
2022-02-01 09:11:35 +00:00
committed by Matthew Parkinson
parent f1be609cdb
commit 3d1b973480
9 changed files with 83 additions and 87 deletions

View File

@@ -30,11 +30,7 @@ namespace
#ifdef SNMALLOC_CHECK_LOADS
SNMALLOC_CHECK_LOADS
#else
# ifdef NDEBUG
false
# else
true
# endif
DEBUG
#endif
;
@@ -50,11 +46,7 @@ namespace
#ifdef SNMALLOC_FAIL_FAST
SNMALLOC_FAIL_FAST
#else
# ifdef NDEBUG
true
# else
false
# endif
!DEBUG
#endif
;