Skip to content

Commit

Permalink
Utility: fix DebugAssertDisabledTest if CMAKE_BUILD_TYPE is unset.
Browse files Browse the repository at this point in the history
Then neither CORRADE_IS_DEBUG_BUILD nor NDEBUG is set, and then the test
fails to even build because the CORRADE_CONSTEXPR_DEBUG_ASSERT() macro
expands to a non-constexpr lambda call.
  • Loading branch information
mosra committed May 27, 2022
1 parent 69bc315 commit 1fea951
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Corrade/Utility/Test/AssertDisabledTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

#include <sstream>

#if defined(TEST_DEBUG_ASSERT) && !defined(CORRADE_IS_DEBUG_BUILD)
#if defined(TEST_DEBUG_ASSERT) && !defined(CORRADE_IS_DEBUG_BUILD) && defined(NDEBUG)
/* for debug asserts do nothing, they should be disabled in release builds */
#elif !defined(CORRADE_NO_ASSERT)
#define CORRADE_NO_ASSERT
Expand Down

0 comments on commit 1fea951

Please sign in to comment.