From d7ba6c3ea84316e2dd0615a8266db41534a43275 Mon Sep 17 00:00:00 2001 From: Daniela Engert Date: Mon, 31 May 2021 18:11:24 +0200 Subject: [PATCH] Use qualified name-lookup in module. (#2324) Allow lookup of non-exported names from local classes in function templates. --- include/fmt/chrono.h | 4 ++-- include/fmt/core.h | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/include/fmt/chrono.h b/include/fmt/chrono.h index 7aae7896..5e03149d 100644 --- a/include/fmt/chrono.h +++ b/include/fmt/chrono.h @@ -298,7 +298,7 @@ inline auto do_write(const std::tm& time, const std::locale& loc, char format, auto str = os.str(); if (!detail::is_utf8() || loc == std::locale::classic()) return str; // char16_t and char32_t codecvts are broken in MSVC (linkage errors). - using code_unit = conditional_t; + using code_unit = conditional_t; auto& f = std::use_facet>(loc); auto mb = std::mbstate_t(); const char* from_next = nullptr; @@ -1246,7 +1246,7 @@ struct formatter, Char> { ctx, out, d); f.precision = precision_copy; f.localized = localized; - parse_chrono_format(begin, end, f); + detail::parse_chrono_format(begin, end, f); } return detail::write( ctx.out(), basic_string_view(buf.data(), buf.size()), specs_copy); diff --git a/include/fmt/core.h b/include/fmt/core.h index 8d53d86a..d71a2ab1 100644 --- a/include/fmt/core.h +++ b/include/fmt/core.h @@ -2169,6 +2169,7 @@ FMT_CONSTEXPR FMT_INLINE auto parse_arg_id(const Char* begin, const Char* end, template FMT_CONSTEXPR auto parse_width(const Char* begin, const Char* end, Handler&& handler) -> const Char* { + using detail::auto_id; struct width_adapter { Handler& handler; @@ -2198,6 +2199,7 @@ FMT_CONSTEXPR auto parse_width(const Char* begin, const Char* end, template FMT_CONSTEXPR auto parse_precision(const Char* begin, const Char* end, Handler&& handler) -> const Char* { + using detail::auto_id; struct precision_adapter { Handler& handler;