Add a missing num_bits specialization

This commit is contained in:
Victor Zverovich 2024-01-12 07:20:12 -08:00
parent 7e58af4eaf
commit 0cdee904a4
2 changed files with 3 additions and 1 deletions

View File

@ -1491,7 +1491,8 @@ constexpr unsigned long long make_descriptor() {
template <typename T, typename Char>
#if FMT_CLANG_VERSION && FMT_CLANG_VERSION <= 1500
// https://github.com/fmtlib/fmt/issues/3796
struct type_is_unformattable_for {};
struct type_is_unformattable_for {
};
#else
struct type_is_unformattable_for;
#endif

View File

@ -462,6 +462,7 @@ template <typename T> constexpr auto num_bits() -> int {
}
// std::numeric_limits<T>::digits may return 0 for 128-bit ints.
template <> constexpr auto num_bits<int128_opt>() -> int { return 128; }
template <> constexpr auto num_bits<uint128_opt>() -> int { return 128; }
template <> constexpr auto num_bits<uint128_fallback>() -> int { return 128; }
// A heterogeneous bit_cast used for converting 96-bit long double to uint128_t