From cbad2a6cb8b0763a325273a870baf85f3e8e4fa7 Mon Sep 17 00:00:00 2001 From: matthesoundman <52799792+matthesoundman@users.noreply.github.com> Date: Sun, 19 Apr 2020 17:22:52 -0700 Subject: [PATCH] Update to include funcname When logging with ```SPDLOG_LOGGER_``` macro the ```funcname``` is missing. Updated ```full_formatter``` to include the funcname if source location is present. --- include/spdlog/pattern_formatter-inl.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/spdlog/pattern_formatter-inl.h b/include/spdlog/pattern_formatter-inl.h index e68b91be..c4d1d9d0 100644 --- a/include/spdlog/pattern_formatter-inl.h +++ b/include/spdlog/pattern_formatter-inl.h @@ -978,6 +978,8 @@ public: fmt_helper::append_string_view(filename, dest); dest.push_back(':'); fmt_helper::append_int(msg.source.line, dest); + dest.push_back(':'); + fmt_helper::append_string_view(msg.source.funcname, dest); dest.push_back(']'); dest.push_back(' '); }