[gcc r15-1155] ada: For freezing, treat an extension or delta aggregate like a regular aggregate.

Marc Poulhi?s dkm@gcc.gnu.org
Mon Jun 10 09:09:10 GMT 2024


https://gcc.gnu.org/g:f32d2d14452a9d7ca704f866a86da43865c966bd

commit r15-1155-gf32d2d14452a9d7ca704f866a86da43865c966bd
Author: Steve Baird <baird@adacore.com>
Date:   Tue Apr 16 15:45:45 2024 -0700

    ada: For freezing, treat an extension or delta aggregate like a regular aggregate.
    
    Extend existing special freezing rules for regular aggregates to also apply to
    extension and delta aggregates.
    
    gcc/ada/
    
            * freeze.adb
            (Should_Freeze_Type.Is_Dispatching_Call_Or_Aggregate): Treat an extension
            aggregate or a delta aggregate like a regular aggregate.

Diff:
---
 gcc/ada/freeze.adb | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/gcc/ada/freeze.adb b/gcc/ada/freeze.adb
index ea18f87a4ab..c872050dd35 100644
--- a/gcc/ada/freeze.adb
+++ b/gcc/ada/freeze.adb
@@ -222,7 +222,9 @@ package body Freeze is
                       = Scope (Typ)
          then
             return Abandon;
-         elsif Nkind (N) = N_Aggregate
+         elsif Nkind (N) in N_Aggregate
+                          | N_Extension_Aggregate
+                          | N_Delta_Aggregate
            and then Base_Type (Etype (N)) = Base_Type (Typ)
          then
             return Abandon;


More information about the Gcc-cvs mailing list