diff --git a/include/fast_float/float_common.h b/include/fast_float/float_common.h index e717a88..926fea9 100644 --- a/include/fast_float/float_common.h +++ b/include/fast_float/float_common.h @@ -5,6 +5,7 @@ #include #include #include +#include #include #include #ifdef __has_include @@ -222,13 +223,13 @@ fastfloat_really_inline constexpr bool cpp20_and_in_constexpr() { template struct is_supported_float_type : std::integral_constant< - bool, std::is_same::value || std::is_same::value -#ifdef __STDCPP_FLOAT32_T__ - || std::is_same::value -#endif + bool, std::is_same::value || std::is_same::value #ifdef __STDCPP_FLOAT64_T__ || std::is_same::value #endif +#ifdef __STDCPP_FLOAT32_T__ + || std::is_same::value +#endif #ifdef __STDCPP_FLOAT16_T__ || std::is_same::value #endif @@ -757,8 +758,7 @@ template <> inline constexpr size_t binary_format::max_digits() { return 22; } - -#endif +#endif // __STDCPP_FLOAT16_T__ // credit: Jakub JelĂ­nek #ifdef __STDCPP_BFLOAT16_T__ @@ -881,8 +881,7 @@ template <> inline constexpr size_t binary_format::max_digits() { return 98; } - -#endif +#endif // __STDCPP_BFLOAT16_T__ template <> inline constexpr uint64_t @@ -1051,7 +1050,6 @@ template <> constexpr char32_t const *str_const_nan() { template <> constexpr char8_t const *str_const_nan() { return u8"nan"; } - #endif template constexpr UC const *str_const_inf(); @@ -1074,7 +1072,6 @@ template <> constexpr char32_t const *str_const_inf() { template <> constexpr char8_t const *str_const_inf() { return u8"infinity"; } - #endif template struct int_luts { @@ -1158,7 +1155,7 @@ static_assert(std::is_same, uint64_t>::value, static_assert( std::numeric_limits::is_iec559, "std::float64_t must fulfill the requirements of IEC 559 (IEEE 754)"); -#endif +#endif // __STDCPP_FLOAT64_T__ #ifdef __STDCPP_FLOAT32_T__ static_assert(std::is_same, uint32_t>::value, @@ -1166,7 +1163,7 @@ static_assert(std::is_same, uint32_t>::value, static_assert( std::numeric_limits::is_iec559, "std::float32_t must fulfill the requirements of IEC 559 (IEEE 754)"); -#endif +#endif // __STDCPP_FLOAT32_T__ #ifdef __STDCPP_FLOAT16_T__ static_assert( @@ -1175,7 +1172,7 @@ static_assert( static_assert( std::numeric_limits::is_iec559, "std::float16_t must fulfill the requirements of IEC 559 (IEEE 754)"); -#endif +#endif // __STDCPP_FLOAT16_T__ #ifdef __STDCPP_BFLOAT16_T__ static_assert( @@ -1184,7 +1181,7 @@ static_assert( static_assert( std::numeric_limits::is_iec559, "std::bfloat16_t must fulfill the requirements of IEC 559 (IEEE 754)"); -#endif +#endif // __STDCPP_BFLOAT16_T__ constexpr chars_format operator~(chars_format rhs) noexcept { using int_type = std::underlying_type::type;