specialize for std::float32_t and std::float64_t explicitly

This commit is contained in:
Daniel Lemire 2025-09-29 14:14:01 -04:00
parent 04e8e545d8
commit b3dd09bb86

View File

@ -1246,6 +1246,16 @@ constexpr chars_format adjust_for_feature_macros(chars_format fmt) {
}
} // namespace detail
#ifdef __STDCPP_FLOAT64_T__
template <>
struct binary_format<std::float64_t> : public binary_format<double> {};
#endif
#ifdef __STDCPP_FLOAT32_T__
template <>
struct binary_format<std::float32_t> : public binary_format<float> {};
#endif
} // namespace fast_float
#endif