From fc1b0f3486b8db0da34c10b544382471075cf627 Mon Sep 17 00:00:00 2001 From: Victor Zverovich Date: Sun, 5 Jan 2025 07:31:19 -1000 Subject: [PATCH] Clarify use of FMT_THROW in a comment --- include/fmt/format-inl.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/include/fmt/format-inl.h b/include/fmt/format-inl.h index 62ea03ab..14c65a09 100644 --- a/include/fmt/format-inl.h +++ b/include/fmt/format-inl.h @@ -134,6 +134,8 @@ FMT_FUNC auto write_loc(appender out, loc_value value, FMT_FUNC void report_error(const char* message) { #if FMT_USE_EXCEPTIONS + // Use FMT_THROW instead of throw to avoid bogus unreachable code warnings + // from MSVC. FMT_THROW(format_error(message)); #else fputs(message, stderr);