aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.8/gcc/cp/except.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc-4.8/gcc/cp/except.c')
-rw-r--r--gcc-4.8/gcc/cp/except.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gcc-4.8/gcc/cp/except.c b/gcc-4.8/gcc/cp/except.c
index 216ec103f..604f274fb 100644
--- a/gcc-4.8/gcc/cp/except.c
+++ b/gcc-4.8/gcc/cp/except.c
@@ -380,6 +380,9 @@ build_must_not_throw_expr (tree body, tree cond)
{
tree type = body ? TREE_TYPE (body) : void_type_node;
+ if (!flag_exceptions)
+ return body;
+
if (cond && !value_dependent_expression_p (cond))
{
cond = cxx_constant_value (cond);