From 68e71cfc497df76cd8d98afdade847f438f1bcd6 Mon Sep 17 00:00:00 2001 From: gabime Date: Mon, 25 Dec 2023 00:03:16 +0200 Subject: [PATCH] Revert "force constexpr of empty source_loc" This reverts commit 7e3700f6508347cdaf32f5d97ff684c518ffdb97. --- include/spdlog/logger.h | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/include/spdlog/logger.h b/include/spdlog/logger.h index 0190a4f3..f733507e 100644 --- a/include/spdlog/logger.h +++ b/include/spdlog/logger.h @@ -77,8 +77,7 @@ public: template void log(level lvl, format_string_t fmt, Args &&...args) { if (should_log(lvl)) { - constexpr source_loc empty_loc{}; - log_with_format_(empty_loc, lvl, details::to_string_view(fmt), + log_with_format_(source_loc{}, lvl, details::to_string_view(fmt), std::forward(args)...); } } @@ -99,8 +98,7 @@ public: void log(level lvl, string_view_t msg) { if (should_log(lvl)) { - constexpr source_loc empty_loc{}; - sink_it_(details::log_msg(empty_loc, name_, lvl, msg)); + sink_it_(details::log_msg(source_loc{}, name_, lvl, msg)); } }