From: Jason Merrill Date: Tue, 3 Apr 2018 17:41:17 +0000 (-0400) Subject: * semantics.c (finish_if_stmt_cond): Use instantiation_dependent_expression_p. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=83afe9b528896ba26d774839c930098f4833cb87;p=gcc.git * semantics.c (finish_if_stmt_cond): Use instantiation_dependent_expression_p. From-SVN: r259044 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 9dbb215154e..8759dc26642 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,8 @@ 2018-04-03 Jason Merrill + * semantics.c (finish_if_stmt_cond): Use + instantiation_dependent_expression_p. + PR c++/85149 - generic lambda and constexpr if. * pt.c (build_extra_args, add_extra_args): Split from tsubst_pack_expansion. diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c index eef9e2f645d..ef243f6bf0a 100644 --- a/gcc/cp/semantics.c +++ b/gcc/cp/semantics.c @@ -733,7 +733,7 @@ finish_if_stmt_cond (tree cond, tree if_stmt) if (IF_STMT_CONSTEXPR_P (if_stmt) && !type_dependent_expression_p (cond) && require_constant_expression (cond) - && !value_dependent_expression_p (cond) + && !instantiation_dependent_expression_p (cond) /* Wait until instantiation time, since only then COND has been converted to bool. */ && TREE_TYPE (cond) == boolean_type_node)