From: "Marc Poulhiès" <poulhies@adacore.com>
To: gcc-patches@gcc.gnu.org
Cc: Piotr Trojanek <trojanek@adacore.com>
Subject: [Ada] Remove no longer referenced GNATprove utility routine for itypes
Date: Mon, 5 Sep 2022 09:26:11 +0200 [thread overview]
Message-ID: <20220905072611.GA1174790@poulhies-Precision-5550> (raw)
[-- Attachment #1: Type: text/plain, Size: 321 bytes --]
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.
Tested on x86_64-pc-linux-gnu, committed on trunk
gcc/ada/
* sem_util.ads (Itype_Has_Declaration): Remove spec.
* sem_util.adb (Itype_Has_Declaration): Remove body.
[-- Attachment #2: patch.diff --]
[-- Type: text/x-diff, Size: 1527 bytes --]
diff --git a/gcc/ada/sem_util.adb b/gcc/ada/sem_util.adb
--- a/gcc/ada/sem_util.adb
+++ b/gcc/ada/sem_util.adb
@@ -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 --
-------------------------
diff --git a/gcc/ada/sem_util.ads b/gcc/ada/sem_util.ads
--- a/gcc/ada/sem_util.ads
+++ b/gcc/ada/sem_util.ads
@@ -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
reply other threads:[~2022-09-05 7:26 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220905072611.GA1174790@poulhies-Precision-5550 \
--to=poulhies@adacore.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=trojanek@adacore.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).