File tree Expand file tree Collapse file tree 3 files changed +5
-4
lines changed Expand file tree Collapse file tree 3 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 1212 #if defined(__cpp_lib_bit_cast)
1313 #undef CXX20_CONSTEXPR
1414 #define CXX20_CONSTEXPR constexpr
15+ #define HAS_CXX20_CONSTEXPR 1
1516 #endif
1617 #endif
1718 #endif
Original file line number Diff line number Diff line change 8181 #if defined(__cpp_lib_bit_cast)
8282 #undef CXX20_CONSTEXPR
8383 #define CXX20_CONSTEXPR constexpr
84+ #define HAS_CXX20_CONSTEXPR 1
8485 #endif
8586 #endif
8687 #endif
Original file line number Diff line number Diff line change 55#include " fast_float/fast_float.h"
66#include < iomanip>
77#include < string>
8- #include < version>
98
109#ifndef SUPPLEMENTAL_TEST_DATA_DIR
1110#define SUPPLEMENTAL_TEST_DATA_DIR " data/"
3837#define FASTFLOAT_ODDPLATFORM 1
3938#endif
4039
41- #if defined(__cpp_lib_bit_cast)
40+ #if HAS_CXX20_CONSTEXPR
4241#include < bit>
4342#include < string_view>
4443#endif
@@ -116,7 +115,7 @@ TEST_CASE("supplemental") {
116115}
117116#endif
118117
119- #if defined(__cpp_lib_bit_cast)
118+ #if HAS_CXX20_CONSTEXPR
120119
121120constexpr double tryParse (std::string_view input)
122121{
@@ -136,7 +135,7 @@ static_assert(tryParse("3.14156") != 3.1415600000001);
136135static_assert (std::isnan(tryParse(" hellothere" ))); // technically isnan is not constexpr but GCC and clang allow it
137136#endif
138137
139- #endif // #if defined(__cpp_lib_bit_cast)
138+ #endif // #if HAS_CXX20_CONSTEXPR
140139
141140TEST_CASE (" leading_zeroes" ) {
142141 constexpr const uint64_t bit = 1 ;
You can’t perform that action at this time.
0 commit comments