From 29235d9b4b573a1a4b906120e71de6ec81e9679f Mon Sep 17 00:00:00 2001 From: gabime Date: Mon, 19 Jul 2021 01:15:53 +0300 Subject: [PATCH] minor string_view change and comment --- include/spdlog/logger.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/spdlog/logger.h b/include/spdlog/logger.h index 89ea0fb0..da5bf274 100644 --- a/include/spdlog/logger.h +++ b/include/spdlog/logger.h @@ -328,8 +328,8 @@ protected: SPDLOG_TRY { memory_buf_t buf; - // faster than fmt::format_to(std::back_inserter(buf), fmt, std::forward(args)...); - fmt::detail::vformat_to(buf, fmt::string_view(fmt), fmt::make_format_args(args...), {}); + // little bit faster than fmt::format_to(std::back_inserter(buf), fmt, std::forward(args)...); + fmt::detail::vformat_to(buf, string_view_t{fmt}, fmt::make_format_args(args...), {}); details::log_msg log_msg(loc, name_, lvl, string_view_t(buf.data(), buf.size())); log_it_(log_msg, log_enabled, traceback_enabled); }