summaryrefslogtreecommitdiff
path: root/gcc/ada/exp_ch6.adb
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2012-07-17 10:16:59 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2012-07-17 10:16:59 +0000
commit4f19349e0d44df6e45ce246ebbb2967f91a4f6ed (patch)
treebb226c2fdd284b0e5fdb8ba483fd2147154cd2c6 /gcc/ada/exp_ch6.adb
parenteb87f0fd42a1c80fe8a4779a6822626ac6b68308 (diff)
downloadgcc-4f19349e0d44df6e45ce246ebbb2967f91a4f6ed.tar.gz
2012-07-17 Vincent Pucci <pucci@adacore.com>
* gnat_ugn.texi: GNAT dimensionality checking documentation updated with System.Dim.Mks modifications. 2012-07-17 Ed Schonberg <schonberg@adacore.com> * exp_ch3.adb: sloc of array init_proc is sloc of type declaration. 2012-07-17 Tristan Gingold <gingold@adacore.com> * raise-gcc.c (get_call_site_action_for): Remove useless init expression for p. (get_action_description_for): Do not overwrite action->kind. 2012-07-17 Hristian Kirtchev <kirtchev@adacore.com> * exp_attr.adb (Expand_N_Attribute_Reference): Add local variables Attr and Conversion_Added. Add local constant Typ. Retrieve the original attribute after the arithmetic check machinery has modified the node. Add a conversion to the target type when the prefix of attribute Max_Size_In_Storage_Elements is a controlled type. 2012-07-17 Gary Dismukes <dismukes@adacore.com> * exp_ch6.adb (Expand_Inlined_Call): For each actual parameter of mode 'out' or 'in out' that denotes an entity, reset Last_Assignment on the entity so that any assignments to the corresponding formal in the inlining will not trigger spurious warnings about overwriting assignments. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@189570 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/ada/exp_ch6.adb')
-rw-r--r--gcc/ada/exp_ch6.adb10
1 files changed, 10 insertions, 0 deletions
diff --git a/gcc/ada/exp_ch6.adb b/gcc/ada/exp_ch6.adb
index eb37fa3c2fa..bbf212698a7 100644
--- a/gcc/ada/exp_ch6.adb
+++ b/gcc/ada/exp_ch6.adb
@@ -4846,6 +4846,16 @@ package body Exp_Ch6 is
return;
end if;
+ -- Reset Last_Assignment for any parameters of mode out or in out, to
+ -- prevent spurious warnings about overwriting for assignments to the
+ -- formal in the inlined code.
+
+ if Is_Entity_Name (A)
+ and then Ekind (F) /= E_In_Parameter
+ then
+ Set_Last_Assignment (Entity (A), Empty);
+ end if;
+
-- If the argument may be a controlling argument in a call within
-- the inlined body, we must preserve its classwide nature to insure
-- that dynamic dispatching take place subsequently. If the formal