fix throw with exceptions disabled

This commit is contained in:
Alexey Ochapov 2021-12-13 02:54:10 +03:00
parent 3a951a66cb
commit a1cb6bf949
No known key found for this signature in database
GPG Key ID: 9DC52E8F031B8DA8

View File

@ -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<int>() - 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.