From 5aee7970fbfc66c2f0f1668ea15671b43166df68 Mon Sep 17 00:00:00 2001 From: Florian Uhlig Date: Tue, 10 Mar 2026 14:36:43 +0100 Subject: [PATCH] Fix FairLogger crash when used with C++23 --- logger/Logger.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/logger/Logger.h b/logger/Logger.h index faa5682..3548677 100644 --- a/logger/Logger.h +++ b/logger/Logger.h @@ -244,9 +244,10 @@ class Logger bgWhite = 107 }; - static std::string startColor(Color color) { return fmt::format("\033[01;{}m", static_cast(color)); } + static std::string startColor(Color color) { return fmt::format(fmt::runtime("\033[01;{}m"), static_cast(color)); } + static std::string endColor() { return "\033[0m"; } - static std::string ColorOut(Color c, std::string_view s) { return fmt::format("\033[01;{}m{}\033[0m", static_cast(c), s); } + static std::string ColorOut(Color c, std::string_view s) { return fmt::format(fmt::runtime("\033[01;{}m{}\033[0m"), static_cast(c), s); } static std::string GetColoredSeverityString(Severity severity); static void SetConsoleSeverity(const Severity severity);