aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason Merrill <jason@redhat.com>2011-06-09 23:55:48 -0400
committerJason Merrill <jason@gcc.gnu.org>2011-06-09 23:55:48 -0400
commitb82972cae2cbba7f8b85517ae4d10d086c0b5de0 (patch)
tree5004f20164b9d3e4af698de8de8e259f98c84a1b
parentb1623cc545933d93b4b34b3159d03554525f6e04 (diff)
downloadgcc-b82972cae2cbba7f8b85517ae4d10d086c0b5de0.zip
gcc-b82972cae2cbba7f8b85517ae4d10d086c0b5de0.tar.gz
gcc-b82972cae2cbba7f8b85517ae4d10d086c0b5de0.tar.bz2
* pt.c (build_non_dependent_expr): Use fold_non_dependent_expr_sfinae.
From-SVN: r174883
-rw-r--r--gcc/cp/ChangeLog2
-rw-r--r--gcc/cp/pt.c2
2 files changed, 3 insertions, 1 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index 4cff258..377780a 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,5 +1,7 @@
2011-06-09 Jason Merrill <jason@redhat.com>
+ * pt.c (build_non_dependent_expr): Use fold_non_dependent_expr_sfinae.
+
* parser.c (cp_parser_constant_expression): Just return the
non-constant expression.
diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c
index 51d590e..ac150ce 100644
--- a/gcc/cp/pt.c
+++ b/gcc/cp/pt.c
@@ -19124,7 +19124,7 @@ build_non_dependent_expr (tree expr)
/* Try to get a constant value for all non-type-dependent expressions in
order to expose bugs in *_dependent_expression_p and constexpr. */
if (cxx_dialect >= cxx0x)
- maybe_constant_value (fold_non_dependent_expr (expr));
+ maybe_constant_value (fold_non_dependent_expr_sfinae (expr, tf_none));
#endif
/* Preserve OVERLOADs; the functions must be available to resolve