diff options
Diffstat (limited to 'gcc/tree-nested.c')
-rw-r--r-- | gcc/tree-nested.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/tree-nested.c b/gcc/tree-nested.c index 1b52669..addd6ee 100644 --- a/gcc/tree-nested.c +++ b/gcc/tree-nested.c @@ -1214,7 +1214,6 @@ convert_nonlocal_reference_op (tree *tp, int *walk_subtrees, void *data) save_context = current_function_decl; current_function_decl = info->context; recompute_tree_invariant_for_addr_expr (t); - current_function_decl = save_context; /* If the callback converted the address argument in a context where we only accept variables (and min_invariant, presumably), @@ -1222,6 +1221,7 @@ convert_nonlocal_reference_op (tree *tp, int *walk_subtrees, void *data) if (save_val_only) *tp = gsi_gimplify_val ((struct nesting_info *) wi->info, t, &wi->gsi); + current_function_decl = save_context; } } break; @@ -1969,13 +1969,13 @@ convert_local_reference_op (tree *tp, int *walk_subtrees, void *data) save_context = current_function_decl; current_function_decl = info->context; recompute_tree_invariant_for_addr_expr (t); - current_function_decl = save_context; /* If we are in a context where we only accept values, then compute the address into a temporary. */ if (save_val_only) *tp = gsi_gimplify_val ((struct nesting_info *) wi->info, t, &wi->gsi); + current_function_decl = save_context; } break; |