From 4a392adaa7644c5467576a92c376a4c172dd3f0c Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Wed, 17 May 2023 07:47:42 -0700 Subject: [PATCH] Remove basic_printf_parse_context --- include/fmt/printf.h | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/include/fmt/printf.h b/include/fmt/printf.h index 1fb5e0f7..fddcab06 100644 --- a/include/fmt/printf.h +++ b/include/fmt/printf.h @@ -18,11 +18,6 @@ FMT_BEGIN_EXPORT template struct printf_formatter { printf_formatter() = delete; }; -template -class basic_printf_parse_context : public basic_format_parse_context { - using basic_format_parse_context::basic_format_parse_context; -}; - template class basic_printf_context { private: OutputIt out_; @@ -31,7 +26,7 @@ template class basic_printf_context { public: using char_type = Char; using format_arg = basic_format_arg; - using parse_context_type = basic_printf_parse_context; + using parse_context_type = basic_format_parse_context; template using formatter_type = printf_formatter; /** @@ -299,7 +294,7 @@ class printf_arg_formatter : public arg_formatter { /** Formats an argument of a custom (user-defined) type. */ OutputIt operator()(typename basic_format_arg::handle handle) { auto parse_ctx = - basic_printf_parse_context(basic_string_view()); + basic_format_parse_context(basic_string_view()); handle.format(parse_ctx, context_); return this->out; } @@ -416,7 +411,7 @@ void vprintf(buffer& buf, basic_string_view format, using iterator = buffer_appender; auto out = iterator(buf); auto context = basic_printf_context(out, args); - auto parse_ctx = basic_printf_parse_context(format); + auto parse_ctx = basic_format_parse_context(format); // Returns the argument with specified index or, if arg_index is -1, the next // argument.