1 ------------------------------------------------------------------------------
3 -- GNAT COMPILER COMPONENTS --
9 -- Copyright (C) 1992-2010, Free Software Foundation, Inc. --
11 -- GNAT is free software; you can redistribute it and/or modify it under --
12 -- terms of the GNU General Public License as published by the Free Soft- --
13 -- ware Foundation; either version 3, or (at your option) any later ver- --
14 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
15 -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
16 -- or FITNESS FOR A PARTICULAR PURPOSE. --
18 -- As a special exception under Section 7 of GPL version 3, you are granted --
19 -- additional permissions described in the GCC Runtime Library Exception, --
20 -- version 3.1, as published by the Free Software Foundation. --
22 -- You should have received a copy of the GNU General Public License and --
23 -- a copy of the GCC Runtime Library Exception along with this program; --
24 -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
25 -- <http://www.gnu.org/licenses/>. --
27 -- GNAT was originally developed by the GNAT team at New York University. --
28 -- Extensive contributions were provided by Ada Core Technologies Inc. --
30 ------------------------------------------------------------------------------
32 pragma Style_Checks (All_Checks);
33 -- Turn off subprogram ordering, not used for this unit
35 with Atree; use Atree;
36 with Nlists; use Nlists;
37 with Output; use Output;
38 with Sinfo; use Sinfo;
39 with Stand; use Stand;
43 use Atree.Unchecked_Access;
44 -- This is one of the packages that is allowed direct untyped access to
45 -- the fields in a node, since it provides the next level abstraction
46 -- which incorporates appropriate checks.
48 ----------------------------------------------
49 -- Usage of Fields in Defining Entity Nodes --
50 ----------------------------------------------
52 -- Four of these fields are defined in Sinfo, since they in are the base
53 -- part of the node. The access routines for these four fields and the
54 -- corresponding set procedures are defined in Sinfo. These fields are
55 -- present in all entities. Note that Homonym is also in the base part of
56 -- the node, but has access routines that are more properly part of Einfo,
57 -- which is why they are defined here.
64 -- Remaining fields are present only in extended nodes (i.e. entities)
66 -- The following fields are present in all entities
69 -- First_Rep_Item Node6
72 -- The usage of other fields (and the entity kinds to which it applies)
73 -- depends on the particular field (see Einfo spec for details).
75 -- Associated_Node_For_Itype Node8
76 -- Dependent_Instances Elist8
77 -- Hiding_Loop_Variable Node8
78 -- Mechanism Uint8 (but returns Mechanism_Type)
79 -- Normalized_First_Bit Uint8
80 -- Postcondition_Proc Node8
81 -- Return_Applies_To Node8
82 -- First_Exit_Statement Node8
84 -- Class_Wide_Type Node9
85 -- Current_Value Node9
88 -- Direct_Primitive_Operations Elist10
89 -- Discriminal_Link Node10
90 -- Handler_Records List10
91 -- Normalized_Position_Max Uint10
93 -- Component_Bit_Offset Uint11
95 -- Entry_Component Node11
96 -- Enumeration_Pos Uint11
97 -- Generic_Homonym Node11
98 -- Protected_Body_Subprogram Node11
101 -- Barrier_Function Node12
102 -- Enumeration_Rep Uint12
104 -- Next_Inlined_Subprogram Node12
106 -- Corresponding_Equality Node13
107 -- Component_Clause Node13
108 -- Elaboration_Entity Node13
109 -- Extra_Accessibility Node13
113 -- First_Optional_Parameter Node14
114 -- Normalized_Position Uint14
115 -- Shadow_Entities List14
117 -- Discriminant_Number Uint15
118 -- DT_Position Uint15
119 -- DT_Entry_Count Uint15
120 -- Entry_Bodies_Array Node15
121 -- Entry_Parameters_Type Node15
122 -- Extra_Formal Node15
123 -- Lit_Indexes Node15
124 -- Related_Instance Node15
125 -- Scale_Value Uint15
126 -- Storage_Size_Variable Node15
127 -- String_Literal_Low_Bound Node15
129 -- Access_Disp_Table Elist16
130 -- Cloned_Subtype Node16
132 -- Entry_Formal Node16
133 -- First_Private_Entity Node16
134 -- Lit_Strings Node16
135 -- String_Literal_Length Uint16
136 -- Unset_Reference Node16
138 -- Actual_Subtype Node17
139 -- Digits_Value Uint17
140 -- Discriminal Node17
141 -- First_Entity Node17
142 -- First_Index Node17
143 -- First_Literal Node17
146 -- Non_Limited_View Node17
150 -- Corresponding_Concurrent_Type Node18
151 -- Corresponding_Protected_Entry Node18
152 -- Corresponding_Record_Type Node18
153 -- Delta_Value Ureal18
154 -- Enclosing_Scope Node18
155 -- Equivalent_Type Node18
156 -- Private_Dependents Elist18
157 -- Renamed_Entity Node18
158 -- Renamed_Object Node18
160 -- Body_Entity Node19
161 -- Corresponding_Discriminant Node19
162 -- Finalization_Chain_Entity Node19
163 -- Parent_Subtype Node19
164 -- Related_Array_Object Node19
165 -- Size_Check_Code Node19
166 -- Spec_Entity Node19
167 -- Underlying_Full_View Node19
169 -- Component_Type Node20
170 -- Default_Value Node20
171 -- Directly_Designated_Type Node20
172 -- Discriminant_Checking_Func Node20
173 -- Discriminant_Default_Value Node20
174 -- Last_Entity Node20
175 -- Prival_Link Node20
176 -- Register_Exception_Call Node20
177 -- Scalar_Range Node20
179 -- Accept_Address Elist21
180 -- Default_Expr_Function Node21
181 -- Discriminant_Constraint Elist21
182 -- Interface_Name Node21
183 -- Original_Array_Type Node21
184 -- Small_Value Ureal21
186 -- Associated_Storage_Pool Node22
187 -- Component_Size Uint22
188 -- Corresponding_Remote_Type Node22
189 -- Enumeration_Rep_Expr Node22
190 -- Exception_Code Uint22
191 -- Original_Record_Component Node22
192 -- Private_View Node22
193 -- Protected_Formal Node22
194 -- Scope_Depth_Value Uint22
195 -- Shared_Var_Procs_Instance Node22
197 -- Associated_Final_Chain Node23
198 -- CR_Discriminant Node23
199 -- Entry_Cancel_Parameter Node23
200 -- Enum_Pos_To_Rep Node23
201 -- Extra_Constrained Node23
202 -- Generic_Renamings Elist23
203 -- Inner_Instances Elist23
204 -- Limited_View Node23
205 -- Packed_Array_Type Node23
206 -- Protection_Object Node23
207 -- Stored_Constraint Elist23
209 -- Related_Expression Node24
210 -- Spec_PPC_List Node24
212 -- Interface_Alias Node25
213 -- Interfaces Elist25
214 -- Debug_Renaming_Link Node25
215 -- DT_Offset_To_Top_Func Node25
216 -- PPC_Wrapper Node25
217 -- Task_Body_Procedure Node25
219 -- Dispatch_Table_Wrappers Elist26
220 -- Last_Assignment Node26
221 -- Overridden_Operation Node26
222 -- Package_Instantiation Node26
223 -- Relative_Deadline_Variable Node26
224 -- Static_Initialization Node26
226 -- Current_Use_Clause Node27
227 -- Related_Type Node27
228 -- Wrapped_Entity Node27
230 -- Extra_Formals Node28
231 -- Underlying_Record_View Node28
233 -- Subprograms_For_Type Node29
235 ---------------------------------------------
236 -- Usage of Flags in Defining Entity Nodes --
237 ---------------------------------------------
239 -- All flags are unique, there is no overlaying, so each flag is physically
240 -- present in every entity. However, for many of the flags, it only makes
241 -- sense for them to be set true for certain subsets of entity kinds. See
242 -- the spec of Einfo for further details.
244 -- Note: Flag1-Flag3 are absent from this list, for historical reasons
247 -- Has_Discriminants Flag5
248 -- Is_Dispatching_Operation Flag6
249 -- Is_Immediately_Visible Flag7
251 -- Is_Potentially_Use_Visible Flag9
255 -- Is_Constrained Flag12
256 -- Is_Generic_Type Flag13
257 -- Depends_On_Private Flag14
259 -- Is_Volatile Flag16
260 -- Is_Internal Flag17
261 -- Has_Delayed_Freeze Flag18
262 -- Is_Abstract_Subprogram Flag19
263 -- Is_Concurrent_Record_Type Flag20
265 -- Has_Master_Entity Flag21
266 -- Needs_No_Actuals Flag22
267 -- Has_Storage_Size_Clause Flag23
268 -- Is_Imported Flag24
269 -- Is_Limited_Record Flag25
270 -- Has_Completion Flag26
271 -- Has_Pragma_Controlled Flag27
272 -- Is_Statically_Allocated Flag28
273 -- Has_Size_Clause Flag29
276 -- Checks_May_Be_Suppressed Flag31
277 -- Kill_Elaboration_Checks Flag32
278 -- Kill_Range_Checks Flag33
279 -- Kill_Tag_Checks Flag34
280 -- Is_Class_Wide_Equivalent_Type Flag35
281 -- Referenced_As_LHS Flag36
282 -- Is_Known_Non_Null Flag37
283 -- Can_Never_Be_Null Flag38
284 -- Is_Overriding_Operation Flag39
285 -- Body_Needed_For_SAL Flag40
287 -- Treat_As_Volatile Flag41
288 -- Is_Controlled Flag42
289 -- Has_Controlled_Component Flag43
291 -- In_Private_Part Flag45
292 -- Has_Alignment_Clause Flag46
294 -- In_Package_Body Flag48
296 -- Delay_Subprogram_Descriptors Flag50
299 -- Is_Entry_Formal Flag52
300 -- Is_Private_Descendant Flag53
301 -- Return_Present Flag54
302 -- Is_Tagged_Type Flag55
303 -- Has_Homonym Flag56
305 -- Non_Binary_Modulus Flag58
306 -- Is_Preelaborated Flag59
307 -- Is_Shared_Passive Flag60
309 -- Is_Remote_Types Flag61
310 -- Is_Remote_Call_Interface Flag62
311 -- Is_Character_Type Flag63
312 -- Is_Intrinsic_Subprogram Flag64
313 -- Has_Record_Rep_Clause Flag65
314 -- Has_Enumeration_Rep_Clause Flag66
315 -- Has_Small_Clause Flag67
316 -- Has_Component_Size_Clause Flag68
317 -- Is_Access_Constant Flag69
318 -- Is_First_Subtype Flag70
320 -- Has_Completion_In_Body Flag71
321 -- Has_Unknown_Discriminants Flag72
322 -- Is_Child_Unit Flag73
323 -- Is_CPP_Class Flag74
324 -- Has_Non_Standard_Rep Flag75
325 -- Is_Constructor Flag76
326 -- Static_Elaboration_Desired Flag77
328 -- Has_All_Calls_Remote Flag79
329 -- Is_Constr_Subt_For_U_Nominal Flag80
331 -- Is_Asynchronous Flag81
332 -- Has_Gigi_Rep_Item Flag82
333 -- Has_Machine_Radix_Clause Flag83
334 -- Machine_Radix_10 Flag84
336 -- Has_Atomic_Components Flag86
337 -- Has_Volatile_Components Flag87
338 -- Discard_Names Flag88
339 -- Is_Interrupt_Handler Flag89
340 -- Returns_By_Ref Flag90
343 -- Size_Known_At_Compile_Time Flag92
344 -- Has_Subprogram_Descriptor Flag93
345 -- Is_Generic_Actual_Type Flag94
346 -- Uses_Sec_Stack Flag95
347 -- Warnings_Off Flag96
348 -- Is_Controlling_Formal Flag97
349 -- Has_Controlling_Result Flag98
350 -- Is_Exported Flag99
351 -- Has_Specified_Layout Flag100
353 -- Has_Nested_Block_With_Handler Flag101
355 -- Is_Completely_Hidden Flag103
356 -- Address_Taken Flag104
357 -- Suppress_Init_Proc Flag105
358 -- Is_Limited_Composite Flag106
359 -- Is_Private_Composite Flag107
360 -- Default_Expressions_Processed Flag108
361 -- Is_Non_Static_Subtype Flag109
362 -- Has_External_Tag_Rep_Clause Flag110
364 -- Is_Formal_Subprogram Flag111
365 -- Is_Renaming_Of_Object Flag112
367 -- Delay_Cleanups Flag114
368 -- Never_Set_In_Source Flag115
369 -- Is_Visible_Child_Unit Flag116
370 -- Is_Unchecked_Union Flag117
371 -- Is_For_Access_Subtype Flag118
372 -- Has_Convention_Pragma Flag119
373 -- Has_Primitive_Operations Flag120
375 -- Has_Pragma_Pack Flag121
376 -- Is_Bit_Packed_Array Flag122
377 -- Has_Unchecked_Union Flag123
378 -- Is_Eliminated Flag124
379 -- C_Pass_By_Copy Flag125
380 -- Is_Instantiated Flag126
381 -- Is_Valued_Procedure Flag127
382 -- (used for Component_Alignment) Flag128
383 -- (used for Component_Alignment) Flag129
384 -- Is_Generic_Instance Flag130
386 -- No_Pool_Assigned Flag131
387 -- Is_AST_Entry Flag132
388 -- Is_VMS_Exception Flag133
389 -- Is_Optional_Parameter Flag134
390 -- Has_Aliased_Components Flag135
391 -- No_Strict_Aliasing Flag136
392 -- Is_Machine_Code_Subprogram Flag137
393 -- Is_Packed_Array_Type Flag138
394 -- Has_Biased_Representation Flag139
395 -- Has_Complex_Representation Flag140
397 -- Is_Constr_Subt_For_UN_Aliased Flag141
398 -- Has_Missing_Return Flag142
399 -- Has_Recursive_Call Flag143
400 -- Is_Unsigned_Type Flag144
401 -- Strict_Alignment Flag145
402 -- Is_Abstract_Type Flag146
403 -- Needs_Debug_Info Flag147
404 -- Suppress_Elaboration_Warnings Flag148
405 -- Is_Compilation_Unit Flag149
406 -- Has_Pragma_Elaborate_Body Flag150
409 -- Entry_Accepted Flag152
410 -- Is_Obsolescent Flag153
411 -- Has_Per_Object_Constraint Flag154
412 -- Has_Private_Declaration Flag155
413 -- Referenced Flag156
414 -- Has_Pragma_Inline Flag157
415 -- Finalize_Storage_Only Flag158
416 -- From_With_Type Flag159
417 -- Is_Package_Body_Entity Flag160
419 -- Has_Qualified_Name Flag161
420 -- Nonzero_Is_True Flag162
421 -- Is_True_Constant Flag163
422 -- Reverse_Bit_Order Flag164
423 -- Suppress_Style_Checks Flag165
424 -- Debug_Info_Off Flag166
425 -- Sec_Stack_Needed_For_Return Flag167
426 -- Materialize_Entity Flag168
427 -- Has_Pragma_Thread_Local_Storage Flag169
428 -- Is_Known_Valid Flag170
430 -- Is_Hidden_Open_Scope Flag171
431 -- Has_Object_Size_Clause Flag172
432 -- Has_Fully_Qualified_Name Flag173
433 -- Elaboration_Entity_Required Flag174
434 -- Has_Forward_Instantiation Flag175
435 -- Is_Discrim_SO_Function Flag176
436 -- Size_Depends_On_Discriminant Flag177
437 -- Is_Null_Init_Proc Flag178
438 -- Has_Pragma_Pure_Function Flag179
439 -- Has_Pragma_Unreferenced Flag180
441 -- Has_Contiguous_Rep Flag181
442 -- Has_Xref_Entry Flag182
443 -- Must_Be_On_Byte_Boundary Flag183
444 -- Has_Stream_Size_Clause Flag184
445 -- Is_Ada_2005_Only Flag185
446 -- Is_Interface Flag186
447 -- Has_Constrained_Partial_View Flag187
448 -- Has_Persistent_BSS Flag188
449 -- Is_Pure_Unit_Access_Type Flag189
450 -- Has_Specified_Stream_Input Flag190
452 -- Has_Specified_Stream_Output Flag191
453 -- Has_Specified_Stream_Read Flag192
454 -- Has_Specified_Stream_Write Flag193
455 -- Is_Local_Anonymous_Access Flag194
456 -- Is_Primitive_Wrapper Flag195
457 -- Was_Hidden Flag196
458 -- Is_Limited_Interface Flag197
459 -- Has_Pragma_Ordered Flag198
460 -- Is_Ada_2012_Only Flag199
462 -- Has_Delayed_Aspects Flag200
463 -- Has_Anon_Block_Suffix Flag201
464 -- Itype_Printed Flag202
465 -- Has_Pragma_Pure Flag203
466 -- Is_Known_Null Flag204
467 -- Low_Bound_Tested Flag205
468 -- Is_Visible_Formal Flag206
469 -- Known_To_Have_Preelab_Init Flag207
470 -- Must_Have_Preelab_Init Flag208
471 -- Is_Return_Object Flag209
472 -- Elaborate_Body_Desirable Flag210
474 -- Has_Static_Discriminants Flag211
475 -- Has_Pragma_Unreferenced_Objects Flag212
476 -- Requires_Overriding Flag213
478 -- Has_Up_Level_Access Flag215
479 -- Universal_Aliasing Flag216
480 -- Suppress_Value_Tracking_On_Call Flag217
481 -- Is_Primitive Flag218
482 -- Has_Initial_Value Flag219
483 -- Has_Dispatch_Table Flag220
485 -- Has_Pragma_Preelab_Init Flag221
486 -- Used_As_Generic_Actual Flag222
487 -- Is_Descendent_Of_Address Flag223
490 -- Is_Only_Out_Parameter Flag226
491 -- Referenced_As_Out_Parameter Flag227
492 -- Has_Thunks Flag228
493 -- Can_Use_Internal_Rep Flag229
494 -- Has_Pragma_Inline_Always Flag230
496 -- Renamed_In_Spec Flag231
497 -- Has_Invariants Flag232
498 -- Has_Pragma_Unmodified Flag233
499 -- Is_Dispatch_Table_Entity Flag234
500 -- Is_Trivial_Subprogram Flag235
501 -- Warnings_Off_Used Flag236
502 -- Warnings_Off_Used_Unmodified Flag237
503 -- Warnings_Off_Used_Unreferenced Flag238
504 -- OK_To_Reorder_Components Flag239
505 -- Has_Postconditions Flag240
507 -- Optimize_Alignment_Space Flag241
508 -- Optimize_Alignment_Time Flag242
509 -- Overlays_Constant Flag243
510 -- Is_RACW_Stub_Type Flag244
511 -- Is_Private_Primitive Flag245
512 -- Is_Underlying_Record_View Flag246
513 -- OK_To_Rename Flag247
514 -- Has_Inheritable_Invariants Flag248
515 -- OK_To_Reference Flag249
516 -- Has_Predicates Flag250
523 -----------------------
524 -- Local subprograms --
525 -----------------------
527 function Rep_Clause (Id : E; Rep_Name : Name_Id) return N;
528 -- Returns the attribute definition clause for Id whose name is Rep_Name.
529 -- Returns Empty if no matching attribute definition clause found for Id.
535 function Rep_Clause (Id : E; Rep_Name : Name_Id) return N is
539 Ritem := First_Rep_Item (Id);
540 while Present (Ritem) loop
541 if Nkind (Ritem) = N_Attribute_Definition_Clause
542 and then Chars (Ritem) = Rep_Name
546 Next_Rep_Item (Ritem);
553 --------------------------------
554 -- Attribute Access Functions --
555 --------------------------------
557 function Accept_Address (Id : E) return L is
562 function Access_Disp_Table (Id : E) return L is
564 pragma Assert (Is_Tagged_Type (Id));
565 return Elist16 (Implementation_Base_Type (Id));
566 end Access_Disp_Table;
568 function Actual_Subtype (Id : E) return E is
571 (Ekind_In (Id, E_Constant, E_Variable, E_Generic_In_Out_Parameter)
572 or else Is_Formal (Id));
576 function Address_Taken (Id : E) return B is
581 function Alias (Id : E) return E is
584 (Is_Overloadable (Id) or else Ekind (Id) = E_Subprogram_Type);
588 function Alignment (Id : E) return U is
590 pragma Assert (Is_Type (Id)
591 or else Is_Formal (Id)
592 or else Ekind_In (Id, E_Loop_Parameter,
599 function Associated_Final_Chain (Id : E) return E is
601 pragma Assert (Is_Access_Type (Id));
603 end Associated_Final_Chain;
605 function Associated_Formal_Package (Id : E) return E is
607 pragma Assert (Ekind (Id) = E_Package);
609 end Associated_Formal_Package;
611 function Associated_Node_For_Itype (Id : E) return N is
614 end Associated_Node_For_Itype;
616 function Associated_Storage_Pool (Id : E) return E is
618 pragma Assert (Is_Access_Type (Id));
619 return Node22 (Root_Type (Id));
620 end Associated_Storage_Pool;
622 function Barrier_Function (Id : E) return N is
624 pragma Assert (Is_Entry (Id));
626 end Barrier_Function;
628 function Block_Node (Id : E) return N is
630 pragma Assert (Ekind (Id) = E_Block);
634 function Body_Entity (Id : E) return E is
636 pragma Assert (Ekind_In (Id, E_Package, E_Generic_Package));
640 function Body_Needed_For_SAL (Id : E) return B is
643 (Ekind (Id) = E_Package
644 or else Is_Subprogram (Id)
645 or else Is_Generic_Unit (Id));
647 end Body_Needed_For_SAL;
649 function C_Pass_By_Copy (Id : E) return B is
651 pragma Assert (Is_Record_Type (Id));
652 return Flag125 (Implementation_Base_Type (Id));
655 function Can_Never_Be_Null (Id : E) return B is
658 end Can_Never_Be_Null;
660 function Checks_May_Be_Suppressed (Id : E) return B is
663 end Checks_May_Be_Suppressed;
665 function Class_Wide_Type (Id : E) return E is
667 pragma Assert (Is_Type (Id));
671 function Cloned_Subtype (Id : E) return E is
673 pragma Assert (Ekind_In (Id, E_Record_Subtype, E_Class_Wide_Subtype));
677 function Component_Bit_Offset (Id : E) return U is
679 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
681 end Component_Bit_Offset;
683 function Component_Clause (Id : E) return N is
685 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
687 end Component_Clause;
689 function Component_Size (Id : E) return U is
691 pragma Assert (Is_Array_Type (Id));
692 return Uint22 (Implementation_Base_Type (Id));
695 function Component_Type (Id : E) return E is
697 pragma Assert (Is_Array_Type (Id) or else Is_String_Type (Id));
698 return Node20 (Implementation_Base_Type (Id));
701 function Corresponding_Concurrent_Type (Id : E) return E is
703 pragma Assert (Ekind (Id) = E_Record_Type);
705 end Corresponding_Concurrent_Type;
707 function Corresponding_Discriminant (Id : E) return E is
709 pragma Assert (Ekind (Id) = E_Discriminant);
711 end Corresponding_Discriminant;
713 function Corresponding_Equality (Id : E) return E is
716 (Ekind (Id) = E_Function
717 and then not Comes_From_Source (Id)
718 and then Chars (Id) = Name_Op_Ne);
720 end Corresponding_Equality;
722 function Corresponding_Protected_Entry (Id : E) return E is
724 pragma Assert (Ekind (Id) = E_Subprogram_Body);
726 end Corresponding_Protected_Entry;
728 function Corresponding_Record_Type (Id : E) return E is
730 pragma Assert (Is_Concurrent_Type (Id));
732 end Corresponding_Record_Type;
734 function Corresponding_Remote_Type (Id : E) return E is
737 end Corresponding_Remote_Type;
739 function Current_Use_Clause (Id : E) return E is
741 pragma Assert (Ekind (Id) = E_Package or else Is_Type (Id));
743 end Current_Use_Clause;
745 function Current_Value (Id : E) return N is
747 pragma Assert (Ekind (Id) in Object_Kind);
751 function CR_Discriminant (Id : E) return E is
756 function Debug_Info_Off (Id : E) return B is
761 function Debug_Renaming_Link (Id : E) return E is
764 end Debug_Renaming_Link;
766 function Default_Expr_Function (Id : E) return E is
768 pragma Assert (Is_Formal (Id));
770 end Default_Expr_Function;
772 function Default_Expressions_Processed (Id : E) return B is
775 end Default_Expressions_Processed;
777 function Default_Value (Id : E) return N is
779 pragma Assert (Is_Formal (Id));
783 function Delay_Cleanups (Id : E) return B is
788 function Delay_Subprogram_Descriptors (Id : E) return B is
791 end Delay_Subprogram_Descriptors;
793 function Delta_Value (Id : E) return R is
795 pragma Assert (Is_Fixed_Point_Type (Id));
799 function Dependent_Instances (Id : E) return L is
801 pragma Assert (Is_Generic_Instance (Id));
803 end Dependent_Instances;
805 function Depends_On_Private (Id : E) return B is
807 pragma Assert (Nkind (Id) in N_Entity);
809 end Depends_On_Private;
811 function Digits_Value (Id : E) return U is
814 (Is_Floating_Point_Type (Id)
815 or else Is_Decimal_Fixed_Point_Type (Id));
819 function Direct_Primitive_Operations (Id : E) return L is
821 pragma Assert (Is_Tagged_Type (Id));
823 end Direct_Primitive_Operations;
825 function Directly_Designated_Type (Id : E) return E is
827 pragma Assert (Is_Access_Type (Id));
829 end Directly_Designated_Type;
831 function Discard_Names (Id : E) return B is
836 function Discriminal (Id : E) return E is
838 pragma Assert (Ekind (Id) = E_Discriminant);
842 function Discriminal_Link (Id : E) return N is
845 end Discriminal_Link;
847 function Discriminant_Checking_Func (Id : E) return E is
849 pragma Assert (Ekind (Id) = E_Component);
851 end Discriminant_Checking_Func;
853 function Discriminant_Constraint (Id : E) return L is
855 pragma Assert (Is_Composite_Type (Id) and then Has_Discriminants (Id));
857 end Discriminant_Constraint;
859 function Discriminant_Default_Value (Id : E) return N is
861 pragma Assert (Ekind (Id) = E_Discriminant);
863 end Discriminant_Default_Value;
865 function Discriminant_Number (Id : E) return U is
867 pragma Assert (Ekind (Id) = E_Discriminant);
869 end Discriminant_Number;
871 function Dispatch_Table_Wrappers (Id : E) return L is
873 pragma Assert (Is_Tagged_Type (Id));
874 return Elist26 (Implementation_Base_Type (Id));
875 end Dispatch_Table_Wrappers;
877 function DT_Entry_Count (Id : E) return U is
879 pragma Assert (Ekind (Id) = E_Component and then Is_Tag (Id));
883 function DT_Offset_To_Top_Func (Id : E) return E is
885 pragma Assert (Ekind (Id) = E_Component and then Is_Tag (Id));
887 end DT_Offset_To_Top_Func;
889 function DT_Position (Id : E) return U is
891 pragma Assert (Ekind_In (Id, E_Function, E_Procedure)
892 and then Present (DTC_Entity (Id)));
896 function DTC_Entity (Id : E) return E is
898 pragma Assert (Ekind_In (Id, E_Function, E_Procedure));
902 function Elaborate_Body_Desirable (Id : E) return B is
904 pragma Assert (Ekind (Id) = E_Package);
906 end Elaborate_Body_Desirable;
908 function Elaboration_Entity (Id : E) return E is
913 Ekind (Id) = E_Package
915 Is_Generic_Unit (Id));
917 end Elaboration_Entity;
919 function Elaboration_Entity_Required (Id : E) return B is
924 Ekind (Id) = E_Package
926 Is_Generic_Unit (Id));
928 end Elaboration_Entity_Required;
930 function Enclosing_Scope (Id : E) return E is
935 function Entry_Accepted (Id : E) return B is
937 pragma Assert (Is_Entry (Id));
941 function Entry_Bodies_Array (Id : E) return E is
944 end Entry_Bodies_Array;
946 function Entry_Cancel_Parameter (Id : E) return E is
949 end Entry_Cancel_Parameter;
951 function Entry_Component (Id : E) return E is
956 function Entry_Formal (Id : E) return E is
961 function Entry_Index_Constant (Id : E) return N is
963 pragma Assert (Ekind (Id) = E_Entry_Index_Parameter);
965 end Entry_Index_Constant;
967 function Entry_Parameters_Type (Id : E) return E is
970 end Entry_Parameters_Type;
972 function Enum_Pos_To_Rep (Id : E) return E is
974 pragma Assert (Ekind (Id) = E_Enumeration_Type);
978 function Enumeration_Pos (Id : E) return Uint is
980 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
984 function Enumeration_Rep (Id : E) return U is
986 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
990 function Enumeration_Rep_Expr (Id : E) return N is
992 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
994 end Enumeration_Rep_Expr;
996 function Equivalent_Type (Id : E) return E is
999 (Ekind_In (Id, E_Class_Wide_Type,
1000 E_Class_Wide_Subtype,
1001 E_Access_Protected_Subprogram_Type,
1002 E_Anonymous_Access_Protected_Subprogram_Type,
1003 E_Access_Subprogram_Type,
1006 end Equivalent_Type;
1008 function Esize (Id : E) return Uint is
1013 function Exception_Code (Id : E) return Uint is
1015 pragma Assert (Ekind (Id) = E_Exception);
1019 function Extra_Accessibility (Id : E) return E is
1021 pragma Assert (Is_Formal (Id) or else Ekind (Id) = E_Variable);
1023 end Extra_Accessibility;
1025 function Extra_Constrained (Id : E) return E is
1027 pragma Assert (Is_Formal (Id) or else Ekind (Id) = E_Variable);
1029 end Extra_Constrained;
1031 function Extra_Formal (Id : E) return E is
1036 function Extra_Formals (Id : E) return E is
1039 (Is_Overloadable (Id)
1040 or else Ekind_In (Id, E_Entry_Family,
1042 E_Subprogram_Type));
1046 function Can_Use_Internal_Rep (Id : E) return B is
1048 pragma Assert (Is_Access_Subprogram_Type (Base_Type (Id)));
1049 return Flag229 (Base_Type (Id));
1050 end Can_Use_Internal_Rep;
1052 function Finalization_Chain_Entity (Id : E) return E is
1055 end Finalization_Chain_Entity;
1057 function Finalize_Storage_Only (Id : E) return B is
1059 pragma Assert (Is_Type (Id));
1060 return Flag158 (Base_Type (Id));
1061 end Finalize_Storage_Only;
1063 function First_Entity (Id : E) return E is
1068 function First_Exit_Statement (Id : E) return N is
1070 pragma Assert (Ekind (Id) = E_Loop);
1072 end First_Exit_Statement;
1074 function First_Index (Id : E) return N is
1076 pragma Assert (Is_Array_Type (Id) or else Is_String_Type (Id));
1080 function First_Literal (Id : E) return E is
1082 pragma Assert (Is_Enumeration_Type (Id));
1086 function First_Optional_Parameter (Id : E) return E is
1088 pragma Assert (Ekind_In (Id, E_Function, E_Procedure));
1090 end First_Optional_Parameter;
1092 function First_Private_Entity (Id : E) return E is
1094 pragma Assert (Ekind_In (Id, E_Package, E_Generic_Package)
1095 or else Ekind (Id) in Concurrent_Kind);
1097 end First_Private_Entity;
1099 function First_Rep_Item (Id : E) return E is
1104 function Freeze_Node (Id : E) return N is
1109 function From_With_Type (Id : E) return B is
1111 return Flag159 (Id);
1114 function Full_View (Id : E) return E is
1116 pragma Assert (Is_Type (Id) or else Ekind (Id) = E_Constant);
1120 function Generic_Homonym (Id : E) return E is
1122 pragma Assert (Ekind (Id) = E_Generic_Package);
1124 end Generic_Homonym;
1126 function Generic_Renamings (Id : E) return L is
1128 return Elist23 (Id);
1129 end Generic_Renamings;
1131 function Handler_Records (Id : E) return S is
1134 end Handler_Records;
1136 function Has_Aliased_Components (Id : E) return B is
1138 return Flag135 (Implementation_Base_Type (Id));
1139 end Has_Aliased_Components;
1141 function Has_Alignment_Clause (Id : E) return B is
1144 end Has_Alignment_Clause;
1146 function Has_All_Calls_Remote (Id : E) return B is
1149 end Has_All_Calls_Remote;
1151 function Has_Anon_Block_Suffix (Id : E) return B is
1153 return Flag201 (Id);
1154 end Has_Anon_Block_Suffix;
1156 function Has_Atomic_Components (Id : E) return B is
1158 return Flag86 (Implementation_Base_Type (Id));
1159 end Has_Atomic_Components;
1161 function Has_Biased_Representation (Id : E) return B is
1163 return Flag139 (Id);
1164 end Has_Biased_Representation;
1166 function Has_Completion (Id : E) return B is
1171 function Has_Completion_In_Body (Id : E) return B is
1173 pragma Assert (Is_Type (Id));
1175 end Has_Completion_In_Body;
1177 function Has_Complex_Representation (Id : E) return B is
1179 pragma Assert (Is_Type (Id));
1180 return Flag140 (Implementation_Base_Type (Id));
1181 end Has_Complex_Representation;
1183 function Has_Component_Size_Clause (Id : E) return B is
1185 pragma Assert (Is_Array_Type (Id));
1186 return Flag68 (Implementation_Base_Type (Id));
1187 end Has_Component_Size_Clause;
1189 function Has_Constrained_Partial_View (Id : E) return B is
1191 pragma Assert (Is_Type (Id));
1192 return Flag187 (Id);
1193 end Has_Constrained_Partial_View;
1195 function Has_Controlled_Component (Id : E) return B is
1197 return Flag43 (Base_Type (Id));
1198 end Has_Controlled_Component;
1200 function Has_Contiguous_Rep (Id : E) return B is
1202 return Flag181 (Id);
1203 end Has_Contiguous_Rep;
1205 function Has_Controlling_Result (Id : E) return B is
1208 end Has_Controlling_Result;
1210 function Has_Convention_Pragma (Id : E) return B is
1212 return Flag119 (Id);
1213 end Has_Convention_Pragma;
1215 function Has_Delayed_Aspects (Id : E) return B is
1217 pragma Assert (Nkind (Id) in N_Entity);
1218 return Flag200 (Id);
1219 end Has_Delayed_Aspects;
1221 function Has_Delayed_Freeze (Id : E) return B is
1223 pragma Assert (Nkind (Id) in N_Entity);
1225 end Has_Delayed_Freeze;
1227 function Has_Discriminants (Id : E) return B is
1229 pragma Assert (Nkind (Id) in N_Entity);
1231 end Has_Discriminants;
1233 function Has_Dispatch_Table (Id : E) return B is
1235 pragma Assert (Is_Tagged_Type (Id));
1236 return Flag220 (Id);
1237 end Has_Dispatch_Table;
1239 function Has_Enumeration_Rep_Clause (Id : E) return B is
1241 pragma Assert (Is_Enumeration_Type (Id));
1243 end Has_Enumeration_Rep_Clause;
1245 function Has_Exit (Id : E) return B is
1250 function Has_External_Tag_Rep_Clause (Id : E) return B is
1252 pragma Assert (Is_Tagged_Type (Id));
1253 return Flag110 (Id);
1254 end Has_External_Tag_Rep_Clause;
1256 function Has_Forward_Instantiation (Id : E) return B is
1258 return Flag175 (Id);
1259 end Has_Forward_Instantiation;
1261 function Has_Fully_Qualified_Name (Id : E) return B is
1263 return Flag173 (Id);
1264 end Has_Fully_Qualified_Name;
1266 function Has_Gigi_Rep_Item (Id : E) return B is
1269 end Has_Gigi_Rep_Item;
1271 function Has_Homonym (Id : E) return B is
1276 function Has_Inheritable_Invariants (Id : E) return B is
1278 pragma Assert (Is_Type (Id));
1279 return Flag248 (Id);
1280 end Has_Inheritable_Invariants;
1282 function Has_Initial_Value (Id : E) return B is
1284 pragma Assert (Ekind (Id) = E_Variable or else Is_Formal (Id));
1285 return Flag219 (Id);
1286 end Has_Initial_Value;
1288 function Has_Invariants (Id : E) return B is
1290 pragma Assert (Is_Type (Id) or else Ekind (Id) = E_Procedure);
1291 return Flag232 (Id);
1294 function Has_Machine_Radix_Clause (Id : E) return B is
1296 pragma Assert (Is_Decimal_Fixed_Point_Type (Id));
1298 end Has_Machine_Radix_Clause;
1300 function Has_Master_Entity (Id : E) return B is
1303 end Has_Master_Entity;
1305 function Has_Missing_Return (Id : E) return B is
1307 pragma Assert (Ekind_In (Id, E_Function, E_Generic_Function));
1308 return Flag142 (Id);
1309 end Has_Missing_Return;
1311 function Has_Nested_Block_With_Handler (Id : E) return B is
1313 return Flag101 (Id);
1314 end Has_Nested_Block_With_Handler;
1316 function Has_Non_Standard_Rep (Id : E) return B is
1318 return Flag75 (Implementation_Base_Type (Id));
1319 end Has_Non_Standard_Rep;
1321 function Has_Object_Size_Clause (Id : E) return B is
1323 pragma Assert (Is_Type (Id));
1324 return Flag172 (Id);
1325 end Has_Object_Size_Clause;
1327 function Has_Per_Object_Constraint (Id : E) return B is
1329 return Flag154 (Id);
1330 end Has_Per_Object_Constraint;
1332 function Has_Persistent_BSS (Id : E) return B is
1334 return Flag188 (Id);
1335 end Has_Persistent_BSS;
1337 function Has_Postconditions (Id : E) return B is
1339 pragma Assert (Is_Subprogram (Id));
1340 return Flag240 (Id);
1341 end Has_Postconditions;
1343 function Has_Pragma_Controlled (Id : E) return B is
1345 pragma Assert (Is_Access_Type (Id));
1346 return Flag27 (Implementation_Base_Type (Id));
1347 end Has_Pragma_Controlled;
1349 function Has_Pragma_Elaborate_Body (Id : E) return B is
1351 return Flag150 (Id);
1352 end Has_Pragma_Elaborate_Body;
1354 function Has_Pragma_Inline (Id : E) return B is
1356 return Flag157 (Id);
1357 end Has_Pragma_Inline;
1359 function Has_Pragma_Inline_Always (Id : E) return B is
1361 return Flag230 (Id);
1362 end Has_Pragma_Inline_Always;
1364 function Has_Pragma_Ordered (Id : E) return B is
1366 pragma Assert (Is_Enumeration_Type (Id));
1367 return Flag198 (Implementation_Base_Type (Id));
1368 end Has_Pragma_Ordered;
1370 function Has_Pragma_Pack (Id : E) return B is
1372 pragma Assert (Is_Record_Type (Id) or else Is_Array_Type (Id));
1373 return Flag121 (Implementation_Base_Type (Id));
1374 end Has_Pragma_Pack;
1376 function Has_Pragma_Preelab_Init (Id : E) return B is
1378 return Flag221 (Id);
1379 end Has_Pragma_Preelab_Init;
1381 function Has_Pragma_Pure (Id : E) return B is
1383 return Flag203 (Id);
1384 end Has_Pragma_Pure;
1386 function Has_Pragma_Pure_Function (Id : E) return B is
1388 return Flag179 (Id);
1389 end Has_Pragma_Pure_Function;
1391 function Has_Pragma_Thread_Local_Storage (Id : E) return B is
1393 return Flag169 (Id);
1394 end Has_Pragma_Thread_Local_Storage;
1396 function Has_Pragma_Unmodified (Id : E) return B is
1398 return Flag233 (Id);
1399 end Has_Pragma_Unmodified;
1401 function Has_Pragma_Unreferenced (Id : E) return B is
1403 return Flag180 (Id);
1404 end Has_Pragma_Unreferenced;
1406 function Has_Pragma_Unreferenced_Objects (Id : E) return B is
1408 pragma Assert (Is_Type (Id));
1409 return Flag212 (Id);
1410 end Has_Pragma_Unreferenced_Objects;
1412 function Has_Predicates (Id : E) return B is
1414 pragma Assert (Is_Type (Id) or else Ekind (Id) = E_Function);
1415 return Flag250 (Id);
1418 function Has_Primitive_Operations (Id : E) return B is
1420 pragma Assert (Is_Type (Id));
1421 return Flag120 (Base_Type (Id));
1422 end Has_Primitive_Operations;
1424 function Has_Private_Declaration (Id : E) return B is
1426 return Flag155 (Id);
1427 end Has_Private_Declaration;
1429 function Has_Qualified_Name (Id : E) return B is
1431 return Flag161 (Id);
1432 end Has_Qualified_Name;
1434 function Has_RACW (Id : E) return B is
1436 pragma Assert (Ekind (Id) = E_Package);
1437 return Flag214 (Id);
1440 function Has_Record_Rep_Clause (Id : E) return B is
1442 pragma Assert (Is_Record_Type (Id));
1443 return Flag65 (Implementation_Base_Type (Id));
1444 end Has_Record_Rep_Clause;
1446 function Has_Recursive_Call (Id : E) return B is
1448 pragma Assert (Is_Subprogram (Id));
1449 return Flag143 (Id);
1450 end Has_Recursive_Call;
1452 function Has_Size_Clause (Id : E) return B is
1455 end Has_Size_Clause;
1457 function Has_Small_Clause (Id : E) return B is
1460 end Has_Small_Clause;
1462 function Has_Specified_Layout (Id : E) return B is
1464 pragma Assert (Is_Type (Id));
1465 return Flag100 (Implementation_Base_Type (Id));
1466 end Has_Specified_Layout;
1468 function Has_Specified_Stream_Input (Id : E) return B is
1470 pragma Assert (Is_Type (Id));
1471 return Flag190 (Id);
1472 end Has_Specified_Stream_Input;
1474 function Has_Specified_Stream_Output (Id : E) return B is
1476 pragma Assert (Is_Type (Id));
1477 return Flag191 (Id);
1478 end Has_Specified_Stream_Output;
1480 function Has_Specified_Stream_Read (Id : E) return B is
1482 pragma Assert (Is_Type (Id));
1483 return Flag192 (Id);
1484 end Has_Specified_Stream_Read;
1486 function Has_Specified_Stream_Write (Id : E) return B is
1488 pragma Assert (Is_Type (Id));
1489 return Flag193 (Id);
1490 end Has_Specified_Stream_Write;
1492 function Has_Static_Discriminants (Id : E) return B is
1494 pragma Assert (Is_Type (Id));
1495 return Flag211 (Id);
1496 end Has_Static_Discriminants;
1498 function Has_Storage_Size_Clause (Id : E) return B is
1500 pragma Assert (Is_Access_Type (Id) or else Is_Task_Type (Id));
1501 return Flag23 (Implementation_Base_Type (Id));
1502 end Has_Storage_Size_Clause;
1504 function Has_Stream_Size_Clause (Id : E) return B is
1506 return Flag184 (Id);
1507 end Has_Stream_Size_Clause;
1509 function Has_Subprogram_Descriptor (Id : E) return B is
1512 end Has_Subprogram_Descriptor;
1514 function Has_Task (Id : E) return B is
1516 return Flag30 (Base_Type (Id));
1519 function Has_Thunks (Id : E) return B is
1521 return Flag228 (Id);
1524 function Has_Unchecked_Union (Id : E) return B is
1526 return Flag123 (Base_Type (Id));
1527 end Has_Unchecked_Union;
1529 function Has_Unknown_Discriminants (Id : E) return B is
1531 pragma Assert (Is_Type (Id));
1533 end Has_Unknown_Discriminants;
1535 function Has_Up_Level_Access (Id : E) return B is
1538 (Ekind_In (Id, E_Variable, E_Constant, E_Loop_Parameter));
1539 return Flag215 (Id);
1540 end Has_Up_Level_Access;
1542 function Has_Volatile_Components (Id : E) return B is
1544 return Flag87 (Implementation_Base_Type (Id));
1545 end Has_Volatile_Components;
1547 function Has_Xref_Entry (Id : E) return B is
1549 return Flag182 (Implementation_Base_Type (Id));
1552 function Hiding_Loop_Variable (Id : E) return E is
1554 pragma Assert (Ekind (Id) = E_Variable);
1556 end Hiding_Loop_Variable;
1558 function Homonym (Id : E) return E is
1563 function Interface_Alias (Id : E) return E is
1565 pragma Assert (Is_Subprogram (Id));
1567 end Interface_Alias;
1569 function Interfaces (Id : E) return L is
1571 pragma Assert (Is_Record_Type (Id));
1572 return Elist25 (Id);
1575 function In_Package_Body (Id : E) return B is
1578 end In_Package_Body;
1580 function In_Private_Part (Id : E) return B is
1583 end In_Private_Part;
1585 function In_Use (Id : E) return B is
1587 pragma Assert (Nkind (Id) in N_Entity);
1591 function Inner_Instances (Id : E) return L is
1593 return Elist23 (Id);
1594 end Inner_Instances;
1596 function Interface_Name (Id : E) return N is
1601 function Is_Abstract_Subprogram (Id : E) return B is
1603 pragma Assert (Is_Overloadable (Id));
1605 end Is_Abstract_Subprogram;
1607 function Is_Abstract_Type (Id : E) return B is
1609 pragma Assert (Is_Type (Id));
1610 return Flag146 (Id);
1611 end Is_Abstract_Type;
1613 function Is_Local_Anonymous_Access (Id : E) return B is
1615 pragma Assert (Is_Access_Type (Id));
1616 return Flag194 (Id);
1617 end Is_Local_Anonymous_Access;
1619 function Is_Access_Constant (Id : E) return B is
1621 pragma Assert (Is_Access_Type (Id));
1623 end Is_Access_Constant;
1625 function Is_Ada_2005_Only (Id : E) return B is
1627 return Flag185 (Id);
1628 end Is_Ada_2005_Only;
1630 function Is_Ada_2012_Only (Id : E) return B is
1632 return Flag199 (Id);
1633 end Is_Ada_2012_Only;
1635 function Is_Aliased (Id : E) return B is
1637 pragma Assert (Nkind (Id) in N_Entity);
1641 function Is_AST_Entry (Id : E) return B is
1643 pragma Assert (Is_Entry (Id));
1644 return Flag132 (Id);
1647 function Is_Asynchronous (Id : E) return B is
1649 pragma Assert (Ekind (Id) = E_Procedure or else Is_Type (Id));
1651 end Is_Asynchronous;
1653 function Is_Atomic (Id : E) return B is
1658 function Is_Bit_Packed_Array (Id : E) return B is
1660 return Flag122 (Implementation_Base_Type (Id));
1661 end Is_Bit_Packed_Array;
1663 function Is_Called (Id : E) return B is
1665 pragma Assert (Ekind_In (Id, E_Procedure, E_Function));
1666 return Flag102 (Id);
1669 function Is_Character_Type (Id : E) return B is
1672 end Is_Character_Type;
1674 function Is_Child_Unit (Id : E) return B is
1679 function Is_Class_Wide_Equivalent_Type (Id : E) return B is
1682 end Is_Class_Wide_Equivalent_Type;
1684 function Is_Compilation_Unit (Id : E) return B is
1686 return Flag149 (Id);
1687 end Is_Compilation_Unit;
1689 function Is_Completely_Hidden (Id : E) return B is
1691 pragma Assert (Ekind (Id) = E_Discriminant);
1692 return Flag103 (Id);
1693 end Is_Completely_Hidden;
1695 function Is_Constr_Subt_For_U_Nominal (Id : E) return B is
1698 end Is_Constr_Subt_For_U_Nominal;
1700 function Is_Constr_Subt_For_UN_Aliased (Id : E) return B is
1702 return Flag141 (Id);
1703 end Is_Constr_Subt_For_UN_Aliased;
1705 function Is_Constrained (Id : E) return B is
1707 pragma Assert (Nkind (Id) in N_Entity);
1711 function Is_Constructor (Id : E) return B is
1716 function Is_Controlled (Id : E) return B is
1718 return Flag42 (Base_Type (Id));
1721 function Is_Controlling_Formal (Id : E) return B is
1723 pragma Assert (Is_Formal (Id));
1725 end Is_Controlling_Formal;
1727 function Is_CPP_Class (Id : E) return B is
1732 function Is_Descendent_Of_Address (Id : E) return B is
1734 pragma Assert (Is_Type (Id));
1735 return Flag223 (Id);
1736 end Is_Descendent_Of_Address;
1738 function Is_Discrim_SO_Function (Id : E) return B is
1740 return Flag176 (Id);
1741 end Is_Discrim_SO_Function;
1743 function Is_Dispatch_Table_Entity (Id : E) return B is
1745 return Flag234 (Id);
1746 end Is_Dispatch_Table_Entity;
1748 function Is_Dispatching_Operation (Id : E) return B is
1750 pragma Assert (Nkind (Id) in N_Entity);
1752 end Is_Dispatching_Operation;
1754 function Is_Eliminated (Id : E) return B is
1756 return Flag124 (Id);
1759 function Is_Entry_Formal (Id : E) return B is
1762 end Is_Entry_Formal;
1764 function Is_Exported (Id : E) return B is
1769 function Is_First_Subtype (Id : E) return B is
1772 end Is_First_Subtype;
1774 function Is_For_Access_Subtype (Id : E) return B is
1776 pragma Assert (Ekind_In (Id, E_Record_Subtype, E_Private_Subtype));
1777 return Flag118 (Id);
1778 end Is_For_Access_Subtype;
1780 function Is_Formal_Subprogram (Id : E) return B is
1782 return Flag111 (Id);
1783 end Is_Formal_Subprogram;
1785 function Is_Frozen (Id : E) return B is
1790 function Is_Generic_Actual_Type (Id : E) return B is
1792 pragma Assert (Is_Type (Id));
1794 end Is_Generic_Actual_Type;
1796 function Is_Generic_Instance (Id : E) return B is
1798 return Flag130 (Id);
1799 end Is_Generic_Instance;
1801 function Is_Generic_Type (Id : E) return B is
1803 pragma Assert (Nkind (Id) in N_Entity);
1805 end Is_Generic_Type;
1807 function Is_Hidden (Id : E) return B is
1812 function Is_Hidden_Open_Scope (Id : E) return B is
1814 return Flag171 (Id);
1815 end Is_Hidden_Open_Scope;
1817 function Is_Immediately_Visible (Id : E) return B is
1819 pragma Assert (Nkind (Id) in N_Entity);
1821 end Is_Immediately_Visible;
1823 function Is_Imported (Id : E) return B is
1828 function Is_Inlined (Id : E) return B is
1833 function Is_Interface (Id : E) return B is
1835 return Flag186 (Id);
1838 function Is_Instantiated (Id : E) return B is
1840 return Flag126 (Id);
1841 end Is_Instantiated;
1843 function Is_Internal (Id : E) return B is
1845 pragma Assert (Nkind (Id) in N_Entity);
1849 function Is_Interrupt_Handler (Id : E) return B is
1851 pragma Assert (Nkind (Id) in N_Entity);
1853 end Is_Interrupt_Handler;
1855 function Is_Intrinsic_Subprogram (Id : E) return B is
1858 end Is_Intrinsic_Subprogram;
1860 function Is_Itype (Id : E) return B is
1865 function Is_Known_Non_Null (Id : E) return B is
1868 end Is_Known_Non_Null;
1870 function Is_Known_Null (Id : E) return B is
1872 return Flag204 (Id);
1875 function Is_Known_Valid (Id : E) return B is
1877 return Flag170 (Id);
1880 function Is_Limited_Composite (Id : E) return B is
1882 return Flag106 (Id);
1883 end Is_Limited_Composite;
1885 function Is_Limited_Interface (Id : E) return B is
1887 return Flag197 (Id);
1888 end Is_Limited_Interface;
1890 function Is_Limited_Record (Id : E) return B is
1893 end Is_Limited_Record;
1895 function Is_Machine_Code_Subprogram (Id : E) return B is
1897 pragma Assert (Is_Subprogram (Id));
1898 return Flag137 (Id);
1899 end Is_Machine_Code_Subprogram;
1901 function Is_Non_Static_Subtype (Id : E) return B is
1903 pragma Assert (Is_Type (Id));
1904 return Flag109 (Id);
1905 end Is_Non_Static_Subtype;
1907 function Is_Null_Init_Proc (Id : E) return B is
1909 pragma Assert (Ekind (Id) = E_Procedure);
1910 return Flag178 (Id);
1911 end Is_Null_Init_Proc;
1913 function Is_Obsolescent (Id : E) return B is
1915 return Flag153 (Id);
1918 function Is_Only_Out_Parameter (Id : E) return B is
1920 pragma Assert (Is_Formal (Id));
1921 return Flag226 (Id);
1922 end Is_Only_Out_Parameter;
1924 function Is_Optional_Parameter (Id : E) return B is
1926 pragma Assert (Is_Formal (Id));
1927 return Flag134 (Id);
1928 end Is_Optional_Parameter;
1930 function Is_Overriding_Operation (Id : E) return B is
1932 pragma Assert (Is_Subprogram (Id));
1934 end Is_Overriding_Operation;
1936 function Is_Package_Body_Entity (Id : E) return B is
1938 return Flag160 (Id);
1939 end Is_Package_Body_Entity;
1941 function Is_Packed (Id : E) return B is
1943 return Flag51 (Implementation_Base_Type (Id));
1946 function Is_Packed_Array_Type (Id : E) return B is
1948 return Flag138 (Id);
1949 end Is_Packed_Array_Type;
1951 function Is_Potentially_Use_Visible (Id : E) return B is
1953 pragma Assert (Nkind (Id) in N_Entity);
1955 end Is_Potentially_Use_Visible;
1957 function Is_Preelaborated (Id : E) return B is
1960 end Is_Preelaborated;
1962 function Is_Primitive (Id : E) return B is
1965 (Is_Overloadable (Id)
1966 or else Ekind_In (Id, E_Generic_Function, E_Generic_Procedure));
1967 return Flag218 (Id);
1970 function Is_Primitive_Wrapper (Id : E) return B is
1972 pragma Assert (Ekind_In (Id, E_Function, E_Procedure));
1973 return Flag195 (Id);
1974 end Is_Primitive_Wrapper;
1976 function Is_Private_Composite (Id : E) return B is
1978 pragma Assert (Is_Type (Id));
1979 return Flag107 (Id);
1980 end Is_Private_Composite;
1982 function Is_Private_Descendant (Id : E) return B is
1985 end Is_Private_Descendant;
1987 function Is_Private_Primitive (Id : E) return B is
1989 pragma Assert (Ekind_In (Id, E_Function, E_Procedure));
1990 return Flag245 (Id);
1991 end Is_Private_Primitive;
1993 function Is_Public (Id : E) return B is
1995 pragma Assert (Nkind (Id) in N_Entity);
1999 function Is_Pure (Id : E) return B is
2004 function Is_Pure_Unit_Access_Type (Id : E) return B is
2006 pragma Assert (Is_Access_Type (Id));
2007 return Flag189 (Id);
2008 end Is_Pure_Unit_Access_Type;
2010 function Is_RACW_Stub_Type (Id : E) return B is
2012 pragma Assert (Is_Type (Id));
2013 return Flag244 (Id);
2014 end Is_RACW_Stub_Type;
2016 function Is_Raised (Id : E) return B is
2018 pragma Assert (Ekind (Id) = E_Exception);
2019 return Flag224 (Id);
2022 function Is_Remote_Call_Interface (Id : E) return B is
2025 end Is_Remote_Call_Interface;
2027 function Is_Remote_Types (Id : E) return B is
2030 end Is_Remote_Types;
2032 function Is_Renaming_Of_Object (Id : E) return B is
2034 return Flag112 (Id);
2035 end Is_Renaming_Of_Object;
2037 function Is_Return_Object (Id : E) return B is
2039 return Flag209 (Id);
2040 end Is_Return_Object;
2042 function Is_Shared_Passive (Id : E) return B is
2045 end Is_Shared_Passive;
2047 function Is_Statically_Allocated (Id : E) return B is
2050 end Is_Statically_Allocated;
2052 function Is_Tag (Id : E) return B is
2054 pragma Assert (Nkind (Id) in N_Entity);
2058 function Is_Tagged_Type (Id : E) return B is
2063 function Is_Thunk (Id : E) return B is
2065 pragma Assert (Is_Subprogram (Id));
2066 return Flag225 (Id);
2069 function Is_Trivial_Subprogram (Id : E) return B is
2071 return Flag235 (Id);
2072 end Is_Trivial_Subprogram;
2074 function Is_True_Constant (Id : E) return B is
2076 return Flag163 (Id);
2077 end Is_True_Constant;
2079 function Is_Unchecked_Union (Id : E) return B is
2081 return Flag117 (Implementation_Base_Type (Id));
2082 end Is_Unchecked_Union;
2084 function Is_Underlying_Record_View (Id : E) return B is
2086 return Flag246 (Id);
2087 end Is_Underlying_Record_View;
2089 function Is_Unsigned_Type (Id : E) return B is
2091 pragma Assert (Is_Type (Id));
2092 return Flag144 (Id);
2093 end Is_Unsigned_Type;
2095 function Is_Valued_Procedure (Id : E) return B is
2097 pragma Assert (Ekind (Id) = E_Procedure);
2098 return Flag127 (Id);
2099 end Is_Valued_Procedure;
2101 function Is_Visible_Child_Unit (Id : E) return B is
2103 pragma Assert (Is_Child_Unit (Id));
2104 return Flag116 (Id);
2105 end Is_Visible_Child_Unit;
2107 function Is_Visible_Formal (Id : E) return B is
2109 return Flag206 (Id);
2110 end Is_Visible_Formal;
2112 function Is_VMS_Exception (Id : E) return B is
2114 return Flag133 (Id);
2115 end Is_VMS_Exception;
2117 function Is_Volatile (Id : E) return B is
2119 pragma Assert (Nkind (Id) in N_Entity);
2121 if Is_Type (Id) then
2122 return Flag16 (Base_Type (Id));
2128 function Itype_Printed (Id : E) return B is
2130 pragma Assert (Is_Itype (Id));
2131 return Flag202 (Id);
2134 function Kill_Elaboration_Checks (Id : E) return B is
2137 end Kill_Elaboration_Checks;
2139 function Kill_Range_Checks (Id : E) return B is
2142 end Kill_Range_Checks;
2144 function Kill_Tag_Checks (Id : E) return B is
2147 end Kill_Tag_Checks;
2149 function Known_To_Have_Preelab_Init (Id : E) return B is
2151 pragma Assert (Is_Type (Id));
2152 return Flag207 (Id);
2153 end Known_To_Have_Preelab_Init;
2155 function Last_Assignment (Id : E) return N is
2157 pragma Assert (Is_Assignable (Id));
2159 end Last_Assignment;
2161 function Last_Entity (Id : E) return E is
2166 function Limited_View (Id : E) return E is
2168 pragma Assert (Ekind (Id) = E_Package);
2172 function Lit_Indexes (Id : E) return E is
2174 pragma Assert (Is_Enumeration_Type (Id));
2178 function Lit_Strings (Id : E) return E is
2180 pragma Assert (Is_Enumeration_Type (Id));
2184 function Low_Bound_Tested (Id : E) return B is
2186 return Flag205 (Id);
2187 end Low_Bound_Tested;
2189 function Machine_Radix_10 (Id : E) return B is
2191 pragma Assert (Is_Decimal_Fixed_Point_Type (Id));
2193 end Machine_Radix_10;
2195 function Master_Id (Id : E) return E is
2197 pragma Assert (Is_Access_Type (Id));
2201 function Materialize_Entity (Id : E) return B is
2203 return Flag168 (Id);
2204 end Materialize_Entity;
2206 function Mechanism (Id : E) return M is
2208 pragma Assert (Ekind (Id) = E_Function or else Is_Formal (Id));
2209 return UI_To_Int (Uint8 (Id));
2212 function Modulus (Id : E) return Uint is
2214 pragma Assert (Is_Modular_Integer_Type (Id));
2215 return Uint17 (Base_Type (Id));
2218 function Must_Be_On_Byte_Boundary (Id : E) return B is
2220 pragma Assert (Is_Type (Id));
2221 return Flag183 (Id);
2222 end Must_Be_On_Byte_Boundary;
2224 function Must_Have_Preelab_Init (Id : E) return B is
2226 pragma Assert (Is_Type (Id));
2227 return Flag208 (Id);
2228 end Must_Have_Preelab_Init;
2230 function Needs_Debug_Info (Id : E) return B is
2232 return Flag147 (Id);
2233 end Needs_Debug_Info;
2235 function Needs_No_Actuals (Id : E) return B is
2238 (Is_Overloadable (Id)
2239 or else Ekind_In (Id, E_Subprogram_Type, E_Entry_Family));
2241 end Needs_No_Actuals;
2243 function Never_Set_In_Source (Id : E) return B is
2245 return Flag115 (Id);
2246 end Never_Set_In_Source;
2248 function Next_Inlined_Subprogram (Id : E) return E is
2251 end Next_Inlined_Subprogram;
2253 function No_Pool_Assigned (Id : E) return B is
2255 pragma Assert (Is_Access_Type (Id));
2256 return Flag131 (Root_Type (Id));
2257 end No_Pool_Assigned;
2259 function No_Return (Id : E) return B is
2261 return Flag113 (Id);
2264 function No_Strict_Aliasing (Id : E) return B is
2266 pragma Assert (Is_Access_Type (Id));
2267 return Flag136 (Base_Type (Id));
2268 end No_Strict_Aliasing;
2270 function Non_Binary_Modulus (Id : E) return B is
2272 pragma Assert (Is_Type (Id));
2273 return Flag58 (Base_Type (Id));
2274 end Non_Binary_Modulus;
2276 function Non_Limited_View (Id : E) return E is
2278 pragma Assert (Ekind (Id) in Incomplete_Kind);
2280 end Non_Limited_View;
2282 function Nonzero_Is_True (Id : E) return B is
2284 pragma Assert (Root_Type (Id) = Standard_Boolean);
2285 return Flag162 (Base_Type (Id));
2286 end Nonzero_Is_True;
2288 function Normalized_First_Bit (Id : E) return U is
2290 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
2292 end Normalized_First_Bit;
2294 function Normalized_Position (Id : E) return U is
2296 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
2298 end Normalized_Position;
2300 function Normalized_Position_Max (Id : E) return U is
2302 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
2304 end Normalized_Position_Max;
2306 function OK_To_Reference (Id : E) return B is
2308 pragma Assert (Is_Type (Id));
2309 return Flag249 (Id);
2310 end OK_To_Reference;
2312 function OK_To_Rename (Id : E) return B is
2314 pragma Assert (Ekind (Id) = E_Variable);
2315 return Flag247 (Id);
2318 function OK_To_Reorder_Components (Id : E) return B is
2320 pragma Assert (Is_Record_Type (Id));
2321 return Flag239 (Base_Type (Id));
2322 end OK_To_Reorder_Components;
2324 function Optimize_Alignment_Space (Id : E) return B is
2327 (Is_Type (Id) or else Ekind_In (Id, E_Constant, E_Variable));
2328 return Flag241 (Id);
2329 end Optimize_Alignment_Space;
2331 function Optimize_Alignment_Time (Id : E) return B is
2334 (Is_Type (Id) or else Ekind_In (Id, E_Constant, E_Variable));
2335 return Flag242 (Id);
2336 end Optimize_Alignment_Time;
2338 function Original_Array_Type (Id : E) return E is
2340 pragma Assert (Is_Array_Type (Id) or else Is_Modular_Integer_Type (Id));
2342 end Original_Array_Type;
2344 function Original_Record_Component (Id : E) return E is
2346 pragma Assert (Ekind_In (Id, E_Void, E_Component, E_Discriminant));
2348 end Original_Record_Component;
2350 function Overlays_Constant (Id : E) return B is
2352 return Flag243 (Id);
2353 end Overlays_Constant;
2355 function Overridden_Operation (Id : E) return E is
2358 end Overridden_Operation;
2360 function Package_Instantiation (Id : E) return N is
2362 pragma Assert (Ekind_In (Id, E_Package, E_Generic_Package));
2364 end Package_Instantiation;
2366 function Packed_Array_Type (Id : E) return E is
2368 pragma Assert (Is_Array_Type (Id));
2370 end Packed_Array_Type;
2372 function Parent_Subtype (Id : E) return E is
2374 pragma Assert (Is_Record_Type (Id));
2375 return Node19 (Base_Type (Id));
2378 function Postcondition_Proc (Id : E) return E is
2380 pragma Assert (Ekind (Id) = E_Procedure);
2382 end Postcondition_Proc;
2384 function PPC_Wrapper (Id : E) return E is
2386 pragma Assert (Ekind_In (Id, E_Entry, E_Entry_Family));
2390 function Prival (Id : E) return E is
2392 pragma Assert (Is_Protected_Component (Id));
2396 function Prival_Link (Id : E) return E is
2398 pragma Assert (Ekind_In (Id, E_Constant, E_Variable));
2402 function Private_Dependents (Id : E) return L is
2404 pragma Assert (Is_Incomplete_Or_Private_Type (Id));
2405 return Elist18 (Id);
2406 end Private_Dependents;
2408 function Private_View (Id : E) return N is
2410 pragma Assert (Is_Private_Type (Id));
2414 function Protected_Body_Subprogram (Id : E) return E is
2416 pragma Assert (Is_Subprogram (Id) or else Is_Entry (Id));
2418 end Protected_Body_Subprogram;
2420 function Protected_Formal (Id : E) return E is
2422 pragma Assert (Is_Formal (Id));
2424 end Protected_Formal;
2426 function Protection_Object (Id : E) return E is
2429 (Ekind_In (Id, E_Entry, E_Entry_Family, E_Function, E_Procedure));
2431 end Protection_Object;
2433 function Reachable (Id : E) return B is
2438 function Referenced (Id : E) return B is
2440 return Flag156 (Id);
2443 function Referenced_As_LHS (Id : E) return B is
2446 end Referenced_As_LHS;
2448 function Referenced_As_Out_Parameter (Id : E) return B is
2450 return Flag227 (Id);
2451 end Referenced_As_Out_Parameter;
2453 function Register_Exception_Call (Id : E) return N is
2455 pragma Assert (Ekind (Id) = E_Exception);
2457 end Register_Exception_Call;
2459 function Related_Array_Object (Id : E) return E is
2461 pragma Assert (Is_Array_Type (Id));
2463 end Related_Array_Object;
2465 function Related_Expression (Id : E) return N is
2467 pragma Assert (Ekind (Id) in Type_Kind
2468 or else Ekind_In (Id, E_Constant, E_Variable));
2470 end Related_Expression;
2472 function Related_Instance (Id : E) return E is
2474 pragma Assert (Ekind_In (Id, E_Package, E_Package_Body));
2476 end Related_Instance;
2478 function Related_Type (Id : E) return E is
2480 pragma Assert (Ekind_In (Id, E_Component, E_Constant, E_Variable));
2484 function Relative_Deadline_Variable (Id : E) return E is
2486 pragma Assert (Is_Task_Type (Id));
2487 return Node26 (Implementation_Base_Type (Id));
2488 end Relative_Deadline_Variable;
2490 function Renamed_Entity (Id : E) return N is
2495 function Renamed_In_Spec (Id : E) return B is
2497 pragma Assert (Ekind (Id) = E_Package);
2498 return Flag231 (Id);
2499 end Renamed_In_Spec;
2501 function Renamed_Object (Id : E) return N is
2506 function Renaming_Map (Id : E) return U is
2511 function Requires_Overriding (Id : E) return B is
2513 pragma Assert (Is_Overloadable (Id));
2514 return Flag213 (Id);
2515 end Requires_Overriding;
2517 function Return_Present (Id : E) return B is
2522 function Return_Applies_To (Id : E) return N is
2525 end Return_Applies_To;
2527 function Returns_By_Ref (Id : E) return B is
2532 function Reverse_Bit_Order (Id : E) return B is
2534 pragma Assert (Is_Record_Type (Id));
2535 return Flag164 (Base_Type (Id));
2536 end Reverse_Bit_Order;
2538 function RM_Size (Id : E) return U is
2540 pragma Assert (Is_Type (Id));
2544 function Scalar_Range (Id : E) return N is
2549 function Scale_Value (Id : E) return U is
2554 function Scope_Depth_Value (Id : E) return U is
2557 end Scope_Depth_Value;
2559 function Sec_Stack_Needed_For_Return (Id : E) return B is
2561 return Flag167 (Id);
2562 end Sec_Stack_Needed_For_Return;
2564 function Shadow_Entities (Id : E) return S is
2566 pragma Assert (Ekind_In (Id, E_Package, E_Generic_Package));
2568 end Shadow_Entities;
2570 function Shared_Var_Procs_Instance (Id : E) return E is
2572 pragma Assert (Ekind (Id) = E_Variable);
2574 end Shared_Var_Procs_Instance;
2576 function Size_Check_Code (Id : E) return N is
2578 pragma Assert (Ekind_In (Id, E_Constant, E_Variable));
2580 end Size_Check_Code;
2582 function Size_Depends_On_Discriminant (Id : E) return B is
2584 return Flag177 (Id);
2585 end Size_Depends_On_Discriminant;
2587 function Size_Known_At_Compile_Time (Id : E) return B is
2590 end Size_Known_At_Compile_Time;
2592 function Small_Value (Id : E) return R is
2594 pragma Assert (Is_Fixed_Point_Type (Id));
2595 return Ureal21 (Id);
2598 function Spec_Entity (Id : E) return E is
2600 pragma Assert (Ekind (Id) = E_Package_Body or else Is_Formal (Id));
2604 function Spec_PPC_List (Id : E) return N is
2607 (Ekind_In (Id, E_Entry, E_Entry_Family)
2608 or else Is_Subprogram (Id)
2609 or else Is_Generic_Subprogram (Id));
2613 function Storage_Size_Variable (Id : E) return E is
2615 pragma Assert (Is_Access_Type (Id) or else Is_Task_Type (Id));
2616 return Node15 (Implementation_Base_Type (Id));
2617 end Storage_Size_Variable;
2619 function Static_Elaboration_Desired (Id : E) return B is
2621 pragma Assert (Ekind (Id) = E_Package);
2623 end Static_Elaboration_Desired;
2625 function Static_Initialization (Id : E) return N is
2628 (Ekind (Id) = E_Procedure and then not Is_Dispatching_Operation (Id));
2630 end Static_Initialization;
2632 function Stored_Constraint (Id : E) return L is
2635 (Is_Composite_Type (Id) and then not Is_Array_Type (Id));
2636 return Elist23 (Id);
2637 end Stored_Constraint;
2639 function Strict_Alignment (Id : E) return B is
2641 return Flag145 (Implementation_Base_Type (Id));
2642 end Strict_Alignment;
2644 function String_Literal_Length (Id : E) return U is
2647 end String_Literal_Length;
2649 function String_Literal_Low_Bound (Id : E) return N is
2652 end String_Literal_Low_Bound;
2654 function Subprograms_For_Type (Id : E) return E is
2656 pragma Assert (Is_Type (Id) or else Is_Subprogram (Id));
2658 end Subprograms_For_Type;
2660 function Suppress_Elaboration_Warnings (Id : E) return B is
2662 return Flag148 (Id);
2663 end Suppress_Elaboration_Warnings;
2665 function Suppress_Init_Proc (Id : E) return B is
2667 return Flag105 (Base_Type (Id));
2668 end Suppress_Init_Proc;
2670 function Suppress_Style_Checks (Id : E) return B is
2672 return Flag165 (Id);
2673 end Suppress_Style_Checks;
2675 function Suppress_Value_Tracking_On_Call (Id : E) return B is
2677 return Flag217 (Id);
2678 end Suppress_Value_Tracking_On_Call;
2680 function Task_Body_Procedure (Id : E) return N is
2682 pragma Assert (Ekind (Id) in Task_Kind);
2684 end Task_Body_Procedure;
2686 function Treat_As_Volatile (Id : E) return B is
2689 end Treat_As_Volatile;
2691 function Underlying_Full_View (Id : E) return E is
2693 pragma Assert (Ekind (Id) in Private_Kind);
2695 end Underlying_Full_View;
2697 function Underlying_Record_View (Id : E) return E is
2700 end Underlying_Record_View;
2702 function Universal_Aliasing (Id : E) return B is
2704 pragma Assert (Is_Type (Id));
2705 return Flag216 (Base_Type (Id));
2706 end Universal_Aliasing;
2708 function Unset_Reference (Id : E) return N is
2711 end Unset_Reference;
2713 function Used_As_Generic_Actual (Id : E) return B is
2715 return Flag222 (Id);
2716 end Used_As_Generic_Actual;
2718 function Uses_Sec_Stack (Id : E) return B is
2723 function Vax_Float (Id : E) return B is
2725 return Flag151 (Base_Type (Id));
2728 function Warnings_Off (Id : E) return B is
2733 function Warnings_Off_Used (Id : E) return B is
2735 return Flag236 (Id);
2736 end Warnings_Off_Used;
2738 function Warnings_Off_Used_Unmodified (Id : E) return B is
2740 return Flag237 (Id);
2741 end Warnings_Off_Used_Unmodified;
2743 function Warnings_Off_Used_Unreferenced (Id : E) return B is
2745 return Flag238 (Id);
2746 end Warnings_Off_Used_Unreferenced;
2748 function Wrapped_Entity (Id : E) return E is
2750 pragma Assert (Ekind_In (Id, E_Function, E_Procedure)
2751 and then Is_Primitive_Wrapper (Id));
2755 function Was_Hidden (Id : E) return B is
2757 return Flag196 (Id);
2760 ------------------------------
2761 -- Classification Functions --
2762 ------------------------------
2764 function Is_Access_Type (Id : E) return B is
2766 return Ekind (Id) in Access_Kind;
2769 function Is_Access_Protected_Subprogram_Type (Id : E) return B is
2771 return Ekind (Id) in Access_Protected_Kind;
2772 end Is_Access_Protected_Subprogram_Type;
2774 function Is_Access_Subprogram_Type (Id : E) return B is
2776 return Ekind (Id) in Access_Subprogram_Kind;
2777 end Is_Access_Subprogram_Type;
2779 function Is_Aggregate_Type (Id : E) return B is
2781 return Ekind (Id) in Aggregate_Kind;
2782 end Is_Aggregate_Type;
2784 function Is_Array_Type (Id : E) return B is
2786 return Ekind (Id) in Array_Kind;
2789 function Is_Assignable (Id : E) return B is
2791 return Ekind (Id) in Assignable_Kind;
2794 function Is_Class_Wide_Type (Id : E) return B is
2796 return Ekind (Id) in Class_Wide_Kind;
2797 end Is_Class_Wide_Type;
2799 function Is_Composite_Type (Id : E) return B is
2801 return Ekind (Id) in Composite_Kind;
2802 end Is_Composite_Type;
2804 function Is_Concurrent_Body (Id : E) return B is
2806 return Ekind (Id) in
2807 Concurrent_Body_Kind;
2808 end Is_Concurrent_Body;
2810 function Is_Concurrent_Record_Type (Id : E) return B is
2813 end Is_Concurrent_Record_Type;
2815 function Is_Concurrent_Type (Id : E) return B is
2817 return Ekind (Id) in Concurrent_Kind;
2818 end Is_Concurrent_Type;
2820 function Is_Decimal_Fixed_Point_Type (Id : E) return B is
2822 return Ekind (Id) in
2823 Decimal_Fixed_Point_Kind;
2824 end Is_Decimal_Fixed_Point_Type;
2826 function Is_Digits_Type (Id : E) return B is
2828 return Ekind (Id) in Digits_Kind;
2831 function Is_Discrete_Or_Fixed_Point_Type (Id : E) return B is
2833 return Ekind (Id) in Discrete_Or_Fixed_Point_Kind;
2834 end Is_Discrete_Or_Fixed_Point_Type;
2836 function Is_Discrete_Type (Id : E) return B is
2838 return Ekind (Id) in Discrete_Kind;
2839 end Is_Discrete_Type;
2841 function Is_Elementary_Type (Id : E) return B is
2843 return Ekind (Id) in Elementary_Kind;
2844 end Is_Elementary_Type;
2846 function Is_Entry (Id : E) return B is
2848 return Ekind (Id) in Entry_Kind;
2851 function Is_Enumeration_Type (Id : E) return B is
2853 return Ekind (Id) in
2855 end Is_Enumeration_Type;
2857 function Is_Fixed_Point_Type (Id : E) return B is
2859 return Ekind (Id) in
2861 end Is_Fixed_Point_Type;
2863 function Is_Floating_Point_Type (Id : E) return B is
2865 return Ekind (Id) in Float_Kind;
2866 end Is_Floating_Point_Type;
2868 function Is_Formal (Id : E) return B is
2870 return Ekind (Id) in Formal_Kind;
2873 function Is_Formal_Object (Id : E) return B is
2875 return Ekind (Id) in Formal_Object_Kind;
2876 end Is_Formal_Object;
2878 function Is_Generic_Subprogram (Id : E) return B is
2880 return Ekind (Id) in Generic_Subprogram_Kind;
2881 end Is_Generic_Subprogram;
2883 function Is_Generic_Unit (Id : E) return B is
2885 return Ekind (Id) in Generic_Unit_Kind;
2886 end Is_Generic_Unit;
2888 function Is_Incomplete_Or_Private_Type (Id : E) return B is
2890 return Ekind (Id) in
2891 Incomplete_Or_Private_Kind;
2892 end Is_Incomplete_Or_Private_Type;
2894 function Is_Incomplete_Type (Id : E) return B is
2896 return Ekind (Id) in
2898 end Is_Incomplete_Type;
2900 function Is_Integer_Type (Id : E) return B is
2902 return Ekind (Id) in Integer_Kind;
2903 end Is_Integer_Type;
2905 function Is_Modular_Integer_Type (Id : E) return B is
2907 return Ekind (Id) in
2908 Modular_Integer_Kind;
2909 end Is_Modular_Integer_Type;
2911 function Is_Named_Number (Id : E) return B is
2913 return Ekind (Id) in Named_Kind;
2914 end Is_Named_Number;
2916 function Is_Numeric_Type (Id : E) return B is
2918 return Ekind (Id) in Numeric_Kind;
2919 end Is_Numeric_Type;
2921 function Is_Object (Id : E) return B is
2923 return Ekind (Id) in Object_Kind;
2926 function Is_Ordinary_Fixed_Point_Type (Id : E) return B is
2928 return Ekind (Id) in
2929 Ordinary_Fixed_Point_Kind;
2930 end Is_Ordinary_Fixed_Point_Type;
2932 function Is_Overloadable (Id : E) return B is
2934 return Ekind (Id) in Overloadable_Kind;
2935 end Is_Overloadable;
2937 function Is_Private_Type (Id : E) return B is
2939 return Ekind (Id) in Private_Kind;
2940 end Is_Private_Type;
2942 function Is_Protected_Type (Id : E) return B is
2944 return Ekind (Id) in Protected_Kind;
2945 end Is_Protected_Type;
2947 function Is_Real_Type (Id : E) return B is
2949 return Ekind (Id) in Real_Kind;
2952 function Is_Record_Type (Id : E) return B is
2954 return Ekind (Id) in Record_Kind;
2957 function Is_Scalar_Type (Id : E) return B is
2959 return Ekind (Id) in Scalar_Kind;
2962 function Is_Signed_Integer_Type (Id : E) return B is
2964 return Ekind (Id) in Signed_Integer_Kind;
2965 end Is_Signed_Integer_Type;
2967 function Is_Subprogram (Id : E) return B is
2969 return Ekind (Id) in Subprogram_Kind;
2972 function Is_Task_Type (Id : E) return B is
2974 return Ekind (Id) in Task_Kind;
2977 function Is_Type (Id : E) return B is
2979 return Ekind (Id) in Type_Kind;
2982 ------------------------------
2983 -- Attribute Set Procedures --
2984 ------------------------------
2986 -- Note: in many of these set procedures an "obvious" assertion is missing.
2987 -- The reason for this is that in many cases, a field is set before the
2988 -- Ekind field is set, so that the field is set when Ekind = E_Void. It
2989 -- it is possible to add assertions that specifically include the E_Void
2990 -- possibility, but in some cases, we just omit the assertions.
2992 procedure Set_Accept_Address (Id : E; V : L) is
2994 Set_Elist21 (Id, V);
2995 end Set_Accept_Address;
2997 procedure Set_Access_Disp_Table (Id : E; V : L) is
2999 pragma Assert (Is_Tagged_Type (Id) and then Id = Base_Type (Id));
3000 Set_Elist16 (Id, V);
3001 end Set_Access_Disp_Table;
3003 procedure Set_Associated_Final_Chain (Id : E; V : E) is
3005 pragma Assert (Is_Access_Type (Id));
3007 end Set_Associated_Final_Chain;
3009 procedure Set_Associated_Formal_Package (Id : E; V : E) is
3012 end Set_Associated_Formal_Package;
3014 procedure Set_Associated_Node_For_Itype (Id : E; V : E) is
3017 end Set_Associated_Node_For_Itype;
3019 procedure Set_Associated_Storage_Pool (Id : E; V : E) is
3021 pragma Assert (Is_Access_Type (Id) and then Id = Base_Type (Id));
3023 end Set_Associated_Storage_Pool;
3025 procedure Set_Actual_Subtype (Id : E; V : E) is
3028 (Ekind_In (Id, E_Constant, E_Variable, E_Generic_In_Out_Parameter)
3029 or else Is_Formal (Id));
3031 end Set_Actual_Subtype;
3033 procedure Set_Address_Taken (Id : E; V : B := True) is
3035 Set_Flag104 (Id, V);
3036 end Set_Address_Taken;
3038 procedure Set_Alias (Id : E; V : E) is
3041 (Is_Overloadable (Id) or else Ekind (Id) = E_Subprogram_Type);
3045 procedure Set_Alignment (Id : E; V : U) is
3047 pragma Assert (Is_Type (Id)
3048 or else Is_Formal (Id)
3049 or else Ekind_In (Id, E_Loop_Parameter,
3056 procedure Set_Barrier_Function (Id : E; V : N) is
3058 pragma Assert (Is_Entry (Id));
3060 end Set_Barrier_Function;
3062 procedure Set_Block_Node (Id : E; V : N) is
3064 pragma Assert (Ekind (Id) = E_Block);
3068 procedure Set_Body_Entity (Id : E; V : E) is
3070 pragma Assert (Ekind_In (Id, E_Package, E_Generic_Package));
3072 end Set_Body_Entity;
3074 procedure Set_Body_Needed_For_SAL (Id : E; V : B := True) is
3077 (Ekind (Id) = E_Package
3078 or else Is_Subprogram (Id)
3079 or else Is_Generic_Unit (Id));
3081 end Set_Body_Needed_For_SAL;
3083 procedure Set_C_Pass_By_Copy (Id : E; V : B := True) is
3085 pragma Assert (Is_Record_Type (Id) and then Id = Base_Type (Id));
3086 Set_Flag125 (Id, V);
3087 end Set_C_Pass_By_Copy;
3089 procedure Set_Can_Never_Be_Null (Id : E; V : B := True) is
3092 end Set_Can_Never_Be_Null;
3094 procedure Set_Checks_May_Be_Suppressed (Id : E; V : B := True) is
3097 end Set_Checks_May_Be_Suppressed;
3099 procedure Set_Class_Wide_Type (Id : E; V : E) is
3101 pragma Assert (Is_Type (Id));
3103 end Set_Class_Wide_Type;
3105 procedure Set_Cloned_Subtype (Id : E; V : E) is
3107 pragma Assert (Ekind_In (Id, E_Record_Subtype, E_Class_Wide_Subtype));
3109 end Set_Cloned_Subtype;
3111 procedure Set_Component_Bit_Offset (Id : E; V : U) is
3113 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
3115 end Set_Component_Bit_Offset;
3117 procedure Set_Component_Clause (Id : E; V : N) is
3119 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
3121 end Set_Component_Clause;
3123 procedure Set_Component_Size (Id : E; V : U) is
3125 pragma Assert (Is_Array_Type (Id) and then Id = Base_Type (Id));
3127 end Set_Component_Size;
3129 procedure Set_Component_Type (Id : E; V : E) is
3131 pragma Assert (Is_Array_Type (Id) and then Id = Base_Type (Id));
3133 end Set_Component_Type;
3135 procedure Set_Corresponding_Concurrent_Type (Id : E; V : E) is
3138 (Ekind (Id) = E_Record_Type and then Is_Concurrent_Type (V));
3140 end Set_Corresponding_Concurrent_Type;
3142 procedure Set_Corresponding_Discriminant (Id : E; V : E) is
3144 pragma Assert (Ekind (Id) = E_Discriminant);
3146 end Set_Corresponding_Discriminant;
3148 procedure Set_Corresponding_Equality (Id : E; V : E) is
3151 (Ekind (Id) = E_Function
3152 and then not Comes_From_Source (Id)
3153 and then Chars (Id) = Name_Op_Ne);
3155 end Set_Corresponding_Equality;
3157 procedure Set_Corresponding_Protected_Entry (Id : E; V : E) is
3159 pragma Assert (Ekind_In (Id, E_Void, E_Subprogram_Body));
3161 end Set_Corresponding_Protected_Entry;
3163 procedure Set_Corresponding_Record_Type (Id : E; V : E) is
3165 pragma Assert (Is_Concurrent_Type (Id));
3167 end Set_Corresponding_Record_Type;
3169 procedure Set_Corresponding_Remote_Type (Id : E; V : E) is
3172 end Set_Corresponding_Remote_Type;
3174 procedure Set_Current_Use_Clause (Id : E; V : E) is
3176 pragma Assert (Ekind (Id) = E_Package or else Is_Type (Id));
3178 end Set_Current_Use_Clause;
3180 procedure Set_Current_Value (Id : E; V : N) is
3182 pragma Assert (Ekind (Id) in Object_Kind or else Ekind (Id) = E_Void);
3184 end Set_Current_Value;
3186 procedure Set_CR_Discriminant (Id : E; V : E) is
3189 end Set_CR_Discriminant;
3191 procedure Set_Debug_Info_Off (Id : E; V : B := True) is
3193 Set_Flag166 (Id, V);
3194 end Set_Debug_Info_Off;
3196 procedure Set_Debug_Renaming_Link (Id : E; V : E) is
3199 end Set_Debug_Renaming_Link;
3201 procedure Set_Default_Expr_Function (Id : E; V : E) is
3203 pragma Assert (Is_Formal (Id));
3205 end Set_Default_Expr_Function;
3207 procedure Set_Default_Expressions_Processed (Id : E; V : B := True) is
3209 Set_Flag108 (Id, V);
3210 end Set_Default_Expressions_Processed;
3212 procedure Set_Default_Value (Id : E; V : N) is
3214 pragma Assert (Is_Formal (Id));
3216 end Set_Default_Value;
3218 procedure Set_Delay_Cleanups (Id : E; V : B := True) is
3222 or else Is_Task_Type (Id)
3223 or else Ekind (Id) = E_Block);
3224 Set_Flag114 (Id, V);
3225 end Set_Delay_Cleanups;
3227 procedure Set_Delay_Subprogram_Descriptors (Id : E; V : B := True) is
3230 (Is_Subprogram (Id) or else Ekind_In (Id, E_Package, E_Package_Body));
3232 end Set_Delay_Subprogram_Descriptors;
3234 procedure Set_Delta_Value (Id : E; V : R) is
3236 pragma Assert (Is_Fixed_Point_Type (Id));
3237 Set_Ureal18 (Id, V);
3238 end Set_Delta_Value;
3240 procedure Set_Dependent_Instances (Id : E; V : L) is
3242 pragma Assert (Is_Generic_Instance (Id));
3244 end Set_Dependent_Instances;
3246 procedure Set_Depends_On_Private (Id : E; V : B := True) is
3248 pragma Assert (Nkind (Id) in N_Entity);
3250 end Set_Depends_On_Private;
3252 procedure Set_Digits_Value (Id : E; V : U) is
3255 (Is_Floating_Point_Type (Id)
3256 or else Is_Decimal_Fixed_Point_Type (Id));
3258 end Set_Digits_Value;
3260 procedure Set_Directly_Designated_Type (Id : E; V : E) is
3263 end Set_Directly_Designated_Type;
3265 procedure Set_Discard_Names (Id : E; V : B := True) is
3268 end Set_Discard_Names;
3270 procedure Set_Discriminal (Id : E; V : E) is
3272 pragma Assert (Ekind (Id) = E_Discriminant);
3274 end Set_Discriminal;
3276 procedure Set_Discriminal_Link (Id : E; V : E) is
3279 end Set_Discriminal_Link;
3281 procedure Set_Discriminant_Checking_Func (Id : E; V : E) is
3283 pragma Assert (Ekind (Id) = E_Component);
3285 end Set_Discriminant_Checking_Func;
3287 procedure Set_Discriminant_Constraint (Id : E; V : L) is
3289 pragma Assert (Nkind (Id) in N_Entity);
3290 Set_Elist21 (Id, V);
3291 end Set_Discriminant_Constraint;
3293 procedure Set_Discriminant_Default_Value (Id : E; V : N) is
3296 end Set_Discriminant_Default_Value;
3298 procedure Set_Discriminant_Number (Id : E; V : U) is
3301 end Set_Discriminant_Number;
3303 procedure Set_Dispatch_Table_Wrappers (Id : E; V : L) is
3305 pragma Assert (Is_Tagged_Type (Id) and then Id = Base_Type (Id));
3306 Set_Elist26 (Id, V);
3307 end Set_Dispatch_Table_Wrappers;
3309 procedure Set_DT_Entry_Count (Id : E; V : U) is
3311 pragma Assert (Ekind (Id) = E_Component);
3313 end Set_DT_Entry_Count;
3315 procedure Set_DT_Offset_To_Top_Func (Id : E; V : E) is
3317 pragma Assert (Ekind (Id) = E_Component and then Is_Tag (Id));
3319 end Set_DT_Offset_To_Top_Func;
3321 procedure Set_DT_Position (Id : E; V : U) is
3323 pragma Assert (Ekind_In (Id, E_Function, E_Procedure));
3325 end Set_DT_Position;
3327 procedure Set_DTC_Entity (Id : E; V : E) is
3329 pragma Assert (Ekind_In (Id, E_Function, E_Procedure));
3333 procedure Set_Elaborate_Body_Desirable (Id : E; V : B := True) is
3335 pragma Assert (Ekind (Id) = E_Package);
3336 Set_Flag210 (Id, V);
3337 end Set_Elaborate_Body_Desirable;
3339 procedure Set_Elaboration_Entity (Id : E; V : E) is
3344 Ekind (Id) = E_Package
3346 Is_Generic_Unit (Id));
3348 end Set_Elaboration_Entity;
3350 procedure Set_Elaboration_Entity_Required (Id : E; V : B := True) is
3355 Ekind (Id) = E_Package
3357 Is_Generic_Unit (Id));
3358 Set_Flag174 (Id, V);
3359 end Set_Elaboration_Entity_Required;
3361 procedure Set_Enclosing_Scope (Id : E; V : E) is
3364 end Set_Enclosing_Scope;
3366 procedure Set_Entry_Accepted (Id : E; V : B := True) is
3368 pragma Assert (Is_Entry (Id));
3369 Set_Flag152 (Id, V);
3370 end Set_Entry_Accepted;
3372 procedure Set_Entry_Bodies_Array (Id : E; V : E) is
3375 end Set_Entry_Bodies_Array;
3377 procedure Set_Entry_Cancel_Parameter (Id : E; V : E) is
3380 end Set_Entry_Cancel_Parameter;
3382 procedure Set_Entry_Component (Id : E; V : E) is
3385 end Set_Entry_Component;
3387 procedure Set_Entry_Formal (Id : E; V : E) is
3390 end Set_Entry_Formal;
3392 procedure Set_Entry_Index_Constant (Id : E; V : E) is
3394 pragma Assert (Ekind (Id) = E_Entry_Index_Parameter);
3396 end Set_Entry_Index_Constant;
3398 procedure Set_Entry_Parameters_Type (Id : E; V : E) is
3401 end Set_Entry_Parameters_Type;
3403 procedure Set_Enum_Pos_To_Rep (Id : E; V : E) is
3405 pragma Assert (Ekind (Id) = E_Enumeration_Type);
3407 end Set_Enum_Pos_To_Rep;
3409 procedure Set_Enumeration_Pos (Id : E; V : U) is
3411 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
3413 end Set_Enumeration_Pos;
3415 procedure Set_Enumeration_Rep (Id : E; V : U) is
3417 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
3419 end Set_Enumeration_Rep;
3421 procedure Set_Enumeration_Rep_Expr (Id : E; V : N) is
3423 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
3425 end Set_Enumeration_Rep_Expr;
3427 procedure Set_Equivalent_Type (Id : E; V : E) is
3430 (Ekind_In (Id, E_Class_Wide_Type,
3431 E_Class_Wide_Subtype,
3432 E_Access_Protected_Subprogram_Type,
3433 E_Anonymous_Access_Protected_Subprogram_Type,
3434 E_Access_Subprogram_Type,
3437 end Set_Equivalent_Type;
3439 procedure Set_Esize (Id : E; V : U) is
3444 procedure Set_Exception_Code (Id : E; V : U) is
3446 pragma Assert (Ekind (Id) = E_Exception);
3448 end Set_Exception_Code;
3450 procedure Set_Extra_Accessibility (Id : E; V : E) is
3452 pragma Assert (Is_Formal (Id) or else Ekind (Id) = E_Variable);
3454 end Set_Extra_Accessibility;
3456 procedure Set_Extra_Constrained (Id : E; V : E) is
3458 pragma Assert (Is_Formal (Id) or else Ekind (Id) = E_Variable);
3460 end Set_Extra_Constrained;
3462 procedure Set_Extra_Formal (Id : E; V : E) is
3465 end Set_Extra_Formal;
3467 procedure Set_Extra_Formals (Id : E; V : E) is
3470 (Is_Overloadable (Id)
3471 or else Ekind_In (Id, E_Entry_Family,
3473 E_Subprogram_Type));
3475 end Set_Extra_Formals;
3477 procedure Set_Can_Use_Internal_Rep (Id : E; V : B := True) is
3480 (Is_Access_Subprogram_Type (Id)
3481 and then Id = Base_Type (Id));
3482 Set_Flag229 (Id, V);
3483 end Set_Can_Use_Internal_Rep;
3485 procedure Set_Finalization_Chain_Entity (Id : E; V : E) is
3488 end Set_Finalization_Chain_Entity;
3490 procedure Set_Finalize_Storage_Only (Id : E; V : B := True) is
3492 pragma Assert (Is_Type (Id) and then Id = Base_Type (Id));
3493 Set_Flag158 (Id, V);
3494 end Set_Finalize_Storage_Only;
3496 procedure Set_First_Entity (Id : E; V : E) is
3499 end Set_First_Entity;
3501 procedure Set_First_Exit_Statement (Id : E; V : N) is
3503 pragma Assert (Ekind (Id) = E_Loop);
3505 end Set_First_Exit_Statement;
3507 procedure Set_First_Index (Id : E; V : N) is
3509 pragma Assert (Is_Array_Type (Id) or else Is_String_Type (Id));
3511 end Set_First_Index;
3513 procedure Set_First_Literal (Id : E; V : E) is
3515 pragma Assert (Is_Enumeration_Type (Id));
3517 end Set_First_Literal;
3519 procedure Set_First_Optional_Parameter (Id : E; V : E) is
3521 pragma Assert (Ekind_In (Id, E_Function, E_Procedure));
3523 end Set_First_Optional_Parameter;
3525 procedure Set_First_Private_Entity (Id : E; V : E) is
3527 pragma Assert (Ekind_In (Id, E_Package, E_Generic_Package)
3528 or else Ekind (Id) in Concurrent_Kind);
3530 end Set_First_Private_Entity;
3532 procedure Set_First_Rep_Item (Id : E; V : N) is
3535 end Set_First_Rep_Item;
3537 procedure Set_Freeze_Node (Id : E; V : N) is
3540 end Set_Freeze_Node;
3542 procedure Set_From_With_Type (Id : E; V : B := True) is
3546 or else Ekind (Id) = E_Package);
3547 Set_Flag159 (Id, V);
3548 end Set_From_With_Type;
3550 procedure Set_Full_View (Id : E; V : E) is
3552 pragma Assert (Is_Type (Id) or else Ekind (Id) = E_Constant);
3556 procedure Set_Generic_Homonym (Id : E; V : E) is
3559 end Set_Generic_Homonym;
3561 procedure Set_Generic_Renamings (Id : E; V : L) is
3563 Set_Elist23 (Id, V);
3564 end Set_Generic_Renamings;
3566 procedure Set_Handler_Records (Id : E; V : S) is
3569 end Set_Handler_Records;
3571 procedure Set_Has_Aliased_Components (Id : E; V : B := True) is
3573 pragma Assert (Id = Base_Type (Id));
3574 Set_Flag135 (Id, V);
3575 end Set_Has_Aliased_Components;
3577 procedure Set_Has_Alignment_Clause (Id : E; V : B := True) is
3580 end Set_Has_Alignment_Clause;
3582 procedure Set_Has_All_Calls_Remote (Id : E; V : B := True) is
3585 end Set_Has_All_Calls_Remote;
3587 procedure Set_Has_Anon_Block_Suffix (Id : E; V : B := True) is
3589 Set_Flag201 (Id, V);
3590 end Set_Has_Anon_Block_Suffix;
3592 procedure Set_Has_Atomic_Components (Id : E; V : B := True) is
3594 pragma Assert (not Is_Type (Id) or else Id = Base_Type (Id));
3596 end Set_Has_Atomic_Components;
3598 procedure Set_Has_Biased_Representation (Id : E; V : B := True) is
3601 ((V = False) or else (Is_Discrete_Type (Id) or else Is_Object (Id)));
3602 Set_Flag139 (Id, V);
3603 end Set_Has_Biased_Representation;
3605 procedure Set_Has_Completion (Id : E; V : B := True) is
3608 end Set_Has_Completion;
3610 procedure Set_Has_Completion_In_Body (Id : E; V : B := True) is
3612 pragma Assert (Is_Type (Id));
3614 end Set_Has_Completion_In_Body;
3616 procedure Set_Has_Complex_Representation (Id : E; V : B := True) is
3618 pragma Assert (Ekind (Id) = E_Record_Type);
3619 Set_Flag140 (Id, V);
3620 end Set_Has_Complex_Representation;
3622 procedure Set_Has_Component_Size_Clause (Id : E; V : B := True) is
3624 pragma Assert (Ekind (Id) = E_Array_Type);
3626 end Set_Has_Component_Size_Clause;
3628 procedure Set_Has_Constrained_Partial_View (Id : E; V : B := True) is
3630 pragma Assert (Is_Type (Id));
3631 Set_Flag187 (Id, V);
3632 end Set_Has_Constrained_Partial_View;
3634 procedure Set_Has_Contiguous_Rep (Id : E; V : B := True) is
3636 Set_Flag181 (Id, V);
3637 end Set_Has_Contiguous_Rep;
3639 procedure Set_Has_Controlled_Component (Id : E; V : B := True) is
3641 pragma Assert (Id = Base_Type (Id));
3643 end Set_Has_Controlled_Component;
3645 procedure Set_Has_Controlling_Result (Id : E; V : B := True) is
3648 end Set_Has_Controlling_Result;
3650 procedure Set_Has_Convention_Pragma (Id : E; V : B := True) is
3652 Set_Flag119 (Id, V);
3653 end Set_Has_Convention_Pragma;
3655 procedure Set_Has_Delayed_Aspects (Id : E; V : B := True) is
3657 pragma Assert (Nkind (Id) in N_Entity);
3658 Set_Flag200 (Id, V);
3659 end Set_Has_Delayed_Aspects;
3661 procedure Set_Has_Delayed_Freeze (Id : E; V : B := True) is
3663 pragma Assert (Nkind (Id) in N_Entity);
3665 end Set_Has_Delayed_Freeze;
3667 procedure Set_Has_Discriminants (Id : E; V : B := True) is
3669 pragma Assert (Nkind (Id) in N_Entity);
3671 end Set_Has_Discriminants;
3673 procedure Set_Has_Dispatch_Table (Id : E; V : B := True) is
3675 pragma Assert (Ekind (Id) = E_Record_Type
3676 and then Is_Tagged_Type (Id));
3677 Set_Flag220 (Id, V);
3678 end Set_Has_Dispatch_Table;
3680 procedure Set_Has_Enumeration_Rep_Clause (Id : E; V : B := True) is
3682 pragma Assert (Is_Enumeration_Type (Id));
3684 end Set_Has_Enumeration_Rep_Clause;
3686 procedure Set_Has_Exit (Id : E; V : B := True) is
3691 procedure Set_Has_External_Tag_Rep_Clause (Id : E; V : B := True) is
3693 pragma Assert (Is_Tagged_Type (Id));
3694 Set_Flag110 (Id, V);
3695 end Set_Has_External_Tag_Rep_Clause;
3697 procedure Set_Has_Forward_Instantiation (Id : E; V : B := True) is
3699 Set_Flag175 (Id, V);
3700 end Set_Has_Forward_Instantiation;
3702 procedure Set_Has_Fully_Qualified_Name (Id : E; V : B := True) is
3704 Set_Flag173 (Id, V);
3705 end Set_Has_Fully_Qualified_Name;
3707 procedure Set_Has_Gigi_Rep_Item (Id : E; V : B := True) is
3710 end Set_Has_Gigi_Rep_Item;
3712 procedure Set_Has_Homonym (Id : E; V : B := True) is
3715 end Set_Has_Homonym;
3717 procedure Set_Has_Inheritable_Invariants (Id : E; V : B := True) is
3719 pragma Assert (Is_Type (Id));
3720 Set_Flag248 (Id, V);
3721 end Set_Has_Inheritable_Invariants;
3723 procedure Set_Has_Initial_Value (Id : E; V : B := True) is
3725 pragma Assert (Ekind_In (Id, E_Variable, E_Out_Parameter));
3726 Set_Flag219 (Id, V);
3727 end Set_Has_Initial_Value;
3729 procedure Set_Has_Invariants (Id : E; V : B := True) is
3731 pragma Assert (Is_Type (Id)
3732 or else Ekind (Id) = E_Procedure
3733 or else Ekind (Id) = E_Void);
3734 Set_Flag232 (Id, V);
3735 end Set_Has_Invariants;
3737 procedure Set_Has_Machine_Radix_Clause (Id : E; V : B := True) is
3739 pragma Assert (Is_Decimal_Fixed_Point_Type (Id));
3741 end Set_Has_Machine_Radix_Clause;
3743 procedure Set_Has_Master_Entity (Id : E; V : B := True) is
3746 end Set_Has_Master_Entity;
3748 procedure Set_Has_Missing_Return (Id : E; V : B := True) is
3750 pragma Assert (Ekind_In (Id, E_Function, E_Generic_Function));
3751 Set_Flag142 (Id, V);
3752 end Set_Has_Missing_Return;
3754 procedure Set_Has_Nested_Block_With_Handler (Id : E; V : B := True) is
3756 Set_Flag101 (Id, V);
3757 end Set_Has_Nested_Block_With_Handler;
3759 procedure Set_Has_Up_Level_Access (Id : E; V : B := True) is
3761 pragma Assert (Ekind_In (Id, E_Variable, E_Constant, E_Loop_Parameter));
3762 Set_Flag215 (Id, V);
3763 end Set_Has_Up_Level_Access;
3765 procedure Set_Has_Non_Standard_Rep (Id : E; V : B := True) is
3767 pragma Assert (Id = Base_Type (Id));
3769 end Set_Has_Non_Standard_Rep;
3771 procedure Set_Has_Object_Size_Clause (Id : E; V : B := True) is
3773 pragma Assert (Is_Type (Id));
3774 Set_Flag172 (Id, V);
3775 end Set_Has_Object_Size_Clause;
3777 procedure Set_Has_Per_Object_Constraint (Id : E; V : B := True) is
3779 Set_Flag154 (Id, V);
3780 end Set_Has_Per_Object_Constraint;
3782 procedure Set_Has_Persistent_BSS (Id : E; V : B := True) is
3784 Set_Flag188 (Id, V);
3785 end Set_Has_Persistent_BSS;
3787 procedure Set_Has_Postconditions (Id : E; V : B := True) is
3789 pragma Assert (Is_Subprogram (Id));
3790 Set_Flag240 (Id, V);
3791 end Set_Has_Postconditions;
3793 procedure Set_Has_Pragma_Controlled (Id : E; V : B := True) is
3795 pragma Assert (Is_Access_Type (Id));
3796 Set_Flag27 (Base_Type (Id), V);
3797 end Set_Has_Pragma_Controlled;
3799 procedure Set_Has_Pragma_Elaborate_Body (Id : E; V : B := True) is
3801 Set_Flag150 (Id, V);
3802 end Set_Has_Pragma_Elaborate_Body;
3804 procedure Set_Has_Pragma_Inline (Id : E; V : B := True) is
3806 Set_Flag157 (Id, V);
3807 end Set_Has_Pragma_Inline;
3809 procedure Set_Has_Pragma_Inline_Always (Id : E; V : B := True) is
3811 Set_Flag230 (Id, V);
3812 end Set_Has_Pragma_Inline_Always;
3814 procedure Set_Has_Pragma_Ordered (Id : E; V : B := True) is
3816 pragma Assert (Is_Enumeration_Type (Id));
3817 pragma Assert (Id = Base_Type (Id));
3818 Set_Flag198 (Id, V);
3819 end Set_Has_Pragma_Ordered;
3821 procedure Set_Has_Pragma_Pack (Id : E; V : B := True) is
3823 pragma Assert (Is_Array_Type (Id) or else Is_Record_Type (Id));
3824 pragma Assert (Id = Base_Type (Id));
3825 Set_Flag121 (Id, V);
3826 end Set_Has_Pragma_Pack;
3828 procedure Set_Has_Pragma_Preelab_Init (Id : E; V : B := True) is
3830 Set_Flag221 (Id, V);
3831 end Set_Has_Pragma_Preelab_Init;
3833 procedure Set_Has_Pragma_Pure (Id : E; V : B := True) is
3835 Set_Flag203 (Id, V);
3836 end Set_Has_Pragma_Pure;
3838 procedure Set_Has_Pragma_Pure_Function (Id : E; V : B := True) is
3840 Set_Flag179 (Id, V);
3841 end Set_Has_Pragma_Pure_Function;
3843 procedure Set_Has_Pragma_Thread_Local_Storage (Id : E; V : B := True) is
3845 Set_Flag169 (Id, V);
3846 end Set_Has_Pragma_Thread_Local_Storage;
3848 procedure Set_Has_Pragma_Unmodified (Id : E; V : B := True) is
3850 Set_Flag233 (Id, V);
3851 end Set_Has_Pragma_Unmodified;
3853 procedure Set_Has_Pragma_Unreferenced (Id : E; V : B := True) is
3855 Set_Flag180 (Id, V);
3856 end Set_Has_Pragma_Unreferenced;
3858 procedure Set_Has_Pragma_Unreferenced_Objects (Id : E; V : B := True) is
3860 pragma Assert (Is_Type (Id));
3861 Set_Flag212 (Id, V);
3862 end Set_Has_Pragma_Unreferenced_Objects;
3864 procedure Set_Has_Predicates (Id : E; V : B := True) is
3866 pragma Assert (Is_Type (Id)
3867 or else Ekind (Id) = E_Function
3868 or else Ekind (Id) = E_Void);
3869 Set_Flag250 (Id, V);
3870 end Set_Has_Predicates;
3872 procedure Set_Has_Primitive_Operations (Id : E; V : B := True) is
3874 pragma Assert (Id = Base_Type (Id));
3875 Set_Flag120 (Id, V);
3876 end Set_Has_Primitive_Operations;
3878 procedure Set_Has_Private_Declaration (Id : E; V : B := True) is
3880 Set_Flag155 (Id, V);
3881 end Set_Has_Private_Declaration;
3883 procedure Set_Has_Qualified_Name (Id : E; V : B := True) is
3885 Set_Flag161 (Id, V);
3886 end Set_Has_Qualified_Name;
3888 procedure Set_Has_RACW (Id : E; V : B := True) is
3890 pragma Assert (Ekind (Id) = E_Package);
3891 Set_Flag214 (Id, V);
3894 procedure Set_Has_Record_Rep_Clause (Id : E; V : B := True) is
3896 pragma Assert (Id = Base_Type (Id));
3898 end Set_Has_Record_Rep_Clause;
3900 procedure Set_Has_Recursive_Call (Id : E; V : B := True) is
3902 pragma Assert (Is_Subprogram (Id));
3903 Set_Flag143 (Id, V);
3904 end Set_Has_Recursive_Call;
3906 procedure Set_Has_Size_Clause (Id : E; V : B := True) is
3909 end Set_Has_Size_Clause;
3911 procedure Set_Has_Small_Clause (Id : E; V : B := True) is
3914 end Set_Has_Small_Clause;
3916 procedure Set_Has_Specified_Layout (Id : E; V : B := True) is
3918 pragma Assert (Id = Base_Type (Id));
3919 Set_Flag100 (Id, V);
3920 end Set_Has_Specified_Layout;
3922 procedure Set_Has_Specified_Stream_Input (Id : E; V : B := True) is
3924 pragma Assert (Is_Type (Id));
3925 Set_Flag190 (Id, V);
3926 end Set_Has_Specified_Stream_Input;
3928 procedure Set_Has_Specified_Stream_Output (Id : E; V : B := True) is
3930 pragma Assert (Is_Type (Id));
3931 Set_Flag191 (Id, V);
3932 end Set_Has_Specified_Stream_Output;
3934 procedure Set_Has_Specified_Stream_Read (Id : E; V : B := True) is
3936 pragma Assert (Is_Type (Id));
3937 Set_Flag192 (Id, V);
3938 end Set_Has_Specified_Stream_Read;
3940 procedure Set_Has_Specified_Stream_Write (Id : E; V : B := True) is
3942 pragma Assert (Is_Type (Id));
3943 Set_Flag193 (Id, V);
3944 end Set_Has_Specified_Stream_Write;
3946 procedure Set_Has_Static_Discriminants (Id : E; V : B := True) is
3948 Set_Flag211 (Id, V);
3949 end Set_Has_Static_Discriminants;
3951 procedure Set_Has_Storage_Size_Clause (Id : E; V : B := True) is
3953 pragma Assert (Is_Access_Type (Id) or else Is_Task_Type (Id));
3954 pragma Assert (Id = Base_Type (Id));
3956 end Set_Has_Storage_Size_Clause;
3958 procedure Set_Has_Stream_Size_Clause (Id : E; V : B := True) is
3960 pragma Assert (Is_Elementary_Type (Id));
3961 Set_Flag184 (Id, V);
3962 end Set_Has_Stream_Size_Clause;
3964 procedure Set_Has_Subprogram_Descriptor (Id : E; V : B := True) is
3967 end Set_Has_Subprogram_Descriptor;
3969 procedure Set_Has_Task (Id : E; V : B := True) is
3971 pragma Assert (Id = Base_Type (Id));
3975 procedure Set_Has_Thunks (Id : E; V : B := True) is
3977 pragma Assert (Is_Tag (Id));
3978 Set_Flag228 (Id, V);
3981 procedure Set_Has_Unchecked_Union (Id : E; V : B := True) is
3983 pragma Assert (Id = Base_Type (Id));
3984 Set_Flag123 (Id, V);
3985 end Set_Has_Unchecked_Union;
3987 procedure Set_Has_Unknown_Discriminants (Id : E; V : B := True) is
3989 pragma Assert (Is_Type (Id));
3991 end Set_Has_Unknown_Discriminants;
3993 procedure Set_Has_Volatile_Components (Id : E; V : B := True) is
3995 pragma Assert (not Is_Type (Id) or else Id = Base_Type (Id));
3997 end Set_Has_Volatile_Components;
3999 procedure Set_Has_Xref_Entry (Id : E; V : B := True) is
4001 Set_Flag182 (Id, V);
4002 end Set_Has_Xref_Entry;
4004 procedure Set_Hiding_Loop_Variable (Id : E; V : E) is
4006 pragma Assert (Ekind (Id) = E_Variable);
4008 end Set_Hiding_Loop_Variable;
4010 procedure Set_Homonym (Id : E; V : E) is
4012 pragma Assert (Id /= V);
4016 procedure Set_Interface_Alias (Id : E; V : E) is
4020 and then Is_Hidden (Id)
4021 and then (Ekind_In (Id, E_Procedure, E_Function)));
4023 end Set_Interface_Alias;
4025 procedure Set_Interfaces (Id : E; V : L) is
4027 pragma Assert (Is_Record_Type (Id));
4028 Set_Elist25 (Id, V);
4031 procedure Set_In_Package_Body (Id : E; V : B := True) is
4034 end Set_In_Package_Body;
4036 procedure Set_In_Private_Part (Id : E; V : B := True) is
4039 end Set_In_Private_Part;
4041 procedure Set_In_Use (Id : E; V : B := True) is
4043 pragma Assert (Nkind (Id) in N_Entity);
4047 procedure Set_Inner_Instances (Id : E; V : L) is
4049 Set_Elist23 (Id, V);
4050 end Set_Inner_Instances;
4052 procedure Set_Interface_Name (Id : E; V : N) is
4055 end Set_Interface_Name;
4057 procedure Set_Is_Abstract_Subprogram (Id : E; V : B := True) is
4059 pragma Assert (Is_Overloadable (Id));
4061 end Set_Is_Abstract_Subprogram;
4063 procedure Set_Is_Abstract_Type (Id : E; V : B := True) is
4065 pragma Assert (Is_Type (Id));
4066 Set_Flag146 (Id, V);
4067 end Set_Is_Abstract_Type;
4069 procedure Set_Is_Local_Anonymous_Access (Id : E; V : B := True) is
4071 pragma Assert (Is_Access_Type (Id));
4072 Set_Flag194 (Id, V);
4073 end Set_Is_Local_Anonymous_Access;
4075 procedure Set_Is_Access_Constant (Id : E; V : B := True) is
4077 pragma Assert (Is_Access_Type (Id));
4079 end Set_Is_Access_Constant;
4081 procedure Set_Is_Ada_2005_Only (Id : E; V : B := True) is
4083 Set_Flag185 (Id, V);
4084 end Set_Is_Ada_2005_Only;
4086 procedure Set_Is_Ada_2012_Only (Id : E; V : B := True) is
4088 Set_Flag199 (Id, V);
4089 end Set_Is_Ada_2012_Only;
4091 procedure Set_Is_Aliased (Id : E; V : B := True) is
4093 pragma Assert (Nkind (Id) in N_Entity);
4097 procedure Set_Is_AST_Entry (Id : E; V : B := True) is
4099 pragma Assert (Is_Entry (Id));
4100 Set_Flag132 (Id, V);
4101 end Set_Is_AST_Entry;
4103 procedure Set_Is_Asynchronous (Id : E; V : B := True) is
4106 (Ekind (Id) = E_Procedure or else Is_Type (Id));
4108 end Set_Is_Asynchronous;
4110 procedure Set_Is_Atomic (Id : E; V : B := True) is
4115 procedure Set_Is_Bit_Packed_Array (Id : E; V : B := True) is
4117 pragma Assert ((not V)
4118 or else (Is_Array_Type (Id) and then Id = Base_Type (Id)));
4120 Set_Flag122 (Id, V);
4121 end Set_Is_Bit_Packed_Array;
4123 procedure Set_Is_Called (Id : E; V : B := True) is
4125 pragma Assert (Ekind_In (Id, E_Procedure, E_Function));
4126 Set_Flag102 (Id, V);
4129 procedure Set_Is_Character_Type (Id : E; V : B := True) is
4132 end Set_Is_Character_Type;
4134 procedure Set_Is_Child_Unit (Id : E; V : B := True) is
4137 end Set_Is_Child_Unit;
4139 procedure Set_Is_Class_Wide_Equivalent_Type (Id : E; V : B := True) is
4142 end Set_Is_Class_Wide_Equivalent_Type;
4144 procedure Set_Is_Compilation_Unit (Id : E; V : B := True) is
4146 Set_Flag149 (Id, V);
4147 end Set_Is_Compilation_Unit;
4149 procedure Set_Is_Completely_Hidden (Id : E; V : B := True) is
4151 pragma Assert (Ekind (Id) = E_Discriminant);
4152 Set_Flag103 (Id, V);
4153 end Set_Is_Completely_Hidden;
4155 procedure Set_Is_Concurrent_Record_Type (Id : E; V : B := True) is
4158 end Set_Is_Concurrent_Record_Type;
4160 procedure Set_Is_Constr_Subt_For_U_Nominal (Id : E; V : B := True) is
4163 end Set_Is_Constr_Subt_For_U_Nominal;
4165 procedure Set_Is_Constr_Subt_For_UN_Aliased (Id : E; V : B := True) is
4167 Set_Flag141 (Id, V);
4168 end Set_Is_Constr_Subt_For_UN_Aliased;
4170 procedure Set_Is_Constrained (Id : E; V : B := True) is
4172 pragma Assert (Nkind (Id) in N_Entity);
4174 end Set_Is_Constrained;
4176 procedure Set_Is_Constructor (Id : E; V : B := True) is
4179 end Set_Is_Constructor;
4181 procedure Set_Is_Controlled (Id : E; V : B := True) is
4183 pragma Assert (Id = Base_Type (Id));
4185 end Set_Is_Controlled;
4187 procedure Set_Is_Controlling_Formal (Id : E; V : B := True) is
4189 pragma Assert (Is_Formal (Id));
4191 end Set_Is_Controlling_Formal;
4193 procedure Set_Is_CPP_Class (Id : E; V : B := True) is
4196 end Set_Is_CPP_Class;
4198 procedure Set_Is_Descendent_Of_Address (Id : E; V : B := True) is
4200 pragma Assert (Is_Type (Id));
4201 Set_Flag223 (Id, V);
4202 end Set_Is_Descendent_Of_Address;
4204 procedure Set_Is_Discrim_SO_Function (Id : E; V : B := True) is
4206 Set_Flag176 (Id, V);
4207 end Set_Is_Discrim_SO_Function;
4209 procedure Set_Is_Dispatch_Table_Entity (Id : E; V : B := True) is
4211 Set_Flag234 (Id, V);
4212 end Set_Is_Dispatch_Table_Entity;
4214 procedure Set_Is_Dispatching_Operation (Id : E; V : B := True) is
4219 Is_Overloadable (Id)
4221 Ekind (Id) = E_Subprogram_Type);
4224 end Set_Is_Dispatching_Operation;
4226 procedure Set_Is_Eliminated (Id : E; V : B := True) is
4228 Set_Flag124 (Id, V);
4229 end Set_Is_Eliminated;
4231 procedure Set_Is_Entry_Formal (Id : E; V : B := True) is
4234 end Set_Is_Entry_Formal;
4236 procedure Set_Is_Exported (Id : E; V : B := True) is
4239 end Set_Is_Exported;
4241 procedure Set_Is_First_Subtype (Id : E; V : B := True) is
4244 end Set_Is_First_Subtype;
4246 procedure Set_Is_For_Access_Subtype (Id : E; V : B := True) is
4248 pragma Assert (Ekind_In (Id, E_Record_Subtype, E_Private_Subtype));
4249 Set_Flag118 (Id, V);
4250 end Set_Is_For_Access_Subtype;
4252 procedure Set_Is_Formal_Subprogram (Id : E; V : B := True) is
4254 Set_Flag111 (Id, V);
4255 end Set_Is_Formal_Subprogram;
4257 procedure Set_Is_Frozen (Id : E; V : B := True) is
4259 pragma Assert (Nkind (Id) in N_Entity);
4263 procedure Set_Is_Generic_Actual_Type (Id : E; V : B := True) is
4265 pragma Assert (Is_Type (Id));
4267 end Set_Is_Generic_Actual_Type;
4269 procedure Set_Is_Generic_Instance (Id : E; V : B := True) is
4271 Set_Flag130 (Id, V);
4272 end Set_Is_Generic_Instance;
4274 procedure Set_Is_Generic_Type (Id : E; V : B := True) is
4276 pragma Assert (Nkind (Id) in N_Entity);
4278 end Set_Is_Generic_Type;
4280 procedure Set_Is_Hidden (Id : E; V : B := True) is
4285 procedure Set_Is_Hidden_Open_Scope (Id : E; V : B := True) is
4287 Set_Flag171 (Id, V);
4288 end Set_Is_Hidden_Open_Scope;
4290 procedure Set_Is_Immediately_Visible (Id : E; V : B := True) is
4292 pragma Assert (Nkind (Id) in N_Entity);
4294 end Set_Is_Immediately_Visible;
4296 procedure Set_Is_Imported (Id : E; V : B := True) is
4299 end Set_Is_Imported;
4301 procedure Set_Is_Inlined (Id : E; V : B := True) is
4306 procedure Set_Is_Interface (Id : E; V : B := True) is
4309 (Ekind_In (Id, E_Record_Type,
4311 E_Record_Type_With_Private,
4312 E_Record_Subtype_With_Private,
4314 E_Class_Wide_Subtype));
4315 Set_Flag186 (Id, V);
4316 end Set_Is_Interface;
4318 procedure Set_Is_Instantiated (Id : E; V : B := True) is
4320 Set_Flag126 (Id, V);
4321 end Set_Is_Instantiated;
4323 procedure Set_Is_Internal (Id : E; V : B := True) is
4325 pragma Assert (Nkind (Id) in N_Entity);
4327 end Set_Is_Internal;
4329 procedure Set_Is_Interrupt_Handler (Id : E; V : B := True) is
4331 pragma Assert (Nkind (Id) in N_Entity);
4333 end Set_Is_Interrupt_Handler;
4335 procedure Set_Is_Intrinsic_Subprogram (Id : E; V : B := True) is
4338 end Set_Is_Intrinsic_Subprogram;
4340 procedure Set_Is_Itype (Id : E; V : B := True) is
4345 procedure Set_Is_Known_Non_Null (Id : E; V : B := True) is
4348 end Set_Is_Known_Non_Null;
4350 procedure Set_Is_Known_Null (Id : E; V : B := True) is
4352 Set_Flag204 (Id, V);
4353 end Set_Is_Known_Null;
4355 procedure Set_Is_Known_Valid (Id : E; V : B := True) is
4357 Set_Flag170 (Id, V);
4358 end Set_Is_Known_Valid;
4360 procedure Set_Is_Limited_Composite (Id : E; V : B := True) is
4362 pragma Assert (Is_Type (Id));
4363 Set_Flag106 (Id, V);
4364 end Set_Is_Limited_Composite;
4366 procedure Set_Is_Limited_Interface (Id : E; V : B := True) is
4368 pragma Assert (Is_Interface (Id));
4369 Set_Flag197 (Id, V);
4370 end Set_Is_Limited_Interface;
4372 procedure Set_Is_Limited_Record (Id : E; V : B := True) is
4375 end Set_Is_Limited_Record;
4377 procedure Set_Is_Machine_Code_Subprogram (Id : E; V : B := True) is
4379 pragma Assert (Is_Subprogram (Id));
4380 Set_Flag137 (Id, V);
4381 end Set_Is_Machine_Code_Subprogram;
4383 procedure Set_Is_Non_Static_Subtype (Id : E; V : B := True) is
4385 pragma Assert (Is_Type (Id));
4386 Set_Flag109 (Id, V);
4387 end Set_Is_Non_Static_Subtype;
4389 procedure Set_Is_Null_Init_Proc (Id : E; V : B := True) is
4391 pragma Assert (Ekind (Id) = E_Procedure);
4392 Set_Flag178 (Id, V);
4393 end Set_Is_Null_Init_Proc;
4395 procedure Set_Is_Obsolescent (Id : E; V : B := True) is
4397 Set_Flag153 (Id, V);
4398 end Set_Is_Obsolescent;
4400 procedure Set_Is_Only_Out_Parameter (Id : E; V : B := True) is
4402 pragma Assert (Ekind (Id) = E_Out_Parameter);
4403 Set_Flag226 (Id, V);
4404 end Set_Is_Only_Out_Parameter;
4406 procedure Set_Is_Optional_Parameter (Id : E; V : B := True) is
4408 pragma Assert (Is_Formal (Id));
4409 Set_Flag134 (Id, V);
4410 end Set_Is_Optional_Parameter;
4412 procedure Set_Is_Overriding_Operation (Id : E; V : B := True) is
4414 pragma Assert (Is_Subprogram (Id));
4416 end Set_Is_Overriding_Operation;
4418 procedure Set_Is_Package_Body_Entity (Id : E; V : B := True) is
4420 Set_Flag160 (Id, V);
4421 end Set_Is_Package_Body_Entity;
4423 procedure Set_Is_Packed (Id : E; V : B := True) is
4425 pragma Assert (Id = Base_Type (Id));
4429 procedure Set_Is_Packed_Array_Type (Id : E; V : B := True) is
4431 Set_Flag138 (Id, V);
4432 end Set_Is_Packed_Array_Type;
4434 procedure Set_Is_Potentially_Use_Visible (Id : E; V : B := True) is
4436 pragma Assert (Nkind (Id) in N_Entity);
4438 end Set_Is_Potentially_Use_Visible;
4440 procedure Set_Is_Preelaborated (Id : E; V : B := True) is
4443 end Set_Is_Preelaborated;
4445 procedure Set_Is_Primitive (Id : E; V : B := True) is
4448 (Is_Overloadable (Id)
4449 or else Ekind_In (Id, E_Generic_Function, E_Generic_Procedure));
4450 Set_Flag218 (Id, V);
4451 end Set_Is_Primitive;
4453 procedure Set_Is_Primitive_Wrapper (Id : E; V : B := True) is
4455 pragma Assert (Ekind_In (Id, E_Function, E_Procedure));
4456 Set_Flag195 (Id, V);
4457 end Set_Is_Primitive_Wrapper;
4459 procedure Set_Is_Private_Composite (Id : E; V : B := True) is
4461 pragma Assert (Is_Type (Id));
4462 Set_Flag107 (Id, V);
4463 end Set_Is_Private_Composite;
4465 procedure Set_Is_Private_Descendant (Id : E; V : B := True) is
4468 end Set_Is_Private_Descendant;
4470 procedure Set_Is_Private_Primitive (Id : E; V : B := True) is
4472 pragma Assert (Ekind_In (Id, E_Function, E_Procedure));
4473 Set_Flag245 (Id, V);
4474 end Set_Is_Private_Primitive;
4476 procedure Set_Is_Public (Id : E; V : B := True) is
4478 pragma Assert (Nkind (Id) in N_Entity);
4482 procedure Set_Is_Pure (Id : E; V : B := True) is
4487 procedure Set_Is_Pure_Unit_Access_Type (Id : E; V : B := True) is
4489 pragma Assert (Is_Access_Type (Id));
4490 Set_Flag189 (Id, V);
4491 end Set_Is_Pure_Unit_Access_Type;
4493 procedure Set_Is_RACW_Stub_Type (Id : E; V : B := True) is
4495 pragma Assert (Is_Type (Id));
4496 Set_Flag244 (Id, V);
4497 end Set_Is_RACW_Stub_Type;
4499 procedure Set_Is_Raised (Id : E; V : B := True) is
4501 pragma Assert (Ekind (Id) = E_Exception);
4502 Set_Flag224 (Id, V);
4505 procedure Set_Is_Remote_Call_Interface (Id : E; V : B := True) is
4508 end Set_Is_Remote_Call_Interface;
4510 procedure Set_Is_Remote_Types (Id : E; V : B := True) is
4513 end Set_Is_Remote_Types;
4515 procedure Set_Is_Renaming_Of_Object (Id : E; V : B := True) is
4517 Set_Flag112 (Id, V);
4518 end Set_Is_Renaming_Of_Object;
4520 procedure Set_Is_Return_Object (Id : E; V : B := True) is
4522 Set_Flag209 (Id, V);
4523 end Set_Is_Return_Object;
4525 procedure Set_Is_Shared_Passive (Id : E; V : B := True) is
4528 end Set_Is_Shared_Passive;
4530 procedure Set_Is_Statically_Allocated (Id : E; V : B := True) is
4534 or else Ekind_In (Id, E_Exception,
4539 end Set_Is_Statically_Allocated;
4541 procedure Set_Is_Tag (Id : E; V : B := True) is
4543 pragma Assert (Ekind_In (Id, E_Component, E_Constant, E_Variable));
4547 procedure Set_Is_Tagged_Type (Id : E; V : B := True) is
4550 end Set_Is_Tagged_Type;
4552 procedure Set_Is_Thunk (Id : E; V : B := True) is
4554 Set_Flag225 (Id, V);
4557 procedure Set_Is_Trivial_Subprogram (Id : E; V : B := True) is
4559 Set_Flag235 (Id, V);
4560 end Set_Is_Trivial_Subprogram;
4562 procedure Set_Is_True_Constant (Id : E; V : B := True) is
4564 Set_Flag163 (Id, V);
4565 end Set_Is_True_Constant;
4567 procedure Set_Is_Unchecked_Union (Id : E; V : B := True) is
4569 pragma Assert (Id = Base_Type (Id));
4570 Set_Flag117 (Id, V);
4571 end Set_Is_Unchecked_Union;
4573 procedure Set_Is_Underlying_Record_View (Id : E; V : B := True) is
4575 pragma Assert (Ekind (Id) = E_Record_Type);
4576 Set_Flag246 (Id, V);
4577 end Set_Is_Underlying_Record_View;
4579 procedure Set_Is_Unsigned_Type (Id : E; V : B := True) is
4581 pragma Assert (Is_Discrete_Or_Fixed_Point_Type (Id));
4582 Set_Flag144 (Id, V);
4583 end Set_Is_Unsigned_Type;
4585 procedure Set_Is_Valued_Procedure (Id : E; V : B := True) is
4587 pragma Assert (Ekind (Id) = E_Procedure);
4588 Set_Flag127 (Id, V);
4589 end Set_Is_Valued_Procedure;
4591 procedure Set_Is_Visible_Child_Unit (Id : E; V : B := True) is
4593 pragma Assert (Is_Child_Unit (Id));
4594 Set_Flag116 (Id, V);
4595 end Set_Is_Visible_Child_Unit;
4597 procedure Set_Is_Visible_Formal (Id : E; V : B := True) is
4599 Set_Flag206 (Id, V);
4600 end Set_Is_Visible_Formal;
4602 procedure Set_Is_VMS_Exception (Id : E; V : B := True) is
4604 pragma Assert (Ekind (Id) = E_Exception);
4605 Set_Flag133 (Id, V);
4606 end Set_Is_VMS_Exception;
4608 procedure Set_Is_Volatile (Id : E; V : B := True) is
4610 pragma Assert (Nkind (Id) in N_Entity);
4612 end Set_Is_Volatile;
4614 procedure Set_Itype_Printed (Id : E; V : B := True) is
4616 pragma Assert (Is_Itype (Id));
4617 Set_Flag202 (Id, V);
4618 end Set_Itype_Printed;
4620 procedure Set_Kill_Elaboration_Checks (Id : E; V : B := True) is
4623 end Set_Kill_Elaboration_Checks;
4625 procedure Set_Kill_Range_Checks (Id : E; V : B := True) is
4628 end Set_Kill_Range_Checks;
4630 procedure Set_Kill_Tag_Checks (Id : E; V : B := True) is
4633 end Set_Kill_Tag_Checks;
4635 procedure Set_Known_To_Have_Preelab_Init (Id : E; V : B := True) is
4637 pragma Assert (Is_Type (Id));
4638 Set_Flag207 (Id, V);
4639 end Set_Known_To_Have_Preelab_Init;
4641 procedure Set_Last_Assignment (Id : E; V : N) is
4643 pragma Assert (Is_Assignable (Id));
4645 end Set_Last_Assignment;
4647 procedure Set_Last_Entity (Id : E; V : E) is
4650 end Set_Last_Entity;
4652 procedure Set_Limited_View (Id : E; V : E) is
4654 pragma Assert (Ekind (Id) = E_Package);
4656 end Set_Limited_View;
4658 procedure Set_Lit_Indexes (Id : E; V : E) is
4660 pragma Assert (Is_Enumeration_Type (Id) and then Root_Type (Id) = Id);
4662 end Set_Lit_Indexes;
4664 procedure Set_Lit_Strings (Id : E; V : E) is
4666 pragma Assert (Is_Enumeration_Type (Id) and then Root_Type (Id) = Id);
4668 end Set_Lit_Strings;
4670 procedure Set_Low_Bound_Tested (Id : E; V : B := True) is
4672 pragma Assert (Is_Formal (Id));
4673 Set_Flag205 (Id, V);
4674 end Set_Low_Bound_Tested;
4676 procedure Set_Machine_Radix_10 (Id : E; V : B := True) is
4678 pragma Assert (Is_Decimal_Fixed_Point_Type (Id));
4680 end Set_Machine_Radix_10;
4682 procedure Set_Master_Id (Id : E; V : E) is
4684 pragma Assert (Is_Access_Type (Id));
4688 procedure Set_Materialize_Entity (Id : E; V : B := True) is
4690 Set_Flag168 (Id, V);
4691 end Set_Materialize_Entity;
4693 procedure Set_Mechanism (Id : E; V : M) is
4695 pragma Assert (Ekind (Id) = E_Function or else Is_Formal (Id));
4696 Set_Uint8 (Id, UI_From_Int (V));
4699 procedure Set_Modulus (Id : E; V : U) is
4701 pragma Assert (Ekind (Id) = E_Modular_Integer_Type);
4705 procedure Set_Must_Be_On_Byte_Boundary (Id : E; V : B := True) is
4707 pragma Assert (Is_Type (Id));
4708 Set_Flag183 (Id, V);
4709 end Set_Must_Be_On_Byte_Boundary;
4711 procedure Set_Must_Have_Preelab_Init (Id : E; V : B := True) is
4713 pragma Assert (Is_Type (Id));
4714 Set_Flag208 (Id, V);
4715 end Set_Must_Have_Preelab_Init;
4717 procedure Set_Needs_Debug_Info (Id : E; V : B := True) is
4719 Set_Flag147 (Id, V);
4720 end Set_Needs_Debug_Info;
4722 procedure Set_Needs_No_Actuals (Id : E; V : B := True) is
4725 (Is_Overloadable (Id)
4726 or else Ekind_In (Id, E_Subprogram_Type, E_Entry_Family));
4728 end Set_Needs_No_Actuals;
4730 procedure Set_Never_Set_In_Source (Id : E; V : B := True) is
4732 Set_Flag115 (Id, V);
4733 end Set_Never_Set_In_Source;
4735 procedure Set_Next_Inlined_Subprogram (Id : E; V : E) is
4738 end Set_Next_Inlined_Subprogram;
4740 procedure Set_No_Pool_Assigned (Id : E; V : B := True) is
4742 pragma Assert (Is_Access_Type (Id) and then Id = Base_Type (Id));
4743 Set_Flag131 (Id, V);
4744 end Set_No_Pool_Assigned;
4746 procedure Set_No_Return (Id : E; V : B := True) is
4749 (V = False or else Ekind_In (Id, E_Procedure, E_Generic_Procedure));
4750 Set_Flag113 (Id, V);
4753 procedure Set_No_Strict_Aliasing (Id : E; V : B := True) is
4755 pragma Assert (Is_Access_Type (Id) and then Id = Base_Type (Id));
4756 Set_Flag136 (Id, V);
4757 end Set_No_Strict_Aliasing;
4759 procedure Set_Non_Binary_Modulus (Id : E; V : B := True) is
4761 pragma Assert (Is_Type (Id) and then Id = Base_Type (Id));
4763 end Set_Non_Binary_Modulus;
4765 procedure Set_Non_Limited_View (Id : E; V : E) is
4767 pragma Assert (Ekind (Id) in Incomplete_Kind);
4769 end Set_Non_Limited_View;
4771 procedure Set_Nonzero_Is_True (Id : E; V : B := True) is
4774 (Root_Type (Id) = Standard_Boolean
4775 and then Ekind (Id) = E_Enumeration_Type);
4776 Set_Flag162 (Id, V);
4777 end Set_Nonzero_Is_True;
4779 procedure Set_Normalized_First_Bit (Id : E; V : U) is
4781 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
4783 end Set_Normalized_First_Bit;
4785 procedure Set_Normalized_Position (Id : E; V : U) is
4787 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
4789 end Set_Normalized_Position;
4791 procedure Set_Normalized_Position_Max (Id : E; V : U) is
4793 pragma Assert (Ekind_In (Id, E_Component, E_Discriminant));
4795 end Set_Normalized_Position_Max;
4797 procedure Set_OK_To_Reference (Id : E; V : B := True) is
4799 pragma Assert (Is_Type (Id));
4800 Set_Flag249 (Id, V);
4801 end Set_OK_To_Reference;
4803 procedure Set_OK_To_Rename (Id : E; V : B := True) is
4805 pragma Assert (Ekind (Id) = E_Variable);
4806 Set_Flag247 (Id, V);
4807 end Set_OK_To_Rename;
4809 procedure Set_OK_To_Reorder_Components (Id : E; V : B := True) is
4812 (Is_Record_Type (Id) and then Id = Base_Type (Id));
4813 Set_Flag239 (Id, V);
4814 end Set_OK_To_Reorder_Components;
4816 procedure Set_Optimize_Alignment_Space (Id : E; V : B := True) is
4819 (Is_Type (Id) or else Ekind_In (Id, E_Constant, E_Variable));
4820 Set_Flag241 (Id, V);
4821 end Set_Optimize_Alignment_Space;
4823 procedure Set_Optimize_Alignment_Time (Id : E; V : B := True) is
4826 (Is_Type (Id) or else Ekind_In (Id, E_Constant, E_Variable));
4827 Set_Flag242 (Id, V);
4828 end Set_Optimize_Alignment_Time;
4830 procedure Set_Original_Array_Type (Id : E; V : E) is
4832 pragma Assert (Is_Array_Type (Id) or else Is_Modular_Integer_Type (Id));
4834 end Set_Original_Array_Type;
4836 procedure Set_Original_Record_Component (Id : E; V : E) is
4838 pragma Assert (Ekind_In (Id, E_Void, E_Component, E_Discriminant));
4840 end Set_Original_Record_Component;
4842 procedure Set_Overlays_Constant (Id : E; V : B := True) is
4844 Set_Flag243 (Id, V);
4845 end Set_Overlays_Constant;
4847 procedure Set_Overridden_Operation (Id : E; V : E) is
4850 end Set_Overridden_Operation;
4852 procedure Set_Package_Instantiation (Id : E; V : N) is
4854 pragma Assert (Ekind_In (Id, E_Void, E_Generic_Package, E_Package));
4856 end Set_Package_Instantiation;
4858 procedure Set_Packed_Array_Type (Id : E; V : E) is
4860 pragma Assert (Is_Array_Type (Id));
4862 end Set_Packed_Array_Type;
4864 procedure Set_Parent_Subtype (Id : E; V : E) is
4866 pragma Assert (Ekind (Id) = E_Record_Type);
4868 end Set_Parent_Subtype;
4870 procedure Set_Postcondition_Proc (Id : E; V : E) is
4872 pragma Assert (Ekind (Id) = E_Procedure);
4874 end Set_Postcondition_Proc;
4876 procedure Set_PPC_Wrapper (Id : E; V : E) is
4878 pragma Assert (Ekind_In (Id, E_Entry, E_Entry_Family));
4880 end Set_PPC_Wrapper;
4882 procedure Set_Direct_Primitive_Operations (Id : E; V : L) is
4884 pragma Assert (Is_Tagged_Type (Id));
4885 Set_Elist10 (Id, V);
4886 end Set_Direct_Primitive_Operations;
4888 procedure Set_Prival (Id : E; V : E) is
4890 pragma Assert (Is_Protected_Component (Id));
4894 procedure Set_Prival_Link (Id : E; V : E) is
4896 pragma Assert (Ekind_In (Id, E_Constant, E_Variable));
4898 end Set_Prival_Link;
4900 procedure Set_Private_Dependents (Id : E; V : L) is
4902 pragma Assert (Is_Incomplete_Or_Private_Type (Id));
4903 Set_Elist18 (Id, V);
4904 end Set_Private_Dependents;
4906 procedure Set_Private_View (Id : E; V : N) is
4908 pragma Assert (Is_Private_Type (Id));
4910 end Set_Private_View;
4912 procedure Set_Protected_Body_Subprogram (Id : E; V : E) is
4914 pragma Assert (Is_Subprogram (Id) or else Is_Entry (Id));
4916 end Set_Protected_Body_Subprogram;
4918 procedure Set_Protected_Formal (Id : E; V : E) is
4920 pragma Assert (Is_Formal (Id));
4922 end Set_Protected_Formal;
4924 procedure Set_Protection_Object (Id : E; V : E) is
4926 pragma Assert (Ekind_In (Id, E_Entry,
4931 end Set_Protection_Object;
4933 procedure Set_Reachable (Id : E; V : B := True) is
4938 procedure Set_Referenced (Id : E; V : B := True) is
4940 Set_Flag156 (Id, V);
4943 procedure Set_Referenced_As_LHS (Id : E; V : B := True) is
4946 end Set_Referenced_As_LHS;
4948 procedure Set_Referenced_As_Out_Parameter (Id : E; V : B := True) is
4950 Set_Flag227 (Id, V);
4951 end Set_Referenced_As_Out_Parameter;
4953 procedure Set_Register_Exception_Call (Id : E; V : N) is
4955 pragma Assert (Ekind (Id) = E_Exception);
4957 end Set_Register_Exception_Call;
4959 procedure Set_Related_Array_Object (Id : E; V : E) is
4961 pragma Assert (Is_Array_Type (Id));
4963 end Set_Related_Array_Object;
4965 procedure Set_Related_Expression (Id : E; V : N) is
4967 pragma Assert (Ekind (Id) in Type_Kind
4968 or else Ekind_In (Id, E_Constant, E_Variable, E_Void));
4970 end Set_Related_Expression;
4972 procedure Set_Related_Instance (Id : E; V : E) is
4974 pragma Assert (Ekind_In (Id, E_Package, E_Package_Body));
4976 end Set_Related_Instance;
4978 procedure Set_Related_Type (Id : E; V : E) is
4980 pragma Assert (Ekind_In (Id, E_Component, E_Constant, E_Variable));
4982 end Set_Related_Type;
4984 procedure Set_Relative_Deadline_Variable (Id : E; V : E) is
4986 pragma Assert (Is_Task_Type (Id) and then Id = Base_Type (Id));
4988 end Set_Relative_Deadline_Variable;
4990 procedure Set_Renamed_Entity (Id : E; V : N) is
4993 end Set_Renamed_Entity;
4995 procedure Set_Renamed_In_Spec (Id : E; V : B := True) is
4997 pragma Assert (Ekind (Id) = E_Package);
4998 Set_Flag231 (Id, V);
4999 end Set_Renamed_In_Spec;
5001 procedure Set_Renamed_Object (Id : E; V : N) is
5004 end Set_Renamed_Object;
5006 procedure Set_Renaming_Map (Id : E; V : U) is
5009 end Set_Renaming_Map;
5011 procedure Set_Requires_Overriding (Id : E; V : B := True) is
5013 pragma Assert (Is_Overloadable (Id));
5014 Set_Flag213 (Id, V);
5015 end Set_Requires_Overriding;
5017 procedure Set_Return_Present (Id : E; V : B := True) is
5020 end Set_Return_Present;
5022 procedure Set_Return_Applies_To (Id : E; V : N) is
5025 end Set_Return_Applies_To;
5027 procedure Set_Returns_By_Ref (Id : E; V : B := True) is
5030 end Set_Returns_By_Ref;
5032 procedure Set_Reverse_Bit_Order (Id : E; V : B := True) is
5035 (Is_Record_Type (Id) and then Id = Base_Type (Id));
5036 Set_Flag164 (Id, V);
5037 end Set_Reverse_Bit_Order;
5039 procedure Set_RM_Size (Id : E; V : U) is
5041 pragma Assert (Is_Type (Id));
5045 procedure Set_Scalar_Range (Id : E; V : N) is
5048 end Set_Scalar_Range;
5050 procedure Set_Scale_Value (Id : E; V : U) is
5053 end Set_Scale_Value;
5055 procedure Set_Scope_Depth_Value (Id : E; V : U) is
5057 pragma Assert (not Is_Record_Type (Id));
5059 end Set_Scope_Depth_Value;
5061 procedure Set_Sec_Stack_Needed_For_Return (Id : E; V : B := True) is
5063 Set_Flag167 (Id, V);
5064 end Set_Sec_Stack_Needed_For_Return;
5066 procedure Set_Shadow_Entities (Id : E; V : S) is
5068 pragma Assert (Ekind_In (Id, E_Package, E_Generic_Package));
5070 end Set_Shadow_Entities;
5072 procedure Set_Shared_Var_Procs_Instance (Id : E; V : E) is
5074 pragma Assert (Ekind (Id) = E_Variable);
5076 end Set_Shared_Var_Procs_Instance;
5078 procedure Set_Size_Check_Code (Id : E; V : N) is
5080 pragma Assert (Ekind_In (Id, E_Constant, E_Variable));
5082 end Set_Size_Check_Code;
5084 procedure Set_Size_Depends_On_Discriminant (Id : E; V : B := True) is
5086 Set_Flag177 (Id, V);
5087 end Set_Size_Depends_On_Discriminant;
5089 procedure Set_Size_Known_At_Compile_Time (Id : E; V : B := True) is
5092 end Set_Size_Known_At_Compile_Time;
5094 procedure Set_Small_Value (Id : E; V : R) is
5096 pragma Assert (Is_Fixed_Point_Type (Id));
5097 Set_Ureal21 (Id, V);
5098 end Set_Small_Value;
5100 procedure Set_Spec_Entity (Id : E; V : E) is
5102 pragma Assert (Ekind (Id) = E_Package_Body or else Is_Formal (Id));
5104 end Set_Spec_Entity;
5106 procedure Set_Spec_PPC_List (Id : E; V : N) is
5109 (Ekind_In (Id, E_Entry, E_Entry_Family, E_Void)
5110 or else Is_Subprogram (Id)
5111 or else Is_Generic_Subprogram (Id));
5113 end Set_Spec_PPC_List;
5115 procedure Set_Storage_Size_Variable (Id : E; V : E) is
5117 pragma Assert (Is_Access_Type (Id) or else Is_Task_Type (Id));
5118 pragma Assert (Id = Base_Type (Id));
5120 end Set_Storage_Size_Variable;
5122 procedure Set_Static_Elaboration_Desired (Id : E; V : B) is
5124 pragma Assert (Ekind (Id) = E_Package);
5126 end Set_Static_Elaboration_Desired;
5128 procedure Set_Static_Initialization (Id : E; V : N) is
5131 (Ekind (Id) = E_Procedure and then not Is_Dispatching_Operation (Id));
5133 end Set_Static_Initialization;
5135 procedure Set_Stored_Constraint (Id : E; V : L) is
5137 pragma Assert (Nkind (Id) in N_Entity);
5138 Set_Elist23 (Id, V);
5139 end Set_Stored_Constraint;
5141 procedure Set_Strict_Alignment (Id : E; V : B := True) is
5143 pragma Assert (Id = Base_Type (Id));
5144 Set_Flag145 (Id, V);
5145 end Set_Strict_Alignment;
5147 procedure Set_String_Literal_Length (Id : E; V : U) is
5149 pragma Assert (Ekind (Id) = E_String_Literal_Subtype);
5151 end Set_String_Literal_Length;
5153 procedure Set_String_Literal_Low_Bound (Id : E; V : N) is
5155 pragma Assert (Ekind (Id) = E_String_Literal_Subtype);
5157 end Set_String_Literal_Low_Bound;
5159 procedure Set_Subprograms_For_Type (Id : E; V : E) is
5161 pragma Assert (Is_Type (Id) or else Is_Subprogram (Id));
5163 end Set_Subprograms_For_Type;
5165 procedure Set_Suppress_Elaboration_Warnings (Id : E; V : B := True) is
5167 Set_Flag148 (Id, V);
5168 end Set_Suppress_Elaboration_Warnings;
5170 procedure Set_Suppress_Init_Proc (Id : E; V : B := True) is
5172 pragma Assert (Id = Base_Type (Id));
5173 Set_Flag105 (Id, V);
5174 end Set_Suppress_Init_Proc;
5176 procedure Set_Suppress_Style_Checks (Id : E; V : B := True) is
5178 Set_Flag165 (Id, V);
5179 end Set_Suppress_Style_Checks;
5181 procedure Set_Suppress_Value_Tracking_On_Call (Id : E; V : B := True) is
5183 Set_Flag217 (Id, V);
5184 end Set_Suppress_Value_Tracking_On_Call;
5186 procedure Set_Task_Body_Procedure (Id : E; V : N) is
5188 pragma Assert (Ekind (Id) in Task_Kind);
5190 end Set_Task_Body_Procedure;
5192 procedure Set_Treat_As_Volatile (Id : E; V : B := True) is
5195 end Set_Treat_As_Volatile;
5197 procedure Set_Underlying_Full_View (Id : E; V : E) is
5199 pragma Assert (Ekind (Id) in Private_Kind);
5201 end Set_Underlying_Full_View;
5203 procedure Set_Underlying_Record_View (Id : E; V : E) is
5205 pragma Assert (Ekind (Id) = E_Record_Type);
5207 end Set_Underlying_Record_View;
5209 procedure Set_Universal_Aliasing (Id : E; V : B := True) is
5211 pragma Assert (Is_Type (Id) and then Id = Base_Type (Id));
5212 Set_Flag216 (Id, V);
5213 end Set_Universal_Aliasing;
5215 procedure Set_Unset_Reference (Id : E; V : N) is
5218 end Set_Unset_Reference;
5220 procedure Set_Uses_Sec_Stack (Id : E; V : B := True) is
5223 end Set_Uses_Sec_Stack;
5225 procedure Set_Used_As_Generic_Actual (Id : E; V : B := True) is
5227 Set_Flag222 (Id, V);
5228 end Set_Used_As_Generic_Actual;
5230 procedure Set_Vax_Float (Id : E; V : B := True) is
5232 pragma Assert (Id = Base_Type (Id));
5233 Set_Flag151 (Id, V);
5236 procedure Set_Warnings_Off (Id : E; V : B := True) is
5239 end Set_Warnings_Off;
5241 procedure Set_Warnings_Off_Used (Id : E; V : B := True) is
5243 Set_Flag236 (Id, V);
5244 end Set_Warnings_Off_Used;
5246 procedure Set_Warnings_Off_Used_Unmodified (Id : E; V : B := True) is
5248 Set_Flag237 (Id, V);
5249 end Set_Warnings_Off_Used_Unmodified;
5251 procedure Set_Warnings_Off_Used_Unreferenced (Id : E; V : B := True) is
5253 Set_Flag238 (Id, V);
5254 end Set_Warnings_Off_Used_Unreferenced;
5256 procedure Set_Was_Hidden (Id : E; V : B := True) is
5258 Set_Flag196 (Id, V);
5261 procedure Set_Wrapped_Entity (Id : E; V : E) is
5263 pragma Assert (Ekind_In (Id, E_Function, E_Procedure)
5264 and then Is_Primitive_Wrapper (Id));
5266 end Set_Wrapped_Entity;
5268 -----------------------------------
5269 -- Field Initialization Routines --
5270 -----------------------------------
5272 procedure Init_Alignment (Id : E) is
5274 Set_Uint14 (Id, Uint_0);
5277 procedure Init_Alignment (Id : E; V : Int) is
5279 Set_Uint14 (Id, UI_From_Int (V));
5282 procedure Init_Component_Bit_Offset (Id : E) is
5284 Set_Uint11 (Id, No_Uint);
5285 end Init_Component_Bit_Offset;
5287 procedure Init_Component_Bit_Offset (Id : E; V : Int) is
5289 Set_Uint11 (Id, UI_From_Int (V));
5290 end Init_Component_Bit_Offset;
5292 procedure Init_Component_Size (Id : E) is
5294 Set_Uint22 (Id, Uint_0);
5295 end Init_Component_Size;
5297 procedure Init_Component_Size (Id : E; V : Int) is
5299 Set_Uint22 (Id, UI_From_Int (V));
5300 end Init_Component_Size;
5302 procedure Init_Digits_Value (Id : E) is
5304 Set_Uint17 (Id, Uint_0);
5305 end Init_Digits_Value;
5307 procedure Init_Digits_Value (Id : E; V : Int) is
5309 Set_Uint17 (Id, UI_From_Int (V));
5310 end Init_Digits_Value;
5312 procedure Init_Esize (Id : E) is
5314 Set_Uint12 (Id, Uint_0);
5317 procedure Init_Esize (Id : E; V : Int) is
5319 Set_Uint12 (Id, UI_From_Int (V));
5322 procedure Init_Normalized_First_Bit (Id : E) is
5324 Set_Uint8 (Id, No_Uint);
5325 end Init_Normalized_First_Bit;
5327 procedure Init_Normalized_First_Bit (Id : E; V : Int) is
5329 Set_Uint8 (Id, UI_From_Int (V));
5330 end Init_Normalized_First_Bit;
5332 procedure Init_Normalized_Position (Id : E) is
5334 Set_Uint14 (Id, No_Uint);
5335 end Init_Normalized_Position;
5337 procedure Init_Normalized_Position (Id : E; V : Int) is
5339 Set_Uint14 (Id, UI_From_Int (V));
5340 end Init_Normalized_Position;
5342 procedure Init_Normalized_Position_Max (Id : E) is
5344 Set_Uint10 (Id, No_Uint);
5345 end Init_Normalized_Position_Max;
5347 procedure Init_Normalized_Position_Max (Id : E; V : Int) is
5349 Set_Uint10 (Id, UI_From_Int (V));
5350 end Init_Normalized_Position_Max;
5352 procedure Init_RM_Size (Id : E) is
5354 Set_Uint13 (Id, Uint_0);
5357 procedure Init_RM_Size (Id : E; V : Int) is
5359 Set_Uint13 (Id, UI_From_Int (V));
5362 -----------------------------
5363 -- Init_Component_Location --
5364 -----------------------------
5366 procedure Init_Component_Location (Id : E) is
5368 Set_Uint8 (Id, No_Uint); -- Normalized_First_Bit
5369 Set_Uint10 (Id, No_Uint); -- Normalized_Position_Max
5370 Set_Uint11 (Id, No_Uint); -- Component_Bit_Offset
5371 Set_Uint12 (Id, Uint_0); -- Esize
5372 Set_Uint14 (Id, No_Uint); -- Normalized_Position
5373 end Init_Component_Location;
5379 procedure Init_Size (Id : E; V : Int) is
5381 Set_Uint12 (Id, UI_From_Int (V)); -- Esize
5382 Set_Uint13 (Id, UI_From_Int (V)); -- RM_Size
5385 ---------------------
5386 -- Init_Size_Align --
5387 ---------------------
5389 procedure Init_Size_Align (Id : E) is
5391 Set_Uint12 (Id, Uint_0); -- Esize
5392 Set_Uint13 (Id, Uint_0); -- RM_Size
5393 Set_Uint14 (Id, Uint_0); -- Alignment
5394 end Init_Size_Align;
5396 ----------------------------------------------
5397 -- Type Representation Attribute Predicates --
5398 ----------------------------------------------
5400 function Known_Alignment (E : Entity_Id) return B is
5402 return Uint14 (E) /= Uint_0
5403 and then Uint14 (E) /= No_Uint;
5404 end Known_Alignment;
5406 function Known_Component_Bit_Offset (E : Entity_Id) return B is
5408 return Uint11 (E) /= No_Uint;
5409 end Known_Component_Bit_Offset;
5411 function Known_Component_Size (E : Entity_Id) return B is
5413 return Uint22 (Base_Type (E)) /= Uint_0
5414 and then Uint22 (Base_Type (E)) /= No_Uint;
5415 end Known_Component_Size;
5417 function Known_Esize (E : Entity_Id) return B is
5419 return Uint12 (E) /= Uint_0
5420 and then Uint12 (E) /= No_Uint;
5423 function Known_Normalized_First_Bit (E : Entity_Id) return B is
5425 return Uint8 (E) /= No_Uint;
5426 end Known_Normalized_First_Bit;
5428 function Known_Normalized_Position (E : Entity_Id) return B is
5430 return Uint14 (E) /= No_Uint;
5431 end Known_Normalized_Position;
5433 function Known_Normalized_Position_Max (E : Entity_Id) return B is
5435 return Uint10 (E) /= No_Uint;
5436 end Known_Normalized_Position_Max;
5438 function Known_RM_Size (E : Entity_Id) return B is
5440 return Uint13 (E) /= No_Uint
5441 and then (Uint13 (E) /= Uint_0
5442 or else Is_Discrete_Type (E)
5443 or else Is_Fixed_Point_Type (E));
5446 function Known_Static_Component_Bit_Offset (E : Entity_Id) return B is
5448 return Uint11 (E) /= No_Uint
5449 and then Uint11 (E) >= Uint_0;
5450 end Known_Static_Component_Bit_Offset;
5452 function Known_Static_Component_Size (E : Entity_Id) return B is
5454 return Uint22 (Base_Type (E)) > Uint_0;
5455 end Known_Static_Component_Size;
5457 function Known_Static_Esize (E : Entity_Id) return B is
5459 return Uint12 (E) > Uint_0
5460 and then not Is_Generic_Type (E);
5461 end Known_Static_Esize;
5463 function Known_Static_Normalized_First_Bit (E : Entity_Id) return B is
5465 return Uint8 (E) /= No_Uint
5466 and then Uint8 (E) >= Uint_0;
5467 end Known_Static_Normalized_First_Bit;
5469 function Known_Static_Normalized_Position (E : Entity_Id) return B is
5471 return Uint14 (E) /= No_Uint
5472 and then Uint14 (E) >= Uint_0;
5473 end Known_Static_Normalized_Position;
5475 function Known_Static_Normalized_Position_Max (E : Entity_Id) return B is
5477 return Uint10 (E) /= No_Uint
5478 and then Uint10 (E) >= Uint_0;
5479 end Known_Static_Normalized_Position_Max;
5481 function Known_Static_RM_Size (E : Entity_Id) return B is
5483 return (Uint13 (E) > Uint_0
5484 or else Is_Discrete_Type (E)
5485 or else Is_Fixed_Point_Type (E))
5486 and then not Is_Generic_Type (E);
5487 end Known_Static_RM_Size;
5489 function Unknown_Alignment (E : Entity_Id) return B is
5491 return Uint14 (E) = Uint_0
5492 or else Uint14 (E) = No_Uint;
5493 end Unknown_Alignment;
5495 function Unknown_Component_Bit_Offset (E : Entity_Id) return B is
5497 return Uint11 (E) = No_Uint;
5498 end Unknown_Component_Bit_Offset;
5500 function Unknown_Component_Size (E : Entity_Id) return B is
5502 return Uint22 (Base_Type (E)) = Uint_0
5504 Uint22 (Base_Type (E)) = No_Uint;
5505 end Unknown_Component_Size;
5507 function Unknown_Esize (E : Entity_Id) return B is
5509 return Uint12 (E) = No_Uint
5511 Uint12 (E) = Uint_0;
5514 function Unknown_Normalized_First_Bit (E : Entity_Id) return B is
5516 return Uint8 (E) = No_Uint;
5517 end Unknown_Normalized_First_Bit;
5519 function Unknown_Normalized_Position (E : Entity_Id) return B is
5521 return Uint14 (E) = No_Uint;
5522 end Unknown_Normalized_Position;
5524 function Unknown_Normalized_Position_Max (E : Entity_Id) return B is
5526 return Uint10 (E) = No_Uint;
5527 end Unknown_Normalized_Position_Max;
5529 function Unknown_RM_Size (E : Entity_Id) return B is
5531 return (Uint13 (E) = Uint_0
5532 and then not Is_Discrete_Type (E)
5533 and then not Is_Fixed_Point_Type (E))
5534 or else Uint13 (E) = No_Uint;
5535 end Unknown_RM_Size;
5537 --------------------
5538 -- Address_Clause --
5539 --------------------
5541 function Address_Clause (Id : E) return N is
5543 return Rep_Clause (Id, Name_Address);
5550 function Aft_Value (Id : E) return U is
5552 Delta_Val : Ureal := Delta_Value (Id);
5554 while Delta_Val < Ureal_Tenth loop
5555 Delta_Val := Delta_Val * Ureal_10;
5556 Result := Result + 1;
5559 return UI_From_Int (Result);
5562 ----------------------
5563 -- Alignment_Clause --
5564 ----------------------
5566 function Alignment_Clause (Id : E) return N is
5568 return Rep_Clause (Id, Name_Alignment);
5569 end Alignment_Clause;
5575 procedure Append_Entity (Id : Entity_Id; V : Entity_Id) is
5577 if Last_Entity (V) = Empty then
5578 Set_First_Entity (Id => V, V => Id);
5580 Set_Next_Entity (Last_Entity (V), Id);
5583 Set_Next_Entity (Id, Empty);
5585 Set_Last_Entity (Id => V, V => Id);
5592 function Base_Type (Id : E) return E is
5595 when E_Enumeration_Subtype |
5597 E_Signed_Integer_Subtype |
5598 E_Modular_Integer_Subtype |
5599 E_Floating_Point_Subtype |
5600 E_Ordinary_Fixed_Point_Subtype |
5601 E_Decimal_Fixed_Point_Subtype |
5606 E_Record_Subtype_With_Private |
5607 E_Limited_Private_Subtype |
5609 E_Protected_Subtype |
5611 E_String_Literal_Subtype |
5612 E_Class_Wide_Subtype =>
5620 -------------------------
5621 -- Component_Alignment --
5622 -------------------------
5624 -- Component Alignment is encoded using two flags, Flag128/129 as
5625 -- follows. Note that both flags False = Align_Default, so that the
5626 -- default initialization of flags to False initializes component
5627 -- alignment to the default value as required.
5629 -- Flag128 Flag129 Value
5630 -- ------- ------- -----
5631 -- False False Calign_Default
5632 -- False True Calign_Component_Size
5633 -- True False Calign_Component_Size_4
5634 -- True True Calign_Storage_Unit
5636 function Component_Alignment (Id : E) return C is
5637 BT : constant Node_Id := Base_Type (Id);
5640 pragma Assert (Is_Array_Type (Id) or else Is_Record_Type (Id));
5642 if Flag128 (BT) then
5643 if Flag129 (BT) then
5644 return Calign_Storage_Unit;
5646 return Calign_Component_Size_4;
5650 if Flag129 (BT) then
5651 return Calign_Component_Size;
5653 return Calign_Default;
5656 end Component_Alignment;
5658 ----------------------
5659 -- Declaration_Node --
5660 ----------------------
5662 function Declaration_Node (Id : E) return N is
5666 if Ekind (Id) = E_Incomplete_Type
5667 and then Present (Full_View (Id))
5669 P := Parent (Full_View (Id));
5675 if Nkind (P) /= N_Selected_Component
5676 and then Nkind (P) /= N_Expanded_Name
5678 not (Nkind (P) = N_Defining_Program_Unit_Name
5679 and then Is_Child_Unit (Id))
5686 end Declaration_Node;
5688 ---------------------
5689 -- Designated_Type --
5690 ---------------------
5692 function Designated_Type (Id : E) return E is
5696 Desig_Type := Directly_Designated_Type (Id);
5698 if Ekind (Desig_Type) = E_Incomplete_Type
5699 and then Present (Full_View (Desig_Type))
5701 return Full_View (Desig_Type);
5703 elsif Is_Class_Wide_Type (Desig_Type)
5704 and then Ekind (Etype (Desig_Type)) = E_Incomplete_Type
5705 and then Present (Full_View (Etype (Desig_Type)))
5706 and then Present (Class_Wide_Type (Full_View (Etype (Desig_Type))))
5708 return Class_Wide_Type (Full_View (Etype (Desig_Type)));
5713 end Designated_Type;
5715 ----------------------
5716 -- Entry_Index_Type --
5717 ----------------------
5719 function Entry_Index_Type (Id : E) return N is
5721 pragma Assert (Ekind (Id) = E_Entry_Family);
5722 return Etype (Discrete_Subtype_Definition (Parent (Id)));
5723 end Entry_Index_Type;
5725 ---------------------
5726 -- First_Component --
5727 ---------------------
5729 function First_Component (Id : E) return E is
5734 (Is_Record_Type (Id) or else Is_Incomplete_Or_Private_Type (Id));
5736 Comp_Id := First_Entity (Id);
5737 while Present (Comp_Id) loop
5738 exit when Ekind (Comp_Id) = E_Component;
5739 Comp_Id := Next_Entity (Comp_Id);
5743 end First_Component;
5745 -------------------------------------
5746 -- First_Component_Or_Discriminant --
5747 -------------------------------------
5749 function First_Component_Or_Discriminant (Id : E) return E is
5754 (Is_Record_Type (Id) or else Is_Incomplete_Or_Private_Type (Id));
5756 Comp_Id := First_Entity (Id);
5757 while Present (Comp_Id) loop
5758 exit when Ekind (Comp_Id) = E_Component
5760 Ekind (Comp_Id) = E_Discriminant;
5761 Comp_Id := Next_Entity (Comp_Id);
5765 end First_Component_Or_Discriminant;
5771 function First_Formal (Id : E) return E is
5776 (Is_Overloadable (Id)
5777 or else Ekind_In (Id, E_Entry_Family,
5779 E_Subprogram_Type));
5781 if Ekind (Id) = E_Enumeration_Literal then
5785 Formal := First_Entity (Id);
5787 if Present (Formal) and then Is_Formal (Formal) then
5795 ------------------------------
5796 -- First_Formal_With_Extras --
5797 ------------------------------
5799 function First_Formal_With_Extras (Id : E) return E is
5804 (Is_Overloadable (Id)
5805 or else Ekind_In (Id, E_Entry_Family,
5807 E_Subprogram_Type));
5809 if Ekind (Id) = E_Enumeration_Literal then
5813 Formal := First_Entity (Id);
5815 if Present (Formal) and then Is_Formal (Formal) then
5818 return Extra_Formals (Id); -- Empty if no extra formals
5821 end First_Formal_With_Extras;
5823 -------------------------------------
5824 -- Get_Attribute_Definition_Clause --
5825 -------------------------------------
5827 function Get_Attribute_Definition_Clause
5829 Id : Attribute_Id) return Node_Id
5834 N := First_Rep_Item (E);
5835 while Present (N) loop
5836 if Nkind (N) = N_Attribute_Definition_Clause
5837 and then Get_Attribute_Id (Chars (N)) = Id
5846 end Get_Attribute_Definition_Clause;
5852 function Get_Full_View (T : Entity_Id) return Entity_Id is
5854 if Ekind (T) = E_Incomplete_Type and then Present (Full_View (T)) then
5855 return Full_View (T);
5857 elsif Is_Class_Wide_Type (T)
5858 and then Ekind (Root_Type (T)) = E_Incomplete_Type
5859 and then Present (Full_View (Root_Type (T)))
5861 return Class_Wide_Type (Full_View (Root_Type (T)));
5868 --------------------------------------
5869 -- Get_Record_Representation_Clause --
5870 --------------------------------------
5872 function Get_Record_Representation_Clause (E : Entity_Id) return Node_Id is
5876 N := First_Rep_Item (E);
5877 while Present (N) loop
5878 if Nkind (N) = N_Record_Representation_Clause then
5886 end Get_Record_Representation_Clause;
5888 -----------------------------
5889 -- Get_Rep_Item_For_Entity --
5890 -----------------------------
5892 function Get_Rep_Item_For_Entity
5894 Nam : Name_Id) return Node_Id
5900 N := First_Rep_Item (E);
5901 while Present (N) loop
5902 if Nkind (N) = N_Pragma and then Pragma_Name (N) = Nam then
5903 Arg := Get_Pragma_Arg (First (Pragma_Argument_Associations (N)));
5905 if Is_Entity_Name (Arg) and then Entity (Arg) = E then
5909 elsif Nkind (N) = N_Attribute_Definition_Clause
5910 and then Chars (N) = Nam
5911 and then Entity (N) = E
5915 elsif Nkind (N) = N_Aspect_Specification
5916 and then Chars (Identifier (N)) = Nam
5917 and then Entity (N) = E
5926 end Get_Rep_Item_For_Entity;
5928 --------------------
5929 -- Get_Rep_Pragma --
5930 --------------------
5932 function Get_Rep_Pragma (E : Entity_Id; Nam : Name_Id) return Node_Id is
5936 N := First_Rep_Item (E);
5937 while Present (N) loop
5938 if Nkind (N) = N_Pragma and then Pragma_Name (N) = Nam then
5948 ------------------------
5949 -- Has_Attach_Handler --
5950 ------------------------
5952 function Has_Attach_Handler (Id : E) return B is
5956 pragma Assert (Is_Protected_Type (Id));
5958 Ritem := First_Rep_Item (Id);
5959 while Present (Ritem) loop
5960 if Nkind (Ritem) = N_Pragma
5961 and then Pragma_Name (Ritem) = Name_Attach_Handler
5965 Next_Rep_Item (Ritem);
5970 end Has_Attach_Handler;
5972 -------------------------------------
5973 -- Has_Attribute_Definition_Clause --
5974 -------------------------------------
5976 function Has_Attribute_Definition_Clause
5978 Id : Attribute_Id) return Boolean
5981 return Present (Get_Attribute_Definition_Clause (E, Id));
5982 end Has_Attribute_Definition_Clause;
5988 function Has_Entries (Id : E) return B is
5992 pragma Assert (Is_Concurrent_Type (Id));
5994 Ent := First_Entity (Id);
5995 while Present (Ent) loop
5996 if Is_Entry (Ent) then
6000 Ent := Next_Entity (Ent);
6006 ----------------------------
6007 -- Has_Foreign_Convention --
6008 ----------------------------
6010 function Has_Foreign_Convention (Id : E) return B is
6012 -- While regular Intrinsics such as the Standard operators fit in the
6013 -- "Ada" convention, those with an Interface_Name materialize GCC
6014 -- builtin imports for which Ada special treatments shouldn't apply.
6016 return Convention (Id) in Foreign_Convention
6017 or else (Convention (Id) = Convention_Intrinsic
6018 and then Present (Interface_Name (Id)));
6019 end Has_Foreign_Convention;
6021 ---------------------------
6022 -- Has_Interrupt_Handler --
6023 ---------------------------
6025 function Has_Interrupt_Handler (Id : E) return B is
6029 pragma Assert (Is_Protected_Type (Id));
6031 Ritem := First_Rep_Item (Id);
6032 while Present (Ritem) loop
6033 if Nkind (Ritem) = N_Pragma
6034 and then Pragma_Name (Ritem) = Name_Interrupt_Handler
6038 Next_Rep_Item (Ritem);
6043 end Has_Interrupt_Handler;
6045 --------------------------
6046 -- Has_Private_Ancestor --
6047 --------------------------
6049 function Has_Private_Ancestor (Id : E) return B is
6050 R : constant Entity_Id := Root_Type (Id);
6051 T1 : Entity_Id := Id;
6054 if Is_Private_Type (T1) then
6062 end Has_Private_Ancestor;
6064 --------------------
6065 -- Has_Rep_Pragma --
6066 --------------------
6068 function Has_Rep_Pragma (E : Entity_Id; Nam : Name_Id) return Boolean is
6070 return Present (Get_Rep_Pragma (E, Nam));
6073 --------------------
6074 -- Has_Unmodified --
6075 --------------------
6077 function Has_Unmodified (E : Entity_Id) return Boolean is
6079 if Has_Pragma_Unmodified (E) then
6081 elsif Warnings_Off (E) then
6082 Set_Warnings_Off_Used_Unmodified (E);
6089 ---------------------
6090 -- Has_Unreferenced --
6091 ---------------------
6093 function Has_Unreferenced (E : Entity_Id) return Boolean is
6095 if Has_Pragma_Unreferenced (E) then
6097 elsif Warnings_Off (E) then
6098 Set_Warnings_Off_Used_Unreferenced (E);
6103 end Has_Unreferenced;
6105 ----------------------
6106 -- Has_Warnings_Off --
6107 ----------------------
6109 function Has_Warnings_Off (E : Entity_Id) return Boolean is
6111 if Warnings_Off (E) then
6112 Set_Warnings_Off_Used (E);
6117 end Has_Warnings_Off;
6119 ------------------------------
6120 -- Implementation_Base_Type --
6121 ------------------------------
6123 function Implementation_Base_Type (Id : E) return E is
6128 Bastyp := Base_Type (Id);
6130 if Is_Incomplete_Or_Private_Type (Bastyp) then
6131 Imptyp := Underlying_Type (Bastyp);
6133 -- If we have an implementation type, then just return it,
6134 -- otherwise we return the Base_Type anyway. This can only
6135 -- happen in error situations and should avoid some error bombs.
6137 if Present (Imptyp) then
6138 return Base_Type (Imptyp);
6146 end Implementation_Base_Type;
6148 -------------------------
6149 -- Invariant_Procedure --
6150 -------------------------
6152 function Invariant_Procedure (Id : E) return E is
6156 pragma Assert (Is_Type (Id) and then Has_Invariants (Id));
6158 if No (Subprograms_For_Type (Id)) then
6162 S := Subprograms_For_Type (Id);
6163 while Present (S) loop
6164 if Has_Invariants (S) then
6167 S := Subprograms_For_Type (S);
6173 end Invariant_Procedure;
6175 ---------------------
6176 -- Is_Boolean_Type --
6177 ---------------------
6179 function Is_Boolean_Type (Id : E) return B is
6181 return Root_Type (Id) = Standard_Boolean;
6182 end Is_Boolean_Type;
6184 ------------------------
6185 -- Is_Constant_Object --
6186 ------------------------
6188 function Is_Constant_Object (Id : E) return B is
6189 K : constant Entity_Kind := Ekind (Id);
6192 K = E_Constant or else K = E_In_Parameter or else K = E_Loop_Parameter;
6193 end Is_Constant_Object;
6195 --------------------
6196 -- Is_Discriminal --
6197 --------------------
6199 function Is_Discriminal (Id : E) return B is
6201 return (Ekind_In (Id, E_Constant, E_In_Parameter)
6202 and then Present (Discriminal_Link (Id)));
6205 ----------------------
6206 -- Is_Dynamic_Scope --
6207 ----------------------
6209 function Is_Dynamic_Scope (Id : E) return B is
6212 Ekind (Id) = E_Block
6214 Ekind (Id) = E_Function
6216 Ekind (Id) = E_Procedure
6218 Ekind (Id) = E_Subprogram_Body
6220 Ekind (Id) = E_Task_Type
6222 (Ekind (Id) = E_Limited_Private_Type
6223 and then Present (Full_View (Id))
6224 and then Ekind (Full_View (Id)) = E_Task_Type)
6226 Ekind (Id) = E_Entry
6228 Ekind (Id) = E_Entry_Family
6230 Ekind (Id) = E_Return_Statement;
6231 end Is_Dynamic_Scope;
6233 --------------------
6234 -- Is_Entity_Name --
6235 --------------------
6237 function Is_Entity_Name (N : Node_Id) return Boolean is
6238 Kind : constant Node_Kind := Nkind (N);
6241 -- Identifiers, operator symbols, expanded names are entity names
6243 return Kind = N_Identifier
6244 or else Kind = N_Operator_Symbol
6245 or else Kind = N_Expanded_Name
6247 -- Attribute references are entity names if they refer to an entity.
6248 -- Note that we don't do this by testing for the presence of the
6249 -- Entity field in the N_Attribute_Reference node, since it may not
6250 -- have been set yet.
6252 or else (Kind = N_Attribute_Reference
6253 and then Is_Entity_Attribute_Name (Attribute_Name (N)));
6256 -----------------------------------
6257 -- Is_Package_Or_Generic_Package --
6258 -----------------------------------
6260 function Is_Package_Or_Generic_Package (Id : E) return B is
6263 Ekind (Id) = E_Package
6265 Ekind (Id) = E_Generic_Package;
6266 end Is_Package_Or_Generic_Package;
6268 ------------------------
6269 -- Predicate_Function --
6270 ------------------------
6272 function Predicate_Function (Id : E) return E is
6276 pragma Assert (Is_Type (Id));
6278 if No (Subprograms_For_Type (Id)) then
6282 S := Subprograms_For_Type (Id);
6283 while Present (S) loop
6284 if Has_Predicates (S) then
6287 S := Subprograms_For_Type (S);
6293 end Predicate_Function;
6299 function Is_Prival (Id : E) return B is
6301 return (Ekind_In (Id, E_Constant, E_Variable)
6302 and then Present (Prival_Link (Id)));
6305 ----------------------------
6306 -- Is_Protected_Component --
6307 ----------------------------
6309 function Is_Protected_Component (Id : E) return B is
6311 return Ekind (Id) = E_Component
6312 and then Is_Protected_Type (Scope (Id));
6313 end Is_Protected_Component;
6315 ----------------------------
6316 -- Is_Protected_Interface --
6317 ----------------------------
6319 function Is_Protected_Interface (Id : E) return B is
6320 Typ : constant Entity_Id := Base_Type (Id);
6322 if not Is_Interface (Typ) then
6324 elsif Is_Class_Wide_Type (Typ) then
6325 return Is_Protected_Interface (Etype (Typ));
6327 return Protected_Present (Type_Definition (Parent (Typ)));
6329 end Is_Protected_Interface;
6331 ------------------------------
6332 -- Is_Protected_Record_Type --
6333 ------------------------------
6335 function Is_Protected_Record_Type (Id : E) return B is
6338 Is_Concurrent_Record_Type (Id)
6339 and then Is_Protected_Type (Corresponding_Concurrent_Type (Id));
6340 end Is_Protected_Record_Type;
6342 --------------------------------
6343 -- Is_Standard_Character_Type --
6344 --------------------------------
6346 function Is_Standard_Character_Type (Id : E) return B is
6348 if Is_Type (Id) then
6350 R : constant Entity_Id := Root_Type (Id);
6353 R = Standard_Character
6355 R = Standard_Wide_Character
6357 R = Standard_Wide_Wide_Character;
6363 end Is_Standard_Character_Type;
6365 --------------------
6366 -- Is_String_Type --
6367 --------------------
6369 function Is_String_Type (Id : E) return B is
6371 return Ekind (Id) in String_Kind
6372 or else (Is_Array_Type (Id)
6373 and then Id /= Any_Composite
6374 and then Number_Dimensions (Id) = 1
6375 and then Is_Character_Type (Component_Type (Id)));
6378 -------------------------------
6379 -- Is_Synchronized_Interface --
6380 -------------------------------
6382 function Is_Synchronized_Interface (Id : E) return B is
6383 Typ : constant Entity_Id := Base_Type (Id);
6386 if not Is_Interface (Typ) then
6389 elsif Is_Class_Wide_Type (Typ) then
6390 return Is_Synchronized_Interface (Etype (Typ));
6393 return Protected_Present (Type_Definition (Parent (Typ)))
6394 or else Synchronized_Present (Type_Definition (Parent (Typ)))
6395 or else Task_Present (Type_Definition (Parent (Typ)));
6397 end Is_Synchronized_Interface;
6399 -----------------------
6400 -- Is_Task_Interface --
6401 -----------------------
6403 function Is_Task_Interface (Id : E) return B is
6404 Typ : constant Entity_Id := Base_Type (Id);
6406 if not Is_Interface (Typ) then
6408 elsif Is_Class_Wide_Type (Typ) then
6409 return Is_Task_Interface (Etype (Typ));
6411 return Task_Present (Type_Definition (Parent (Typ)));
6413 end Is_Task_Interface;
6415 -------------------------
6416 -- Is_Task_Record_Type --
6417 -------------------------
6419 function Is_Task_Record_Type (Id : E) return B is
6422 Is_Concurrent_Record_Type (Id)
6423 and then Is_Task_Type (Corresponding_Concurrent_Type (Id));
6424 end Is_Task_Record_Type;
6426 ------------------------
6427 -- Is_Wrapper_Package --
6428 ------------------------
6430 function Is_Wrapper_Package (Id : E) return B is
6432 return (Ekind (Id) = E_Package
6433 and then Present (Related_Instance (Id)));
6434 end Is_Wrapper_Package;
6440 function Last_Formal (Id : E) return E is
6445 (Is_Overloadable (Id)
6446 or else Ekind_In (Id, E_Entry_Family,
6448 E_Subprogram_Type));
6450 if Ekind (Id) = E_Enumeration_Literal then
6454 Formal := First_Formal (Id);
6456 if Present (Formal) then
6457 while Present (Next_Formal (Formal)) loop
6458 Formal := Next_Formal (Formal);
6466 --------------------
6467 -- Next_Component --
6468 --------------------
6470 function Next_Component (Id : E) return E is
6474 Comp_Id := Next_Entity (Id);
6475 while Present (Comp_Id) loop
6476 exit when Ekind (Comp_Id) = E_Component;
6477 Comp_Id := Next_Entity (Comp_Id);
6483 ------------------------------------
6484 -- Next_Component_Or_Discriminant --
6485 ------------------------------------
6487 function Next_Component_Or_Discriminant (Id : E) return E is
6491 Comp_Id := Next_Entity (Id);
6492 while Present (Comp_Id) loop
6493 exit when Ekind_In (Comp_Id, E_Component, E_Discriminant);
6494 Comp_Id := Next_Entity (Comp_Id);
6498 end Next_Component_Or_Discriminant;
6500 -----------------------
6501 -- Next_Discriminant --
6502 -----------------------
6504 -- This function actually implements both Next_Discriminant and
6505 -- Next_Stored_Discriminant by making sure that the Discriminant
6506 -- returned is of the same variety as Id.
6508 function Next_Discriminant (Id : E) return E is
6510 -- Derived Tagged types with private extensions look like this...
6512 -- E_Discriminant d1
6513 -- E_Discriminant d2
6515 -- E_Discriminant d1
6516 -- E_Discriminant d2
6519 -- so it is critical not to go past the leading discriminants
6524 pragma Assert (Ekind (Id) = E_Discriminant);
6527 D := Next_Entity (D);
6529 or else (Ekind (D) /= E_Discriminant
6530 and then not Is_Itype (D))
6535 exit when Ekind (D) = E_Discriminant
6536 and then (Is_Completely_Hidden (D) = Is_Completely_Hidden (Id));
6540 end Next_Discriminant;
6546 function Next_Formal (Id : E) return E is
6550 -- Follow the chain of declared entities as long as the kind of the
6551 -- entity corresponds to a formal parameter. Skip internal entities
6552 -- that may have been created for implicit subtypes, in the process
6553 -- of analyzing default expressions.
6558 P := Next_Entity (P);
6560 if No (P) or else Is_Formal (P) then
6562 elsif not Is_Internal (P) then
6568 -----------------------------
6569 -- Next_Formal_With_Extras --
6570 -----------------------------
6572 function Next_Formal_With_Extras (Id : E) return E is
6574 if Present (Extra_Formal (Id)) then
6575 return Extra_Formal (Id);
6577 return Next_Formal (Id);
6579 end Next_Formal_With_Extras;
6585 function Next_Index (Id : Node_Id) return Node_Id is
6594 function Next_Literal (Id : E) return E is
6596 pragma Assert (Nkind (Id) in N_Entity);
6600 ------------------------------
6601 -- Next_Stored_Discriminant --
6602 ------------------------------
6604 function Next_Stored_Discriminant (Id : E) return E is
6606 -- See comment in Next_Discriminant
6608 return Next_Discriminant (Id);
6609 end Next_Stored_Discriminant;
6611 -----------------------
6612 -- Number_Dimensions --
6613 -----------------------
6615 function Number_Dimensions (Id : E) return Pos is
6620 if Ekind (Id) in String_Kind then
6625 T := First_Index (Id);
6626 while Present (T) loop
6633 end Number_Dimensions;
6635 --------------------
6636 -- Number_Entries --
6637 --------------------
6639 function Number_Entries (Id : E) return Nat is
6644 pragma Assert (Is_Concurrent_Type (Id));
6647 Ent := First_Entity (Id);
6648 while Present (Ent) loop
6649 if Is_Entry (Ent) then
6653 Ent := Next_Entity (Ent);
6659 --------------------
6660 -- Number_Formals --
6661 --------------------
6663 function Number_Formals (Id : E) return Pos is
6669 Formal := First_Formal (Id);
6670 while Present (Formal) loop
6672 Formal := Next_Formal (Formal);
6678 --------------------
6679 -- Parameter_Mode --
6680 --------------------
6682 function Parameter_Mode (Id : E) return Formal_Kind is
6687 --------------------------
6688 -- Primitive_Operations --
6689 --------------------------
6691 function Primitive_Operations (Id : E) return L is
6693 if Is_Concurrent_Type (Id) then
6694 if Present (Corresponding_Record_Type (Id)) then
6695 return Direct_Primitive_Operations
6696 (Corresponding_Record_Type (Id));
6701 return Direct_Primitive_Operations (Id);
6703 end Primitive_Operations;
6705 ---------------------
6706 -- Record_Rep_Item --
6707 ---------------------
6709 procedure Record_Rep_Item (E : Entity_Id; N : Node_Id) is
6711 Set_Next_Rep_Item (N, First_Rep_Item (E));
6712 Set_First_Rep_Item (E, N);
6713 end Record_Rep_Item;
6719 function Root_Type (Id : E) return E is
6723 pragma Assert (Nkind (Id) in N_Entity);
6725 T := Base_Type (Id);
6727 if Ekind (T) = E_Class_Wide_Type then
6730 elsif Ekind (T) = E_Class_Wide_Subtype then
6731 return Etype (Base_Type (T));
6733 -- ??? T comes from Base_Type, how can it be a subtype?
6734 -- Also Base_Type is supposed to be idempotent, so either way
6735 -- this is equivalent to "return Etype (T)" and should be merged
6736 -- with the E_Class_Wide_Type case.
6747 -- Following test catches some error cases resulting from
6750 elsif No (Etyp) then
6753 elsif Is_Private_Type (T) and then Etyp = Full_View (T) then
6756 elsif Is_Private_Type (Etyp) and then Full_View (Etyp) = T then
6762 -- Return if there is a circularity in the inheritance chain. This
6763 -- happens in some error situations and we do not want to get
6764 -- stuck in this loop.
6766 if T = Base_Type (Id) then
6777 function Scope_Depth (Id : E) return Uint is
6782 while Is_Record_Type (Scop) loop
6783 Scop := Scope (Scop);
6786 return Scope_Depth_Value (Scop);
6789 ---------------------
6790 -- Scope_Depth_Set --
6791 ---------------------
6793 function Scope_Depth_Set (Id : E) return B is
6795 return not Is_Record_Type (Id)
6796 and then Field22 (Id) /= Union_Id (Empty);
6797 end Scope_Depth_Set;
6799 -----------------------------
6800 -- Set_Component_Alignment --
6801 -----------------------------
6803 -- Component Alignment is encoded using two flags, Flag128/129 as
6804 -- follows. Note that both flags False = Align_Default, so that the
6805 -- default initialization of flags to False initializes component
6806 -- alignment to the default value as required.
6808 -- Flag128 Flag129 Value
6809 -- ------- ------- -----
6810 -- False False Calign_Default
6811 -- False True Calign_Component_Size
6812 -- True False Calign_Component_Size_4
6813 -- True True Calign_Storage_Unit
6815 procedure Set_Component_Alignment (Id : E; V : C) is
6817 pragma Assert ((Is_Array_Type (Id) or else Is_Record_Type (Id))
6818 and then Id = Base_Type (Id));
6821 when Calign_Default =>
6822 Set_Flag128 (Id, False);
6823 Set_Flag129 (Id, False);
6825 when Calign_Component_Size =>
6826 Set_Flag128 (Id, False);
6827 Set_Flag129 (Id, True);
6829 when Calign_Component_Size_4 =>
6830 Set_Flag128 (Id, True);
6831 Set_Flag129 (Id, False);
6833 when Calign_Storage_Unit =>
6834 Set_Flag128 (Id, True);
6835 Set_Flag129 (Id, True);
6837 end Set_Component_Alignment;
6839 -----------------------------
6840 -- Set_Invariant_Procedure --
6841 -----------------------------
6843 procedure Set_Invariant_Procedure (Id : E; V : E) is
6847 pragma Assert (Is_Type (Id) and then Has_Invariants (Id));
6849 S := Subprograms_For_Type (Id);
6850 Set_Subprograms_For_Type (Id, V);
6852 while Present (S) loop
6853 if Has_Invariants (S) then
6854 raise Program_Error;
6856 S := Subprograms_For_Type (S);
6860 Set_Subprograms_For_Type (Id, V);
6861 end Set_Invariant_Procedure;
6863 ----------------------------
6864 -- Set_Predicate_Function --
6865 ----------------------------
6867 procedure Set_Predicate_Function (Id : E; V : E) is
6871 pragma Assert (Is_Type (Id) and then Has_Predicates (Id));
6873 S := Subprograms_For_Type (Id);
6874 Set_Subprograms_For_Type (Id, V);
6876 while Present (S) loop
6877 if Has_Predicates (S) then
6878 raise Program_Error;
6880 S := Subprograms_For_Type (S);
6884 Set_Subprograms_For_Type (Id, V);
6885 end Set_Predicate_Function;
6891 function Size_Clause (Id : E) return N is
6893 return Rep_Clause (Id, Name_Size);
6896 ------------------------
6897 -- Stream_Size_Clause --
6898 ------------------------
6900 function Stream_Size_Clause (Id : E) return N is
6902 return Rep_Clause (Id, Name_Stream_Size);
6903 end Stream_Size_Clause;
6909 function Subtype_Kind (K : Entity_Kind) return Entity_Kind is
6915 Kind := E_Access_Subtype;
6919 Kind := E_Array_Subtype;
6921 when E_Class_Wide_Type |
6922 E_Class_Wide_Subtype =>
6923 Kind := E_Class_Wide_Subtype;
6925 when E_Decimal_Fixed_Point_Type |
6926 E_Decimal_Fixed_Point_Subtype =>
6927 Kind := E_Decimal_Fixed_Point_Subtype;
6929 when E_Ordinary_Fixed_Point_Type |
6930 E_Ordinary_Fixed_Point_Subtype =>
6931 Kind := E_Ordinary_Fixed_Point_Subtype;
6933 when E_Private_Type |
6934 E_Private_Subtype =>
6935 Kind := E_Private_Subtype;
6937 when E_Limited_Private_Type |
6938 E_Limited_Private_Subtype =>
6939 Kind := E_Limited_Private_Subtype;
6941 when E_Record_Type_With_Private |
6942 E_Record_Subtype_With_Private =>
6943 Kind := E_Record_Subtype_With_Private;
6945 when E_Record_Type |
6947 Kind := E_Record_Subtype;
6949 when E_String_Type |
6951 Kind := E_String_Subtype;
6953 when Enumeration_Kind =>
6954 Kind := E_Enumeration_Subtype;
6957 Kind := E_Floating_Point_Subtype;
6959 when Signed_Integer_Kind =>
6960 Kind := E_Signed_Integer_Subtype;
6962 when Modular_Integer_Kind =>
6963 Kind := E_Modular_Integer_Subtype;
6965 when Protected_Kind =>
6966 Kind := E_Protected_Subtype;
6969 Kind := E_Task_Subtype;
6973 raise Program_Error;
6979 ---------------------
6980 -- Type_High_Bound --
6981 ---------------------
6983 function Type_High_Bound (Id : E) return Node_Id is
6984 Rng : constant Node_Id := Scalar_Range (Id);
6986 if Nkind (Rng) = N_Subtype_Indication then
6987 return High_Bound (Range_Expression (Constraint (Rng)));
6989 return High_Bound (Rng);
6991 end Type_High_Bound;
6993 --------------------
6994 -- Type_Low_Bound --
6995 --------------------
6997 function Type_Low_Bound (Id : E) return Node_Id is
6998 Rng : constant Node_Id := Scalar_Range (Id);
7000 if Nkind (Rng) = N_Subtype_Indication then
7001 return Low_Bound (Range_Expression (Constraint (Rng)));
7003 return Low_Bound (Rng);
7007 ---------------------
7008 -- Underlying_Type --
7009 ---------------------
7011 function Underlying_Type (Id : E) return E is
7013 -- For record_with_private the underlying type is always the direct
7014 -- full view. Never try to take the full view of the parent it
7015 -- doesn't make sense.
7017 if Ekind (Id) = E_Record_Type_With_Private then
7018 return Full_View (Id);
7020 elsif Ekind (Id) in Incomplete_Or_Private_Kind then
7022 -- If we have an incomplete or private type with a full view,
7023 -- then we return the Underlying_Type of this full view
7025 if Present (Full_View (Id)) then
7026 if Id = Full_View (Id) then
7028 -- Previous error in declaration
7033 return Underlying_Type (Full_View (Id));
7036 -- If we have an incomplete entity that comes from the limited
7037 -- view then we return the Underlying_Type of its non-limited
7040 elsif From_With_Type (Id)
7041 and then Present (Non_Limited_View (Id))
7043 return Underlying_Type (Non_Limited_View (Id));
7045 -- Otherwise check for the case where we have a derived type or
7046 -- subtype, and if so get the Underlying_Type of the parent type.
7048 elsif Etype (Id) /= Id then
7049 return Underlying_Type (Etype (Id));
7051 -- Otherwise we have an incomplete or private type that has
7052 -- no full view, which means that we have not encountered the
7053 -- completion, so return Empty to indicate the underlying type
7054 -- is not yet known.
7060 -- For non-incomplete, non-private types, return the type itself
7061 -- Also for entities that are not types at all return the entity
7067 end Underlying_Type;
7069 ------------------------
7070 -- Write_Entity_Flags --
7071 ------------------------
7073 procedure Write_Entity_Flags (Id : Entity_Id; Prefix : String) is
7075 procedure W (Flag_Name : String; Flag : Boolean);
7076 -- Write out given flag if it is set
7082 procedure W (Flag_Name : String; Flag : Boolean) is
7086 Write_Str (Flag_Name);
7087 Write_Str (" = True");
7092 -- Start of processing for Write_Entity_Flags
7095 if (Is_Array_Type (Id) or else Is_Record_Type (Id))
7096 and then Id = Base_Type (Id)
7099 Write_Str ("Component_Alignment = ");
7101 case Component_Alignment (Id) is
7102 when Calign_Default =>
7103 Write_Str ("Calign_Default");
7105 when Calign_Component_Size =>
7106 Write_Str ("Calign_Component_Size");
7108 when Calign_Component_Size_4 =>
7109 Write_Str ("Calign_Component_Size_4");
7111 when Calign_Storage_Unit =>
7112 Write_Str ("Calign_Storage_Unit");
7118 W ("Address_Taken", Flag104 (Id));
7119 W ("Body_Needed_For_SAL", Flag40 (Id));
7120 W ("C_Pass_By_Copy", Flag125 (Id));
7121 W ("Can_Never_Be_Null", Flag38 (Id));
7122 W ("Checks_May_Be_Suppressed", Flag31 (Id));
7123 W ("Debug_Info_Off", Flag166 (Id));
7124 W ("Default_Expressions_Processed", Flag108 (Id));
7125 W ("Delay_Cleanups", Flag114 (Id));
7126 W ("Delay_Subprogram_Descriptors", Flag50 (Id));
7127 W ("Depends_On_Private", Flag14 (Id));
7128 W ("Discard_Names", Flag88 (Id));
7129 W ("Elaboration_Entity_Required", Flag174 (Id));
7130 W ("Elaborate_Body_Desirable", Flag210 (Id));
7131 W ("Entry_Accepted", Flag152 (Id));
7132 W ("Can_Use_Internal_Rep", Flag229 (Id));
7133 W ("Finalize_Storage_Only", Flag158 (Id));
7134 W ("From_With_Type", Flag159 (Id));
7135 W ("Has_Aliased_Components", Flag135 (Id));
7136 W ("Has_Alignment_Clause", Flag46 (Id));
7137 W ("Has_All_Calls_Remote", Flag79 (Id));
7138 W ("Has_Anon_Block_Suffix", Flag201 (Id));
7139 W ("Has_Atomic_Components", Flag86 (Id));
7140 W ("Has_Biased_Representation", Flag139 (Id));
7141 W ("Has_Completion", Flag26 (Id));
7142 W ("Has_Completion_In_Body", Flag71 (Id));
7143 W ("Has_Complex_Representation", Flag140 (Id));
7144 W ("Has_Component_Size_Clause", Flag68 (Id));
7145 W ("Has_Contiguous_Rep", Flag181 (Id));
7146 W ("Has_Controlled_Component", Flag43 (Id));
7147 W ("Has_Controlling_Result", Flag98 (Id));
7148 W ("Has_Convention_Pragma", Flag119 (Id));
7149 W ("Has_Delayed_Aspects", Flag200 (Id));
7150 W ("Has_Delayed_Freeze", Flag18 (Id));
7151 W ("Has_Discriminants", Flag5 (Id));
7152 W ("Has_Enumeration_Rep_Clause", Flag66 (Id));
7153 W ("Has_Exit", Flag47 (Id));
7154 W ("Has_External_Tag_Rep_Clause", Flag110 (Id));
7155 W ("Has_Forward_Instantiation", Flag175 (Id));
7156 W ("Has_Fully_Qualified_Name", Flag173 (Id));
7157 W ("Has_Gigi_Rep_Item", Flag82 (Id));
7158 W ("Has_Homonym", Flag56 (Id));
7159 W ("Has_Inheritable_Invariants", Flag248 (Id));
7160 W ("Has_Initial_Value", Flag219 (Id));
7161 W ("Has_Invariants", Flag232 (Id));
7162 W ("Has_Machine_Radix_Clause", Flag83 (Id));
7163 W ("Has_Master_Entity", Flag21 (Id));
7164 W ("Has_Missing_Return", Flag142 (Id));
7165 W ("Has_Nested_Block_With_Handler", Flag101 (Id));
7166 W ("Has_Non_Standard_Rep", Flag75 (Id));
7167 W ("Has_Object_Size_Clause", Flag172 (Id));
7168 W ("Has_Per_Object_Constraint", Flag154 (Id));
7169 W ("Has_Persistent_BSS", Flag188 (Id));
7170 W ("Has_Postconditions", Flag240 (Id));
7171 W ("Has_Pragma_Controlled", Flag27 (Id));
7172 W ("Has_Pragma_Elaborate_Body", Flag150 (Id));
7173 W ("Has_Pragma_Inline", Flag157 (Id));
7174 W ("Has_Pragma_Inline_Always", Flag230 (Id));
7175 W ("Has_Pragma_Ordered", Flag198 (Id));
7176 W ("Has_Pragma_Pack", Flag121 (Id));
7177 W ("Has_Pragma_Preelab_Init", Flag221 (Id));
7178 W ("Has_Pragma_Pure", Flag203 (Id));
7179 W ("Has_Pragma_Pure_Function", Flag179 (Id));
7180 W ("Has_Pragma_Thread_Local_Storage", Flag169 (Id));
7181 W ("Has_Pragma_Unmodified", Flag233 (Id));
7182 W ("Has_Pragma_Unreferenced", Flag180 (Id));
7183 W ("Has_Pragma_Unreferenced_Objects", Flag212 (Id));
7184 W ("Has_Predicates", Flag250 (Id));
7185 W ("Has_Primitive_Operations", Flag120 (Id));
7186 W ("Has_Private_Declaration", Flag155 (Id));
7187 W ("Has_Qualified_Name", Flag161 (Id));
7188 W ("Has_RACW", Flag214 (Id));
7189 W ("Has_Record_Rep_Clause", Flag65 (Id));
7190 W ("Has_Recursive_Call", Flag143 (Id));
7191 W ("Has_Size_Clause", Flag29 (Id));
7192 W ("Has_Small_Clause", Flag67 (Id));
7193 W ("Has_Specified_Layout", Flag100 (Id));
7194 W ("Has_Specified_Stream_Input", Flag190 (Id));
7195 W ("Has_Specified_Stream_Output", Flag191 (Id));
7196 W ("Has_Specified_Stream_Read", Flag192 (Id));
7197 W ("Has_Specified_Stream_Write", Flag193 (Id));
7198 W ("Has_Static_Discriminants", Flag211 (Id));
7199 W ("Has_Storage_Size_Clause", Flag23 (Id));
7200 W ("Has_Stream_Size_Clause", Flag184 (Id));
7201 W ("Has_Subprogram_Descriptor", Flag93 (Id));
7202 W ("Has_Task", Flag30 (Id));
7203 W ("Has_Thunks", Flag228 (Id));
7204 W ("Has_Unchecked_Union", Flag123 (Id));
7205 W ("Has_Unknown_Discriminants", Flag72 (Id));
7206 W ("Has_Up_Level_Access", Flag215 (Id));
7207 W ("Has_Volatile_Components", Flag87 (Id));
7208 W ("Has_Xref_Entry", Flag182 (Id));
7209 W ("In_Package_Body", Flag48 (Id));
7210 W ("In_Private_Part", Flag45 (Id));
7211 W ("In_Use", Flag8 (Id));
7212 W ("Is_AST_Entry", Flag132 (Id));
7213 W ("Is_Abstract_Subprogram", Flag19 (Id));
7214 W ("Is_Abstract_Type", Flag146 (Id));
7215 W ("Is_Local_Anonymous_Access", Flag194 (Id));
7216 W ("Is_Access_Constant", Flag69 (Id));
7217 W ("Is_Ada_2005_Only", Flag185 (Id));
7218 W ("Is_Ada_2012_Only", Flag199 (Id));
7219 W ("Is_Aliased", Flag15 (Id));
7220 W ("Is_Asynchronous", Flag81 (Id));
7221 W ("Is_Atomic", Flag85 (Id));
7222 W ("Is_Bit_Packed_Array", Flag122 (Id));
7223 W ("Is_CPP_Class", Flag74 (Id));
7224 W ("Is_Called", Flag102 (Id));
7225 W ("Is_Character_Type", Flag63 (Id));
7226 W ("Is_Child_Unit", Flag73 (Id));
7227 W ("Is_Class_Wide_Equivalent_Type", Flag35 (Id));
7228 W ("Is_Compilation_Unit", Flag149 (Id));
7229 W ("Is_Completely_Hidden", Flag103 (Id));
7230 W ("Is_Concurrent_Record_Type", Flag20 (Id));
7231 W ("Is_Constr_Subt_For_UN_Aliased", Flag141 (Id));
7232 W ("Is_Constr_Subt_For_U_Nominal", Flag80 (Id));
7233 W ("Is_Constrained", Flag12 (Id));
7234 W ("Is_Constructor", Flag76 (Id));
7235 W ("Is_Controlled", Flag42 (Id));
7236 W ("Is_Controlling_Formal", Flag97 (Id));
7237 W ("Is_Descendent_Of_Address", Flag223 (Id));
7238 W ("Is_Discrim_SO_Function", Flag176 (Id));
7239 W ("Is_Dispatch_Table_Entity", Flag234 (Id));
7240 W ("Is_Dispatching_Operation", Flag6 (Id));
7241 W ("Is_Eliminated", Flag124 (Id));
7242 W ("Is_Entry_Formal", Flag52 (Id));
7243 W ("Is_Exported", Flag99 (Id));
7244 W ("Is_First_Subtype", Flag70 (Id));
7245 W ("Is_For_Access_Subtype", Flag118 (Id));
7246 W ("Is_Formal_Subprogram", Flag111 (Id));
7247 W ("Is_Frozen", Flag4 (Id));
7248 W ("Is_Generic_Actual_Type", Flag94 (Id));
7249 W ("Is_Generic_Instance", Flag130 (Id));
7250 W ("Is_Generic_Type", Flag13 (Id));
7251 W ("Is_Hidden", Flag57 (Id));
7252 W ("Is_Hidden_Open_Scope", Flag171 (Id));
7253 W ("Is_Immediately_Visible", Flag7 (Id));
7254 W ("Is_Imported", Flag24 (Id));
7255 W ("Is_Inlined", Flag11 (Id));
7256 W ("Is_Instantiated", Flag126 (Id));
7257 W ("Is_Interface", Flag186 (Id));
7258 W ("Is_Internal", Flag17 (Id));
7259 W ("Is_Interrupt_Handler", Flag89 (Id));
7260 W ("Is_Intrinsic_Subprogram", Flag64 (Id));
7261 W ("Is_Itype", Flag91 (Id));
7262 W ("Is_Known_Non_Null", Flag37 (Id));
7263 W ("Is_Known_Null", Flag204 (Id));
7264 W ("Is_Known_Valid", Flag170 (Id));
7265 W ("Is_Limited_Composite", Flag106 (Id));
7266 W ("Is_Limited_Interface", Flag197 (Id));
7267 W ("Is_Limited_Record", Flag25 (Id));
7268 W ("Is_Machine_Code_Subprogram", Flag137 (Id));
7269 W ("Is_Non_Static_Subtype", Flag109 (Id));
7270 W ("Is_Null_Init_Proc", Flag178 (Id));
7271 W ("Is_Obsolescent", Flag153 (Id));
7272 W ("Is_Only_Out_Parameter", Flag226 (Id));
7273 W ("Is_Optional_Parameter", Flag134 (Id));
7274 W ("Is_Overriding_Operation", Flag39 (Id));
7275 W ("Is_Package_Body_Entity", Flag160 (Id));
7276 W ("Is_Packed", Flag51 (Id));
7277 W ("Is_Packed_Array_Type", Flag138 (Id));
7278 W ("Is_Potentially_Use_Visible", Flag9 (Id));
7279 W ("Is_Preelaborated", Flag59 (Id));
7280 W ("Is_Primitive", Flag218 (Id));
7281 W ("Is_Primitive_Wrapper", Flag195 (Id));
7282 W ("Is_Private_Composite", Flag107 (Id));
7283 W ("Is_Private_Descendant", Flag53 (Id));
7284 W ("Is_Private_Primitive", Flag245 (Id));
7285 W ("Is_Public", Flag10 (Id));
7286 W ("Is_Pure", Flag44 (Id));
7287 W ("Is_Pure_Unit_Access_Type", Flag189 (Id));
7288 W ("Is_RACW_Stub_Type", Flag244 (Id));
7289 W ("Is_Raised", Flag224 (Id));
7290 W ("Is_Remote_Call_Interface", Flag62 (Id));
7291 W ("Is_Remote_Types", Flag61 (Id));
7292 W ("Is_Renaming_Of_Object", Flag112 (Id));
7293 W ("Is_Return_Object", Flag209 (Id));
7294 W ("Is_Shared_Passive", Flag60 (Id));
7295 W ("Is_Statically_Allocated", Flag28 (Id));
7296 W ("Is_Tag", Flag78 (Id));
7297 W ("Is_Tagged_Type", Flag55 (Id));
7298 W ("Is_Thunk", Flag225 (Id));
7299 W ("Is_Trivial_Subprogram", Flag235 (Id));
7300 W ("Is_True_Constant", Flag163 (Id));
7301 W ("Is_Unchecked_Union", Flag117 (Id));
7302 W ("Is_Underlying_Record_View", Flag246 (Id));
7303 W ("Is_Unsigned_Type", Flag144 (Id));
7304 W ("Is_VMS_Exception", Flag133 (Id));
7305 W ("Is_Valued_Procedure", Flag127 (Id));
7306 W ("Is_Visible_Child_Unit", Flag116 (Id));
7307 W ("Is_Visible_Formal", Flag206 (Id));
7308 W ("Is_Volatile", Flag16 (Id));
7309 W ("Itype_Printed", Flag202 (Id));
7310 W ("Kill_Elaboration_Checks", Flag32 (Id));
7311 W ("Kill_Range_Checks", Flag33 (Id));
7312 W ("Kill_Tag_Checks", Flag34 (Id));
7313 W ("Known_To_Have_Preelab_Init", Flag207 (Id));
7314 W ("Low_Bound_Tested", Flag205 (Id));
7315 W ("Machine_Radix_10", Flag84 (Id));
7316 W ("Materialize_Entity", Flag168 (Id));
7317 W ("Must_Be_On_Byte_Boundary", Flag183 (Id));
7318 W ("Must_Have_Preelab_Init", Flag208 (Id));
7319 W ("Needs_Debug_Info", Flag147 (Id));
7320 W ("Needs_No_Actuals", Flag22 (Id));
7321 W ("Never_Set_In_Source", Flag115 (Id));
7322 W ("No_Pool_Assigned", Flag131 (Id));
7323 W ("No_Return", Flag113 (Id));
7324 W ("No_Strict_Aliasing", Flag136 (Id));
7325 W ("Non_Binary_Modulus", Flag58 (Id));
7326 W ("Nonzero_Is_True", Flag162 (Id));
7327 W ("OK_To_Reference", Flag249 (Id));
7328 W ("OK_To_Rename", Flag247 (Id));
7329 W ("OK_To_Reorder_Components", Flag239 (Id));
7330 W ("Optimize_Alignment_Space", Flag241 (Id));
7331 W ("Optimize_Alignment_Time", Flag242 (Id));
7332 W ("Overlays_Constant", Flag243 (Id));
7333 W ("Reachable", Flag49 (Id));
7334 W ("Referenced", Flag156 (Id));
7335 W ("Referenced_As_LHS", Flag36 (Id));
7336 W ("Referenced_As_Out_Parameter", Flag227 (Id));
7337 W ("Renamed_In_Spec", Flag231 (Id));
7338 W ("Requires_Overriding", Flag213 (Id));
7339 W ("Return_Present", Flag54 (Id));
7340 W ("Returns_By_Ref", Flag90 (Id));
7341 W ("Reverse_Bit_Order", Flag164 (Id));
7342 W ("Sec_Stack_Needed_For_Return", Flag167 (Id));
7343 W ("Size_Depends_On_Discriminant", Flag177 (Id));
7344 W ("Size_Known_At_Compile_Time", Flag92 (Id));
7345 W ("Static_Elaboration_Desired", Flag77 (Id));
7346 W ("Strict_Alignment", Flag145 (Id));
7347 W ("Suppress_Elaboration_Warnings", Flag148 (Id));
7348 W ("Suppress_Init_Proc", Flag105 (Id));
7349 W ("Suppress_Style_Checks", Flag165 (Id));
7350 W ("Suppress_Value_Tracking_On_Call", Flag217 (Id));
7351 W ("Treat_As_Volatile", Flag41 (Id));
7352 W ("Universal_Aliasing", Flag216 (Id));
7353 W ("Used_As_Generic_Actual", Flag222 (Id));
7354 W ("Uses_Sec_Stack", Flag95 (Id));
7355 W ("Vax_Float", Flag151 (Id));
7356 W ("Warnings_Off", Flag96 (Id));
7357 W ("Warnings_Off_Used", Flag236 (Id));
7358 W ("Warnings_Off_Used_Unmodified", Flag237 (Id));
7359 W ("Warnings_Off_Used_Unreferenced", Flag238 (Id));
7360 W ("Was_Hidden", Flag196 (Id));
7361 end Write_Entity_Flags;
7363 -----------------------
7364 -- Write_Entity_Info --
7365 -----------------------
7367 procedure Write_Entity_Info (Id : Entity_Id; Prefix : String) is
7369 procedure Write_Attribute (Which : String; Nam : E);
7370 -- Write attribute value with given string name
7372 procedure Write_Kind (Id : Entity_Id);
7373 -- Write Ekind field of entity
7375 ---------------------
7376 -- Write_Attribute --
7377 ---------------------
7379 procedure Write_Attribute (Which : String; Nam : E) is
7383 Write_Int (Int (Nam));
7385 Write_Name (Chars (Nam));
7387 end Write_Attribute;
7393 procedure Write_Kind (Id : Entity_Id) is
7394 K : constant String := Entity_Kind'Image (Ekind (Id));
7398 Write_Str (" Kind ");
7400 if Is_Type (Id) and then Is_Tagged_Type (Id) then
7401 Write_Str ("TAGGED ");
7404 Write_Str (K (3 .. K'Length));
7407 if Is_Type (Id) and then Depends_On_Private (Id) then
7408 Write_Str ("Depends_On_Private ");
7412 -- Start of processing for Write_Entity_Info
7416 Write_Attribute ("Name ", Id);
7417 Write_Int (Int (Id));
7421 Write_Attribute (" Type ", Etype (Id));
7423 Write_Attribute (" Scope ", Scope (Id));
7428 when Discrete_Kind =>
7429 Write_Str ("Bounds: Id = ");
7431 if Present (Scalar_Range (Id)) then
7432 Write_Int (Int (Type_Low_Bound (Id)));
7433 Write_Str (" .. Id = ");
7434 Write_Int (Int (Type_High_Bound (Id)));
7436 Write_Str ("Empty");
7447 (" Component Type ", Component_Type (Id));
7450 Write_Str (" Indexes ");
7452 Index := First_Index (Id);
7453 while Present (Index) loop
7454 Write_Attribute (" ", Etype (Index));
7455 Index := Next_Index (Index);
7463 (" Directly Designated Type ",
7464 Directly_Designated_Type (Id));
7467 when Overloadable_Kind =>
7468 if Present (Homonym (Id)) then
7469 Write_Str (" Homonym ");
7470 Write_Name (Chars (Homonym (Id)));
7472 Write_Int (Int (Homonym (Id)));
7479 if Ekind (Scope (Id)) in Record_Kind then
7481 " Original_Record_Component ",
7482 Original_Record_Component (Id));
7483 Write_Int (Int (Original_Record_Component (Id)));
7487 when others => null;
7489 end Write_Entity_Info;
7491 -----------------------
7492 -- Write_Field6_Name --
7493 -----------------------
7495 procedure Write_Field6_Name (Id : Entity_Id) is
7496 pragma Warnings (Off, Id);
7498 Write_Str ("First_Rep_Item");
7499 end Write_Field6_Name;
7501 -----------------------
7502 -- Write_Field7_Name --
7503 -----------------------
7505 procedure Write_Field7_Name (Id : Entity_Id) is
7506 pragma Warnings (Off, Id);
7508 Write_Str ("Freeze_Node");
7509 end Write_Field7_Name;
7511 -----------------------
7512 -- Write_Field8_Name --
7513 -----------------------
7515 procedure Write_Field8_Name (Id : Entity_Id) is
7520 Write_Str ("Normalized_First_Bit");
7524 E_Subprogram_Body =>
7525 Write_Str ("Mechanism");
7528 Write_Str ("Associated_Node_For_Itype");
7531 Write_Str ("First_Exit_Statement");
7534 Write_Str ("Dependent_Instances");
7537 Write_Str ("Postcondition_Proc");
7539 when E_Return_Statement =>
7540 Write_Str ("Return_Applies_To");
7543 Write_Str ("Hiding_Loop_Variable");
7546 Write_Str ("Field8??");
7548 end Write_Field8_Name;
7550 -----------------------
7551 -- Write_Field9_Name --
7552 -----------------------
7554 procedure Write_Field9_Name (Id : Entity_Id) is
7558 Write_Str ("Class_Wide_Type");
7561 E_Generic_Function |
7563 E_Generic_Procedure |
7566 Write_Str ("Renaming_Map");
7569 Write_Str ("Current_Value");
7572 Write_Str ("Field9??");
7574 end Write_Field9_Name;
7576 ------------------------
7577 -- Write_Field10_Name --
7578 ------------------------
7580 procedure Write_Field10_Name (Id : Entity_Id) is
7583 when Class_Wide_Kind |
7589 Write_Str ("Direct_Primitive_Operations");
7591 when E_In_Parameter |
7593 Write_Str ("Discriminal_Link");
7599 Write_Str ("Handler_Records");
7603 Write_Str ("Normalized_Position_Max");
7606 Write_Str ("Field10??");
7608 end Write_Field10_Name;
7610 ------------------------
7611 -- Write_Field11_Name --
7612 ------------------------
7614 procedure Write_Field11_Name (Id : Entity_Id) is
7618 Write_Str ("Entry_Component");
7622 Write_Str ("Component_Bit_Offset");
7625 Write_Str ("Full_View");
7627 when E_Enumeration_Literal =>
7628 Write_Str ("Enumeration_Pos");
7631 Write_Str ("Block_Node");
7637 Write_Str ("Protected_Body_Subprogram");
7639 when E_Generic_Package =>
7640 Write_Str ("Generic_Homonym");
7643 Write_Str ("Full_View");
7646 Write_Str ("Field11??");
7648 end Write_Field11_Name;
7650 ------------------------
7651 -- Write_Field12_Name --
7652 ------------------------
7654 procedure Write_Field12_Name (Id : Entity_Id) is
7658 Write_Str ("Barrier_Function");
7660 when E_Enumeration_Literal =>
7661 Write_Str ("Enumeration_Rep");
7669 E_In_Out_Parameter |
7673 Write_Str ("Esize");
7677 Write_Str ("Next_Inlined_Subprogram");
7680 Write_Str ("Associated_Formal_Package");
7683 Write_Str ("Field12??");
7685 end Write_Field12_Name;
7687 ------------------------
7688 -- Write_Field13_Name --
7689 ------------------------
7691 procedure Write_Field13_Name (Id : Entity_Id) is
7695 Write_Str ("RM_Size");
7699 Write_Str ("Component_Clause");
7702 if not Comes_From_Source (Id)
7704 Chars (Id) = Name_Op_Ne
7706 Write_Str ("Corresponding_Equality");
7708 elsif Comes_From_Source (Id) then
7709 Write_Str ("Elaboration_Entity");
7712 Write_Str ("Field13??");
7717 Write_Str ("Extra_Accessibility");
7721 Generic_Unit_Kind =>
7722 Write_Str ("Elaboration_Entity");
7725 Write_Str ("Field13??");
7727 end Write_Field13_Name;
7729 -----------------------
7730 -- Write_Field14_Name --
7731 -----------------------
7733 procedure Write_Field14_Name (Id : Entity_Id) is
7742 Write_Str ("Alignment");
7746 Write_Str ("Normalized_Position");
7750 Write_Str ("First_Optional_Parameter");
7753 E_Generic_Package =>
7754 Write_Str ("Shadow_Entities");
7757 Write_Str ("Field14??");
7759 end Write_Field14_Name;
7761 ------------------------
7762 -- Write_Field15_Name --
7763 ------------------------
7765 procedure Write_Field15_Name (Id : Entity_Id) is
7770 Write_Str ("Storage_Size_Variable");
7773 Write_Str ("DT_Entry_Count");
7775 when Decimal_Fixed_Point_Kind =>
7776 Write_Str ("Scale_Value");
7778 when E_Discriminant =>
7779 Write_Str ("Discriminant_Number");
7782 Write_Str ("Extra_Formal");
7786 Write_Str ("DT_Position");
7789 Write_Str ("Entry_Parameters_Type");
7791 when Enumeration_Kind =>
7792 Write_Str ("Lit_Indexes");
7796 Write_Str ("Related_Instance");
7798 when E_Protected_Type =>
7799 Write_Str ("Entry_Bodies_Array");
7801 when E_String_Literal_Subtype =>
7802 Write_Str ("String_Literal_Low_Bound");
7805 Write_Str ("Field15??");
7807 end Write_Field15_Name;
7809 ------------------------
7810 -- Write_Field16_Name --
7811 ------------------------
7813 procedure Write_Field16_Name (Id : Entity_Id) is
7817 Write_Str ("Entry_Formal");
7821 Write_Str ("DTC_Entity");
7826 Write_Str ("First_Private_Entity");
7828 when E_Record_Type |
7829 E_Record_Type_With_Private =>
7830 Write_Str ("Access_Disp_Table");
7832 when E_String_Literal_Subtype =>
7833 Write_Str ("String_Literal_Length");
7835 when Enumeration_Kind =>
7836 Write_Str ("Lit_Strings");
7840 Write_Str ("Unset_Reference");
7842 when E_Record_Subtype |
7843 E_Class_Wide_Subtype =>
7844 Write_Str ("Cloned_Subtype");
7847 Write_Str ("Field16??");
7849 end Write_Field16_Name;
7851 ------------------------
7852 -- Write_Field17_Name --
7853 ------------------------
7855 procedure Write_Field17_Name (Id : Entity_Id) is
7859 Write_Str ("Digits_Value");
7862 Write_Str ("Prival");
7864 when E_Discriminant =>
7865 Write_Str ("Discriminal");
7874 E_Generic_Function |
7876 E_Generic_Procedure |
7884 E_Return_Statement |
7886 E_Subprogram_Type =>
7887 Write_Str ("First_Entity");
7890 Write_Str ("First_Index");
7892 when Enumeration_Kind =>
7893 Write_Str ("First_Literal");
7896 Write_Str ("Master_Id");
7898 when Modular_Integer_Kind =>
7899 Write_Str ("Modulus");
7903 E_Generic_In_Out_Parameter |
7905 Write_Str ("Actual_Subtype");
7907 when E_Incomplete_Type =>
7908 Write_Str ("Non_Limited_View");
7910 when E_Incomplete_Subtype =>
7911 if From_With_Type (Id) then
7912 Write_Str ("Non_Limited_View");
7916 Write_Str ("Field17??");
7918 end Write_Field17_Name;
7920 ------------------------
7921 -- Write_Field18_Name --
7922 ------------------------
7924 procedure Write_Field18_Name (Id : Entity_Id) is
7927 when E_Enumeration_Literal |
7931 Write_Str ("Alias");
7933 when E_Record_Type =>
7934 Write_Str ("Corresponding_Concurrent_Type");
7936 when E_Subprogram_Body =>
7937 Write_Str ("Corresponding_Protected_Entry");
7939 when E_Entry_Index_Parameter =>
7940 Write_Str ("Entry_Index_Constant");
7942 when E_Class_Wide_Subtype |
7943 E_Access_Protected_Subprogram_Type |
7944 E_Anonymous_Access_Protected_Subprogram_Type |
7945 E_Access_Subprogram_Type |
7947 Write_Str ("Equivalent_Type");
7949 when Fixed_Point_Kind =>
7950 Write_Str ("Delta_Value");
7953 Write_Str ("Renamed_Object");
7957 E_Generic_Function |
7958 E_Generic_Procedure |
7959 E_Generic_Package =>
7960 Write_Str ("Renamed_Entity");
7962 when Incomplete_Or_Private_Kind |
7964 Write_Str ("Private_Dependents");
7966 when Concurrent_Kind =>
7967 Write_Str ("Corresponding_Record_Type");
7972 Write_Str ("Enclosing_Scope");
7975 Write_Str ("Field18??");
7977 end Write_Field18_Name;
7979 -----------------------
7980 -- Write_Field19_Name --
7981 -----------------------
7983 procedure Write_Field19_Name (Id : Entity_Id) is
7988 Write_Str ("Related_Array_Object");
7994 E_Return_Statement |
7996 Write_Str ("Finalization_Chain_Entity");
7998 when E_Constant | E_Variable =>
7999 Write_Str ("Size_Check_Code");
8001 when E_Discriminant =>
8002 Write_Str ("Corresponding_Discriminant");
8005 E_Generic_Package =>
8006 Write_Str ("Body_Entity");
8008 when E_Package_Body |
8010 Write_Str ("Spec_Entity");
8012 when Private_Kind =>
8013 Write_Str ("Underlying_Full_View");
8015 when E_Record_Type =>
8016 Write_Str ("Parent_Subtype");
8019 Write_Str ("Field19??");
8021 end Write_Field19_Name;
8023 -----------------------
8024 -- Write_Field20_Name --
8025 -----------------------
8027 procedure Write_Field20_Name (Id : Entity_Id) is
8031 Write_Str ("Component_Type");
8033 when E_In_Parameter |
8034 E_Generic_In_Parameter =>
8035 Write_Str ("Default_Value");
8038 Write_Str ("Directly_Designated_Type");
8041 Write_Str ("Discriminant_Checking_Func");
8045 Write_Str ("Prival_Link");
8047 when E_Discriminant =>
8048 Write_Str ("Discriminant_Default_Value");
8057 E_Generic_Function |
8059 E_Generic_Procedure |
8067 E_Return_Statement |
8069 E_Subprogram_Type =>
8070 Write_Str ("Last_Entity");
8073 Write_Str ("Scalar_Range");
8076 Write_Str ("Register_Exception_Call");
8079 Write_Str ("Field20??");
8081 end Write_Field20_Name;
8083 -----------------------
8084 -- Write_Field21_Name --
8085 -----------------------
8087 procedure Write_Field21_Name (Id : Entity_Id) is
8093 E_Generic_Function |
8095 E_Generic_Procedure |
8097 Write_Str ("Interface_Name");
8099 when Concurrent_Kind |
8100 Incomplete_Or_Private_Kind |
8104 Write_Str ("Discriminant_Constraint");
8107 Write_Str ("Accept_Address");
8109 when Fixed_Point_Kind =>
8110 Write_Str ("Small_Value");
8112 when E_In_Parameter =>
8113 Write_Str ("Default_Expr_Function");
8116 Modular_Integer_Kind =>
8117 Write_Str ("Original_Array_Type");
8120 Write_Str ("Field21??");
8122 end Write_Field21_Name;
8124 -----------------------
8125 -- Write_Field22_Name --
8126 -----------------------
8128 procedure Write_Field22_Name (Id : Entity_Id) is
8132 Write_Str ("Associated_Storage_Pool");
8135 Write_Str ("Component_Size");
8139 Write_Str ("Original_Record_Component");
8141 when E_Enumeration_Literal =>
8142 Write_Str ("Enumeration_Rep_Expr");
8145 Write_Str ("Exception_Code");
8148 Write_Str ("Protected_Formal");
8150 when E_Record_Type =>
8151 Write_Str ("Corresponding_Remote_Type");
8161 E_Generic_Function |
8162 E_Generic_Procedure |
8165 E_Return_Statement |
8168 Write_Str ("Scope_Depth_Value");
8170 when E_Record_Type_With_Private |
8171 E_Record_Subtype_With_Private |
8174 E_Limited_Private_Type |
8175 E_Limited_Private_Subtype =>
8176 Write_Str ("Private_View");
8179 Write_Str ("Shared_Var_Procs_Instance");
8182 Write_Str ("Field22??");
8184 end Write_Field22_Name;
8186 ------------------------
8187 -- Write_Field23_Name --
8188 ------------------------
8190 procedure Write_Field23_Name (Id : Entity_Id) is
8194 Write_Str ("Associated_Final_Chain");
8197 Write_Str ("Packed_Array_Type");
8200 Write_Str ("Entry_Cancel_Parameter");
8202 when E_Discriminant =>
8203 Write_Str ("CR_Discriminant");
8205 when E_Enumeration_Type =>
8206 Write_Str ("Enum_Pos_To_Rep");
8210 Write_Str ("Extra_Constrained");
8212 when E_Generic_Function |
8214 E_Generic_Procedure =>
8215 Write_Str ("Inner_Instances");
8217 when Concurrent_Kind |
8218 Incomplete_Or_Private_Kind |
8222 Write_Str ("Stored_Constraint");
8226 if Present (Scope (Id))
8227 and then Is_Protected_Type (Scope (Id))
8229 Write_Str ("Protection_Object");
8231 Write_Str ("Generic_Renamings");
8235 if Is_Generic_Instance (Id) then
8236 Write_Str ("Generic_Renamings");
8238 Write_Str ("Limited_View");
8242 Write_Str ("Protection_Object");
8245 Write_Str ("Field23??");
8247 end Write_Field23_Name;
8249 ------------------------
8250 -- Write_Field24_Name --
8251 ------------------------
8253 procedure Write_Field24_Name (Id : Entity_Id) is
8256 when Subprogram_Kind =>
8257 Write_Str ("Spec_PPC_List");
8259 when E_Variable | E_Constant | Type_Kind =>
8260 Write_Str ("Related_Expression");
8263 Write_Str ("Field24???");
8265 end Write_Field24_Name;
8267 ------------------------
8268 -- Write_Field25_Name --
8269 ------------------------
8271 procedure Write_Field25_Name (Id : Entity_Id) is
8275 Write_Str ("DT_Offset_To_Top_Func");
8279 Write_Str ("Interface_Alias");
8281 when E_Record_Type |
8283 E_Record_Type_With_Private |
8284 E_Record_Subtype_With_Private =>
8285 Write_Str ("Interfaces");
8288 Write_Str ("Task_Body_Procedure");
8291 Write_Str ("Debug_Renaming_Link");
8295 Write_Str ("PPC_Wrapper");
8298 Write_Str ("Field25??");
8300 end Write_Field25_Name;
8302 ------------------------
8303 -- Write_Field26_Name --
8304 ------------------------
8306 procedure Write_Field26_Name (Id : Entity_Id) is
8309 when E_Generic_Package |
8311 Write_Str ("Package_Instantiation");
8315 if Is_Dispatching_Operation (Id) then
8316 Write_Str ("Overridden_Operation");
8318 Write_Str ("Static_Initialization");
8321 when E_Record_Type |
8322 E_Record_Type_With_Private =>
8323 Write_Str ("Dispatch_Table_Wrappers");
8325 when E_In_Out_Parameter |
8328 Write_Str ("Last_Assignment");
8331 Write_Str ("Relative_Deadline_Variable");
8334 Write_Str ("Field26??");
8336 end Write_Field26_Name;
8338 ------------------------
8339 -- Write_Field27_Name --
8340 ------------------------
8342 procedure Write_Field27_Name (Id : Entity_Id) is
8348 Write_Str ("Related_Type");
8351 Write_Str ("Wrapped_Entity");
8353 when E_Package | Type_Kind =>
8354 Write_Str ("Current_Use_Clause");
8357 Write_Str ("Field27??");
8359 end Write_Field27_Name;
8361 ------------------------
8362 -- Write_Field28_Name --
8363 ------------------------
8365 procedure Write_Field28_Name (Id : Entity_Id) is
8368 when E_Procedure | E_Function | E_Entry =>
8369 Write_Str ("Extra_Formals");
8371 when E_Record_Type =>
8372 Write_Str ("Underlying_Record_View");
8375 Write_Str ("Field28??");
8377 end Write_Field28_Name;
8379 procedure Write_Field29_Name (Id : Entity_Id) is
8383 Write_Str ("Subprograms_For_Type");
8386 Write_Str ("Field29??");
8388 end Write_Field29_Name;
8390 -------------------------
8391 -- Iterator Procedures --
8392 -------------------------
8394 procedure Proc_Next_Component (N : in out Node_Id) is
8396 N := Next_Component (N);
8397 end Proc_Next_Component;
8399 procedure Proc_Next_Component_Or_Discriminant (N : in out Node_Id) is
8401 N := Next_Entity (N);
8402 while Present (N) loop
8403 exit when Ekind_In (N, E_Component, E_Discriminant);
8404 N := Next_Entity (N);
8406 end Proc_Next_Component_Or_Discriminant;
8408 procedure Proc_Next_Discriminant (N : in out Node_Id) is
8410 N := Next_Discriminant (N);
8411 end Proc_Next_Discriminant;
8413 procedure Proc_Next_Formal (N : in out Node_Id) is
8415 N := Next_Formal (N);
8416 end Proc_Next_Formal;
8418 procedure Proc_Next_Formal_With_Extras (N : in out Node_Id) is
8420 N := Next_Formal_With_Extras (N);
8421 end Proc_Next_Formal_With_Extras;
8423 procedure Proc_Next_Index (N : in out Node_Id) is
8425 N := Next_Index (N);
8426 end Proc_Next_Index;
8428 procedure Proc_Next_Inlined_Subprogram (N : in out Node_Id) is
8430 N := Next_Inlined_Subprogram (N);
8431 end Proc_Next_Inlined_Subprogram;
8433 procedure Proc_Next_Literal (N : in out Node_Id) is
8435 N := Next_Literal (N);
8436 end Proc_Next_Literal;
8438 procedure Proc_Next_Stored_Discriminant (N : in out Node_Id) is
8440 N := Next_Stored_Discriminant (N);
8441 end Proc_Next_Stored_Discriminant;