From 5c4b0c86fbf5ba7dc15508bb0d118cf6301371a5 Mon Sep 17 00:00:00 2001 From: Matthew Gilbert Date: Thu, 20 May 2021 20:02:33 -0400 Subject: [PATCH] Add missing Allocator template argument for basic_memory_buffer in format_to Remove deduced default template arguments in format_to and moves the SFINAE check to a non-deduced template parameter. --- include/fmt/format.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/include/fmt/format.h b/include/fmt/format.h index bbaef4b0..2acbd682 100644 --- a/include/fmt/format.h +++ b/include/fmt/format.h @@ -2699,10 +2699,10 @@ inline void vformat_to( return detail::vformat_to(buf, to_string_view(format_str), args); } -template ::value, char_t>> -inline auto format_to(basic_memory_buffer& buf, const S& format_str, - Args&&... args) -> +template ::value)> +inline auto format_to(basic_memory_buffer& buf, + const S& format_str, Args&&... args) -> typename buffer_context::iterator { const auto& vargs = fmt::make_args_checked(format_str, args...); detail::vformat_to(buf, to_string_view(format_str), vargs);