From c945ee252888acdc9a06c41e42a1089543e53bfa Mon Sep 17 00:00:00 2001 From: Jason Merrill Date: Fri, 2 Mar 2018 13:18:13 -0500 Subject: [PATCH] * semantics.c (force_paren_expr): Remove redundant test. From-SVN: r258151 --- gcc/cp/ChangeLog | 4 ++++ gcc/cp/semantics.c | 3 +-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 112e13a9672..116434282c8 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +2018-03-02 Jason Merrill + + * semantics.c (force_paren_expr): Remove redundant test. + 2018-03-02 Marek Polacek PR c++/84663 diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c index 1ac1d23e761..bf5b41e0879 100644 --- a/gcc/cp/semantics.c +++ b/gcc/cp/semantics.c @@ -1693,8 +1693,7 @@ force_paren_expr (tree expr) if (TREE_CODE (expr) == COMPONENT_REF || TREE_CODE (expr) == SCOPE_REF) REF_PARENTHESIZED_P (expr) = true; - else if (type_dependent_expression_p (expr) - || processing_template_decl) + else if (processing_template_decl) expr = build1 (PAREN_EXPR, TREE_TYPE (expr), expr); else if (VAR_P (expr) && DECL_HARD_REGISTER (expr)) /* We can't bind a hard register variable to a reference. */; -- 2.30.2