aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/einfo.ads
diff options
context:
space:
mode:
authorEric Botcazou <ebotcazou@adacore.com>2023-11-28 20:46:00 +0100
committerMarc Poulhiès <poulhies@adacore.com>2023-12-19 15:27:49 +0100
commit80a63cc744e9f16ace1e007f8973e97448742335 (patch)
treeceeea92d3707049a5bccbc69213209b8dcae5253 /gcc/ada/einfo.ads
parent35ef3e08ec5bc03fe2cb80efc3271168bc6d419e (diff)
downloadgcc-80a63cc744e9f16ace1e007f8973e97448742335.zip
gcc-80a63cc744e9f16ace1e007f8973e97448742335.tar.gz
gcc-80a63cc744e9f16ace1e007f8973e97448742335.tar.bz2
ada: Rename Is_Constr_Subt_For_UN_Aliased flag
The flag is set on the constructed subtype of an object with unconstrained nominal subtype that is aliased and is used by the code generator to adjust the layout of the object. But it is actually only used for array subtypes, where it determines whether the object is allocated with its bounds, and this usage could be extended to other cases than the original case. gcc/ada/ * einfo.ads (Is_Constr_Subt_For_UN_Aliased): Rename into... (Is_Constr_Array_Subt_With_Bounds): ...this. * exp_ch3.adb (Expand_N_Object_Declaration): Adjust to above renaming and remove now redundant test. * sem_ch3.adb (Analyze_Object_Declaration): Likewise, but set Is_Constr_Array_Subt_With_Bounds only on arrays. * gen_il-fields.ads (Opt_Field_Enum): Apply same renaming. * gen_il-gen-gen_entities.adb (Entity_Kind): Likewise. * gen_il-internals.adb (Image): Remove specific processing for Is_Constr_Subt_For_UN_Aliased. * treepr.adb (Image): Likewise. * gcc-interface/decl.cc (gnat_to_gnu_entity): Adjust to renaming and remove now redundant tests. * gcc-interface/trans.cc (Identifier_to_gnu): Likewise. (Call_to_gnu): Likewise.
Diffstat (limited to 'gcc/ada/einfo.ads')
-rw-r--r--gcc/ada/einfo.ads14
1 files changed, 7 insertions, 7 deletions
diff --git a/gcc/ada/einfo.ads b/gcc/ada/einfo.ads
index 1dd5549..d08f02b 100644
--- a/gcc/ada/einfo.ads
+++ b/gcc/ada/einfo.ads
@@ -2474,17 +2474,17 @@ package Einfo is
-- and subtypes, string types and subtypes, and all numeric types).
-- Set if the type or subtype is constrained.
+-- Is_Constr_Array_Subt_With_Bounds
+-- Defined in all types and subtypes. Set only for an array subtype
+-- which is constrained but nevertheless requires objects of this
+-- subtype to be allocated with their bounds. This flag is used by
+-- the back end to determine whether the bounds must be constructed.
+
-- Is_Constr_Subt_For_U_Nominal
-- Defined in all types and subtypes. Set only for the constructed
-- subtype of an object whose nominal subtype is unconstrained. Note
-- that the constructed subtype itself will be constrained.
--- Is_Constr_Subt_For_UN_Aliased
--- Defined in all types and subtypes. This flag can be set only if
--- Is_Constr_Subt_For_U_Nominal is also set. It indicates that in
--- addition the object concerned is aliased. This flag is used by
--- the backend to determine whether a template must be constructed.
-
-- Is_Constructor
-- Defined in function and procedure entities. Set if a pragma
-- CPP_Constructor applies to the subprogram.
@@ -5058,8 +5058,8 @@ package Einfo is
-- Is_Abstract_Type
-- Is_Asynchronous
-- Is_Atomic
+ -- Is_Constr_Array_Subt_With_Bounds
-- Is_Constr_Subt_For_U_Nominal
- -- Is_Constr_Subt_For_UN_Aliased
-- Is_Controlled_Active (base type only)
-- Is_Eliminated
-- Is_Frozen