aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/gcc-interface/decl.c
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2012-10-02 10:34:44 +0000
committerEric Botcazou <ebotcazou@gcc.gnu.org>2012-10-02 10:34:44 +0000
commitf563ce55854c93f9a2b7075d5f84fc6301d41c30 (patch)
treede444b7ca6251b024717d585ae1a2c69dccf2f58 /gcc/ada/gcc-interface/decl.c
parent0f1e88429a98791cd8c5b8d80703fc5f04a80b23 (diff)
downloadgcc-f563ce55854c93f9a2b7075d5f84fc6301d41c30.zip
gcc-f563ce55854c93f9a2b7075d5f84fc6301d41c30.tar.gz
gcc-f563ce55854c93f9a2b7075d5f84fc6301d41c30.tar.bz2
decl.c (elaborate_expression_1): Use the variable for bounds of loop iteraration scheme only for locally defined...
* gcc-interfaces/decl.c (elaborate_expression_1): Use the variable for bounds of loop iteraration scheme only for locally defined subtypes. * gcc-interface/trans.c (gigi): Fix formatting. (build_return_expr): Apply the NRV optimization only for BLKmode. From-SVN: r191971
Diffstat (limited to 'gcc/ada/gcc-interface/decl.c')
-rw-r--r--gcc/ada/gcc-interface/decl.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/ada/gcc-interface/decl.c b/gcc/ada/gcc-interface/decl.c
index 9e14d8a..3935bb3 100644
--- a/gcc/ada/gcc-interface/decl.c
+++ b/gcc/ada/gcc-interface/decl.c
@@ -6165,6 +6165,7 @@ elaborate_expression_1 (tree gnu_expr, Entity_Id gnat_entity, tree gnu_name,
use_variable = expr_variable_p
&& (expr_global_p
|| (!optimize
+ && definition
&& Is_Itype (gnat_entity)
&& Nkind (Associated_Node_For_Itype (gnat_entity))
== N_Loop_Parameter_Specification));