From 82246b8766bc9f9ee00a6572245dfcdf43315af9 Mon Sep 17 00:00:00 2001 From: Alexey Ochapov Date: Sat, 18 Dec 2021 00:44:36 +0300 Subject: [PATCH] fix throw with exceptions disabled (#2647) --- include/fmt/format-inl.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/fmt/format-inl.h b/include/fmt/format-inl.h index ec636247..04ded482 100644 --- a/include/fmt/format-inl.h +++ b/include/fmt/format-inl.h @@ -707,7 +707,7 @@ FMT_INLINE FMT_CONSTEXPR20 digits::result grisu_gen_digits( int precision_offset = exp + handler.exp10; if (precision_offset > 0 && handler.precision > max_value() - precision_offset) { - throw format_error("number is too big"); + FMT_THROW(format_error("number is too big")); } handler.precision += precision_offset; // Check if precision is satisfied just by leading zeros, e.g.