summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorcharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2015-05-26 08:06:51 +0000
committercharlet <charlet@138bc75d-0d04-0410-961f-82ee72b054a4>2015-05-26 08:06:51 +0000
commitbbd127e81478d9dc688833397005312b34bbe1c6 (patch)
tree4addf6343913b54f7ff386157aa4217fb0b887c0
parent5f279a1ef073bc36346947593810e039012b51dc (diff)
downloadgcc-bbd127e81478d9dc688833397005312b34bbe1c6.tar.gz
2015-05-26 Robert Dewar <dewar@adacore.com>
* sem_util.adb: Minor code reorganization. * sem_ch6.adb: Minor reformatting. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@223662 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ada/ChangeLog5
-rw-r--r--gcc/ada/sem_ch6.adb2
-rw-r--r--gcc/ada/sem_util.adb14
3 files changed, 14 insertions, 7 deletions
diff --git a/gcc/ada/ChangeLog b/gcc/ada/ChangeLog
index f75ecf0a37a..92decca3440 100644
--- a/gcc/ada/ChangeLog
+++ b/gcc/ada/ChangeLog
@@ -1,3 +1,8 @@
+2015-05-26 Robert Dewar <dewar@adacore.com>
+
+ * sem_util.adb: Minor code reorganization.
+ * sem_ch6.adb: Minor reformatting.
+
2015-05-25 Eric Botcazou <ebotcazou@adacore.com>
* gcc-interface/utils.c (maybe_pad_type): Do not apply adjustment to
diff --git a/gcc/ada/sem_ch6.adb b/gcc/ada/sem_ch6.adb
index 5e3be75ae98..2c7552eafa8 100644
--- a/gcc/ada/sem_ch6.adb
+++ b/gcc/ada/sem_ch6.adb
@@ -10538,7 +10538,7 @@ package body Sem_Ch6 is
---------------------
procedure Set_Formal_Mode (Formal_Id : Entity_Id) is
- Spec : constant Node_Id := Parent (Formal_Id);
+ Spec : constant Node_Id := Parent (Formal_Id);
Id : constant Entity_Id := Scope (Formal_Id);
begin
diff --git a/gcc/ada/sem_util.adb b/gcc/ada/sem_util.adb
index 5f6f464c1ff..b823d8006d1 100644
--- a/gcc/ada/sem_util.adb
+++ b/gcc/ada/sem_util.adb
@@ -2128,18 +2128,19 @@ package body Sem_Util is
elsif Nkind (Parent (N)) = N_Component_Association
and then Nkind_In (Parent (Parent (N)),
- N_Aggregate,
- N_Extension_Aggregate)
+ N_Aggregate,
+ N_Extension_Aggregate)
then
declare
Choice : constant Node_Id := First (Choices (Parent (N)));
+
begin
if Ekind (Entity (N)) = E_Discriminant then
return Skip;
elsif Expression (Parent (N)) = N
- and then Nkind (Choice) = N_Identifier
- and then Ekind (Entity (Choice)) = E_Discriminant
+ and then Nkind (Choice) = N_Identifier
+ and then Ekind (Entity (Choice)) = E_Discriminant
then
return Skip;
end if;
@@ -2194,9 +2195,10 @@ package body Sem_Util is
-- last (see comment in the body of traverse_func).
declare
- Elmt : Elmt_Id := First_Elmt (Writable_Actuals_List);
+ Elmt : Elmt_Id;
begin
+ Elmt := First_Elmt (Writable_Actuals_List);
while Present (Elmt)
and then Entity (Node (Elmt)) /= Entity (N)
loop
@@ -2210,7 +2212,7 @@ package body Sem_Util is
end if;
Error_Msg_NE
- ("value may be affected by call to& "
+ ("value may be affected by call to & "
& "because order of evaluation is arbitrary",
Error_Node, Id);
return Abandon;