Appender doesn't work on wide strings

pull/2544/head
Charles Milette 3 years ago
parent dec4c73eac
commit 2cca4330cc

@ -394,12 +394,8 @@ protected:
{
// format to wmemory_buffer and convert to utf8
wmemory_buf_t wbuf;
# ifdef SPDLOG_USE_STD_FORMAT
fmt_lib::vformat_to(
std::back_inserter(wbuf), fmt, fmt_lib::make_format_args<fmt_lib::wformat_context>(std::forward<Args>(args)...));
# else
fmt::vformat_to(fmt::appender(wbuf), fmt, fmt::make_format_args<fmt::wformat_context>(std::forward<Args>(args)...));
# endif
memory_buf_t buf;
details::os::wstr_to_utf8buf(wstring_view_t(wbuf.data(), wbuf.size()), buf);

Loading…
Cancel
Save