mirror of
git://gcc.gnu.org/git/gcc.git
synced 2025-04-21 15:40:55 +08:00
[Ada] Fix oversight in Delayed_Aspect_Present predicate
gcc/ada/ * sem_ch3.adb (Delayed_Aspect_Present): Fix oversight in loop. * freeze.adb (Freeze_Object_Declaration): Use Declaration_Node instead of Parent for the sake of consistency.
This commit is contained in:
parent
3a9222bcb3
commit
bdeeeaf71f
@ -3439,11 +3439,11 @@ package body Freeze is
|
||||
if Has_Delayed_Aspects (E)
|
||||
and then Expander_Active
|
||||
and then Is_Array_Type (Typ)
|
||||
and then Present (Expression (Parent (E)))
|
||||
and then Present (Expression (Declaration_Node (E)))
|
||||
and then No (Linker_Section_Pragma (E))
|
||||
then
|
||||
declare
|
||||
Decl : constant Node_Id := Parent (E);
|
||||
Decl : constant Node_Id := Declaration_Node (E);
|
||||
Lhs : constant Node_Id := New_Occurrence_Of (E, Loc);
|
||||
|
||||
begin
|
||||
|
@ -3891,9 +3891,11 @@ package body Sem_Ch3 is
|
||||
|
||||
begin
|
||||
if Present (Aspect_Specifications (N)) then
|
||||
A := First (Aspect_Specifications (N));
|
||||
A_Id := Get_Aspect_Id (Chars (Identifier (A)));
|
||||
A := First (Aspect_Specifications (N));
|
||||
|
||||
while Present (A) loop
|
||||
A_Id := Get_Aspect_Id (Chars (Identifier (A)));
|
||||
|
||||
if A_Id = Aspect_Alignment or else A_Id = Aspect_Address then
|
||||
|
||||
-- Set flag on object entity, for later processing at
|
||||
|
Loading…
x
Reference in New Issue
Block a user