* [COMMITTED] ada: Improve comment on First_Entity
@ 2023-05-15 9:44 Marc Poulhiès
0 siblings, 0 replies; only message in thread
From: Marc Poulhiès @ 2023-05-15 9:44 UTC (permalink / raw)
To: gcc-patches; +Cc: Bob Duff
From: Bob Duff <duff@adacore.com>
Clarify that "act as scope" overlaps with "[sub]type".
gcc/ada/
* einfo.ads:
(First_Entity): Update comment explaining why this exists on all
[sub]types, as opposed to just the ones with associated entities.
Tested on x86_64-pc-linux-gnu, committed on master.
---
gcc/ada/einfo.ads | 11 ++++++-----
1 file changed, 6 insertions(+), 5 deletions(-)
diff --git a/gcc/ada/einfo.ads b/gcc/ada/einfo.ads
index 878737c7cc1..6748533a32c 100644
--- a/gcc/ada/einfo.ads
+++ b/gcc/ada/einfo.ads
@@ -1347,11 +1347,12 @@ package Einfo is
-- First_Entity
-- Defined in all entities that act as scopes to which a list of
--- associated entities is attached. This is defined in all [sub]types,
--- including things like scalars that cannot have nested entities,
--- which makes it more convenient to Mutate_Entity between type kinds.
--- Points to a list of associated entities using the Next_Entity field
--- as a chain pointer with Empty marking the end of the list.
+-- associated entities is attached, and also in all [sub]types. Some
+-- entities are both; for example E_Record_Type acts as a scope and
+-- is a type. [Sub]types that do not act as scopes (e.g. scalars) are
+-- included to make it more convenient to Mutate_Entity between type
+-- kinds. Points to a list of associated entities linked through the
+-- Next_Entity field with Empty marking end-of-list.
-- See also Last_Entity.
-- First_Exit_Statement
--
2.40.0
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-05-15 9:44 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-15 9:44 [COMMITTED] ada: Improve comment on First_Entity Marc Poulhiès
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).