]> gcc.gnu.org Git - gcc.git/commitdiff
ada: Assertion failure on calculation of Large_Max_Size_Mutable
authorJavier Miranda <miranda@adacore.com>
Mon, 28 Aug 2023 19:14:39 +0000 (19:14 +0000)
committerMarc Poulhiès <poulhies@adacore.com>
Thu, 14 Sep 2023 12:42:39 +0000 (14:42 +0200)
gcc/ada/

* sem_util.adb (Large_Max_Size_Mutable): Protect access to
attribute Is_Array_Type.

gcc/ada/sem_util.adb

index 3229f4e9dd2bdb560a9f30943d3fe63df586d5fc..cc9dcb30b180f23f918fcc087d7b2d17dc8921a7 100644 (file)
@@ -22580,7 +22580,9 @@ package body Sem_Util is
                      Ityp : Entity_Id;
 
                   begin
-                     if Is_Array_Type (Comp_Type) then
+                     if Present (Comp_Type)
+                       and then Is_Array_Type (Comp_Type)
+                     then
                         Indx := First_Index (Comp_Type);
 
                         while Present (Indx) loop
This page took 0.087186 seconds and 5 git commands to generate.