From 71fd73fa04e7c5a67508d297623d68e3e1371446 Mon Sep 17 00:00:00 2001 From: Herb Sutter Date: Fri, 18 Dec 2020 12:27:33 -0800 Subject: [PATCH] Make constructor more `constinit`-friendly --- include/gsl/assert | 5 ----- 1 file changed, 5 deletions(-) diff --git a/include/gsl/assert b/include/gsl/assert index 91f43b6..94c9967 100644 --- a/include/gsl/assert +++ b/include/gsl/assert @@ -109,12 +109,7 @@ public: using handler = void (*)(); #endif -#if defined(__cpp_constexpr) && __cpp_constexpr >= 201806 - constexpr contract_group (handler h) { set_handler(h); } -#else // VESTIGIAL, remove when no longer needed for downlevel compilers constexpr contract_group (handler h) : chandler(h ? h : []()noexcept{}) { } -#endif - #if __cplusplus >= 202002L constexpr auto set_handler(handler h) -> handler { return std::exchange(chandler, h ? h : []()noexcept{}); } #else // VESTIGIAL, remove when no longer needed for downlevel compilers