We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents dace94f + de17ac3 commit 526e301Copy full SHA for 526e301
1 file changed
include/stdx/static_assert.hpp
@@ -29,7 +29,7 @@ template <bool B> constexpr auto ct_check = ct_check_t<B>{};
29
30
// NOLINTNEXTLINE(cppcoreguidelines-macro-usage)
31
#define STATIC_ASSERT(cond, ...) \
32
- []<bool B>() -> bool { \
+ [&]<bool B>() -> bool { \
33
STDX_PRAGMA(diagnostic push) \
34
STDX_PRAGMA(diagnostic ignored "-Wunknown-warning-option") \
35
STDX_PRAGMA(diagnostic ignored "-Wc++26-extensions") \
@@ -43,7 +43,7 @@ template <bool B> constexpr auto ct_check = ct_check_t<B>{};
43
44
45
46
47
constexpr auto S = STDX_CT_FORMAT(__VA_ARGS__); \
48
stdx::ct_check<B>.template emit<S>(); \
49
return B; \
0 commit comments