Remove fmt_helper::to_string

This commit is contained in:
Charles Milette 2022-04-26 23:27:55 -04:00
parent cd4f6c1466
commit 8338a48c5b
No known key found for this signature in database
GPG Key ID: 1A5AE81377AD973A

View File

@ -23,20 +23,6 @@ inline spdlog::string_view_t to_string_view(const memory_buf_t &buf) SPDLOG_NOEX
return spdlog::string_view_t{buf.data(), buf.size()}; return spdlog::string_view_t{buf.data(), buf.size()};
} }
#ifdef SPDLOG_USE_STD_FORMAT
template<typename T>
std::basic_string<T> to_string(std::basic_string<T> &&buf)
{
return std::move(buf);
}
#else
template<typename T, size_t Size>
std::basic_string<T> to_string(fmt::basic_memory_buffer<T, Size> &&buf)
{
return fmt::to_string(buf);
}
#endif
inline void append_string_view(spdlog::string_view_t view, memory_buf_t &dest) inline void append_string_view(spdlog::string_view_t view, memory_buf_t &dest)
{ {
auto *buf_ptr = view.data(); auto *buf_ptr = view.data();