]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
ada: Remove useless statements
authorRonan Desplanques <desplanques@adacore.com>
Mon, 4 Aug 2025 14:39:39 +0000 (16:39 +0200)
committerMarc Poulhiès <dkm@gcc.gnu.org>
Tue, 9 Sep 2025 12:39:56 +0000 (14:39 +0200)
The initial value of fields of type Elist_Id is No_Elist, therefore the
statements this patch removes were useless.

gcc/ada/ChangeLog:

* sem_ch7.adb (New_Private_Type): Remove useless statements.

gcc/ada/sem_ch7.adb

index d28bafb3378c10594b64995ffa9900cdd9da3566..42abc894a2967cfa25b5d32c18e1343d7708e547 100644 (file)
@@ -2758,9 +2758,6 @@ package body Sem_Ch7 is
 
       Set_Is_Tagged_Type (Id, Tagged_Present (Def));
 
-      Set_Discriminant_Constraint (Id, No_Elist);
-      Set_Stored_Constraint (Id, No_Elist);
-
       if Present (Discriminant_Specifications (N)) then
          Push_Scope (Id);
          Process_Discriminants (N);