]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
[Ada] Remove no longer referenced GNATprove utility routine for itypes
authorPiotr Trojanek <trojanek@adacore.com>
Tue, 26 Jul 2022 20:47:58 +0000 (22:47 +0200)
committerMarc Poulhiès <poulhies@adacore.com>
Mon, 5 Sep 2022 07:21:05 +0000 (09:21 +0200)
Code cleanup related to itypes for Ada 2022 null array aggregates.
Remove routine that was added in 2011 but is not referenced by
GNATprove since 2015.

gcc/ada/

* sem_util.ads (Itype_Has_Declaration): Remove spec.
* sem_util.adb (Itype_Has_Declaration): Remove body.

gcc/ada/sem_util.adb
gcc/ada/sem_util.ads

index e3e42c8521f222b6500ef36bbcda9008e1abc478..ecfb49a06a857a94a3fabe8c5d3086333f988d19 100644 (file)
@@ -22167,19 +22167,6 @@ package body Sem_Util is
       pragma Assert (No (Actual));
    end Iterate_Call_Parameters;
 
-   ---------------------------
-   -- Itype_Has_Declaration --
-   ---------------------------
-
-   function Itype_Has_Declaration (Id : Entity_Id) return Boolean is
-   begin
-      pragma Assert (Is_Itype (Id));
-      return Present (Parent (Id))
-        and then Nkind (Parent (Id)) in
-                   N_Full_Type_Declaration | N_Subtype_Declaration
-        and then Defining_Entity (Parent (Id)) = Id;
-   end Itype_Has_Declaration;
-
    -------------------------
    -- Kill_Current_Values --
    -------------------------
index dde5b27faa33bac9758d6961826bc943c41179e0..9f909e0dff2dfee1de973f731a27522ba991194c 100644 (file)
@@ -2561,11 +2561,6 @@ package Sem_Util is
    --  Calls Handle_Parameter for each pair of formal and actual parameters of
    --  a function, procedure, or entry call.
 
-   function Itype_Has_Declaration (Id : Entity_Id) return Boolean;
-   --  Applies to Itypes. True if the Itype is attached to a declaration for
-   --  the type through its Parent field, which may or not be present in the
-   --  tree.
-
    procedure Kill_Current_Values (Last_Assignment_Only : Boolean := False);
    --  This procedure is called to clear all constant indications from all
    --  entities in the current scope and in any parent scopes if the current