From c0e12d4437d59dfde7da4aeed2e790040a5f29b1 Mon Sep 17 00:00:00 2001 From: Alexandru Pana Date: Sun, 3 Mar 2019 00:24:54 +0200 Subject: [PATCH] format: Fix compilation with -fno-exceptions --- include/format | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/include/format b/include/format index 1ee6b838..17291a2c 100644 --- a/include/format +++ b/include/format @@ -172,7 +172,7 @@ constexpr void basic_format_parse_context::advance_to(typename basic_form template constexpr size_t basic_format_parse_context::next_arg_id() { if (indexing_ == manual) - throw format_error("manual to automatic indexing"); + FMT_THROW(format_error("manual to automatic indexing")); if (indexing_ == unknown) indexing_ = automatic; return next_arg_id_++; @@ -181,7 +181,7 @@ constexpr size_t basic_format_parse_context::next_arg_id() { template constexpr void basic_format_parse_context::check_arg_id(size_t) { if (indexing_ == automatic) - throw format_error("automatic to manual indexing"); + FMT_THROW(format_error("automatic to manual indexing")); if (indexing_ == unknown) indexing_ = manual; } @@ -490,7 +490,7 @@ class arg_formatter } iterator operator()(monostate) { - throw format_error(""); + FMT_THROW(format_error("")); } };