From 659d088d61718255547f83709f5cebc868c60708 Mon Sep 17 00:00:00 2001 From: Pablo Hoch Date: Wed, 12 Feb 2025 16:24:36 +0100 Subject: [PATCH] scoped_timer: fix moved string --- src/timer.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/timer.cc b/src/timer.cc index 8c81596..f268eaa 100644 --- a/src/timer.cc +++ b/src/timer.cc @@ -6,7 +6,7 @@ namespace utl { scoped_timer::scoped_timer(std::string name) : name_{std::move(name)}, start_{std::chrono::steady_clock::now()} { - utl::log_info("scoped_timer", "[{}] starting", name); + utl::log_info("scoped_timer", "[{}] starting", name_); } scoped_timer::~scoped_timer() { @@ -50,4 +50,4 @@ void manual_timer::print(std::string_view const message) const { utl::log_info("scoped_timer", "[{}] {} ({}ms)", name_, message, t); } -} // namespace utl \ No newline at end of file +} // namespace utl