summaryrefslogtreecommitdiffstats
path: root/gcc/gimplify.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/gimplify.c')
-rw-r--r--gcc/gimplify.c15
1 files changed, 6 insertions, 9 deletions
diff --git a/gcc/gimplify.c b/gcc/gimplify.c
index 6b654be9c11..32d07f0cc84 100644
--- a/gcc/gimplify.c
+++ b/gcc/gimplify.c
@@ -3328,7 +3328,7 @@ gimplify_init_ctor_preeval (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p,
constructor_elt *ce;
VEC(constructor_elt,gc) *v = CONSTRUCTOR_ELTS (*expr_p);
- for (ix = 0; VEC_iterate (constructor_elt, v, ix, ce); ix++)
+ FOR_EACH_VEC_ELT (constructor_elt, v, ix, ce)
gimplify_init_ctor_preeval (&ce->value, pre_p, post_p, data);
return;
@@ -3957,7 +3957,7 @@ gimplify_init_constructor (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p,
/* Vector types use CONSTRUCTOR all the way through gimple
compilation as a general initializer. */
- for (ix = 0; VEC_iterate (constructor_elt, elts, ix, ce); ix++)
+ FOR_EACH_VEC_ELT (constructor_elt, elts, ix, ce)
{
enum gimplify_status tret;
tret = gimplify_expr (&ce->value, pre_p, post_p, is_gimple_val,
@@ -6918,14 +6918,11 @@ gimplify_expr (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p,
if (fallback == fb_none)
{
unsigned HOST_WIDE_INT ix;
- constructor_elt *ce;
+ tree val;
tree temp = NULL_TREE;
- for (ix = 0;
- VEC_iterate (constructor_elt, CONSTRUCTOR_ELTS (*expr_p),
- ix, ce);
- ix++)
- if (TREE_SIDE_EFFECTS (ce->value))
- append_to_statement_list (ce->value, &temp);
+ FOR_EACH_CONSTRUCTOR_VALUE (CONSTRUCTOR_ELTS (*expr_p), ix, val)
+ if (TREE_SIDE_EFFECTS (val))
+ append_to_statement_list (val, &temp);
*expr_p = temp;
ret = temp ? GS_OK : GS_ALL_DONE;
OpenPOWER on IntegriCloud