diff --git a/include/fmt/format-inl.h b/include/fmt/format-inl.h index 2f63a213..5e796bd5 100644 --- a/include/fmt/format-inl.h +++ b/include/fmt/format-inl.h @@ -148,8 +148,7 @@ template <> FMT_FUNC int count_digits<4>(detail::fallback_uintptr n) { } #if __cplusplus < 201703L -template -constexpr const typename basic_data::digit_pair basic_data::digits[]; +template constexpr const char basic_data::digits[][2]; template constexpr const char basic_data::hex_digits[]; template constexpr const char basic_data::signs[]; template constexpr const unsigned basic_data::prefixes[]; diff --git a/include/fmt/format.h b/include/fmt/format.h index 633fa119..b03449e1 100644 --- a/include/fmt/format.h +++ b/include/fmt/format.h @@ -875,8 +875,7 @@ template struct basic_data { static const uint64_t log10_2_significand = 0x4d104d427de7fbcc; // GCC generates slightly better code for pairs than chars. - using digit_pair = char[2]; - FMT_API static constexpr const digit_pair digits[] = { + FMT_API static constexpr const char digits[][2] = { {'0', '0'}, {'0', '1'}, {'0', '2'}, {'0', '3'}, {'0', '4'}, {'0', '5'}, {'0', '6'}, {'0', '7'}, {'0', '8'}, {'0', '9'}, {'1', '0'}, {'1', '1'}, {'1', '2'}, {'1', '3'}, {'1', '4'}, {'1', '5'}, {'1', '6'}, {'1', '7'},