aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada
diff options
context:
space:
mode:
authorBob Duff <duff@adacore.com>2023-01-13 08:03:08 -0500
committerMarc Poulhiès <poulhies@adacore.com>2023-05-15 11:36:42 +0200
commit51e8f41212cfdffef374f9a5e916a19702cdecd1 (patch)
tree185a95c54526be25a781ed6c5d2445d88c18ff7f /gcc/ada
parentd2a1dcf72f793d671512bd5638d5b66eb19e8ca6 (diff)
downloadgcc-51e8f41212cfdffef374f9a5e916a19702cdecd1.zip
gcc-51e8f41212cfdffef374f9a5e916a19702cdecd1.tar.gz
gcc-51e8f41212cfdffef374f9a5e916a19702cdecd1.tar.bz2
ada: Improve comment on First_Entity
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.
Diffstat (limited to 'gcc/ada')
-rw-r--r--gcc/ada/einfo.ads11
1 files changed, 6 insertions, 5 deletions
diff --git a/gcc/ada/einfo.ads b/gcc/ada/einfo.ads
index 878737c..6748533 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