aboutsummaryrefslogtreecommitdiff
path: root/gcc/ada/einfo.adb
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/ada/einfo.adb')
-rw-r--r--gcc/ada/einfo.adb22
1 files changed, 21 insertions, 1 deletions
diff --git a/gcc/ada/einfo.adb b/gcc/ada/einfo.adb
index 2c9a4ba..285e924 100644
--- a/gcc/ada/einfo.adb
+++ b/gcc/ada/einfo.adb
@@ -558,6 +558,7 @@ package body Einfo is
-- Has_Implicit_Dereference Flag251
-- Is_Processed_Transient Flag252
+ -- Disable_Controlled Flag253
-- Is_Implementation_Defined Flag254
-- Is_Predicate_Function Flag255
-- Is_Predicate_Function_M Flag256
@@ -595,7 +596,6 @@ package body Einfo is
-- Is_Volatile_Full_Access Flag285
-- Needs_Typedef Flag286
- -- (unused) Flag253
-- (unused) Flag287
-- (unused) Flag288
-- (unused) Flag289
@@ -1026,6 +1026,11 @@ package body Einfo is
return Node20 (Id);
end Directly_Designated_Type;
+ function Disable_Controlled (Id : E) return B is
+ begin
+ return Flag253 (Base_Type (Id));
+ end Disable_Controlled;
+
function Discard_Names (Id : E) return B is
begin
return Flag88 (Id);
@@ -3941,6 +3946,12 @@ package body Einfo is
Set_Node20 (Id, V);
end Set_Directly_Designated_Type;
+ procedure Set_Disable_Controlled (Id : E; V : B := True) is
+ begin
+ pragma Assert (Is_Type (Id) and then Is_Base_Type (Id));
+ Set_Flag253 (Id, V);
+ end Set_Disable_Controlled;
+
procedure Set_Discard_Names (Id : E; V : B := True) is
begin
Set_Flag88 (Id, V);
@@ -7394,6 +7405,15 @@ package body Einfo is
K = E_Constant or else K = E_In_Parameter or else K = E_Loop_Parameter;
end Is_Constant_Object;
+ --------------------------
+ -- Is_Controlled_Active --
+ --------------------------
+
+ function Is_Controlled_Active (Id : E) return B is
+ begin
+ return Is_Controlled (Id) and then not Disable_Controlled (Id);
+ end Is_Controlled_Active;
+
--------------------
-- Is_Discriminal --
--------------------