From 8c6dc41cf72960678235a7a321c09e6211b6d595 Mon Sep 17 00:00:00 2001 From: jason Date: Wed, 12 Aug 2015 18:08:45 +0000 Subject: PR c++/67104 * constexpr.c (cxx_eval_array_reference): Fix typo. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@226833 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/cp/ChangeLog | 3 +++ gcc/cp/constexpr.c | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) (limited to 'gcc') diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 07ed20ff628..e8008ce0140 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,8 @@ 2015-08-12 Jason Merrill + PR c++/67104 + * constexpr.c (cxx_eval_array_reference): Fix typo. + PR c++/67104 * constexpr.c (cxx_eval_array_reference): Handle sparse CONSTRUCTORs. diff --git a/gcc/cp/constexpr.c b/gcc/cp/constexpr.c index b6788c7a7c0..6048f062593 100644 --- a/gcc/cp/constexpr.c +++ b/gcc/cp/constexpr.c @@ -1709,7 +1709,7 @@ cxx_eval_array_reference (const constexpr_ctx *ctx, tree t, found = false; vec *v = CONSTRUCTOR_ELTS (ary); constructor_elt *e; - for (unsigned ix = 0; vec_safe_iterate (v, ix, &e); ++i) + for (unsigned ix = 0; vec_safe_iterate (v, ix, &e); ++ix) { if (TREE_CODE (e->index) == RANGE_EXPR) { -- cgit v1.2.1