From beb41d4f377e31b912cc8fea1031108046a0ba39 Mon Sep 17 00:00:00 2001 From: denchat <19730041+denchat@users.noreply.github.com> Date: Sun, 18 Apr 2021 13:09:27 +0700 Subject: [PATCH] Remove FMT_INSTANTIATION_DEF_API. --- include/fmt/format-inl.h | 44 ++++++++++++++++++++-------------------- 1 file changed, 22 insertions(+), 22 deletions(-) diff --git a/include/fmt/format-inl.h b/include/fmt/format-inl.h index 9ca0eccd..c6fb6e12 100644 --- a/include/fmt/format-inl.h +++ b/include/fmt/format-inl.h @@ -223,7 +223,7 @@ template <> FMT_FUNC int count_digits<4>(detail::fallback_uintptr n) { return i >= 0 ? i * char_digits + count_digits<4, unsigned>(n.value[i]) : 1; } -template FMT_INSTANTIATION_DEF_API +template const typename basic_data::digit_pair basic_data::digits[] = { {'0', '0'}, {'0', '1'}, {'0', '2'}, {'0', '3'}, {'0', '4'}, {'0', '5'}, {'0', '6'}, {'0', '7'}, {'0', '8'}, {'0', '9'}, {'1', '0'}, {'1', '1'}, @@ -248,31 +248,31 @@ const typename basic_data::digit_pair basic_data::digits[] = { (factor)*1000000, (factor)*10000000, (factor)*100000000, \ (factor)*1000000000 -template FMT_INSTANTIATION_DEF_API +template const uint64_t basic_data::powers_of_10_64[] = { 1, FMT_POWERS_OF_10(1), FMT_POWERS_OF_10(1000000000ULL), 10000000000000000000ULL}; -template FMT_INSTANTIATION_DEF_API +template const uint32_t basic_data::zero_or_powers_of_10_32[] = {0, FMT_POWERS_OF_10(1)}; -template FMT_INSTANTIATION_DEF_API +template const uint64_t basic_data::zero_or_powers_of_10_64[] = { 0, FMT_POWERS_OF_10(1), FMT_POWERS_OF_10(1000000000ULL), 10000000000000000000ULL}; -template FMT_INSTANTIATION_DEF_API +template const uint32_t basic_data::zero_or_powers_of_10_32_new[] = { 0, 0, FMT_POWERS_OF_10(1)}; -template FMT_INSTANTIATION_DEF_API +template const uint64_t basic_data::zero_or_powers_of_10_64_new[] = { 0, 0, FMT_POWERS_OF_10(1), FMT_POWERS_OF_10(1000000000ULL), 10000000000000000000ULL}; // Normalized 64-bit significands of pow(10, k), for k = -348, -340, ..., 340. // These are generated by support/compute-powers.py. -template FMT_INSTANTIATION_DEF_API +template const uint64_t basic_data::grisu_pow10_significands[] = { 0xfa8fd5a0081c0288, 0xbaaee17fa23ebf76, 0x8b16fb203055ac76, 0xcf42894a5dce35ea, 0x9a6bb0aa55653b2d, 0xe61acf033d1a45df, @@ -307,7 +307,7 @@ const uint64_t basic_data::grisu_pow10_significands[] = { // Binary exponents of pow(10, k), for k = -348, -340, ..., 340, corresponding // to significands above. -template FMT_INSTANTIATION_DEF_API +template const int16_t basic_data::grisu_pow10_exponents[] = { -1220, -1193, -1166, -1140, -1113, -1087, -1060, -1034, -1007, -980, -954, -927, -901, -874, -847, -821, -794, -768, -741, -715, -688, -661, @@ -318,7 +318,7 @@ const int16_t basic_data::grisu_pow10_exponents[] = { 534, 561, 588, 614, 641, 667, 694, 720, 747, 774, 800, 827, 853, 880, 907, 933, 960, 986, 1013, 1039, 1066}; -template FMT_INSTANTIATION_DEF_API +template const divtest_table_entry basic_data::divtest_table_for_pow5_32[] = {{0x00000001, 0xffffffff}, {0xcccccccd, 0x33333333}, {0xc28f5c29, 0x0a3d70a3}, {0x26e978d5, 0x020c49ba}, @@ -327,7 +327,7 @@ const divtest_table_entry basic_data::divtest_table_for_pow5_32[] = {0x22e90e21, 0x00002af3}, {0x3a2e9c6d, 0x00000897}, {0x3ed61f49, 0x000001b7}}; -template FMT_INSTANTIATION_DEF_API +template const divtest_table_entry basic_data::divtest_table_for_pow5_64[] = {{0x0000000000000001, 0xffffffffffffffff}, {0xcccccccccccccccd, 0x3333333333333333}, @@ -354,7 +354,7 @@ const divtest_table_entry basic_data::divtest_table_for_pow5_64[] = {0x502e79bf1b6f4f79, 0x0000000000001e39}, {0xdcd618596be30fe5, 0x000000000000060b}}; -template FMT_INSTANTIATION_DEF_API +template const uint64_t basic_data::dragonbox_pow10_significands_64[] = { 0x81ceb32c4b43fcf5, 0xa2425ff75e14fc32, 0xcad2f7f5359a3b3f, 0xfd87b5f28300ca0e, 0x9e74d1b791e07e49, 0xc612062576589ddb, @@ -383,7 +383,7 @@ const uint64_t basic_data::dragonbox_pow10_significands_64[] = { 0x92efd1b8d0cf37be, 0xb7abc627050305ad, 0xe596b7b0c643c719, 0x8f7e32ce7bea5c6f, 0xb35dbf821ae4f38b, 0xe0352f62a19e306e}; -template FMT_INSTANTIATION_DEF_API +template const uint128_wrapper basic_data::dragonbox_pow10_significands_128[] = { #if FMT_USE_FULL_CACHE_DRAGONBOX {0xff77b1fcbebcdc4f, 0x25e8e89c13bb0f7b}, @@ -1045,7 +1045,7 @@ const uint64_t basic_data::powers_of_5_64[] = { 0x0001b1ae4d6e2ef5, 0x000878678326eac9, 0x002a5a058fc295ed, 0x00d3c21bcecceda1, 0x0422ca8b0a00a425, 0x14adf4b7320334b9}; -template FMT_INSTANTIATION_DEF_API +template const uint32_t basic_data::dragonbox_pow10_recovery_errors[] = { 0x50001400, 0x54044100, 0x54014555, 0x55954415, 0x54115555, 0x00000001, 0x50000000, 0x00104000, 0x54010004, 0x05004001, 0x55555544, 0x41545555, @@ -1056,19 +1056,19 @@ const uint32_t basic_data::dragonbox_pow10_recovery_errors[] = { 0x69514555, 0x05151109, 0x00155555}; #endif -template FMT_INSTANTIATION_DEF_API +template const char basic_data::foreground_color[] = "\x1b[38;2;"; -template FMT_INSTANTIATION_DEF_API +template const char basic_data::background_color[] = "\x1b[48;2;"; -template FMT_INSTANTIATION_DEF_API const char basic_data::reset_color[] = "\x1b[0m"; -template FMT_INSTANTIATION_DEF_API const wchar_t basic_data::wreset_color[] = L"\x1b[0m"; -template FMT_INSTANTIATION_DEF_API const char basic_data::signs[] = {0, '-', '+', ' '}; +template const char basic_data::reset_color[] = "\x1b[0m"; +template const wchar_t basic_data::wreset_color[] = L"\x1b[0m"; +template const char basic_data::signs[] = {0, '-', '+', ' '}; #if __cplusplus < 201703L -template FMT_INSTANTIATION_DEF_API constexpr const char basic_data::hex_digits[]; -template FMT_INSTANTIATION_DEF_API constexpr const unsigned basic_data::prefixes[]; -template FMT_INSTANTIATION_DEF_API constexpr const char basic_data::left_padding_shifts[]; -template FMT_INSTANTIATION_DEF_API +template constexpr const char basic_data::hex_digits[]; +template constexpr const unsigned basic_data::prefixes[]; +template constexpr const char basic_data::left_padding_shifts[]; +template constexpr const char basic_data::right_padding_shifts[]; #endif