1 ------------------------------------------------------------------------------
3 -- GNAT COMPILER COMPONENTS --
9 -- Copyright (C) 1992-2009, 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
83 -- Class_Wide_Type Node9
84 -- Current_Value Node9
87 -- Discriminal_Link Node10
88 -- Handler_Records List10
89 -- Normalized_Position_Max Uint10
90 -- Referenced_Object Node10
92 -- Component_Bit_Offset Uint11
94 -- Entry_Component Node11
95 -- Enumeration_Pos Uint11
96 -- Generic_Homonym Node11
97 -- Protected_Body_Subprogram Node11
100 -- Barrier_Function Node12
101 -- Enumeration_Rep Uint12
103 -- Next_Inlined_Subprogram Node12
105 -- Corresponding_Equality Node13
106 -- Component_Clause Node13
107 -- Elaboration_Entity Node13
108 -- Extra_Accessibility Node13
112 -- First_Optional_Parameter Node14
113 -- Normalized_Position Uint14
114 -- Shadow_Entities List14
116 -- Discriminant_Number Uint15
117 -- DT_Position Uint15
118 -- DT_Entry_Count Uint15
119 -- Entry_Bodies_Array Node15
120 -- Entry_Parameters_Type Node15
121 -- Extra_Formal Node15
122 -- Lit_Indexes Node15
123 -- Primitive_Operations Elist15
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_Record_Type Node18
152 -- Delta_Value Ureal18
153 -- Enclosing_Scope Node18
154 -- Equivalent_Type Node18
155 -- Private_Dependents Elist18
156 -- Renamed_Entity Node18
157 -- Renamed_Object Node18
159 -- Body_Entity Node19
160 -- Corresponding_Discriminant Node19
161 -- Finalization_Chain_Entity Node19
162 -- Parent_Subtype Node19
163 -- Related_Array_Object Node19
164 -- Size_Check_Code Node19
165 -- Spec_Entity Node19
166 -- Underlying_Full_View Node19
168 -- Component_Type Node20
169 -- Default_Value Node20
170 -- Directly_Designated_Type Node20
171 -- Discriminant_Checking_Func Node20
172 -- Discriminant_Default_Value Node20
173 -- Last_Entity Node20
174 -- Prival_Link Node20
175 -- Register_Exception_Call Node20
176 -- Scalar_Range Node20
178 -- Accept_Address Elist21
179 -- Default_Expr_Function Node21
180 -- Discriminant_Constraint Elist21
181 -- Interface_Name Node21
182 -- Original_Array_Type Node21
183 -- Small_Value Ureal21
185 -- Associated_Storage_Pool Node22
186 -- Component_Size Uint22
187 -- Corresponding_Remote_Type Node22
188 -- Enumeration_Rep_Expr Node22
189 -- Exception_Code Uint22
190 -- Original_Record_Component Node22
191 -- Private_View Node22
192 -- Protected_Formal Node22
193 -- Scope_Depth_Value Uint22
194 -- Shared_Var_Procs_Instance Node22
196 -- Associated_Final_Chain Node23
197 -- CR_Discriminant Node23
198 -- Entry_Cancel_Parameter Node23
199 -- Enum_Pos_To_Rep Node23
200 -- Extra_Constrained Node23
201 -- Generic_Renamings Elist23
202 -- Inner_Instances Elist23
203 -- Limited_View Node23
204 -- Packed_Array_Type Node23
205 -- Protection_Object Node23
206 -- Stored_Constraint Elist23
208 -- Related_Expression Node24
209 -- Spec_PPC_List Node24
210 -- Underlying_Record_View Node24
212 -- Interface_Alias Node25
213 -- Interfaces Elist25
214 -- Debug_Renaming_Link Node25
215 -- DT_Offset_To_Top_Func Node25
216 -- Task_Body_Procedure Node25
218 -- Dispatch_Table_Wrappers Elist26
219 -- Last_Assignment Node26
220 -- Overridden_Operation Node26
221 -- Package_Instantiation Node26
222 -- Related_Type Node26
223 -- Relative_Deadline_Variable Node26
224 -- Static_Initialization Node26
226 -- Current_Use_Clause Node27
227 -- Wrapped_Entity Node27
229 -- Extra_Formals Node28
231 ---------------------------------------------
232 -- Usage of Flags in Defining Entity Nodes --
233 ---------------------------------------------
235 -- All flags are unique, there is no overlaying, so each flag is physically
236 -- present in every entity. However, for many of the flags, it only makes
237 -- sense for them to be set true for certain subsets of entity kinds. See
238 -- the spec of Einfo for further details.
240 -- Note: Flag1-Flag3 are absent from this list, since these flag positions
241 -- are used for the flags Analyzed, Comes_From_Source, and Error_Posted,
242 -- which are common to all nodes, including entity nodes.
245 -- Has_Discriminants Flag5
246 -- Is_Dispatching_Operation Flag6
247 -- Is_Immediately_Visible Flag7
249 -- Is_Potentially_Use_Visible Flag9
253 -- Is_Constrained Flag12
254 -- Is_Generic_Type Flag13
255 -- Depends_On_Private Flag14
257 -- Is_Volatile Flag16
258 -- Is_Internal Flag17
259 -- Has_Delayed_Freeze Flag18
260 -- Is_Abstract_Subprogram Flag19
261 -- Is_Concurrent_Record_Type Flag20
263 -- Has_Master_Entity Flag21
264 -- Needs_No_Actuals Flag22
265 -- Has_Storage_Size_Clause Flag23
266 -- Is_Imported Flag24
267 -- Is_Limited_Record Flag25
268 -- Has_Completion Flag26
269 -- Has_Pragma_Controlled Flag27
270 -- Is_Statically_Allocated Flag28
271 -- Has_Size_Clause Flag29
274 -- Checks_May_Be_Suppressed Flag31
275 -- Kill_Elaboration_Checks Flag32
276 -- Kill_Range_Checks Flag33
277 -- Kill_Tag_Checks Flag34
278 -- Is_Class_Wide_Equivalent_Type Flag35
279 -- Referenced_As_LHS Flag36
280 -- Is_Known_Non_Null Flag37
281 -- Can_Never_Be_Null Flag38
282 -- Is_Overriding_Operation Flag39
283 -- Body_Needed_For_SAL Flag40
285 -- Treat_As_Volatile Flag41
286 -- Is_Controlled Flag42
287 -- Has_Controlled_Component Flag43
289 -- In_Private_Part Flag45
290 -- Has_Alignment_Clause Flag46
292 -- In_Package_Body Flag48
294 -- Delay_Subprogram_Descriptors Flag50
297 -- Is_Entry_Formal Flag52
298 -- Is_Private_Descendant Flag53
299 -- Return_Present Flag54
300 -- Is_Tagged_Type Flag55
301 -- Has_Homonym Flag56
303 -- Non_Binary_Modulus Flag58
304 -- Is_Preelaborated Flag59
305 -- Is_Shared_Passive Flag60
307 -- Is_Remote_Types Flag61
308 -- Is_Remote_Call_Interface Flag62
309 -- Is_Character_Type Flag63
310 -- Is_Intrinsic_Subprogram Flag64
311 -- Has_Record_Rep_Clause Flag65
312 -- Has_Enumeration_Rep_Clause Flag66
313 -- Has_Small_Clause Flag67
314 -- Has_Component_Size_Clause Flag68
315 -- Is_Access_Constant Flag69
316 -- Is_First_Subtype Flag70
318 -- Has_Completion_In_Body Flag71
319 -- Has_Unknown_Discriminants Flag72
320 -- Is_Child_Unit Flag73
321 -- Is_CPP_Class Flag74
322 -- Has_Non_Standard_Rep Flag75
323 -- Is_Constructor Flag76
324 -- Static_Elaboration_Desired Flag77
326 -- Has_All_Calls_Remote Flag79
327 -- Is_Constr_Subt_For_U_Nominal Flag80
329 -- Is_Asynchronous Flag81
330 -- Has_Gigi_Rep_Item Flag82
331 -- Has_Machine_Radix_Clause Flag83
332 -- Machine_Radix_10 Flag84
334 -- Has_Atomic_Components Flag86
335 -- Has_Volatile_Components Flag87
336 -- Discard_Names Flag88
337 -- Is_Interrupt_Handler Flag89
338 -- Returns_By_Ref Flag90
341 -- Size_Known_At_Compile_Time Flag92
342 -- Has_Subprogram_Descriptor Flag93
343 -- Is_Generic_Actual_Type Flag94
344 -- Uses_Sec_Stack Flag95
345 -- Warnings_Off Flag96
346 -- Is_Controlling_Formal Flag97
347 -- Has_Controlling_Result Flag98
348 -- Is_Exported Flag99
349 -- Has_Specified_Layout Flag100
351 -- Has_Nested_Block_With_Handler Flag101
353 -- Is_Completely_Hidden Flag103
354 -- Address_Taken Flag104
355 -- Suppress_Init_Proc Flag105
356 -- Is_Limited_Composite Flag106
357 -- Is_Private_Composite Flag107
358 -- Default_Expressions_Processed Flag108
359 -- Is_Non_Static_Subtype Flag109
360 -- Has_External_Tag_Rep_Clause Flag110
362 -- Is_Formal_Subprogram Flag111
363 -- Is_Renaming_Of_Object Flag112
365 -- Delay_Cleanups Flag114
366 -- Never_Set_In_Source Flag115
367 -- Is_Visible_Child_Unit Flag116
368 -- Is_Unchecked_Union Flag117
369 -- Is_For_Access_Subtype Flag118
370 -- Has_Convention_Pragma Flag119
371 -- Has_Primitive_Operations Flag120
373 -- Has_Pragma_Pack Flag121
374 -- Is_Bit_Packed_Array Flag122
375 -- Has_Unchecked_Union Flag123
376 -- Is_Eliminated Flag124
377 -- C_Pass_By_Copy Flag125
378 -- Is_Instantiated Flag126
379 -- Is_Valued_Procedure Flag127
380 -- (used for Component_Alignment) Flag128
381 -- (used for Component_Alignment) Flag129
382 -- Is_Generic_Instance Flag130
384 -- No_Pool_Assigned Flag131
385 -- Is_AST_Entry Flag132
386 -- Is_VMS_Exception Flag133
387 -- Is_Optional_Parameter Flag134
388 -- Has_Aliased_Components Flag135
389 -- No_Strict_Aliasing Flag136
390 -- Is_Machine_Code_Subprogram Flag137
391 -- Is_Packed_Array_Type Flag138
392 -- Has_Biased_Representation Flag139
393 -- Has_Complex_Representation Flag140
395 -- Is_Constr_Subt_For_UN_Aliased Flag141
396 -- Has_Missing_Return Flag142
397 -- Has_Recursive_Call Flag143
398 -- Is_Unsigned_Type Flag144
399 -- Strict_Alignment Flag145
400 -- Is_Abstract_Type Flag146
401 -- Needs_Debug_Info Flag147
402 -- Suppress_Elaboration_Warnings Flag148
403 -- Is_Compilation_Unit Flag149
404 -- Has_Pragma_Elaborate_Body Flag150
407 -- Entry_Accepted Flag152
408 -- Is_Obsolescent Flag153
409 -- Has_Per_Object_Constraint Flag154
410 -- Has_Private_Declaration Flag155
411 -- Referenced Flag156
412 -- Has_Pragma_Inline Flag157
413 -- Finalize_Storage_Only Flag158
414 -- From_With_Type Flag159
415 -- Is_Package_Body_Entity Flag160
417 -- Has_Qualified_Name Flag161
418 -- Nonzero_Is_True Flag162
419 -- Is_True_Constant Flag163
420 -- Reverse_Bit_Order Flag164
421 -- Suppress_Style_Checks Flag165
422 -- Debug_Info_Off Flag166
423 -- Sec_Stack_Needed_For_Return Flag167
424 -- Materialize_Entity Flag168
425 -- Has_Pragma_Thread_Local_Storage Flag169
426 -- Is_Known_Valid Flag170
428 -- Is_Hidden_Open_Scope Flag171
429 -- Has_Object_Size_Clause Flag172
430 -- Has_Fully_Qualified_Name Flag173
431 -- Elaboration_Entity_Required Flag174
432 -- Has_Forward_Instantiation Flag175
433 -- Is_Discrim_SO_Function Flag176
434 -- Size_Depends_On_Discriminant Flag177
435 -- Is_Null_Init_Proc Flag178
436 -- Has_Pragma_Pure_Function Flag179
437 -- Has_Pragma_Unreferenced Flag180
439 -- Has_Contiguous_Rep Flag181
440 -- Has_Xref_Entry Flag182
441 -- Must_Be_On_Byte_Boundary Flag183
442 -- Has_Stream_Size_Clause Flag184
443 -- Is_Ada_2005_Only Flag185
444 -- Is_Interface Flag186
445 -- Has_Constrained_Partial_View Flag187
446 -- Has_Persistent_BSS Flag188
447 -- Is_Pure_Unit_Access_Type Flag189
448 -- Has_Specified_Stream_Input Flag190
450 -- Has_Specified_Stream_Output Flag191
451 -- Has_Specified_Stream_Read Flag192
452 -- Has_Specified_Stream_Write Flag193
453 -- Is_Local_Anonymous_Access Flag194
454 -- Is_Primitive_Wrapper Flag195
455 -- Was_Hidden Flag196
456 -- Is_Limited_Interface Flag197
457 -- Is_Protected_Interface Flag198
458 -- Is_Synchronized_Interface Flag199
459 -- Is_Task_Interface Flag200
461 -- Has_Anon_Block_Suffix Flag201
462 -- Itype_Printed Flag202
463 -- Has_Pragma_Pure Flag203
464 -- Is_Known_Null Flag204
465 -- Low_Bound_Tested Flag205
466 -- Is_Visible_Formal Flag206
467 -- Known_To_Have_Preelab_Init Flag207
468 -- Must_Have_Preelab_Init Flag208
469 -- Is_Return_Object Flag209
470 -- Elaborate_Body_Desirable Flag210
472 -- Has_Static_Discriminants Flag211
473 -- Has_Pragma_Unreferenced_Objects Flag212
474 -- Requires_Overriding Flag213
476 -- Has_Up_Level_Access Flag215
477 -- Universal_Aliasing Flag216
478 -- Suppress_Value_Tracking_On_Call Flag217
479 -- Is_Primitive Flag218
480 -- Has_Initial_Value Flag219
481 -- Has_Dispatch_Table Flag220
483 -- Has_Pragma_Preelab_Init Flag221
484 -- Used_As_Generic_Actual Flag222
485 -- Is_Descendent_Of_Address Flag223
488 -- Is_Only_Out_Parameter Flag226
489 -- Referenced_As_Out_Parameter Flag227
490 -- Has_Thunks Flag228
491 -- Can_Use_Internal_Rep Flag229
492 -- Has_Pragma_Inline_Always Flag230
494 -- Renamed_In_Spec Flag231
495 -- Implemented_By_Entry Flag232
496 -- Has_Pragma_Unmodified Flag233
497 -- Is_Dispatch_Table_Entity Flag234
498 -- Is_Trivial_Subprogram Flag235
499 -- Warnings_Off_Used Flag236
500 -- Warnings_Off_Used_Unmodified Flag237
501 -- Warnings_Off_Used_Unreferenced Flag238
502 -- OK_To_Reorder_Components Flag239
503 -- Has_Postconditions Flag240
505 -- Optimize_Alignment_Space Flag241
506 -- Optimize_Alignment_Time Flag242
507 -- Overlays_Constant Flag243
508 -- Is_RACW_Stub_Type Flag244
509 -- Is_Private_Primitive Flag245
510 -- Is_Underlying_Record_View Flag246
511 -- OK_To_Rename Flag247
513 -----------------------
514 -- Local subprograms --
515 -----------------------
517 function Rep_Clause (Id : E; Rep_Name : Name_Id) return N;
518 -- Returns the attribute definition clause for Id whose name is Rep_Name.
519 -- Returns Empty if no matching attribute definition clause found for Id.
525 function Rep_Clause (Id : E; Rep_Name : Name_Id) return N is
529 Ritem := First_Rep_Item (Id);
530 while Present (Ritem) loop
531 if Nkind (Ritem) = N_Attribute_Definition_Clause
532 and then Chars (Ritem) = Rep_Name
536 Ritem := Next_Rep_Item (Ritem);
543 --------------------------------
544 -- Attribute Access Functions --
545 --------------------------------
547 function Accept_Address (Id : E) return L is
552 function Access_Disp_Table (Id : E) return L is
554 pragma Assert (Is_Tagged_Type (Id));
555 return Elist16 (Implementation_Base_Type (Id));
556 end Access_Disp_Table;
558 function Actual_Subtype (Id : E) return E is
561 (Ekind (Id) = E_Constant
562 or else Ekind (Id) = E_Variable
563 or else Ekind (Id) = E_Generic_In_Out_Parameter
564 or else Is_Formal (Id));
568 function Address_Taken (Id : E) return B is
573 function Alias (Id : E) return E is
576 (Is_Overloadable (Id) or else Ekind (Id) = E_Subprogram_Type);
580 function Alignment (Id : E) return U is
582 pragma Assert (Is_Type (Id)
583 or else Is_Formal (Id)
584 or else Ekind (Id) = E_Loop_Parameter
585 or else Ekind (Id) = E_Constant
586 or else Ekind (Id) = E_Exception
587 or else Ekind (Id) = E_Variable);
591 function Associated_Final_Chain (Id : E) return E is
593 pragma Assert (Is_Access_Type (Id));
595 end Associated_Final_Chain;
597 function Associated_Formal_Package (Id : E) return E is
599 pragma Assert (Ekind (Id) = E_Package);
601 end Associated_Formal_Package;
603 function Associated_Node_For_Itype (Id : E) return N is
606 end Associated_Node_For_Itype;
608 function Associated_Storage_Pool (Id : E) return E is
610 pragma Assert (Is_Access_Type (Id));
611 return Node22 (Root_Type (Id));
612 end Associated_Storage_Pool;
614 function Barrier_Function (Id : E) return N is
616 pragma Assert (Is_Entry (Id));
618 end Barrier_Function;
620 function Block_Node (Id : E) return N is
622 pragma Assert (Ekind (Id) = E_Block);
626 function Body_Entity (Id : E) return E is
629 (Ekind (Id) = E_Package or else Ekind (Id) = E_Generic_Package);
633 function Body_Needed_For_SAL (Id : E) return B is
636 (Ekind (Id) = E_Package
637 or else Is_Subprogram (Id)
638 or else Is_Generic_Unit (Id));
640 end Body_Needed_For_SAL;
642 function C_Pass_By_Copy (Id : E) return B is
644 pragma Assert (Is_Record_Type (Id));
645 return Flag125 (Implementation_Base_Type (Id));
648 function Can_Never_Be_Null (Id : E) return B is
651 end Can_Never_Be_Null;
653 function Checks_May_Be_Suppressed (Id : E) return B is
656 end Checks_May_Be_Suppressed;
658 function Class_Wide_Type (Id : E) return E is
660 pragma Assert (Is_Type (Id));
664 function Cloned_Subtype (Id : E) return E is
667 (Ekind (Id) = E_Record_Subtype
669 Ekind (Id) = E_Class_Wide_Subtype);
673 function Component_Bit_Offset (Id : E) return U is
676 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
678 end Component_Bit_Offset;
680 function Component_Clause (Id : E) return N is
683 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
685 end Component_Clause;
687 function Component_Size (Id : E) return U is
689 pragma Assert (Is_Array_Type (Id));
690 return Uint22 (Implementation_Base_Type (Id));
693 function Component_Type (Id : E) return E is
695 pragma Assert (Is_Array_Type (Id) or else Is_String_Type (Id));
696 return Node20 (Implementation_Base_Type (Id));
699 function Corresponding_Concurrent_Type (Id : E) return E is
701 pragma Assert (Ekind (Id) = E_Record_Type);
703 end Corresponding_Concurrent_Type;
705 function Corresponding_Discriminant (Id : E) return E is
707 pragma Assert (Ekind (Id) = E_Discriminant);
709 end Corresponding_Discriminant;
711 function Corresponding_Equality (Id : E) return E is
714 (Ekind (Id) = E_Function
715 and then not Comes_From_Source (Id)
716 and then Chars (Id) = Name_Op_Ne);
718 end Corresponding_Equality;
720 function Corresponding_Record_Type (Id : E) return E is
722 pragma Assert (Is_Concurrent_Type (Id));
724 end Corresponding_Record_Type;
726 function Corresponding_Remote_Type (Id : E) return E is
729 end Corresponding_Remote_Type;
731 function Current_Use_Clause (Id : E) return E is
733 pragma Assert (Ekind (Id) = E_Package or else Is_Type (Id));
735 end Current_Use_Clause;
737 function Current_Value (Id : E) return N is
739 pragma Assert (Ekind (Id) in Object_Kind);
743 function CR_Discriminant (Id : E) return E is
748 function Debug_Info_Off (Id : E) return B is
753 function Debug_Renaming_Link (Id : E) return E is
756 end Debug_Renaming_Link;
758 function Default_Expr_Function (Id : E) return E is
760 pragma Assert (Is_Formal (Id));
762 end Default_Expr_Function;
764 function Default_Expressions_Processed (Id : E) return B is
767 end Default_Expressions_Processed;
769 function Default_Value (Id : E) return N is
771 pragma Assert (Is_Formal (Id));
775 function Delay_Cleanups (Id : E) return B is
780 function Delay_Subprogram_Descriptors (Id : E) return B is
783 end Delay_Subprogram_Descriptors;
785 function Delta_Value (Id : E) return R is
787 pragma Assert (Is_Fixed_Point_Type (Id));
791 function Dependent_Instances (Id : E) return L is
793 pragma Assert (Is_Generic_Instance (Id));
795 end Dependent_Instances;
797 function Depends_On_Private (Id : E) return B is
799 pragma Assert (Nkind (Id) in N_Entity);
801 end Depends_On_Private;
803 function Digits_Value (Id : E) return U is
806 (Is_Floating_Point_Type (Id)
807 or else Is_Decimal_Fixed_Point_Type (Id));
811 function Directly_Designated_Type (Id : E) return E is
813 pragma Assert (Is_Access_Type (Id));
815 end Directly_Designated_Type;
817 function Discard_Names (Id : E) return B is
822 function Discriminal (Id : E) return E is
824 pragma Assert (Ekind (Id) = E_Discriminant);
828 function Discriminal_Link (Id : E) return N is
831 end Discriminal_Link;
833 function Discriminant_Checking_Func (Id : E) return E is
835 pragma Assert (Ekind (Id) = E_Component);
837 end Discriminant_Checking_Func;
839 function Discriminant_Constraint (Id : E) return L is
841 pragma Assert (Is_Composite_Type (Id) and then Has_Discriminants (Id));
843 end Discriminant_Constraint;
845 function Discriminant_Default_Value (Id : E) return N is
847 pragma Assert (Ekind (Id) = E_Discriminant);
849 end Discriminant_Default_Value;
851 function Discriminant_Number (Id : E) return U is
853 pragma Assert (Ekind (Id) = E_Discriminant);
855 end Discriminant_Number;
857 function Dispatch_Table_Wrappers (Id : E) return L is
859 pragma Assert (Is_Tagged_Type (Id));
860 return Elist26 (Implementation_Base_Type (Id));
861 end Dispatch_Table_Wrappers;
863 function DT_Entry_Count (Id : E) return U is
865 pragma Assert (Ekind (Id) = E_Component and then Is_Tag (Id));
869 function DT_Offset_To_Top_Func (Id : E) return E is
871 pragma Assert (Ekind (Id) = E_Component and then Is_Tag (Id));
873 end DT_Offset_To_Top_Func;
875 function DT_Position (Id : E) return U is
878 ((Ekind (Id) = E_Function
879 or else Ekind (Id) = E_Procedure)
880 and then Present (DTC_Entity (Id)));
884 function DTC_Entity (Id : E) return E is
887 (Ekind (Id) = E_Function or else Ekind (Id) = E_Procedure);
891 function Elaborate_Body_Desirable (Id : E) return B is
893 pragma Assert (Ekind (Id) = E_Package);
895 end Elaborate_Body_Desirable;
897 function Elaboration_Entity (Id : E) return E is
902 Ekind (Id) = E_Package
904 Is_Generic_Unit (Id));
906 end Elaboration_Entity;
908 function Elaboration_Entity_Required (Id : E) return B is
913 Ekind (Id) = E_Package
915 Is_Generic_Unit (Id));
917 end Elaboration_Entity_Required;
919 function Enclosing_Scope (Id : E) return E is
924 function Entry_Accepted (Id : E) return B is
926 pragma Assert (Is_Entry (Id));
930 function Entry_Bodies_Array (Id : E) return E is
933 end Entry_Bodies_Array;
935 function Entry_Cancel_Parameter (Id : E) return E is
938 end Entry_Cancel_Parameter;
940 function Entry_Component (Id : E) return E is
945 function Entry_Formal (Id : E) return E is
950 function Entry_Index_Constant (Id : E) return N is
952 pragma Assert (Ekind (Id) = E_Entry_Index_Parameter);
954 end Entry_Index_Constant;
956 function Entry_Parameters_Type (Id : E) return E is
959 end Entry_Parameters_Type;
961 function Enum_Pos_To_Rep (Id : E) return E is
963 pragma Assert (Ekind (Id) = E_Enumeration_Type);
967 function Enumeration_Pos (Id : E) return Uint is
969 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
973 function Enumeration_Rep (Id : E) return U is
975 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
979 function Enumeration_Rep_Expr (Id : E) return N is
981 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
983 end Enumeration_Rep_Expr;
985 function Equivalent_Type (Id : E) return E is
988 (Ekind (Id) = E_Class_Wide_Subtype or else
989 Ekind (Id) = E_Access_Protected_Subprogram_Type or else
990 Ekind (Id) = E_Anonymous_Access_Protected_Subprogram_Type or else
991 Ekind (Id) = E_Access_Subprogram_Type or else
992 Ekind (Id) = E_Exception_Type);
996 function Esize (Id : E) return Uint is
1001 function Exception_Code (Id : E) return Uint is
1003 pragma Assert (Ekind (Id) = E_Exception);
1007 function Extra_Accessibility (Id : E) return E is
1009 pragma Assert (Is_Formal (Id) or else Ekind (Id) = E_Variable);
1011 end Extra_Accessibility;
1013 function Extra_Constrained (Id : E) return E is
1015 pragma Assert (Is_Formal (Id) or else Ekind (Id) = E_Variable);
1017 end Extra_Constrained;
1019 function Extra_Formal (Id : E) return E is
1024 function Extra_Formals (Id : E) return E is
1027 (Is_Overloadable (Id)
1028 or else Ekind (Id) = E_Entry_Family
1029 or else Ekind (Id) = E_Subprogram_Body
1030 or else Ekind (Id) = E_Subprogram_Type);
1034 function Can_Use_Internal_Rep (Id : E) return B is
1036 pragma Assert (Is_Access_Subprogram_Type (Base_Type (Id)));
1037 return Flag229 (Base_Type (Id));
1038 end Can_Use_Internal_Rep;
1040 function Finalization_Chain_Entity (Id : E) return E is
1043 end Finalization_Chain_Entity;
1045 function Finalize_Storage_Only (Id : E) return B is
1047 pragma Assert (Is_Type (Id));
1048 return Flag158 (Base_Type (Id));
1049 end Finalize_Storage_Only;
1051 function First_Entity (Id : E) return E is
1056 function First_Index (Id : E) return N is
1058 pragma Assert (Is_Array_Type (Id) or else Is_String_Type (Id));
1062 function First_Literal (Id : E) return E is
1064 pragma Assert (Is_Enumeration_Type (Id));
1068 function First_Optional_Parameter (Id : E) return E is
1071 (Ekind (Id) = E_Function or else Ekind (Id) = E_Procedure);
1073 end First_Optional_Parameter;
1075 function First_Private_Entity (Id : E) return E is
1077 pragma Assert (Ekind (Id) = E_Package
1078 or else Ekind (Id) = E_Generic_Package
1079 or else Ekind (Id) in Concurrent_Kind);
1081 end First_Private_Entity;
1083 function First_Rep_Item (Id : E) return E is
1088 function Freeze_Node (Id : E) return N is
1093 function From_With_Type (Id : E) return B is
1095 return Flag159 (Id);
1098 function Full_View (Id : E) return E is
1100 pragma Assert (Is_Type (Id) or else Ekind (Id) = E_Constant);
1104 function Generic_Homonym (Id : E) return E is
1106 pragma Assert (Ekind (Id) = E_Generic_Package);
1108 end Generic_Homonym;
1110 function Generic_Renamings (Id : E) return L is
1112 return Elist23 (Id);
1113 end Generic_Renamings;
1115 function Handler_Records (Id : E) return S is
1118 end Handler_Records;
1120 function Has_Aliased_Components (Id : E) return B is
1122 return Flag135 (Implementation_Base_Type (Id));
1123 end Has_Aliased_Components;
1125 function Has_Alignment_Clause (Id : E) return B is
1128 end Has_Alignment_Clause;
1130 function Has_All_Calls_Remote (Id : E) return B is
1133 end Has_All_Calls_Remote;
1135 function Has_Anon_Block_Suffix (Id : E) return B is
1137 return Flag201 (Id);
1138 end Has_Anon_Block_Suffix;
1140 function Has_Atomic_Components (Id : E) return B is
1142 return Flag86 (Implementation_Base_Type (Id));
1143 end Has_Atomic_Components;
1145 function Has_Biased_Representation (Id : E) return B is
1147 return Flag139 (Id);
1148 end Has_Biased_Representation;
1150 function Has_Completion (Id : E) return B is
1155 function Has_Completion_In_Body (Id : E) return B is
1157 pragma Assert (Is_Type (Id));
1159 end Has_Completion_In_Body;
1161 function Has_Complex_Representation (Id : E) return B is
1163 pragma Assert (Is_Type (Id));
1164 return Flag140 (Implementation_Base_Type (Id));
1165 end Has_Complex_Representation;
1167 function Has_Component_Size_Clause (Id : E) return B is
1169 pragma Assert (Is_Array_Type (Id));
1170 return Flag68 (Implementation_Base_Type (Id));
1171 end Has_Component_Size_Clause;
1173 function Has_Constrained_Partial_View (Id : E) return B is
1175 pragma Assert (Is_Type (Id));
1176 return Flag187 (Id);
1177 end Has_Constrained_Partial_View;
1179 function Has_Controlled_Component (Id : E) return B is
1181 return Flag43 (Base_Type (Id));
1182 end Has_Controlled_Component;
1184 function Has_Contiguous_Rep (Id : E) return B is
1186 return Flag181 (Id);
1187 end Has_Contiguous_Rep;
1189 function Has_Controlling_Result (Id : E) return B is
1192 end Has_Controlling_Result;
1194 function Has_Convention_Pragma (Id : E) return B is
1196 return Flag119 (Id);
1197 end Has_Convention_Pragma;
1199 function Has_Delayed_Freeze (Id : E) return B is
1201 pragma Assert (Nkind (Id) in N_Entity);
1203 end Has_Delayed_Freeze;
1205 function Has_Discriminants (Id : E) return B is
1207 pragma Assert (Nkind (Id) in N_Entity);
1209 end Has_Discriminants;
1211 function Has_Dispatch_Table (Id : E) return B is
1213 pragma Assert (Is_Tagged_Type (Id));
1214 return Flag220 (Id);
1215 end Has_Dispatch_Table;
1217 function Has_Enumeration_Rep_Clause (Id : E) return B is
1219 pragma Assert (Is_Enumeration_Type (Id));
1221 end Has_Enumeration_Rep_Clause;
1223 function Has_Exit (Id : E) return B is
1228 function Has_External_Tag_Rep_Clause (Id : E) return B is
1230 pragma Assert (Is_Tagged_Type (Id));
1231 return Flag110 (Id);
1232 end Has_External_Tag_Rep_Clause;
1234 function Has_Forward_Instantiation (Id : E) return B is
1236 return Flag175 (Id);
1237 end Has_Forward_Instantiation;
1239 function Has_Fully_Qualified_Name (Id : E) return B is
1241 return Flag173 (Id);
1242 end Has_Fully_Qualified_Name;
1244 function Has_Gigi_Rep_Item (Id : E) return B is
1247 end Has_Gigi_Rep_Item;
1249 function Has_Homonym (Id : E) return B is
1254 function Has_Initial_Value (Id : E) return B is
1257 (Ekind (Id) = E_Variable or else Is_Formal (Id));
1258 return Flag219 (Id);
1259 end Has_Initial_Value;
1261 function Has_Machine_Radix_Clause (Id : E) return B is
1263 pragma Assert (Is_Decimal_Fixed_Point_Type (Id));
1265 end Has_Machine_Radix_Clause;
1267 function Has_Master_Entity (Id : E) return B is
1270 end Has_Master_Entity;
1272 function Has_Missing_Return (Id : E) return B is
1275 (Ekind (Id) = E_Function or else Ekind (Id) = E_Generic_Function);
1276 return Flag142 (Id);
1277 end Has_Missing_Return;
1279 function Has_Nested_Block_With_Handler (Id : E) return B is
1281 return Flag101 (Id);
1282 end Has_Nested_Block_With_Handler;
1284 function Has_Non_Standard_Rep (Id : E) return B is
1286 return Flag75 (Implementation_Base_Type (Id));
1287 end Has_Non_Standard_Rep;
1289 function Has_Object_Size_Clause (Id : E) return B is
1291 pragma Assert (Is_Type (Id));
1292 return Flag172 (Id);
1293 end Has_Object_Size_Clause;
1295 function Has_Per_Object_Constraint (Id : E) return B is
1297 return Flag154 (Id);
1298 end Has_Per_Object_Constraint;
1300 function Has_Persistent_BSS (Id : E) return B is
1302 return Flag188 (Id);
1303 end Has_Persistent_BSS;
1305 function Has_Postconditions (Id : E) return B is
1307 pragma Assert (Is_Subprogram (Id));
1308 return Flag240 (Id);
1309 end Has_Postconditions;
1311 function Has_Pragma_Controlled (Id : E) return B is
1313 pragma Assert (Is_Access_Type (Id));
1314 return Flag27 (Implementation_Base_Type (Id));
1315 end Has_Pragma_Controlled;
1317 function Has_Pragma_Elaborate_Body (Id : E) return B is
1319 return Flag150 (Id);
1320 end Has_Pragma_Elaborate_Body;
1322 function Has_Pragma_Inline (Id : E) return B is
1324 return Flag157 (Id);
1325 end Has_Pragma_Inline;
1327 function Has_Pragma_Inline_Always (Id : E) return B is
1329 return Flag230 (Id);
1330 end Has_Pragma_Inline_Always;
1332 function Has_Pragma_Pack (Id : E) return B is
1334 pragma Assert (Is_Record_Type (Id) or else Is_Array_Type (Id));
1335 return Flag121 (Implementation_Base_Type (Id));
1336 end Has_Pragma_Pack;
1338 function Has_Pragma_Preelab_Init (Id : E) return B is
1340 return Flag221 (Id);
1341 end Has_Pragma_Preelab_Init;
1343 function Has_Pragma_Pure (Id : E) return B is
1345 return Flag203 (Id);
1346 end Has_Pragma_Pure;
1348 function Has_Pragma_Pure_Function (Id : E) return B is
1350 return Flag179 (Id);
1351 end Has_Pragma_Pure_Function;
1353 function Has_Pragma_Thread_Local_Storage (Id : E) return B is
1355 return Flag169 (Id);
1356 end Has_Pragma_Thread_Local_Storage;
1358 function Has_Pragma_Unmodified (Id : E) return B is
1360 return Flag233 (Id);
1361 end Has_Pragma_Unmodified;
1363 function Has_Pragma_Unreferenced (Id : E) return B is
1365 return Flag180 (Id);
1366 end Has_Pragma_Unreferenced;
1368 function Has_Pragma_Unreferenced_Objects (Id : E) return B is
1370 pragma Assert (Is_Type (Id));
1371 return Flag212 (Id);
1372 end Has_Pragma_Unreferenced_Objects;
1374 function Has_Primitive_Operations (Id : E) return B is
1376 pragma Assert (Is_Type (Id));
1377 return Flag120 (Base_Type (Id));
1378 end Has_Primitive_Operations;
1380 function Has_Private_Declaration (Id : E) return B is
1382 return Flag155 (Id);
1383 end Has_Private_Declaration;
1385 function Has_Qualified_Name (Id : E) return B is
1387 return Flag161 (Id);
1388 end Has_Qualified_Name;
1390 function Has_RACW (Id : E) return B is
1392 pragma Assert (Ekind (Id) = E_Package);
1393 return Flag214 (Id);
1396 function Has_Record_Rep_Clause (Id : E) return B is
1398 pragma Assert (Is_Record_Type (Id));
1399 return Flag65 (Implementation_Base_Type (Id));
1400 end Has_Record_Rep_Clause;
1402 function Has_Recursive_Call (Id : E) return B is
1404 pragma Assert (Is_Subprogram (Id));
1405 return Flag143 (Id);
1406 end Has_Recursive_Call;
1408 function Has_Size_Clause (Id : E) return B is
1411 end Has_Size_Clause;
1413 function Has_Small_Clause (Id : E) return B is
1416 end Has_Small_Clause;
1418 function Has_Specified_Layout (Id : E) return B is
1420 pragma Assert (Is_Type (Id));
1421 return Flag100 (Implementation_Base_Type (Id));
1422 end Has_Specified_Layout;
1424 function Has_Specified_Stream_Input (Id : E) return B is
1426 pragma Assert (Is_Type (Id));
1427 return Flag190 (Id);
1428 end Has_Specified_Stream_Input;
1430 function Has_Specified_Stream_Output (Id : E) return B is
1432 pragma Assert (Is_Type (Id));
1433 return Flag191 (Id);
1434 end Has_Specified_Stream_Output;
1436 function Has_Specified_Stream_Read (Id : E) return B is
1438 pragma Assert (Is_Type (Id));
1439 return Flag192 (Id);
1440 end Has_Specified_Stream_Read;
1442 function Has_Specified_Stream_Write (Id : E) return B is
1444 pragma Assert (Is_Type (Id));
1445 return Flag193 (Id);
1446 end Has_Specified_Stream_Write;
1448 function Has_Static_Discriminants (Id : E) return B is
1450 pragma Assert (Is_Type (Id));
1451 return Flag211 (Id);
1452 end Has_Static_Discriminants;
1454 function Has_Storage_Size_Clause (Id : E) return B is
1456 pragma Assert (Is_Access_Type (Id) or else Is_Task_Type (Id));
1457 return Flag23 (Implementation_Base_Type (Id));
1458 end Has_Storage_Size_Clause;
1460 function Has_Stream_Size_Clause (Id : E) return B is
1462 return Flag184 (Id);
1463 end Has_Stream_Size_Clause;
1465 function Has_Subprogram_Descriptor (Id : E) return B is
1468 end Has_Subprogram_Descriptor;
1470 function Has_Task (Id : E) return B is
1472 return Flag30 (Base_Type (Id));
1475 function Has_Thunks (Id : E) return B is
1477 pragma Assert (Ekind (Id) = E_Constant);
1478 return Flag228 (Id);
1481 function Has_Unchecked_Union (Id : E) return B is
1483 return Flag123 (Base_Type (Id));
1484 end Has_Unchecked_Union;
1486 function Has_Unknown_Discriminants (Id : E) return B is
1488 pragma Assert (Is_Type (Id));
1490 end Has_Unknown_Discriminants;
1492 function Has_Up_Level_Access (Id : E) return B is
1495 (Ekind (Id) = E_Variable
1496 or else Ekind (Id) = E_Constant
1497 or else Ekind (Id) = E_Loop_Parameter);
1498 return Flag215 (Id);
1499 end Has_Up_Level_Access;
1501 function Has_Volatile_Components (Id : E) return B is
1503 return Flag87 (Implementation_Base_Type (Id));
1504 end Has_Volatile_Components;
1506 function Has_Xref_Entry (Id : E) return B is
1508 return Flag182 (Implementation_Base_Type (Id));
1511 function Hiding_Loop_Variable (Id : E) return E is
1513 pragma Assert (Ekind (Id) = E_Variable);
1515 end Hiding_Loop_Variable;
1517 function Homonym (Id : E) return E is
1522 function Implemented_By_Entry (Id : E) return B is
1525 (Ekind (Id) = E_Function
1526 or else Ekind (Id) = E_Procedure);
1527 return Flag232 (Id);
1528 end Implemented_By_Entry;
1530 function Interfaces (Id : E) return L is
1532 pragma Assert (Is_Record_Type (Id));
1533 return Elist25 (Id);
1536 function Interface_Alias (Id : E) return E is
1538 pragma Assert (Is_Subprogram (Id));
1540 end Interface_Alias;
1542 function In_Package_Body (Id : E) return B is
1545 end In_Package_Body;
1547 function In_Private_Part (Id : E) return B is
1550 end In_Private_Part;
1552 function In_Use (Id : E) return B is
1554 pragma Assert (Nkind (Id) in N_Entity);
1558 function Inner_Instances (Id : E) return L is
1560 return Elist23 (Id);
1561 end Inner_Instances;
1563 function Interface_Name (Id : E) return N is
1568 function Is_Abstract_Subprogram (Id : E) return B is
1570 pragma Assert (Is_Overloadable (Id));
1572 end Is_Abstract_Subprogram;
1574 function Is_Abstract_Type (Id : E) return B is
1576 pragma Assert (Is_Type (Id));
1577 return Flag146 (Id);
1578 end Is_Abstract_Type;
1580 function Is_Local_Anonymous_Access (Id : E) return B is
1582 pragma Assert (Is_Access_Type (Id));
1583 return Flag194 (Id);
1584 end Is_Local_Anonymous_Access;
1586 function Is_Access_Constant (Id : E) return B is
1588 pragma Assert (Is_Access_Type (Id));
1590 end Is_Access_Constant;
1592 function Is_Ada_2005_Only (Id : E) return B is
1594 return Flag185 (Id);
1595 end Is_Ada_2005_Only;
1597 function Is_Aliased (Id : E) return B is
1599 pragma Assert (Nkind (Id) in N_Entity);
1603 function Is_AST_Entry (Id : E) return B is
1605 pragma Assert (Is_Entry (Id));
1606 return Flag132 (Id);
1609 function Is_Asynchronous (Id : E) return B is
1612 (Ekind (Id) = E_Procedure or else Is_Type (Id));
1614 end Is_Asynchronous;
1616 function Is_Atomic (Id : E) return B is
1621 function Is_Bit_Packed_Array (Id : E) return B is
1623 return Flag122 (Implementation_Base_Type (Id));
1624 end Is_Bit_Packed_Array;
1626 function Is_Called (Id : E) return B is
1629 (Ekind (Id) = E_Procedure or else Ekind (Id) = E_Function);
1630 return Flag102 (Id);
1633 function Is_Character_Type (Id : E) return B is
1636 end Is_Character_Type;
1638 function Is_Child_Unit (Id : E) return B is
1643 function Is_Class_Wide_Equivalent_Type (Id : E) return B is
1646 end Is_Class_Wide_Equivalent_Type;
1648 function Is_Compilation_Unit (Id : E) return B is
1650 return Flag149 (Id);
1651 end Is_Compilation_Unit;
1653 function Is_Completely_Hidden (Id : E) return B is
1655 pragma Assert (Ekind (Id) = E_Discriminant);
1656 return Flag103 (Id);
1657 end Is_Completely_Hidden;
1659 function Is_Constr_Subt_For_U_Nominal (Id : E) return B is
1662 end Is_Constr_Subt_For_U_Nominal;
1664 function Is_Constr_Subt_For_UN_Aliased (Id : E) return B is
1666 return Flag141 (Id);
1667 end Is_Constr_Subt_For_UN_Aliased;
1669 function Is_Constrained (Id : E) return B is
1671 pragma Assert (Nkind (Id) in N_Entity);
1675 function Is_Constructor (Id : E) return B is
1680 function Is_Controlled (Id : E) return B is
1682 return Flag42 (Base_Type (Id));
1685 function Is_Controlling_Formal (Id : E) return B is
1687 pragma Assert (Is_Formal (Id));
1689 end Is_Controlling_Formal;
1691 function Is_CPP_Class (Id : E) return B is
1696 function Is_Descendent_Of_Address (Id : E) return B is
1698 pragma Assert (Is_Type (Id));
1699 return Flag223 (Id);
1700 end Is_Descendent_Of_Address;
1702 function Is_Discrim_SO_Function (Id : E) return B is
1704 return Flag176 (Id);
1705 end Is_Discrim_SO_Function;
1707 function Is_Dispatch_Table_Entity (Id : E) return B is
1709 return Flag234 (Id);
1710 end Is_Dispatch_Table_Entity;
1712 function Is_Dispatching_Operation (Id : E) return B is
1714 pragma Assert (Nkind (Id) in N_Entity);
1716 end Is_Dispatching_Operation;
1718 function Is_Eliminated (Id : E) return B is
1720 return Flag124 (Id);
1723 function Is_Entry_Formal (Id : E) return B is
1726 end Is_Entry_Formal;
1728 function Is_Exported (Id : E) return B is
1733 function Is_First_Subtype (Id : E) return B is
1736 end Is_First_Subtype;
1738 function Is_For_Access_Subtype (Id : E) return B is
1741 (Ekind (Id) = E_Record_Subtype
1743 Ekind (Id) = E_Private_Subtype);
1744 return Flag118 (Id);
1745 end Is_For_Access_Subtype;
1747 function Is_Formal_Subprogram (Id : E) return B is
1749 return Flag111 (Id);
1750 end Is_Formal_Subprogram;
1752 function Is_Frozen (Id : E) return B is
1757 function Is_Generic_Actual_Type (Id : E) return B is
1759 pragma Assert (Is_Type (Id));
1761 end Is_Generic_Actual_Type;
1763 function Is_Generic_Instance (Id : E) return B is
1765 return Flag130 (Id);
1766 end Is_Generic_Instance;
1768 function Is_Generic_Type (Id : E) return B is
1770 pragma Assert (Nkind (Id) in N_Entity);
1772 end Is_Generic_Type;
1774 function Is_Hidden (Id : E) return B is
1779 function Is_Hidden_Open_Scope (Id : E) return B is
1781 return Flag171 (Id);
1782 end Is_Hidden_Open_Scope;
1784 function Is_Immediately_Visible (Id : E) return B is
1786 pragma Assert (Nkind (Id) in N_Entity);
1788 end Is_Immediately_Visible;
1790 function Is_Imported (Id : E) return B is
1795 function Is_Inlined (Id : E) return B is
1800 function Is_Interface (Id : E) return B is
1802 return Flag186 (Id);
1805 function Is_Instantiated (Id : E) return B is
1807 return Flag126 (Id);
1808 end Is_Instantiated;
1810 function Is_Internal (Id : E) return B is
1812 pragma Assert (Nkind (Id) in N_Entity);
1816 function Is_Interrupt_Handler (Id : E) return B is
1818 pragma Assert (Nkind (Id) in N_Entity);
1820 end Is_Interrupt_Handler;
1822 function Is_Intrinsic_Subprogram (Id : E) return B is
1825 end Is_Intrinsic_Subprogram;
1827 function Is_Itype (Id : E) return B is
1832 function Is_Known_Non_Null (Id : E) return B is
1835 end Is_Known_Non_Null;
1837 function Is_Known_Null (Id : E) return B is
1839 return Flag204 (Id);
1842 function Is_Known_Valid (Id : E) return B is
1844 return Flag170 (Id);
1847 function Is_Limited_Composite (Id : E) return B is
1849 return Flag106 (Id);
1850 end Is_Limited_Composite;
1852 function Is_Limited_Interface (Id : E) return B is
1854 return Flag197 (Id);
1855 end Is_Limited_Interface;
1857 function Is_Limited_Record (Id : E) return B is
1860 end Is_Limited_Record;
1862 function Is_Machine_Code_Subprogram (Id : E) return B is
1864 pragma Assert (Is_Subprogram (Id));
1865 return Flag137 (Id);
1866 end Is_Machine_Code_Subprogram;
1868 function Is_Non_Static_Subtype (Id : E) return B is
1870 pragma Assert (Is_Type (Id));
1871 return Flag109 (Id);
1872 end Is_Non_Static_Subtype;
1874 function Is_Null_Init_Proc (Id : E) return B is
1876 pragma Assert (Ekind (Id) = E_Procedure);
1877 return Flag178 (Id);
1878 end Is_Null_Init_Proc;
1880 function Is_Obsolescent (Id : E) return B is
1882 return Flag153 (Id);
1885 function Is_Only_Out_Parameter (Id : E) return B is
1887 pragma Assert (Is_Formal (Id));
1888 return Flag226 (Id);
1889 end Is_Only_Out_Parameter;
1891 function Is_Optional_Parameter (Id : E) return B is
1893 pragma Assert (Is_Formal (Id));
1894 return Flag134 (Id);
1895 end Is_Optional_Parameter;
1897 function Is_Overriding_Operation (Id : E) return B is
1899 pragma Assert (Is_Subprogram (Id));
1901 end Is_Overriding_Operation;
1903 function Is_Package_Body_Entity (Id : E) return B is
1905 return Flag160 (Id);
1906 end Is_Package_Body_Entity;
1908 function Is_Packed (Id : E) return B is
1910 return Flag51 (Implementation_Base_Type (Id));
1913 function Is_Packed_Array_Type (Id : E) return B is
1915 return Flag138 (Id);
1916 end Is_Packed_Array_Type;
1918 function Is_Potentially_Use_Visible (Id : E) return B is
1920 pragma Assert (Nkind (Id) in N_Entity);
1922 end Is_Potentially_Use_Visible;
1924 function Is_Preelaborated (Id : E) return B is
1927 end Is_Preelaborated;
1929 function Is_Primitive (Id : E) return B is
1932 (Is_Overloadable (Id)
1933 or else Ekind (Id) = E_Generic_Function
1934 or else Ekind (Id) = E_Generic_Procedure);
1935 return Flag218 (Id);
1938 function Is_Primitive_Wrapper (Id : E) return B is
1940 pragma Assert (Ekind (Id) = E_Function
1941 or else Ekind (Id) = E_Procedure);
1942 return Flag195 (Id);
1943 end Is_Primitive_Wrapper;
1945 function Is_Private_Composite (Id : E) return B is
1947 pragma Assert (Is_Type (Id));
1948 return Flag107 (Id);
1949 end Is_Private_Composite;
1951 function Is_Private_Descendant (Id : E) return B is
1954 end Is_Private_Descendant;
1956 function Is_Private_Primitive (Id : E) return B is
1958 pragma Assert (Ekind (Id) = E_Function
1959 or else Ekind (Id) = E_Procedure);
1960 return Flag245 (Id);
1961 end Is_Private_Primitive;
1963 function Is_Protected_Interface (Id : E) return B is
1965 pragma Assert (Is_Interface (Id));
1966 return Flag198 (Id);
1967 end Is_Protected_Interface;
1969 function Is_Public (Id : E) return B is
1971 pragma Assert (Nkind (Id) in N_Entity);
1975 function Is_Pure (Id : E) return B is
1980 function Is_Pure_Unit_Access_Type (Id : E) return B is
1982 pragma Assert (Is_Access_Type (Id));
1983 return Flag189 (Id);
1984 end Is_Pure_Unit_Access_Type;
1986 function Is_RACW_Stub_Type (Id : E) return B is
1988 pragma Assert (Is_Type (Id));
1989 return Flag244 (Id);
1990 end Is_RACW_Stub_Type;
1992 function Is_Raised (Id : E) return B is
1994 pragma Assert (Ekind (Id) = E_Exception);
1995 return Flag224 (Id);
1998 function Is_Remote_Call_Interface (Id : E) return B is
2001 end Is_Remote_Call_Interface;
2003 function Is_Remote_Types (Id : E) return B is
2006 end Is_Remote_Types;
2008 function Is_Renaming_Of_Object (Id : E) return B is
2010 return Flag112 (Id);
2011 end Is_Renaming_Of_Object;
2013 function Is_Return_Object (Id : E) return B is
2015 return Flag209 (Id);
2016 end Is_Return_Object;
2018 function Is_Shared_Passive (Id : E) return B is
2021 end Is_Shared_Passive;
2023 function Is_Statically_Allocated (Id : E) return B is
2026 end Is_Statically_Allocated;
2028 function Is_Synchronized_Interface (Id : E) return B is
2030 pragma Assert (Is_Interface (Id));
2031 return Flag199 (Id);
2032 end Is_Synchronized_Interface;
2034 function Is_Tag (Id : E) return B is
2036 pragma Assert (Nkind (Id) in N_Entity);
2040 function Is_Tagged_Type (Id : E) return B is
2045 function Is_Task_Interface (Id : E) return B is
2047 pragma Assert (Is_Interface (Id));
2048 return Flag200 (Id);
2049 end Is_Task_Interface;
2051 function Is_Thunk (Id : E) return B is
2053 pragma Assert (Is_Subprogram (Id));
2054 return Flag225 (Id);
2057 function Is_Trivial_Subprogram (Id : E) return B is
2059 return Flag235 (Id);
2060 end Is_Trivial_Subprogram;
2062 function Is_True_Constant (Id : E) return B is
2064 return Flag163 (Id);
2065 end Is_True_Constant;
2067 function Is_Unchecked_Union (Id : E) return B is
2069 return Flag117 (Implementation_Base_Type (Id));
2070 end Is_Unchecked_Union;
2072 function Is_Underlying_Record_View (Id : E) return B is
2074 return Flag246 (Id);
2075 end Is_Underlying_Record_View;
2077 function Is_Unsigned_Type (Id : E) return B is
2079 pragma Assert (Is_Type (Id));
2080 return Flag144 (Id);
2081 end Is_Unsigned_Type;
2083 function Is_Valued_Procedure (Id : E) return B is
2085 pragma Assert (Ekind (Id) = E_Procedure);
2086 return Flag127 (Id);
2087 end Is_Valued_Procedure;
2089 function Is_Visible_Child_Unit (Id : E) return B is
2091 pragma Assert (Is_Child_Unit (Id));
2092 return Flag116 (Id);
2093 end Is_Visible_Child_Unit;
2095 function Is_Visible_Formal (Id : E) return B is
2097 return Flag206 (Id);
2098 end Is_Visible_Formal;
2100 function Is_VMS_Exception (Id : E) return B is
2102 return Flag133 (Id);
2103 end Is_VMS_Exception;
2105 function Is_Volatile (Id : E) return B is
2107 pragma Assert (Nkind (Id) in N_Entity);
2109 if Is_Type (Id) then
2110 return Flag16 (Base_Type (Id));
2116 function Itype_Printed (Id : E) return B is
2118 pragma Assert (Is_Itype (Id));
2119 return Flag202 (Id);
2122 function Kill_Elaboration_Checks (Id : E) return B is
2125 end Kill_Elaboration_Checks;
2127 function Kill_Range_Checks (Id : E) return B is
2130 end Kill_Range_Checks;
2132 function Kill_Tag_Checks (Id : E) return B is
2135 end Kill_Tag_Checks;
2137 function Known_To_Have_Preelab_Init (Id : E) return B is
2139 pragma Assert (Is_Type (Id));
2140 return Flag207 (Id);
2141 end Known_To_Have_Preelab_Init;
2143 function Last_Assignment (Id : E) return N is
2145 pragma Assert (Is_Assignable (Id));
2147 end Last_Assignment;
2149 function Last_Entity (Id : E) return E is
2154 function Limited_View (Id : E) return E is
2156 pragma Assert (Ekind (Id) = E_Package);
2160 function Lit_Indexes (Id : E) return E is
2162 pragma Assert (Is_Enumeration_Type (Id));
2166 function Lit_Strings (Id : E) return E is
2168 pragma Assert (Is_Enumeration_Type (Id));
2172 function Low_Bound_Tested (Id : E) return B is
2174 return Flag205 (Id);
2175 end Low_Bound_Tested;
2177 function Machine_Radix_10 (Id : E) return B is
2179 pragma Assert (Is_Decimal_Fixed_Point_Type (Id));
2181 end Machine_Radix_10;
2183 function Master_Id (Id : E) return E is
2185 pragma Assert (Is_Access_Type (Id));
2189 function Materialize_Entity (Id : E) return B is
2191 return Flag168 (Id);
2192 end Materialize_Entity;
2194 function Mechanism (Id : E) return M is
2196 pragma Assert (Ekind (Id) = E_Function or else Is_Formal (Id));
2197 return UI_To_Int (Uint8 (Id));
2200 function Modulus (Id : E) return Uint is
2202 pragma Assert (Is_Modular_Integer_Type (Id));
2203 return Uint17 (Base_Type (Id));
2206 function Must_Be_On_Byte_Boundary (Id : E) return B is
2208 pragma Assert (Is_Type (Id));
2209 return Flag183 (Id);
2210 end Must_Be_On_Byte_Boundary;
2212 function Must_Have_Preelab_Init (Id : E) return B is
2214 pragma Assert (Is_Type (Id));
2215 return Flag208 (Id);
2216 end Must_Have_Preelab_Init;
2218 function Needs_Debug_Info (Id : E) return B is
2220 return Flag147 (Id);
2221 end Needs_Debug_Info;
2223 function Needs_No_Actuals (Id : E) return B is
2226 (Is_Overloadable (Id)
2227 or else Ekind (Id) = E_Subprogram_Type
2228 or else Ekind (Id) = E_Entry_Family);
2230 end Needs_No_Actuals;
2232 function Never_Set_In_Source (Id : E) return B is
2234 return Flag115 (Id);
2235 end Never_Set_In_Source;
2237 function Next_Inlined_Subprogram (Id : E) return E is
2240 end Next_Inlined_Subprogram;
2242 function No_Pool_Assigned (Id : E) return B is
2244 pragma Assert (Is_Access_Type (Id));
2245 return Flag131 (Root_Type (Id));
2246 end No_Pool_Assigned;
2248 function No_Return (Id : E) return B is
2250 return Flag113 (Id);
2253 function No_Strict_Aliasing (Id : E) return B is
2255 pragma Assert (Is_Access_Type (Id));
2256 return Flag136 (Base_Type (Id));
2257 end No_Strict_Aliasing;
2259 function Non_Binary_Modulus (Id : E) return B is
2261 pragma Assert (Is_Type (Id));
2262 return Flag58 (Base_Type (Id));
2263 end Non_Binary_Modulus;
2265 function Non_Limited_View (Id : E) return E is
2267 pragma Assert (Ekind (Id) in Incomplete_Kind);
2269 end Non_Limited_View;
2271 function Nonzero_Is_True (Id : E) return B is
2273 pragma Assert (Root_Type (Id) = Standard_Boolean);
2274 return Flag162 (Base_Type (Id));
2275 end Nonzero_Is_True;
2277 function Normalized_First_Bit (Id : E) return U is
2280 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
2282 end Normalized_First_Bit;
2284 function Normalized_Position (Id : E) return U is
2287 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
2289 end Normalized_Position;
2291 function Normalized_Position_Max (Id : E) return U is
2294 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
2296 end Normalized_Position_Max;
2298 function OK_To_Rename (Id : E) return B is
2300 pragma Assert (Ekind (Id) = E_Variable);
2301 return Flag247 (Id);
2304 function OK_To_Reorder_Components (Id : E) return B is
2306 pragma Assert (Is_Record_Type (Id));
2307 return Flag239 (Base_Type (Id));
2308 end OK_To_Reorder_Components;
2310 function Optimize_Alignment_Space (Id : E) return B is
2314 or else Ekind (Id) = E_Constant
2315 or else Ekind (Id) = E_Variable);
2316 return Flag241 (Id);
2317 end Optimize_Alignment_Space;
2319 function Optimize_Alignment_Time (Id : E) return B is
2323 or else Ekind (Id) = E_Constant
2324 or else Ekind (Id) = E_Variable);
2325 return Flag242 (Id);
2326 end Optimize_Alignment_Time;
2328 function Original_Array_Type (Id : E) return E is
2330 pragma Assert (Is_Array_Type (Id) or else Is_Modular_Integer_Type (Id));
2332 end Original_Array_Type;
2334 function Original_Record_Component (Id : E) return E is
2337 (Ekind (Id) = E_Void
2338 or else Ekind (Id) = E_Component
2339 or else Ekind (Id) = E_Discriminant);
2341 end Original_Record_Component;
2343 function Overlays_Constant (Id : E) return B is
2345 return Flag243 (Id);
2346 end Overlays_Constant;
2348 function Overridden_Operation (Id : E) return E is
2351 end Overridden_Operation;
2353 function Package_Instantiation (Id : E) return N is
2357 or else Ekind (Id) = E_Generic_Package
2358 or else Ekind (Id) = E_Package);
2360 end Package_Instantiation;
2362 function Packed_Array_Type (Id : E) return E is
2364 pragma Assert (Is_Array_Type (Id));
2366 end Packed_Array_Type;
2368 function Parent_Subtype (Id : E) return E is
2370 pragma Assert (Is_Record_Type (Id));
2371 return Node19 (Base_Type (Id));
2374 function Postcondition_Proc (Id : E) return E is
2376 pragma Assert (Ekind (Id) = E_Procedure);
2378 end Postcondition_Proc;
2380 function Primitive_Operations (Id : E) return L is
2382 pragma Assert (Is_Tagged_Type (Id));
2383 return Elist15 (Id);
2384 end Primitive_Operations;
2386 function Prival (Id : E) return E is
2388 pragma Assert (Is_Protected_Component (Id));
2392 function Prival_Link (Id : E) return E is
2394 pragma Assert (Ekind (Id) = E_Constant
2395 or else Ekind (Id) = E_Variable);
2399 function Private_Dependents (Id : E) return L is
2401 pragma Assert (Is_Incomplete_Or_Private_Type (Id));
2402 return Elist18 (Id);
2403 end Private_Dependents;
2405 function Private_View (Id : E) return N is
2407 pragma Assert (Is_Private_Type (Id));
2411 function Protected_Body_Subprogram (Id : E) return E is
2413 pragma Assert (Is_Subprogram (Id) or else Is_Entry (Id));
2415 end Protected_Body_Subprogram;
2417 function Protected_Formal (Id : E) return E is
2419 pragma Assert (Is_Formal (Id));
2421 end Protected_Formal;
2423 function Protection_Object (Id : E) return E is
2425 pragma Assert (Ekind (Id) = E_Entry
2426 or else Ekind (Id) = E_Entry_Family
2427 or else Ekind (Id) = E_Function
2428 or else Ekind (Id) = E_Procedure);
2430 end Protection_Object;
2432 function Reachable (Id : E) return B is
2437 function Referenced (Id : E) return B is
2439 return Flag156 (Id);
2442 function Referenced_As_LHS (Id : E) return B is
2445 end Referenced_As_LHS;
2447 function Referenced_As_Out_Parameter (Id : E) return B is
2449 return Flag227 (Id);
2450 end Referenced_As_Out_Parameter;
2452 function Referenced_Object (Id : E) return N is
2454 pragma Assert (Is_Type (Id));
2456 end Referenced_Object;
2458 function Register_Exception_Call (Id : E) return N is
2460 pragma Assert (Ekind (Id) = E_Exception);
2462 end Register_Exception_Call;
2464 function Related_Array_Object (Id : E) return E is
2466 pragma Assert (Is_Array_Type (Id));
2468 end Related_Array_Object;
2470 function Related_Expression (Id : E) return N is
2472 pragma Assert (Ekind (Id) = E_Constant or else Ekind (Id) = E_Variable);
2474 end Related_Expression;
2476 function Related_Instance (Id : E) return E is
2479 (Ekind (Id) = E_Package or else Ekind (Id) = E_Package_Body);
2481 end Related_Instance;
2483 function Related_Type (Id : E) return E is
2486 (Ekind (Id) = E_Component or else Ekind (Id) = E_Constant);
2490 function Relative_Deadline_Variable (Id : E) return E is
2492 pragma Assert (Is_Task_Type (Id));
2493 return Node26 (Implementation_Base_Type (Id));
2494 end Relative_Deadline_Variable;
2496 function Renamed_Entity (Id : E) return N is
2501 function Renamed_In_Spec (Id : E) return B is
2503 pragma Assert (Ekind (Id) = E_Package);
2504 return Flag231 (Id);
2505 end Renamed_In_Spec;
2507 function Renamed_Object (Id : E) return N is
2512 function Renaming_Map (Id : E) return U is
2517 function Requires_Overriding (Id : E) return B is
2519 pragma Assert (Is_Overloadable (Id));
2520 return Flag213 (Id);
2521 end Requires_Overriding;
2523 function Return_Present (Id : E) return B is
2528 function Return_Applies_To (Id : E) return N is
2531 end Return_Applies_To;
2533 function Returns_By_Ref (Id : E) return B is
2538 function Reverse_Bit_Order (Id : E) return B is
2540 pragma Assert (Is_Record_Type (Id));
2541 return Flag164 (Base_Type (Id));
2542 end Reverse_Bit_Order;
2544 function RM_Size (Id : E) return U is
2546 pragma Assert (Is_Type (Id));
2550 function Scalar_Range (Id : E) return N is
2555 function Scale_Value (Id : E) return U is
2560 function Scope_Depth_Value (Id : E) return U is
2563 end Scope_Depth_Value;
2565 function Sec_Stack_Needed_For_Return (Id : E) return B is
2567 return Flag167 (Id);
2568 end Sec_Stack_Needed_For_Return;
2570 function Shadow_Entities (Id : E) return S is
2573 (Ekind (Id) = E_Package or else Ekind (Id) = E_Generic_Package);
2575 end Shadow_Entities;
2577 function Shared_Var_Procs_Instance (Id : E) return E is
2579 pragma Assert (Ekind (Id) = E_Variable);
2581 end Shared_Var_Procs_Instance;
2583 function Size_Check_Code (Id : E) return N is
2585 pragma Assert (Ekind (Id) = E_Constant or else Ekind (Id) = E_Variable);
2587 end Size_Check_Code;
2589 function Size_Depends_On_Discriminant (Id : E) return B is
2591 return Flag177 (Id);
2592 end Size_Depends_On_Discriminant;
2594 function Size_Known_At_Compile_Time (Id : E) return B is
2597 end Size_Known_At_Compile_Time;
2599 function Small_Value (Id : E) return R is
2601 pragma Assert (Is_Fixed_Point_Type (Id));
2602 return Ureal21 (Id);
2605 function Spec_Entity (Id : E) return E is
2608 (Ekind (Id) = E_Package_Body or else Is_Formal (Id));
2612 function Spec_PPC_List (Id : E) return N is
2614 pragma Assert (Is_Subprogram (Id) or else Is_Generic_Subprogram (Id));
2618 function Storage_Size_Variable (Id : E) return E is
2620 pragma Assert (Is_Access_Type (Id) or else Is_Task_Type (Id));
2621 return Node15 (Implementation_Base_Type (Id));
2622 end Storage_Size_Variable;
2624 function Static_Elaboration_Desired (Id : E) return B is
2626 pragma Assert (Ekind (Id) = E_Package);
2628 end Static_Elaboration_Desired;
2630 function Static_Initialization (Id : E) return N is
2633 (Ekind (Id) = E_Procedure and then not Is_Dispatching_Operation (Id));
2635 end Static_Initialization;
2637 function Stored_Constraint (Id : E) return L is
2640 (Is_Composite_Type (Id) and then not Is_Array_Type (Id));
2641 return Elist23 (Id);
2642 end Stored_Constraint;
2644 function Strict_Alignment (Id : E) return B is
2646 return Flag145 (Implementation_Base_Type (Id));
2647 end Strict_Alignment;
2649 function String_Literal_Length (Id : E) return U is
2652 end String_Literal_Length;
2654 function String_Literal_Low_Bound (Id : E) return N is
2657 end String_Literal_Low_Bound;
2659 function Suppress_Elaboration_Warnings (Id : E) return B is
2661 return Flag148 (Id);
2662 end Suppress_Elaboration_Warnings;
2664 function Suppress_Init_Proc (Id : E) return B is
2666 return Flag105 (Base_Type (Id));
2667 end Suppress_Init_Proc;
2669 function Suppress_Style_Checks (Id : E) return B is
2671 return Flag165 (Id);
2672 end Suppress_Style_Checks;
2674 function Suppress_Value_Tracking_On_Call (Id : E) return B is
2676 return Flag217 (Id);
2677 end Suppress_Value_Tracking_On_Call;
2679 function Task_Body_Procedure (Id : E) return N is
2681 pragma Assert (Ekind (Id) in Task_Kind);
2683 end Task_Body_Procedure;
2685 function Treat_As_Volatile (Id : E) return B is
2688 end Treat_As_Volatile;
2690 function Underlying_Full_View (Id : E) return E is
2692 pragma Assert (Ekind (Id) in Private_Kind);
2694 end Underlying_Full_View;
2696 function Underlying_Record_View (Id : E) return E is
2699 end Underlying_Record_View;
2701 function Universal_Aliasing (Id : E) return B is
2703 pragma Assert (Is_Type (Id));
2704 return Flag216 (Base_Type (Id));
2705 end Universal_Aliasing;
2707 function Unset_Reference (Id : E) return N is
2710 end Unset_Reference;
2712 function Used_As_Generic_Actual (Id : E) return B is
2714 return Flag222 (Id);
2715 end Used_As_Generic_Actual;
2717 function Uses_Sec_Stack (Id : E) return B is
2722 function Vax_Float (Id : E) return B is
2724 return Flag151 (Base_Type (Id));
2727 function Warnings_Off (Id : E) return B is
2732 function Warnings_Off_Used (Id : E) return B is
2734 return Flag236 (Id);
2735 end Warnings_Off_Used;
2737 function Warnings_Off_Used_Unmodified (Id : E) return B is
2739 return Flag237 (Id);
2740 end Warnings_Off_Used_Unmodified;
2742 function Warnings_Off_Used_Unreferenced (Id : E) return B is
2744 return Flag238 (Id);
2745 end Warnings_Off_Used_Unreferenced;
2747 function Wrapped_Entity (Id : E) return E is
2749 pragma Assert ((Ekind (Id) = E_Function
2750 or else Ekind (Id) = 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_Array_Type (Id : E) return B is
2781 return Ekind (Id) in Array_Kind;
2784 function Is_Assignable (Id : E) return B is
2786 return Ekind (Id) in Assignable_Kind;
2789 function Is_Class_Wide_Type (Id : E) return B is
2791 return Ekind (Id) in Class_Wide_Kind;
2792 end Is_Class_Wide_Type;
2794 function Is_Composite_Type (Id : E) return B is
2796 return Ekind (Id) in Composite_Kind;
2797 end Is_Composite_Type;
2799 function Is_Concurrent_Body (Id : E) return B is
2801 return Ekind (Id) in
2802 Concurrent_Body_Kind;
2803 end Is_Concurrent_Body;
2805 function Is_Concurrent_Record_Type (Id : E) return B is
2808 end Is_Concurrent_Record_Type;
2810 function Is_Concurrent_Type (Id : E) return B is
2812 return Ekind (Id) in Concurrent_Kind;
2813 end Is_Concurrent_Type;
2815 function Is_Decimal_Fixed_Point_Type (Id : E) return B is
2817 return Ekind (Id) in
2818 Decimal_Fixed_Point_Kind;
2819 end Is_Decimal_Fixed_Point_Type;
2821 function Is_Digits_Type (Id : E) return B is
2823 return Ekind (Id) in Digits_Kind;
2826 function Is_Discrete_Or_Fixed_Point_Type (Id : E) return B is
2828 return Ekind (Id) in Discrete_Or_Fixed_Point_Kind;
2829 end Is_Discrete_Or_Fixed_Point_Type;
2831 function Is_Discrete_Type (Id : E) return B is
2833 return Ekind (Id) in Discrete_Kind;
2834 end Is_Discrete_Type;
2836 function Is_Elementary_Type (Id : E) return B is
2838 return Ekind (Id) in Elementary_Kind;
2839 end Is_Elementary_Type;
2841 function Is_Entry (Id : E) return B is
2843 return Ekind (Id) in Entry_Kind;
2846 function Is_Enumeration_Type (Id : E) return B is
2848 return Ekind (Id) in
2850 end Is_Enumeration_Type;
2852 function Is_Fixed_Point_Type (Id : E) return B is
2854 return Ekind (Id) in
2856 end Is_Fixed_Point_Type;
2858 function Is_Floating_Point_Type (Id : E) return B is
2860 return Ekind (Id) in Float_Kind;
2861 end Is_Floating_Point_Type;
2863 function Is_Formal (Id : E) return B is
2865 return Ekind (Id) in Formal_Kind;
2868 function Is_Formal_Object (Id : E) return B is
2870 return Ekind (Id) in Formal_Object_Kind;
2871 end Is_Formal_Object;
2873 function Is_Generic_Subprogram (Id : E) return B is
2875 return Ekind (Id) in Generic_Subprogram_Kind;
2876 end Is_Generic_Subprogram;
2878 function Is_Generic_Unit (Id : E) return B is
2880 return Ekind (Id) in Generic_Unit_Kind;
2881 end Is_Generic_Unit;
2883 function Is_Incomplete_Or_Private_Type (Id : E) return B is
2885 return Ekind (Id) in
2886 Incomplete_Or_Private_Kind;
2887 end Is_Incomplete_Or_Private_Type;
2889 function Is_Incomplete_Type (Id : E) return B is
2891 return Ekind (Id) in
2893 end Is_Incomplete_Type;
2895 function Is_Integer_Type (Id : E) return B is
2897 return Ekind (Id) in Integer_Kind;
2898 end Is_Integer_Type;
2900 function Is_Modular_Integer_Type (Id : E) return B is
2902 return Ekind (Id) in
2903 Modular_Integer_Kind;
2904 end Is_Modular_Integer_Type;
2906 function Is_Named_Number (Id : E) return B is
2908 return Ekind (Id) in Named_Kind;
2909 end Is_Named_Number;
2911 function Is_Numeric_Type (Id : E) return B is
2913 return Ekind (Id) in Numeric_Kind;
2914 end Is_Numeric_Type;
2916 function Is_Object (Id : E) return B is
2918 return Ekind (Id) in Object_Kind;
2921 function Is_Ordinary_Fixed_Point_Type (Id : E) return B is
2923 return Ekind (Id) in
2924 Ordinary_Fixed_Point_Kind;
2925 end Is_Ordinary_Fixed_Point_Type;
2927 function Is_Overloadable (Id : E) return B is
2929 return Ekind (Id) in Overloadable_Kind;
2930 end Is_Overloadable;
2932 function Is_Private_Type (Id : E) return B is
2934 return Ekind (Id) in Private_Kind;
2935 end Is_Private_Type;
2937 function Is_Protected_Type (Id : E) return B is
2939 return Ekind (Id) in Protected_Kind;
2940 end Is_Protected_Type;
2942 function Is_Real_Type (Id : E) return B is
2944 return Ekind (Id) in Real_Kind;
2947 function Is_Record_Type (Id : E) return B is
2949 return Ekind (Id) in Record_Kind;
2952 function Is_Scalar_Type (Id : E) return B is
2954 return Ekind (Id) in Scalar_Kind;
2957 function Is_Signed_Integer_Type (Id : E) return B is
2959 return Ekind (Id) in
2960 Signed_Integer_Kind;
2961 end Is_Signed_Integer_Type;
2963 function Is_Subprogram (Id : E) return B is
2965 return Ekind (Id) in Subprogram_Kind;
2968 function Is_Task_Type (Id : E) return B is
2970 return Ekind (Id) in Task_Kind;
2973 function Is_Type (Id : E) return B is
2975 return Ekind (Id) in Type_Kind;
2978 ------------------------------
2979 -- Attribute Set Procedures --
2980 ------------------------------
2982 procedure Set_Accept_Address (Id : E; V : L) is
2984 Set_Elist21 (Id, V);
2985 end Set_Accept_Address;
2987 procedure Set_Access_Disp_Table (Id : E; V : L) is
2989 pragma Assert (Is_Tagged_Type (Id) and then Id = Base_Type (Id));
2990 Set_Elist16 (Id, V);
2991 end Set_Access_Disp_Table;
2993 procedure Set_Associated_Final_Chain (Id : E; V : E) is
2995 pragma Assert (Is_Access_Type (Id));
2997 end Set_Associated_Final_Chain;
2999 procedure Set_Associated_Formal_Package (Id : E; V : E) is
3002 end Set_Associated_Formal_Package;
3004 procedure Set_Associated_Node_For_Itype (Id : E; V : E) is
3007 end Set_Associated_Node_For_Itype;
3009 procedure Set_Associated_Storage_Pool (Id : E; V : E) is
3011 pragma Assert (Is_Access_Type (Id) and then Id = Base_Type (Id));
3013 end Set_Associated_Storage_Pool;
3015 procedure Set_Actual_Subtype (Id : E; V : E) is
3018 (Ekind (Id) = E_Constant
3019 or else Ekind (Id) = E_Variable
3020 or else Ekind (Id) = E_Generic_In_Out_Parameter
3021 or else Is_Formal (Id));
3023 end Set_Actual_Subtype;
3025 procedure Set_Address_Taken (Id : E; V : B := True) is
3027 Set_Flag104 (Id, V);
3028 end Set_Address_Taken;
3030 procedure Set_Alias (Id : E; V : E) is
3033 (Is_Overloadable (Id) or else Ekind (Id) = E_Subprogram_Type);
3037 procedure Set_Alignment (Id : E; V : U) is
3039 pragma Assert (Is_Type (Id)
3040 or else Is_Formal (Id)
3041 or else Ekind (Id) = E_Loop_Parameter
3042 or else Ekind (Id) = E_Constant
3043 or else Ekind (Id) = E_Exception
3044 or else Ekind (Id) = E_Variable);
3048 procedure Set_Barrier_Function (Id : E; V : N) is
3050 pragma Assert (Is_Entry (Id));
3052 end Set_Barrier_Function;
3054 procedure Set_Block_Node (Id : E; V : N) is
3056 pragma Assert (Ekind (Id) = E_Block);
3060 procedure Set_Body_Entity (Id : E; V : E) is
3063 (Ekind (Id) = E_Package or else Ekind (Id) = E_Generic_Package);
3065 end Set_Body_Entity;
3067 procedure Set_Body_Needed_For_SAL (Id : E; V : B := True) is
3070 (Ekind (Id) = E_Package
3071 or else Is_Subprogram (Id)
3072 or else Is_Generic_Unit (Id));
3074 end Set_Body_Needed_For_SAL;
3076 procedure Set_C_Pass_By_Copy (Id : E; V : B := True) is
3078 pragma Assert (Is_Record_Type (Id) and then Id = Base_Type (Id));
3079 Set_Flag125 (Id, V);
3080 end Set_C_Pass_By_Copy;
3082 procedure Set_Can_Never_Be_Null (Id : E; V : B := True) is
3085 end Set_Can_Never_Be_Null;
3087 procedure Set_Checks_May_Be_Suppressed (Id : E; V : B := True) is
3090 end Set_Checks_May_Be_Suppressed;
3092 procedure Set_Class_Wide_Type (Id : E; V : E) is
3094 pragma Assert (Is_Type (Id));
3096 end Set_Class_Wide_Type;
3098 procedure Set_Cloned_Subtype (Id : E; V : E) is
3101 (Ekind (Id) = E_Record_Subtype
3102 or else Ekind (Id) = E_Class_Wide_Subtype);
3104 end Set_Cloned_Subtype;
3106 procedure Set_Component_Bit_Offset (Id : E; V : U) is
3109 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
3111 end Set_Component_Bit_Offset;
3113 procedure Set_Component_Clause (Id : E; V : N) is
3116 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
3118 end Set_Component_Clause;
3120 procedure Set_Component_Size (Id : E; V : U) is
3122 pragma Assert (Is_Array_Type (Id) and then Id = Base_Type (Id));
3124 end Set_Component_Size;
3126 procedure Set_Component_Type (Id : E; V : E) is
3128 pragma Assert (Is_Array_Type (Id) and then Id = Base_Type (Id));
3130 end Set_Component_Type;
3132 procedure Set_Corresponding_Concurrent_Type (Id : E; V : E) is
3135 (Ekind (Id) = E_Record_Type and then Is_Concurrent_Type (V));
3137 end Set_Corresponding_Concurrent_Type;
3139 procedure Set_Corresponding_Discriminant (Id : E; V : E) is
3141 pragma Assert (Ekind (Id) = E_Discriminant);
3143 end Set_Corresponding_Discriminant;
3145 procedure Set_Corresponding_Equality (Id : E; V : E) is
3148 (Ekind (Id) = E_Function
3149 and then not Comes_From_Source (Id)
3150 and then Chars (Id) = Name_Op_Ne);
3152 end Set_Corresponding_Equality;
3154 procedure Set_Corresponding_Record_Type (Id : E; V : E) is
3156 pragma Assert (Is_Concurrent_Type (Id));
3158 end Set_Corresponding_Record_Type;
3160 procedure Set_Corresponding_Remote_Type (Id : E; V : E) is
3163 end Set_Corresponding_Remote_Type;
3165 procedure Set_Current_Use_Clause (Id : E; V : E) is
3167 pragma Assert (Ekind (Id) = E_Package or else Is_Type (Id));
3169 end Set_Current_Use_Clause;
3171 procedure Set_Current_Value (Id : E; V : N) is
3173 pragma Assert (Ekind (Id) in Object_Kind or else Ekind (Id) = E_Void);
3175 end Set_Current_Value;
3177 procedure Set_CR_Discriminant (Id : E; V : E) is
3180 end Set_CR_Discriminant;
3182 procedure Set_Debug_Info_Off (Id : E; V : B := True) is
3184 Set_Flag166 (Id, V);
3185 end Set_Debug_Info_Off;
3187 procedure Set_Debug_Renaming_Link (Id : E; V : E) is
3190 end Set_Debug_Renaming_Link;
3192 procedure Set_Default_Expr_Function (Id : E; V : E) is
3194 pragma Assert (Is_Formal (Id));
3196 end Set_Default_Expr_Function;
3198 procedure Set_Default_Expressions_Processed (Id : E; V : B := True) is
3200 Set_Flag108 (Id, V);
3201 end Set_Default_Expressions_Processed;
3203 procedure Set_Default_Value (Id : E; V : N) is
3205 pragma Assert (Is_Formal (Id));
3207 end Set_Default_Value;
3209 procedure Set_Delay_Cleanups (Id : E; V : B := True) is
3213 or else Is_Task_Type (Id)
3214 or else Ekind (Id) = E_Block);
3215 Set_Flag114 (Id, V);
3216 end Set_Delay_Cleanups;
3218 procedure Set_Delay_Subprogram_Descriptors (Id : E; V : B := True) is
3222 or else Ekind (Id) = E_Package
3223 or else Ekind (Id) = E_Package_Body);
3225 end Set_Delay_Subprogram_Descriptors;
3227 procedure Set_Delta_Value (Id : E; V : R) is
3229 pragma Assert (Is_Fixed_Point_Type (Id));
3230 Set_Ureal18 (Id, V);
3231 end Set_Delta_Value;
3233 procedure Set_Dependent_Instances (Id : E; V : L) is
3235 pragma Assert (Is_Generic_Instance (Id));
3237 end Set_Dependent_Instances;
3239 procedure Set_Depends_On_Private (Id : E; V : B := True) is
3241 pragma Assert (Nkind (Id) in N_Entity);
3243 end Set_Depends_On_Private;
3245 procedure Set_Digits_Value (Id : E; V : U) is
3248 (Is_Floating_Point_Type (Id)
3249 or else Is_Decimal_Fixed_Point_Type (Id));
3251 end Set_Digits_Value;
3253 procedure Set_Directly_Designated_Type (Id : E; V : E) is
3256 end Set_Directly_Designated_Type;
3258 procedure Set_Discard_Names (Id : E; V : B := True) is
3261 end Set_Discard_Names;
3263 procedure Set_Discriminal (Id : E; V : E) is
3265 pragma Assert (Ekind (Id) = E_Discriminant);
3267 end Set_Discriminal;
3269 procedure Set_Discriminal_Link (Id : E; V : E) is
3272 end Set_Discriminal_Link;
3274 procedure Set_Discriminant_Checking_Func (Id : E; V : E) is
3276 pragma Assert (Ekind (Id) = E_Component);
3278 end Set_Discriminant_Checking_Func;
3280 procedure Set_Discriminant_Constraint (Id : E; V : L) is
3282 pragma Assert (Nkind (Id) in N_Entity);
3283 Set_Elist21 (Id, V);
3284 end Set_Discriminant_Constraint;
3286 procedure Set_Discriminant_Default_Value (Id : E; V : N) is
3289 end Set_Discriminant_Default_Value;
3291 procedure Set_Discriminant_Number (Id : E; V : U) is
3294 end Set_Discriminant_Number;
3296 procedure Set_Dispatch_Table_Wrappers (Id : E; V : L) is
3298 pragma Assert (Is_Tagged_Type (Id) and then Id = Base_Type (Id));
3299 Set_Elist26 (Id, V);
3300 end Set_Dispatch_Table_Wrappers;
3302 procedure Set_DT_Entry_Count (Id : E; V : U) is
3304 pragma Assert (Ekind (Id) = E_Component);
3306 end Set_DT_Entry_Count;
3308 procedure Set_DT_Offset_To_Top_Func (Id : E; V : E) is
3310 pragma Assert (Ekind (Id) = E_Component and then Is_Tag (Id));
3312 end Set_DT_Offset_To_Top_Func;
3314 procedure Set_DT_Position (Id : E; V : U) is
3316 pragma Assert (Ekind (Id) = E_Function or else Ekind (Id) = E_Procedure);
3318 end Set_DT_Position;
3320 procedure Set_DTC_Entity (Id : E; V : E) is
3323 (Ekind (Id) = E_Function or else Ekind (Id) = E_Procedure);
3327 procedure Set_Elaborate_Body_Desirable (Id : E; V : B := True) is
3329 pragma Assert (Ekind (Id) = E_Package);
3330 Set_Flag210 (Id, V);
3331 end Set_Elaborate_Body_Desirable;
3333 procedure Set_Elaboration_Entity (Id : E; V : E) is
3338 Ekind (Id) = E_Package
3340 Is_Generic_Unit (Id));
3342 end Set_Elaboration_Entity;
3344 procedure Set_Elaboration_Entity_Required (Id : E; V : B := True) is
3349 Ekind (Id) = E_Package
3351 Is_Generic_Unit (Id));
3352 Set_Flag174 (Id, V);
3353 end Set_Elaboration_Entity_Required;
3355 procedure Set_Enclosing_Scope (Id : E; V : E) is
3358 end Set_Enclosing_Scope;
3360 procedure Set_Entry_Accepted (Id : E; V : B := True) is
3362 pragma Assert (Is_Entry (Id));
3363 Set_Flag152 (Id, V);
3364 end Set_Entry_Accepted;
3366 procedure Set_Entry_Bodies_Array (Id : E; V : E) is
3369 end Set_Entry_Bodies_Array;
3371 procedure Set_Entry_Cancel_Parameter (Id : E; V : E) is
3374 end Set_Entry_Cancel_Parameter;
3376 procedure Set_Entry_Component (Id : E; V : E) is
3379 end Set_Entry_Component;
3381 procedure Set_Entry_Formal (Id : E; V : E) is
3384 end Set_Entry_Formal;
3386 procedure Set_Entry_Index_Constant (Id : E; V : E) is
3388 pragma Assert (Ekind (Id) = E_Entry_Index_Parameter);
3390 end Set_Entry_Index_Constant;
3392 procedure Set_Entry_Parameters_Type (Id : E; V : E) is
3395 end Set_Entry_Parameters_Type;
3397 procedure Set_Enum_Pos_To_Rep (Id : E; V : E) is
3399 pragma Assert (Ekind (Id) = E_Enumeration_Type);
3401 end Set_Enum_Pos_To_Rep;
3403 procedure Set_Enumeration_Pos (Id : E; V : U) is
3405 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
3407 end Set_Enumeration_Pos;
3409 procedure Set_Enumeration_Rep (Id : E; V : U) is
3411 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
3413 end Set_Enumeration_Rep;
3415 procedure Set_Enumeration_Rep_Expr (Id : E; V : N) is
3417 pragma Assert (Ekind (Id) = E_Enumeration_Literal);
3419 end Set_Enumeration_Rep_Expr;
3421 procedure Set_Equivalent_Type (Id : E; V : E) is
3424 (Ekind (Id) = E_Class_Wide_Type or else
3425 Ekind (Id) = E_Class_Wide_Subtype or else
3426 Ekind (Id) = E_Access_Protected_Subprogram_Type or else
3427 Ekind (Id) = E_Anonymous_Access_Protected_Subprogram_Type or else
3428 Ekind (Id) = E_Access_Subprogram_Type or else
3429 Ekind (Id) = E_Exception_Type);
3431 end Set_Equivalent_Type;
3433 procedure Set_Esize (Id : E; V : U) is
3438 procedure Set_Exception_Code (Id : E; V : U) is
3440 pragma Assert (Ekind (Id) = E_Exception);
3442 end Set_Exception_Code;
3444 procedure Set_Extra_Accessibility (Id : E; V : E) is
3446 pragma Assert (Is_Formal (Id) or else Ekind (Id) = E_Variable);
3448 end Set_Extra_Accessibility;
3450 procedure Set_Extra_Constrained (Id : E; V : E) is
3452 pragma Assert (Is_Formal (Id) or else Ekind (Id) = E_Variable);
3454 end Set_Extra_Constrained;
3456 procedure Set_Extra_Formal (Id : E; V : E) is
3459 end Set_Extra_Formal;
3461 procedure Set_Extra_Formals (Id : E; V : E) is
3464 (Is_Overloadable (Id)
3465 or else Ekind (Id) = E_Entry_Family
3466 or else Ekind (Id) = E_Subprogram_Body
3467 or else Ekind (Id) = E_Subprogram_Type);
3469 end Set_Extra_Formals;
3471 procedure Set_Can_Use_Internal_Rep (Id : E; V : B := True) is
3474 (Is_Access_Subprogram_Type (Id)
3475 and then Id = Base_Type (Id));
3476 Set_Flag229 (Id, V);
3477 end Set_Can_Use_Internal_Rep;
3479 procedure Set_Finalization_Chain_Entity (Id : E; V : E) is
3482 end Set_Finalization_Chain_Entity;
3484 procedure Set_Finalize_Storage_Only (Id : E; V : B := True) is
3486 pragma Assert (Is_Type (Id) and then Id = Base_Type (Id));
3487 Set_Flag158 (Id, V);
3488 end Set_Finalize_Storage_Only;
3490 procedure Set_First_Entity (Id : E; V : E) is
3493 end Set_First_Entity;
3495 procedure Set_First_Index (Id : E; V : N) is
3497 pragma Assert (Is_Array_Type (Id) or else Is_String_Type (Id));
3499 end Set_First_Index;
3501 procedure Set_First_Literal (Id : E; V : E) is
3503 pragma Assert (Is_Enumeration_Type (Id));
3505 end Set_First_Literal;
3507 procedure Set_First_Optional_Parameter (Id : E; V : E) is
3510 (Ekind (Id) = E_Function or else Ekind (Id) = E_Procedure);
3512 end Set_First_Optional_Parameter;
3514 procedure Set_First_Private_Entity (Id : E; V : E) is
3516 pragma Assert (Ekind (Id) = E_Package
3517 or else Ekind (Id) = E_Generic_Package
3518 or else Ekind (Id) in Concurrent_Kind);
3520 end Set_First_Private_Entity;
3522 procedure Set_First_Rep_Item (Id : E; V : N) is
3525 end Set_First_Rep_Item;
3527 procedure Set_Freeze_Node (Id : E; V : N) is
3530 end Set_Freeze_Node;
3532 procedure Set_From_With_Type (Id : E; V : B := True) is
3536 or else Ekind (Id) = E_Package);
3537 Set_Flag159 (Id, V);
3538 end Set_From_With_Type;
3540 procedure Set_Full_View (Id : E; V : E) is
3542 pragma Assert (Is_Type (Id) or else Ekind (Id) = E_Constant);
3546 procedure Set_Generic_Homonym (Id : E; V : E) is
3549 end Set_Generic_Homonym;
3551 procedure Set_Generic_Renamings (Id : E; V : L) is
3553 Set_Elist23 (Id, V);
3554 end Set_Generic_Renamings;
3556 procedure Set_Handler_Records (Id : E; V : S) is
3559 end Set_Handler_Records;
3561 procedure Set_Has_Aliased_Components (Id : E; V : B := True) is
3563 pragma Assert (Id = Base_Type (Id));
3564 Set_Flag135 (Id, V);
3565 end Set_Has_Aliased_Components;
3567 procedure Set_Has_Alignment_Clause (Id : E; V : B := True) is
3570 end Set_Has_Alignment_Clause;
3572 procedure Set_Has_All_Calls_Remote (Id : E; V : B := True) is
3575 end Set_Has_All_Calls_Remote;
3577 procedure Set_Has_Anon_Block_Suffix (Id : E; V : B := True) is
3579 Set_Flag201 (Id, V);
3580 end Set_Has_Anon_Block_Suffix;
3582 procedure Set_Has_Atomic_Components (Id : E; V : B := True) is
3584 pragma Assert (not Is_Type (Id) or else Id = Base_Type (Id));
3586 end Set_Has_Atomic_Components;
3588 procedure Set_Has_Biased_Representation (Id : E; V : B := True) is
3591 ((V = False) or else (Is_Discrete_Type (Id) or else Is_Object (Id)));
3592 Set_Flag139 (Id, V);
3593 end Set_Has_Biased_Representation;
3595 procedure Set_Has_Completion (Id : E; V : B := True) is
3598 end Set_Has_Completion;
3600 procedure Set_Has_Completion_In_Body (Id : E; V : B := True) is
3602 pragma Assert (Is_Type (Id));
3604 end Set_Has_Completion_In_Body;
3606 procedure Set_Has_Complex_Representation (Id : E; V : B := True) is
3608 pragma Assert (Ekind (Id) = E_Record_Type);
3609 Set_Flag140 (Id, V);
3610 end Set_Has_Complex_Representation;
3612 procedure Set_Has_Component_Size_Clause (Id : E; V : B := True) is
3614 pragma Assert (Ekind (Id) = E_Array_Type);
3616 end Set_Has_Component_Size_Clause;
3618 procedure Set_Has_Constrained_Partial_View (Id : E; V : B := True) is
3620 pragma Assert (Is_Type (Id));
3621 Set_Flag187 (Id, V);
3622 end Set_Has_Constrained_Partial_View;
3624 procedure Set_Has_Contiguous_Rep (Id : E; V : B := True) is
3626 Set_Flag181 (Id, V);
3627 end Set_Has_Contiguous_Rep;
3629 procedure Set_Has_Controlled_Component (Id : E; V : B := True) is
3631 pragma Assert (Id = Base_Type (Id));
3633 end Set_Has_Controlled_Component;
3635 procedure Set_Has_Controlling_Result (Id : E; V : B := True) is
3638 end Set_Has_Controlling_Result;
3640 procedure Set_Has_Convention_Pragma (Id : E; V : B := True) is
3642 Set_Flag119 (Id, V);
3643 end Set_Has_Convention_Pragma;
3645 procedure Set_Has_Delayed_Freeze (Id : E; V : B := True) is
3647 pragma Assert (Nkind (Id) in N_Entity);
3649 end Set_Has_Delayed_Freeze;
3651 procedure Set_Has_Discriminants (Id : E; V : B := True) is
3653 pragma Assert (Nkind (Id) in N_Entity);
3655 end Set_Has_Discriminants;
3657 procedure Set_Has_Dispatch_Table (Id : E; V : B := True) is
3659 pragma Assert (Ekind (Id) = E_Record_Type
3660 and then Is_Tagged_Type (Id));
3661 Set_Flag220 (Id, V);
3662 end Set_Has_Dispatch_Table;
3664 procedure Set_Has_Enumeration_Rep_Clause (Id : E; V : B := True) is
3666 pragma Assert (Is_Enumeration_Type (Id));
3668 end Set_Has_Enumeration_Rep_Clause;
3670 procedure Set_Has_Exit (Id : E; V : B := True) is
3675 procedure Set_Has_External_Tag_Rep_Clause (Id : E; V : B := True) is
3677 pragma Assert (Is_Tagged_Type (Id));
3678 Set_Flag110 (Id, V);
3679 end Set_Has_External_Tag_Rep_Clause;
3681 procedure Set_Has_Forward_Instantiation (Id : E; V : B := True) is
3683 Set_Flag175 (Id, V);
3684 end Set_Has_Forward_Instantiation;
3686 procedure Set_Has_Fully_Qualified_Name (Id : E; V : B := True) is
3688 Set_Flag173 (Id, V);
3689 end Set_Has_Fully_Qualified_Name;
3691 procedure Set_Has_Gigi_Rep_Item (Id : E; V : B := True) is
3694 end Set_Has_Gigi_Rep_Item;
3696 procedure Set_Has_Homonym (Id : E; V : B := True) is
3699 end Set_Has_Homonym;
3701 procedure Set_Has_Initial_Value (Id : E; V : B := True) is
3704 (Ekind (Id) = E_Variable or else Ekind (Id) = E_Out_Parameter);
3705 Set_Flag219 (Id, V);
3706 end Set_Has_Initial_Value;
3708 procedure Set_Has_Machine_Radix_Clause (Id : E; V : B := True) is
3710 pragma Assert (Is_Decimal_Fixed_Point_Type (Id));
3712 end Set_Has_Machine_Radix_Clause;
3714 procedure Set_Has_Master_Entity (Id : E; V : B := True) is
3717 end Set_Has_Master_Entity;
3719 procedure Set_Has_Missing_Return (Id : E; V : B := True) is
3722 (Ekind (Id) = E_Function or else Ekind (Id) = E_Generic_Function);
3723 Set_Flag142 (Id, V);
3724 end Set_Has_Missing_Return;
3726 procedure Set_Has_Nested_Block_With_Handler (Id : E; V : B := True) is
3728 Set_Flag101 (Id, V);
3729 end Set_Has_Nested_Block_With_Handler;
3731 procedure Set_Has_Up_Level_Access (Id : E; V : B := True) is
3734 (Ekind (Id) = E_Variable
3735 or else Ekind (Id) = E_Constant
3736 or else Ekind (Id) = E_Loop_Parameter);
3737 Set_Flag215 (Id, V);
3738 end Set_Has_Up_Level_Access;
3740 procedure Set_Has_Non_Standard_Rep (Id : E; V : B := True) is
3742 pragma Assert (Id = Base_Type (Id));
3744 end Set_Has_Non_Standard_Rep;
3746 procedure Set_Has_Object_Size_Clause (Id : E; V : B := True) is
3748 pragma Assert (Is_Type (Id));
3749 Set_Flag172 (Id, V);
3750 end Set_Has_Object_Size_Clause;
3752 procedure Set_Has_Per_Object_Constraint (Id : E; V : B := True) is
3754 Set_Flag154 (Id, V);
3755 end Set_Has_Per_Object_Constraint;
3757 procedure Set_Has_Persistent_BSS (Id : E; V : B := True) is
3759 Set_Flag188 (Id, V);
3760 end Set_Has_Persistent_BSS;
3762 procedure Set_Has_Postconditions (Id : E; V : B := True) is
3764 pragma Assert (Is_Subprogram (Id));
3765 Set_Flag240 (Id, V);
3766 end Set_Has_Postconditions;
3768 procedure Set_Has_Pragma_Controlled (Id : E; V : B := True) is
3770 pragma Assert (Is_Access_Type (Id));
3771 Set_Flag27 (Base_Type (Id), V);
3772 end Set_Has_Pragma_Controlled;
3774 procedure Set_Has_Pragma_Elaborate_Body (Id : E; V : B := True) is
3776 Set_Flag150 (Id, V);
3777 end Set_Has_Pragma_Elaborate_Body;
3779 procedure Set_Has_Pragma_Inline (Id : E; V : B := True) is
3781 Set_Flag157 (Id, V);
3782 end Set_Has_Pragma_Inline;
3784 procedure Set_Has_Pragma_Inline_Always (Id : E; V : B := True) is
3786 Set_Flag230 (Id, V);
3787 end Set_Has_Pragma_Inline_Always;
3789 procedure Set_Has_Pragma_Pack (Id : E; V : B := True) is
3791 pragma Assert (Is_Array_Type (Id) or else Is_Record_Type (Id));
3792 pragma Assert (Id = Base_Type (Id));
3793 Set_Flag121 (Id, V);
3794 end Set_Has_Pragma_Pack;
3796 procedure Set_Has_Pragma_Preelab_Init (Id : E; V : B := True) is
3798 Set_Flag221 (Id, V);
3799 end Set_Has_Pragma_Preelab_Init;
3801 procedure Set_Has_Pragma_Pure (Id : E; V : B := True) is
3803 Set_Flag203 (Id, V);
3804 end Set_Has_Pragma_Pure;
3806 procedure Set_Has_Pragma_Pure_Function (Id : E; V : B := True) is
3808 Set_Flag179 (Id, V);
3809 end Set_Has_Pragma_Pure_Function;
3811 procedure Set_Has_Pragma_Thread_Local_Storage (Id : E; V : B := True) is
3813 Set_Flag169 (Id, V);
3814 end Set_Has_Pragma_Thread_Local_Storage;
3816 procedure Set_Has_Pragma_Unmodified (Id : E; V : B := True) is
3818 Set_Flag233 (Id, V);
3819 end Set_Has_Pragma_Unmodified;
3821 procedure Set_Has_Pragma_Unreferenced (Id : E; V : B := True) is
3823 Set_Flag180 (Id, V);
3824 end Set_Has_Pragma_Unreferenced;
3826 procedure Set_Has_Pragma_Unreferenced_Objects (Id : E; V : B := True) is
3828 pragma Assert (Is_Type (Id));
3829 Set_Flag212 (Id, V);
3830 end Set_Has_Pragma_Unreferenced_Objects;
3832 procedure Set_Has_Primitive_Operations (Id : E; V : B := True) is
3834 pragma Assert (Id = Base_Type (Id));
3835 Set_Flag120 (Id, V);
3836 end Set_Has_Primitive_Operations;
3838 procedure Set_Has_Private_Declaration (Id : E; V : B := True) is
3840 Set_Flag155 (Id, V);
3841 end Set_Has_Private_Declaration;
3843 procedure Set_Has_Qualified_Name (Id : E; V : B := True) is
3845 Set_Flag161 (Id, V);
3846 end Set_Has_Qualified_Name;
3848 procedure Set_Has_RACW (Id : E; V : B := True) is
3850 pragma Assert (Ekind (Id) = E_Package);
3851 Set_Flag214 (Id, V);
3854 procedure Set_Has_Record_Rep_Clause (Id : E; V : B := True) is
3856 pragma Assert (Id = Base_Type (Id));
3858 end Set_Has_Record_Rep_Clause;
3860 procedure Set_Has_Recursive_Call (Id : E; V : B := True) is
3862 pragma Assert (Is_Subprogram (Id));
3863 Set_Flag143 (Id, V);
3864 end Set_Has_Recursive_Call;
3866 procedure Set_Has_Size_Clause (Id : E; V : B := True) is
3869 end Set_Has_Size_Clause;
3871 procedure Set_Has_Small_Clause (Id : E; V : B := True) is
3874 end Set_Has_Small_Clause;
3876 procedure Set_Has_Specified_Layout (Id : E; V : B := True) is
3878 pragma Assert (Id = Base_Type (Id));
3879 Set_Flag100 (Id, V);
3880 end Set_Has_Specified_Layout;
3882 procedure Set_Has_Specified_Stream_Input (Id : E; V : B := True) is
3884 pragma Assert (Is_Type (Id));
3885 Set_Flag190 (Id, V);
3886 end Set_Has_Specified_Stream_Input;
3888 procedure Set_Has_Specified_Stream_Output (Id : E; V : B := True) is
3890 pragma Assert (Is_Type (Id));
3891 Set_Flag191 (Id, V);
3892 end Set_Has_Specified_Stream_Output;
3894 procedure Set_Has_Specified_Stream_Read (Id : E; V : B := True) is
3896 pragma Assert (Is_Type (Id));
3897 Set_Flag192 (Id, V);
3898 end Set_Has_Specified_Stream_Read;
3900 procedure Set_Has_Specified_Stream_Write (Id : E; V : B := True) is
3902 pragma Assert (Is_Type (Id));
3903 Set_Flag193 (Id, V);
3904 end Set_Has_Specified_Stream_Write;
3906 procedure Set_Has_Static_Discriminants (Id : E; V : B := True) is
3908 Set_Flag211 (Id, V);
3909 end Set_Has_Static_Discriminants;
3911 procedure Set_Has_Storage_Size_Clause (Id : E; V : B := True) is
3913 pragma Assert (Is_Access_Type (Id) or else Is_Task_Type (Id));
3914 pragma Assert (Id = Base_Type (Id));
3916 end Set_Has_Storage_Size_Clause;
3918 procedure Set_Has_Stream_Size_Clause (Id : E; V : B := True) is
3920 pragma Assert (Is_Elementary_Type (Id));
3921 Set_Flag184 (Id, V);
3922 end Set_Has_Stream_Size_Clause;
3924 procedure Set_Has_Subprogram_Descriptor (Id : E; V : B := True) is
3927 end Set_Has_Subprogram_Descriptor;
3929 procedure Set_Has_Task (Id : E; V : B := True) is
3931 pragma Assert (Id = Base_Type (Id));
3935 procedure Set_Has_Thunks (Id : E; V : B := True) is
3937 pragma Assert (Is_Tag (Id)
3938 and then Ekind (Id) = E_Constant);
3939 Set_Flag228 (Id, V);
3942 procedure Set_Has_Unchecked_Union (Id : E; V : B := True) is
3944 pragma Assert (Id = Base_Type (Id));
3945 Set_Flag123 (Id, V);
3946 end Set_Has_Unchecked_Union;
3948 procedure Set_Has_Unknown_Discriminants (Id : E; V : B := True) is
3950 pragma Assert (Is_Type (Id));
3952 end Set_Has_Unknown_Discriminants;
3954 procedure Set_Has_Volatile_Components (Id : E; V : B := True) is
3956 pragma Assert (not Is_Type (Id) or else Id = Base_Type (Id));
3958 end Set_Has_Volatile_Components;
3960 procedure Set_Has_Xref_Entry (Id : E; V : B := True) is
3962 Set_Flag182 (Id, V);
3963 end Set_Has_Xref_Entry;
3965 procedure Set_Hiding_Loop_Variable (Id : E; V : E) is
3967 pragma Assert (Ekind (Id) = E_Variable);
3969 end Set_Hiding_Loop_Variable;
3971 procedure Set_Homonym (Id : E; V : E) is
3973 pragma Assert (Id /= V);
3977 procedure Set_Implemented_By_Entry (Id : E; V : B := True) is
3980 (Ekind (Id) = E_Function
3981 or else Ekind (Id) = E_Procedure);
3982 Set_Flag232 (Id, V);
3983 end Set_Implemented_By_Entry;
3985 procedure Set_Interfaces (Id : E; V : L) is
3987 pragma Assert (Is_Record_Type (Id));
3988 Set_Elist25 (Id, V);
3991 procedure Set_Interface_Alias (Id : E; V : E) is
3995 and then Is_Hidden (Id)
3996 and then (Ekind (Id) = E_Procedure
3997 or else Ekind (Id) = E_Function));
3999 end Set_Interface_Alias;
4001 procedure Set_In_Package_Body (Id : E; V : B := True) is
4004 end Set_In_Package_Body;
4006 procedure Set_In_Private_Part (Id : E; V : B := True) is
4009 end Set_In_Private_Part;
4011 procedure Set_In_Use (Id : E; V : B := True) is
4013 pragma Assert (Nkind (Id) in N_Entity);
4017 procedure Set_Inner_Instances (Id : E; V : L) is
4019 Set_Elist23 (Id, V);
4020 end Set_Inner_Instances;
4022 procedure Set_Interface_Name (Id : E; V : N) is
4025 end Set_Interface_Name;
4027 procedure Set_Is_Abstract_Subprogram (Id : E; V : B := True) is
4029 pragma Assert (Is_Overloadable (Id));
4031 end Set_Is_Abstract_Subprogram;
4033 procedure Set_Is_Abstract_Type (Id : E; V : B := True) is
4035 pragma Assert (Is_Type (Id));
4036 Set_Flag146 (Id, V);
4037 end Set_Is_Abstract_Type;
4039 procedure Set_Is_Local_Anonymous_Access (Id : E; V : B := True) is
4041 pragma Assert (Is_Access_Type (Id));
4042 Set_Flag194 (Id, V);
4043 end Set_Is_Local_Anonymous_Access;
4045 procedure Set_Is_Access_Constant (Id : E; V : B := True) is
4047 pragma Assert (Is_Access_Type (Id));
4049 end Set_Is_Access_Constant;
4051 procedure Set_Is_Ada_2005_Only (Id : E; V : B := True) is
4053 Set_Flag185 (Id, V);
4054 end Set_Is_Ada_2005_Only;
4056 procedure Set_Is_Aliased (Id : E; V : B := True) is
4058 pragma Assert (Nkind (Id) in N_Entity);
4062 procedure Set_Is_AST_Entry (Id : E; V : B := True) is
4064 pragma Assert (Is_Entry (Id));
4065 Set_Flag132 (Id, V);
4066 end Set_Is_AST_Entry;
4068 procedure Set_Is_Asynchronous (Id : E; V : B := True) is
4071 (Ekind (Id) = E_Procedure or else Is_Type (Id));
4073 end Set_Is_Asynchronous;
4075 procedure Set_Is_Atomic (Id : E; V : B := True) is
4080 procedure Set_Is_Bit_Packed_Array (Id : E; V : B := True) is
4082 pragma Assert ((not V)
4083 or else (Is_Array_Type (Id) and then Id = Base_Type (Id)));
4085 Set_Flag122 (Id, V);
4086 end Set_Is_Bit_Packed_Array;
4088 procedure Set_Is_Called (Id : E; V : B := True) is
4091 (Ekind (Id) = E_Procedure or else Ekind (Id) = E_Function);
4092 Set_Flag102 (Id, V);
4095 procedure Set_Is_Character_Type (Id : E; V : B := True) is
4098 end Set_Is_Character_Type;
4100 procedure Set_Is_Child_Unit (Id : E; V : B := True) is
4103 end Set_Is_Child_Unit;
4105 procedure Set_Is_Class_Wide_Equivalent_Type (Id : E; V : B := True) is
4108 end Set_Is_Class_Wide_Equivalent_Type;
4110 procedure Set_Is_Compilation_Unit (Id : E; V : B := True) is
4112 Set_Flag149 (Id, V);
4113 end Set_Is_Compilation_Unit;
4115 procedure Set_Is_Completely_Hidden (Id : E; V : B := True) is
4117 pragma Assert (Ekind (Id) = E_Discriminant);
4118 Set_Flag103 (Id, V);
4119 end Set_Is_Completely_Hidden;
4121 procedure Set_Is_Concurrent_Record_Type (Id : E; V : B := True) is
4124 end Set_Is_Concurrent_Record_Type;
4126 procedure Set_Is_Constr_Subt_For_U_Nominal (Id : E; V : B := True) is
4129 end Set_Is_Constr_Subt_For_U_Nominal;
4131 procedure Set_Is_Constr_Subt_For_UN_Aliased (Id : E; V : B := True) is
4133 Set_Flag141 (Id, V);
4134 end Set_Is_Constr_Subt_For_UN_Aliased;
4136 procedure Set_Is_Constrained (Id : E; V : B := True) is
4138 pragma Assert (Nkind (Id) in N_Entity);
4140 end Set_Is_Constrained;
4142 procedure Set_Is_Constructor (Id : E; V : B := True) is
4145 end Set_Is_Constructor;
4147 procedure Set_Is_Controlled (Id : E; V : B := True) is
4149 pragma Assert (Id = Base_Type (Id));
4151 end Set_Is_Controlled;
4153 procedure Set_Is_Controlling_Formal (Id : E; V : B := True) is
4155 pragma Assert (Is_Formal (Id));
4157 end Set_Is_Controlling_Formal;
4159 procedure Set_Is_CPP_Class (Id : E; V : B := True) is
4162 end Set_Is_CPP_Class;
4164 procedure Set_Is_Descendent_Of_Address (Id : E; V : B := True) is
4166 pragma Assert (Is_Type (Id));
4167 Set_Flag223 (Id, V);
4168 end Set_Is_Descendent_Of_Address;
4170 procedure Set_Is_Discrim_SO_Function (Id : E; V : B := True) is
4172 Set_Flag176 (Id, V);
4173 end Set_Is_Discrim_SO_Function;
4175 procedure Set_Is_Dispatch_Table_Entity (Id : E; V : B := True) is
4177 Set_Flag234 (Id, V);
4178 end Set_Is_Dispatch_Table_Entity;
4180 procedure Set_Is_Dispatching_Operation (Id : E; V : B := True) is
4185 Is_Overloadable (Id)
4187 Ekind (Id) = E_Subprogram_Type);
4190 end Set_Is_Dispatching_Operation;
4192 procedure Set_Is_Eliminated (Id : E; V : B := True) is
4194 Set_Flag124 (Id, V);
4195 end Set_Is_Eliminated;
4197 procedure Set_Is_Entry_Formal (Id : E; V : B := True) is
4200 end Set_Is_Entry_Formal;
4202 procedure Set_Is_Exported (Id : E; V : B := True) is
4205 end Set_Is_Exported;
4207 procedure Set_Is_First_Subtype (Id : E; V : B := True) is
4210 end Set_Is_First_Subtype;
4212 procedure Set_Is_For_Access_Subtype (Id : E; V : B := True) is
4215 (Ekind (Id) = E_Record_Subtype
4217 Ekind (Id) = E_Private_Subtype);
4218 Set_Flag118 (Id, V);
4219 end Set_Is_For_Access_Subtype;
4221 procedure Set_Is_Formal_Subprogram (Id : E; V : B := True) is
4223 Set_Flag111 (Id, V);
4224 end Set_Is_Formal_Subprogram;
4226 procedure Set_Is_Frozen (Id : E; V : B := True) is
4228 pragma Assert (Nkind (Id) in N_Entity);
4232 procedure Set_Is_Generic_Actual_Type (Id : E; V : B := True) is
4234 pragma Assert (Is_Type (Id));
4236 end Set_Is_Generic_Actual_Type;
4238 procedure Set_Is_Generic_Instance (Id : E; V : B := True) is
4240 Set_Flag130 (Id, V);
4241 end Set_Is_Generic_Instance;
4243 procedure Set_Is_Generic_Type (Id : E; V : B := True) is
4245 pragma Assert (Nkind (Id) in N_Entity);
4247 end Set_Is_Generic_Type;
4249 procedure Set_Is_Hidden (Id : E; V : B := True) is
4254 procedure Set_Is_Hidden_Open_Scope (Id : E; V : B := True) is
4256 Set_Flag171 (Id, V);
4257 end Set_Is_Hidden_Open_Scope;
4259 procedure Set_Is_Immediately_Visible (Id : E; V : B := True) is
4261 pragma Assert (Nkind (Id) in N_Entity);
4263 end Set_Is_Immediately_Visible;
4265 procedure Set_Is_Imported (Id : E; V : B := True) is
4268 end Set_Is_Imported;
4270 procedure Set_Is_Inlined (Id : E; V : B := True) is
4275 procedure Set_Is_Interface (Id : E; V : B := True) is
4278 (Ekind (Id) = E_Record_Type
4279 or else Ekind (Id) = E_Record_Subtype
4280 or else Ekind (Id) = E_Record_Type_With_Private
4281 or else Ekind (Id) = E_Record_Subtype_With_Private
4282 or else Ekind (Id) = E_Class_Wide_Type
4283 or else Ekind (Id) = E_Class_Wide_Subtype);
4284 Set_Flag186 (Id, V);
4285 end Set_Is_Interface;
4287 procedure Set_Is_Instantiated (Id : E; V : B := True) is
4289 Set_Flag126 (Id, V);
4290 end Set_Is_Instantiated;
4292 procedure Set_Is_Internal (Id : E; V : B := True) is
4294 pragma Assert (Nkind (Id) in N_Entity);
4296 end Set_Is_Internal;
4298 procedure Set_Is_Interrupt_Handler (Id : E; V : B := True) is
4300 pragma Assert (Nkind (Id) in N_Entity);
4302 end Set_Is_Interrupt_Handler;
4304 procedure Set_Is_Intrinsic_Subprogram (Id : E; V : B := True) is
4307 end Set_Is_Intrinsic_Subprogram;
4309 procedure Set_Is_Itype (Id : E; V : B := True) is
4314 procedure Set_Is_Known_Non_Null (Id : E; V : B := True) is
4317 end Set_Is_Known_Non_Null;
4319 procedure Set_Is_Known_Null (Id : E; V : B := True) is
4321 Set_Flag204 (Id, V);
4322 end Set_Is_Known_Null;
4324 procedure Set_Is_Known_Valid (Id : E; V : B := True) is
4326 Set_Flag170 (Id, V);
4327 end Set_Is_Known_Valid;
4329 procedure Set_Is_Limited_Composite (Id : E; V : B := True) is
4331 pragma Assert (Is_Type (Id));
4332 Set_Flag106 (Id, V);
4333 end Set_Is_Limited_Composite;
4335 procedure Set_Is_Limited_Interface (Id : E; V : B := True) is
4337 pragma Assert (Is_Interface (Id));
4338 Set_Flag197 (Id, V);
4339 end Set_Is_Limited_Interface;
4341 procedure Set_Is_Limited_Record (Id : E; V : B := True) is
4344 end Set_Is_Limited_Record;
4346 procedure Set_Is_Machine_Code_Subprogram (Id : E; V : B := True) is
4348 pragma Assert (Is_Subprogram (Id));
4349 Set_Flag137 (Id, V);
4350 end Set_Is_Machine_Code_Subprogram;
4352 procedure Set_Is_Non_Static_Subtype (Id : E; V : B := True) is
4354 pragma Assert (Is_Type (Id));
4355 Set_Flag109 (Id, V);
4356 end Set_Is_Non_Static_Subtype;
4358 procedure Set_Is_Null_Init_Proc (Id : E; V : B := True) is
4360 pragma Assert (Ekind (Id) = E_Procedure);
4361 Set_Flag178 (Id, V);
4362 end Set_Is_Null_Init_Proc;
4364 procedure Set_Is_Obsolescent (Id : E; V : B := True) is
4366 Set_Flag153 (Id, V);
4367 end Set_Is_Obsolescent;
4369 procedure Set_Is_Only_Out_Parameter (Id : E; V : B := True) is
4371 pragma Assert (Ekind (Id) = E_Out_Parameter);
4372 Set_Flag226 (Id, V);
4373 end Set_Is_Only_Out_Parameter;
4375 procedure Set_Is_Optional_Parameter (Id : E; V : B := True) is
4377 pragma Assert (Is_Formal (Id));
4378 Set_Flag134 (Id, V);
4379 end Set_Is_Optional_Parameter;
4381 procedure Set_Is_Overriding_Operation (Id : E; V : B := True) is
4383 pragma Assert (Is_Subprogram (Id));
4385 end Set_Is_Overriding_Operation;
4387 procedure Set_Is_Package_Body_Entity (Id : E; V : B := True) is
4389 Set_Flag160 (Id, V);
4390 end Set_Is_Package_Body_Entity;
4392 procedure Set_Is_Packed (Id : E; V : B := True) is
4394 pragma Assert (Id = Base_Type (Id));
4398 procedure Set_Is_Packed_Array_Type (Id : E; V : B := True) is
4400 Set_Flag138 (Id, V);
4401 end Set_Is_Packed_Array_Type;
4403 procedure Set_Is_Potentially_Use_Visible (Id : E; V : B := True) is
4405 pragma Assert (Nkind (Id) in N_Entity);
4407 end Set_Is_Potentially_Use_Visible;
4409 procedure Set_Is_Preelaborated (Id : E; V : B := True) is
4412 end Set_Is_Preelaborated;
4414 procedure Set_Is_Primitive (Id : E; V : B := True) is
4417 (Is_Overloadable (Id)
4418 or else Ekind (Id) = E_Generic_Function
4419 or else Ekind (Id) = E_Generic_Procedure);
4420 Set_Flag218 (Id, V);
4421 end Set_Is_Primitive;
4423 procedure Set_Is_Primitive_Wrapper (Id : E; V : B := True) is
4425 pragma Assert (Ekind (Id) = E_Function
4426 or else Ekind (Id) = E_Procedure);
4427 Set_Flag195 (Id, V);
4428 end Set_Is_Primitive_Wrapper;
4430 procedure Set_Is_Private_Composite (Id : E; V : B := True) is
4432 pragma Assert (Is_Type (Id));
4433 Set_Flag107 (Id, V);
4434 end Set_Is_Private_Composite;
4436 procedure Set_Is_Private_Descendant (Id : E; V : B := True) is
4439 end Set_Is_Private_Descendant;
4441 procedure Set_Is_Private_Primitive (Id : E; V : B := True) is
4443 pragma Assert (Ekind (Id) = E_Function
4444 or else Ekind (Id) = E_Procedure);
4445 Set_Flag245 (Id, V);
4446 end Set_Is_Private_Primitive;
4448 procedure Set_Is_Protected_Interface (Id : E; V : B := True) is
4450 pragma Assert (Is_Interface (Id));
4451 Set_Flag198 (Id, V);
4452 end Set_Is_Protected_Interface;
4454 procedure Set_Is_Public (Id : E; V : B := True) is
4456 pragma Assert (Nkind (Id) in N_Entity);
4460 procedure Set_Is_Pure (Id : E; V : B := True) is
4465 procedure Set_Is_Pure_Unit_Access_Type (Id : E; V : B := True) is
4467 pragma Assert (Is_Access_Type (Id));
4468 Set_Flag189 (Id, V);
4469 end Set_Is_Pure_Unit_Access_Type;
4471 procedure Set_Is_RACW_Stub_Type (Id : E; V : B := True) is
4473 pragma Assert (Is_Type (Id));
4474 Set_Flag244 (Id, V);
4475 end Set_Is_RACW_Stub_Type;
4477 procedure Set_Is_Raised (Id : E; V : B := True) is
4479 pragma Assert (Ekind (Id) = E_Exception);
4480 Set_Flag224 (Id, V);
4483 procedure Set_Is_Remote_Call_Interface (Id : E; V : B := True) is
4486 end Set_Is_Remote_Call_Interface;
4488 procedure Set_Is_Remote_Types (Id : E; V : B := True) is
4491 end Set_Is_Remote_Types;
4493 procedure Set_Is_Renaming_Of_Object (Id : E; V : B := True) is
4495 Set_Flag112 (Id, V);
4496 end Set_Is_Renaming_Of_Object;
4498 procedure Set_Is_Return_Object (Id : E; V : B := True) is
4500 Set_Flag209 (Id, V);
4501 end Set_Is_Return_Object;
4503 procedure Set_Is_Shared_Passive (Id : E; V : B := True) is
4506 end Set_Is_Shared_Passive;
4508 procedure Set_Is_Statically_Allocated (Id : E; V : B := True) is
4511 (Ekind (Id) = E_Exception
4512 or else Ekind (Id) = E_Variable
4513 or else Ekind (Id) = E_Constant
4514 or else Is_Type (Id)
4515 or else Ekind (Id) = E_Void);
4517 end Set_Is_Statically_Allocated;
4519 procedure Set_Is_Synchronized_Interface (Id : E; V : B := True) is
4521 pragma Assert (Is_Interface (Id));
4522 Set_Flag199 (Id, V);
4523 end Set_Is_Synchronized_Interface;
4525 procedure Set_Is_Tag (Id : E; V : B := True) is
4528 (Ekind (Id) = E_Component
4529 or else Ekind (Id) = E_Constant);
4533 procedure Set_Is_Tagged_Type (Id : E; V : B := True) is
4536 end Set_Is_Tagged_Type;
4538 procedure Set_Is_Task_Interface (Id : E; V : B := True) is
4540 pragma Assert (Is_Interface (Id));
4541 Set_Flag200 (Id, V);
4542 end Set_Is_Task_Interface;
4544 procedure Set_Is_Thunk (Id : E; V : B := True) is
4546 Set_Flag225 (Id, V);
4549 procedure Set_Is_Trivial_Subprogram (Id : E; V : B := True) is
4551 Set_Flag235 (Id, V);
4552 end Set_Is_Trivial_Subprogram;
4554 procedure Set_Is_True_Constant (Id : E; V : B := True) is
4556 Set_Flag163 (Id, V);
4557 end Set_Is_True_Constant;
4559 procedure Set_Is_Unchecked_Union (Id : E; V : B := True) is
4561 pragma Assert (Id = Base_Type (Id));
4562 Set_Flag117 (Id, V);
4563 end Set_Is_Unchecked_Union;
4565 procedure Set_Is_Underlying_Record_View (Id : E; V : B := True) is
4567 pragma Assert (Ekind (Id) = E_Record_Type);
4568 Set_Flag246 (Id, V);
4569 end Set_Is_Underlying_Record_View;
4571 procedure Set_Is_Unsigned_Type (Id : E; V : B := True) is
4573 pragma Assert (Is_Discrete_Or_Fixed_Point_Type (Id));
4574 Set_Flag144 (Id, V);
4575 end Set_Is_Unsigned_Type;
4577 procedure Set_Is_Valued_Procedure (Id : E; V : B := True) is
4579 pragma Assert (Ekind (Id) = E_Procedure);
4580 Set_Flag127 (Id, V);
4581 end Set_Is_Valued_Procedure;
4583 procedure Set_Is_Visible_Child_Unit (Id : E; V : B := True) is
4585 pragma Assert (Is_Child_Unit (Id));
4586 Set_Flag116 (Id, V);
4587 end Set_Is_Visible_Child_Unit;
4589 procedure Set_Is_Visible_Formal (Id : E; V : B := True) is
4591 Set_Flag206 (Id, V);
4592 end Set_Is_Visible_Formal;
4594 procedure Set_Is_VMS_Exception (Id : E; V : B := True) is
4596 pragma Assert (Ekind (Id) = E_Exception);
4597 Set_Flag133 (Id, V);
4598 end Set_Is_VMS_Exception;
4600 procedure Set_Is_Volatile (Id : E; V : B := True) is
4602 pragma Assert (Nkind (Id) in N_Entity);
4604 end Set_Is_Volatile;
4606 procedure Set_Itype_Printed (Id : E; V : B := True) is
4608 pragma Assert (Is_Itype (Id));
4609 Set_Flag202 (Id, V);
4610 end Set_Itype_Printed;
4612 procedure Set_Kill_Elaboration_Checks (Id : E; V : B := True) is
4615 end Set_Kill_Elaboration_Checks;
4617 procedure Set_Kill_Range_Checks (Id : E; V : B := True) is
4620 end Set_Kill_Range_Checks;
4622 procedure Set_Kill_Tag_Checks (Id : E; V : B := True) is
4625 end Set_Kill_Tag_Checks;
4627 procedure Set_Known_To_Have_Preelab_Init (Id : E; V : B := True) is
4629 pragma Assert (Is_Type (Id));
4630 Set_Flag207 (Id, V);
4631 end Set_Known_To_Have_Preelab_Init;
4633 procedure Set_Last_Assignment (Id : E; V : N) is
4635 pragma Assert (Is_Assignable (Id));
4637 end Set_Last_Assignment;
4639 procedure Set_Last_Entity (Id : E; V : E) is
4642 end Set_Last_Entity;
4644 procedure Set_Limited_View (Id : E; V : E) is
4646 pragma Assert (Ekind (Id) = E_Package);
4648 end Set_Limited_View;
4650 procedure Set_Lit_Indexes (Id : E; V : E) is
4652 pragma Assert (Is_Enumeration_Type (Id) and then Root_Type (Id) = Id);
4654 end Set_Lit_Indexes;
4656 procedure Set_Lit_Strings (Id : E; V : E) is
4658 pragma Assert (Is_Enumeration_Type (Id) and then Root_Type (Id) = Id);
4660 end Set_Lit_Strings;
4662 procedure Set_Low_Bound_Tested (Id : E; V : B := True) is
4664 pragma Assert (Is_Formal (Id));
4665 Set_Flag205 (Id, V);
4666 end Set_Low_Bound_Tested;
4668 procedure Set_Machine_Radix_10 (Id : E; V : B := True) is
4670 pragma Assert (Is_Decimal_Fixed_Point_Type (Id));
4672 end Set_Machine_Radix_10;
4674 procedure Set_Master_Id (Id : E; V : E) is
4676 pragma Assert (Is_Access_Type (Id));
4680 procedure Set_Materialize_Entity (Id : E; V : B := True) is
4682 Set_Flag168 (Id, V);
4683 end Set_Materialize_Entity;
4685 procedure Set_Mechanism (Id : E; V : M) is
4687 pragma Assert (Ekind (Id) = E_Function or else Is_Formal (Id));
4688 Set_Uint8 (Id, UI_From_Int (V));
4691 procedure Set_Modulus (Id : E; V : U) is
4693 pragma Assert (Ekind (Id) = E_Modular_Integer_Type);
4697 procedure Set_Must_Be_On_Byte_Boundary (Id : E; V : B := True) is
4699 pragma Assert (Is_Type (Id));
4700 Set_Flag183 (Id, V);
4701 end Set_Must_Be_On_Byte_Boundary;
4703 procedure Set_Must_Have_Preelab_Init (Id : E; V : B := True) is
4705 pragma Assert (Is_Type (Id));
4706 Set_Flag208 (Id, V);
4707 end Set_Must_Have_Preelab_Init;
4709 procedure Set_Needs_Debug_Info (Id : E; V : B := True) is
4711 Set_Flag147 (Id, V);
4712 end Set_Needs_Debug_Info;
4714 procedure Set_Needs_No_Actuals (Id : E; V : B := True) is
4717 (Is_Overloadable (Id)
4718 or else Ekind (Id) = E_Subprogram_Type
4719 or else Ekind (Id) = E_Entry_Family);
4721 end Set_Needs_No_Actuals;
4723 procedure Set_Never_Set_In_Source (Id : E; V : B := True) is
4725 Set_Flag115 (Id, V);
4726 end Set_Never_Set_In_Source;
4728 procedure Set_Next_Inlined_Subprogram (Id : E; V : E) is
4731 end Set_Next_Inlined_Subprogram;
4733 procedure Set_No_Pool_Assigned (Id : E; V : B := True) is
4735 pragma Assert (Is_Access_Type (Id) and then Id = Base_Type (Id));
4736 Set_Flag131 (Id, V);
4737 end Set_No_Pool_Assigned;
4739 procedure Set_No_Return (Id : E; V : B := True) is
4743 or else Ekind (Id) = E_Procedure
4744 or else Ekind (Id) = E_Generic_Procedure);
4745 Set_Flag113 (Id, V);
4748 procedure Set_No_Strict_Aliasing (Id : E; V : B := True) is
4750 pragma Assert (Is_Access_Type (Id) and then Id = Base_Type (Id));
4751 Set_Flag136 (Id, V);
4752 end Set_No_Strict_Aliasing;
4754 procedure Set_Non_Binary_Modulus (Id : E; V : B := True) is
4756 pragma Assert (Is_Type (Id) and then Id = Base_Type (Id));
4758 end Set_Non_Binary_Modulus;
4760 procedure Set_Non_Limited_View (Id : E; V : E) is
4762 pragma Assert (Ekind (Id) in Incomplete_Kind);
4764 end Set_Non_Limited_View;
4766 procedure Set_Nonzero_Is_True (Id : E; V : B := True) is
4769 (Root_Type (Id) = Standard_Boolean
4770 and then Ekind (Id) = E_Enumeration_Type);
4771 Set_Flag162 (Id, V);
4772 end Set_Nonzero_Is_True;
4774 procedure Set_Normalized_First_Bit (Id : E; V : U) is
4777 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
4779 end Set_Normalized_First_Bit;
4781 procedure Set_Normalized_Position (Id : E; V : U) is
4784 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
4786 end Set_Normalized_Position;
4788 procedure Set_Normalized_Position_Max (Id : E; V : U) is
4791 (Ekind (Id) = E_Component or else Ekind (Id) = E_Discriminant);
4793 end Set_Normalized_Position_Max;
4795 procedure Set_OK_To_Rename (Id : E; V : B := True) is
4797 pragma Assert (Ekind (Id) = E_Variable);
4798 Set_Flag247 (Id, V);
4799 end Set_OK_To_Rename;
4801 procedure Set_OK_To_Reorder_Components (Id : E; V : B := True) is
4804 (Is_Record_Type (Id) and then Id = Base_Type (Id));
4805 Set_Flag239 (Id, V);
4806 end Set_OK_To_Reorder_Components;
4808 procedure Set_Optimize_Alignment_Space (Id : E; V : B := True) is
4812 or else Ekind (Id) = E_Constant
4813 or else Ekind (Id) = E_Variable);
4814 Set_Flag241 (Id, V);
4815 end Set_Optimize_Alignment_Space;
4817 procedure Set_Optimize_Alignment_Time (Id : E; V : B := True) is
4821 or else Ekind (Id) = E_Constant
4822 or else Ekind (Id) = E_Variable);
4823 Set_Flag242 (Id, V);
4824 end Set_Optimize_Alignment_Time;
4826 procedure Set_Original_Array_Type (Id : E; V : E) is
4828 pragma Assert (Is_Array_Type (Id) or else Is_Modular_Integer_Type (Id));
4830 end Set_Original_Array_Type;
4832 procedure Set_Original_Record_Component (Id : E; V : E) is
4835 (Ekind (Id) = E_Void
4836 or else Ekind (Id) = E_Component
4837 or else Ekind (Id) = E_Discriminant);
4839 end Set_Original_Record_Component;
4841 procedure Set_Overlays_Constant (Id : E; V : B := True) is
4843 Set_Flag243 (Id, V);
4844 end Set_Overlays_Constant;
4846 procedure Set_Overridden_Operation (Id : E; V : E) is
4849 end Set_Overridden_Operation;
4851 procedure Set_Package_Instantiation (Id : E; V : N) is
4854 (Ekind (Id) = E_Void
4855 or else Ekind (Id) = E_Generic_Package
4856 or else Ekind (Id) = E_Package);
4858 end Set_Package_Instantiation;
4860 procedure Set_Packed_Array_Type (Id : E; V : E) is
4862 pragma Assert (Is_Array_Type (Id));
4864 end Set_Packed_Array_Type;
4866 procedure Set_Parent_Subtype (Id : E; V : E) is
4868 pragma Assert (Ekind (Id) = E_Record_Type);
4870 end Set_Parent_Subtype;
4872 procedure Set_Postcondition_Proc (Id : E; V : E) is
4874 pragma Assert (Ekind (Id) = E_Procedure);
4876 end Set_Postcondition_Proc;
4878 procedure Set_Primitive_Operations (Id : E; V : L) is
4880 pragma Assert (Is_Tagged_Type (Id));
4881 Set_Elist15 (Id, V);
4882 end Set_Primitive_Operations;
4884 procedure Set_Prival (Id : E; V : E) is
4886 pragma Assert (Is_Protected_Component (Id));
4890 procedure Set_Prival_Link (Id : E; V : E) is
4892 pragma Assert (Ekind (Id) = E_Constant
4893 or else Ekind (Id) = E_Variable);
4895 end Set_Prival_Link;
4897 procedure Set_Private_Dependents (Id : E; V : L) is
4899 pragma Assert (Is_Incomplete_Or_Private_Type (Id));
4900 Set_Elist18 (Id, V);
4901 end Set_Private_Dependents;
4903 procedure Set_Private_View (Id : E; V : N) is
4905 pragma Assert (Is_Private_Type (Id));
4907 end Set_Private_View;
4909 procedure Set_Protected_Body_Subprogram (Id : E; V : E) is
4911 pragma Assert (Is_Subprogram (Id) or else Is_Entry (Id));
4913 end Set_Protected_Body_Subprogram;
4915 procedure Set_Protected_Formal (Id : E; V : E) is
4917 pragma Assert (Is_Formal (Id));
4919 end Set_Protected_Formal;
4921 procedure Set_Protection_Object (Id : E; V : E) is
4923 pragma Assert (Ekind (Id) = E_Entry
4924 or else Ekind (Id) = E_Entry_Family
4925 or else Ekind (Id) = E_Function
4926 or else Ekind (Id) = E_Procedure);
4928 end Set_Protection_Object;
4930 procedure Set_Reachable (Id : E; V : B := True) is
4935 procedure Set_Referenced (Id : E; V : B := True) is
4937 Set_Flag156 (Id, V);
4940 procedure Set_Referenced_As_LHS (Id : E; V : B := True) is
4943 end Set_Referenced_As_LHS;
4945 procedure Set_Referenced_As_Out_Parameter (Id : E; V : B := True) is
4947 Set_Flag227 (Id, V);
4948 end Set_Referenced_As_Out_Parameter;
4950 procedure Set_Referenced_Object (Id : E; V : N) is
4952 pragma Assert (Is_Type (Id));
4954 end Set_Referenced_Object;
4956 procedure Set_Register_Exception_Call (Id : E; V : N) is
4958 pragma Assert (Ekind (Id) = E_Exception);
4960 end Set_Register_Exception_Call;
4962 procedure Set_Related_Array_Object (Id : E; V : E) is
4964 pragma Assert (Is_Array_Type (Id));
4966 end Set_Related_Array_Object;
4968 procedure Set_Related_Expression (Id : E; V : N) is
4971 end Set_Related_Expression;
4973 procedure Set_Related_Instance (Id : E; V : E) is
4976 (Ekind (Id) = E_Package or else Ekind (Id) = E_Package_Body);
4978 end Set_Related_Instance;
4980 procedure Set_Related_Type (Id : E; V : E) is
4983 (Ekind (Id) = E_Component or else Ekind (Id) = E_Constant);
4985 end Set_Related_Type;
4987 procedure Set_Relative_Deadline_Variable (Id : E; V : E) is
4989 pragma Assert (Is_Task_Type (Id) and then Id = Base_Type (Id));
4991 end Set_Relative_Deadline_Variable;
4993 procedure Set_Renamed_Entity (Id : E; V : N) is
4996 end Set_Renamed_Entity;
4998 procedure Set_Renamed_In_Spec (Id : E; V : B := True) is
5000 pragma Assert (Ekind (Id) = E_Package);
5001 Set_Flag231 (Id, V);
5002 end Set_Renamed_In_Spec;
5004 procedure Set_Renamed_Object (Id : E; V : N) is
5007 end Set_Renamed_Object;
5009 procedure Set_Renaming_Map (Id : E; V : U) is
5012 end Set_Renaming_Map;
5014 procedure Set_Requires_Overriding (Id : E; V : B := True) is
5016 pragma Assert (Is_Overloadable (Id));
5017 Set_Flag213 (Id, V);
5018 end Set_Requires_Overriding;
5020 procedure Set_Return_Present (Id : E; V : B := True) is
5023 end Set_Return_Present;
5025 procedure Set_Return_Applies_To (Id : E; V : N) is
5028 end Set_Return_Applies_To;
5030 procedure Set_Returns_By_Ref (Id : E; V : B := True) is
5033 end Set_Returns_By_Ref;
5035 procedure Set_Reverse_Bit_Order (Id : E; V : B := True) is
5038 (Is_Record_Type (Id) and then Id = Base_Type (Id));
5039 Set_Flag164 (Id, V);
5040 end Set_Reverse_Bit_Order;
5042 procedure Set_RM_Size (Id : E; V : U) is
5044 pragma Assert (Is_Type (Id));
5048 procedure Set_Scalar_Range (Id : E; V : N) is
5051 end Set_Scalar_Range;
5053 procedure Set_Scale_Value (Id : E; V : U) is
5056 end Set_Scale_Value;
5058 procedure Set_Scope_Depth_Value (Id : E; V : U) is
5060 pragma Assert (not Is_Record_Type (Id));
5062 end Set_Scope_Depth_Value;
5064 procedure Set_Sec_Stack_Needed_For_Return (Id : E; V : B := True) is
5066 Set_Flag167 (Id, V);
5067 end Set_Sec_Stack_Needed_For_Return;
5069 procedure Set_Shadow_Entities (Id : E; V : S) is
5072 (Ekind (Id) = E_Package or else Ekind (Id) = E_Generic_Package);
5074 end Set_Shadow_Entities;
5076 procedure Set_Shared_Var_Procs_Instance (Id : E; V : E) is
5078 pragma Assert (Ekind (Id) = E_Variable);
5080 end Set_Shared_Var_Procs_Instance;
5082 procedure Set_Size_Check_Code (Id : E; V : N) is
5084 pragma Assert (Ekind (Id) = E_Constant or else Ekind (Id) = E_Variable);
5086 end Set_Size_Check_Code;
5088 procedure Set_Size_Depends_On_Discriminant (Id : E; V : B := True) is
5090 Set_Flag177 (Id, V);
5091 end Set_Size_Depends_On_Discriminant;
5093 procedure Set_Size_Known_At_Compile_Time (Id : E; V : B := True) is
5096 end Set_Size_Known_At_Compile_Time;
5098 procedure Set_Small_Value (Id : E; V : R) is
5100 pragma Assert (Is_Fixed_Point_Type (Id));
5101 Set_Ureal21 (Id, V);
5102 end Set_Small_Value;
5104 procedure Set_Spec_Entity (Id : E; V : E) is
5106 pragma Assert (Ekind (Id) = E_Package_Body or else Is_Formal (Id));
5108 end Set_Spec_Entity;
5110 procedure Set_Spec_PPC_List (Id : E; V : N) is
5112 pragma Assert (Is_Subprogram (Id) or else Is_Generic_Subprogram (Id));
5114 end Set_Spec_PPC_List;
5116 procedure Set_Storage_Size_Variable (Id : E; V : E) is
5118 pragma Assert (Is_Access_Type (Id) or else Is_Task_Type (Id));
5119 pragma Assert (Id = Base_Type (Id));
5121 end Set_Storage_Size_Variable;
5123 procedure Set_Static_Elaboration_Desired (Id : E; V : B) is
5125 pragma Assert (Ekind (Id) = E_Package);
5127 end Set_Static_Elaboration_Desired;
5129 procedure Set_Static_Initialization (Id : E; V : N) is
5132 (Ekind (Id) = E_Procedure and then not Is_Dispatching_Operation (Id));
5134 end Set_Static_Initialization;
5136 procedure Set_Stored_Constraint (Id : E; V : L) is
5138 pragma Assert (Nkind (Id) in N_Entity);
5139 Set_Elist23 (Id, V);
5140 end Set_Stored_Constraint;
5142 procedure Set_Strict_Alignment (Id : E; V : B := True) is
5144 pragma Assert (Id = Base_Type (Id));
5145 Set_Flag145 (Id, V);
5146 end Set_Strict_Alignment;
5148 procedure Set_String_Literal_Length (Id : E; V : U) is
5150 pragma Assert (Ekind (Id) = E_String_Literal_Subtype);
5152 end Set_String_Literal_Length;
5154 procedure Set_String_Literal_Low_Bound (Id : E; V : N) is
5156 pragma Assert (Ekind (Id) = E_String_Literal_Subtype);
5158 end Set_String_Literal_Low_Bound;
5160 procedure Set_Suppress_Elaboration_Warnings (Id : E; V : B := True) is
5162 Set_Flag148 (Id, V);
5163 end Set_Suppress_Elaboration_Warnings;
5165 procedure Set_Suppress_Init_Proc (Id : E; V : B := True) is
5167 pragma Assert (Id = Base_Type (Id));
5168 Set_Flag105 (Id, V);
5169 end Set_Suppress_Init_Proc;
5171 procedure Set_Suppress_Style_Checks (Id : E; V : B := True) is
5173 Set_Flag165 (Id, V);
5174 end Set_Suppress_Style_Checks;
5176 procedure Set_Suppress_Value_Tracking_On_Call (Id : E; V : B := True) is
5178 Set_Flag217 (Id, V);
5179 end Set_Suppress_Value_Tracking_On_Call;
5181 procedure Set_Task_Body_Procedure (Id : E; V : N) is
5183 pragma Assert (Ekind (Id) in Task_Kind);
5185 end Set_Task_Body_Procedure;
5187 procedure Set_Treat_As_Volatile (Id : E; V : B := True) is
5190 end Set_Treat_As_Volatile;
5192 procedure Set_Underlying_Full_View (Id : E; V : E) is
5194 pragma Assert (Ekind (Id) in Private_Kind);
5196 end Set_Underlying_Full_View;
5198 procedure Set_Underlying_Record_View (Id : E; V : E) is
5200 pragma Assert (Ekind (Id) = E_Record_Type);
5202 end Set_Underlying_Record_View;
5204 procedure Set_Universal_Aliasing (Id : E; V : B := True) is
5206 pragma Assert (Is_Type (Id) and then Id = Base_Type (Id));
5207 Set_Flag216 (Id, V);
5208 end Set_Universal_Aliasing;
5210 procedure Set_Unset_Reference (Id : E; V : N) is
5213 end Set_Unset_Reference;
5215 procedure Set_Uses_Sec_Stack (Id : E; V : B := True) is
5218 end Set_Uses_Sec_Stack;
5220 procedure Set_Used_As_Generic_Actual (Id : E; V : B := True) is
5222 Set_Flag222 (Id, V);
5223 end Set_Used_As_Generic_Actual;
5225 procedure Set_Vax_Float (Id : E; V : B := True) is
5227 pragma Assert (Id = Base_Type (Id));
5228 Set_Flag151 (Id, V);
5231 procedure Set_Warnings_Off (Id : E; V : B := True) is
5234 end Set_Warnings_Off;
5236 procedure Set_Warnings_Off_Used (Id : E; V : B := True) is
5238 Set_Flag236 (Id, V);
5239 end Set_Warnings_Off_Used;
5241 procedure Set_Warnings_Off_Used_Unmodified (Id : E; V : B := True) is
5243 Set_Flag237 (Id, V);
5244 end Set_Warnings_Off_Used_Unmodified;
5246 procedure Set_Warnings_Off_Used_Unreferenced (Id : E; V : B := True) is
5248 Set_Flag238 (Id, V);
5249 end Set_Warnings_Off_Used_Unreferenced;
5251 procedure Set_Was_Hidden (Id : E; V : B := True) is
5253 Set_Flag196 (Id, V);
5256 procedure Set_Wrapped_Entity (Id : E; V : E) is
5258 pragma Assert ((Ekind (Id) = E_Function
5259 or else Ekind (Id) = E_Procedure)
5260 and then Is_Primitive_Wrapper (Id));
5262 end Set_Wrapped_Entity;
5264 -----------------------------------
5265 -- Field Initialization Routines --
5266 -----------------------------------
5268 procedure Init_Alignment (Id : E) is
5270 Set_Uint14 (Id, Uint_0);
5273 procedure Init_Alignment (Id : E; V : Int) is
5275 Set_Uint14 (Id, UI_From_Int (V));
5278 procedure Init_Component_Bit_Offset (Id : E) is
5280 Set_Uint11 (Id, No_Uint);
5281 end Init_Component_Bit_Offset;
5283 procedure Init_Component_Bit_Offset (Id : E; V : Int) is
5285 Set_Uint11 (Id, UI_From_Int (V));
5286 end Init_Component_Bit_Offset;
5288 procedure Init_Component_Size (Id : E) is
5290 Set_Uint22 (Id, Uint_0);
5291 end Init_Component_Size;
5293 procedure Init_Component_Size (Id : E; V : Int) is
5295 Set_Uint22 (Id, UI_From_Int (V));
5296 end Init_Component_Size;
5298 procedure Init_Digits_Value (Id : E) is
5300 Set_Uint17 (Id, Uint_0);
5301 end Init_Digits_Value;
5303 procedure Init_Digits_Value (Id : E; V : Int) is
5305 Set_Uint17 (Id, UI_From_Int (V));
5306 end Init_Digits_Value;
5308 procedure Init_Esize (Id : E) is
5310 Set_Uint12 (Id, Uint_0);
5313 procedure Init_Esize (Id : E; V : Int) is
5315 Set_Uint12 (Id, UI_From_Int (V));
5318 procedure Init_Normalized_First_Bit (Id : E) is
5320 Set_Uint8 (Id, No_Uint);
5321 end Init_Normalized_First_Bit;
5323 procedure Init_Normalized_First_Bit (Id : E; V : Int) is
5325 Set_Uint8 (Id, UI_From_Int (V));
5326 end Init_Normalized_First_Bit;
5328 procedure Init_Normalized_Position (Id : E) is
5330 Set_Uint14 (Id, No_Uint);
5331 end Init_Normalized_Position;
5333 procedure Init_Normalized_Position (Id : E; V : Int) is
5335 Set_Uint14 (Id, UI_From_Int (V));
5336 end Init_Normalized_Position;
5338 procedure Init_Normalized_Position_Max (Id : E) is
5340 Set_Uint10 (Id, No_Uint);
5341 end Init_Normalized_Position_Max;
5343 procedure Init_Normalized_Position_Max (Id : E; V : Int) is
5345 Set_Uint10 (Id, UI_From_Int (V));
5346 end Init_Normalized_Position_Max;
5348 procedure Init_RM_Size (Id : E) is
5350 Set_Uint13 (Id, Uint_0);
5353 procedure Init_RM_Size (Id : E; V : Int) is
5355 Set_Uint13 (Id, UI_From_Int (V));
5358 -----------------------------
5359 -- Init_Component_Location --
5360 -----------------------------
5362 procedure Init_Component_Location (Id : E) is
5364 Set_Uint8 (Id, No_Uint); -- Normalized_First_Bit
5365 Set_Uint10 (Id, No_Uint); -- Normalized_Position_Max
5366 Set_Uint11 (Id, No_Uint); -- Component_Bit_Offset
5367 Set_Uint12 (Id, Uint_0); -- Esize
5368 Set_Uint14 (Id, No_Uint); -- Normalized_Position
5369 end Init_Component_Location;
5375 procedure Init_Size (Id : E; V : Int) is
5377 Set_Uint12 (Id, UI_From_Int (V)); -- Esize
5378 Set_Uint13 (Id, UI_From_Int (V)); -- RM_Size
5381 ---------------------
5382 -- Init_Size_Align --
5383 ---------------------
5385 procedure Init_Size_Align (Id : E) is
5387 Set_Uint12 (Id, Uint_0); -- Esize
5388 Set_Uint13 (Id, Uint_0); -- RM_Size
5389 Set_Uint14 (Id, Uint_0); -- Alignment
5390 end Init_Size_Align;
5392 ----------------------------------------------
5393 -- Type Representation Attribute Predicates --
5394 ----------------------------------------------
5396 function Known_Alignment (E : Entity_Id) return B is
5398 return Uint14 (E) /= Uint_0
5399 and then Uint14 (E) /= No_Uint;
5400 end Known_Alignment;
5402 function Known_Component_Bit_Offset (E : Entity_Id) return B is
5404 return Uint11 (E) /= No_Uint;
5405 end Known_Component_Bit_Offset;
5407 function Known_Component_Size (E : Entity_Id) return B is
5409 return Uint22 (Base_Type (E)) /= Uint_0
5410 and then Uint22 (Base_Type (E)) /= No_Uint;
5411 end Known_Component_Size;
5413 function Known_Esize (E : Entity_Id) return B is
5415 return Uint12 (E) /= Uint_0
5416 and then Uint12 (E) /= No_Uint;
5419 function Known_Normalized_First_Bit (E : Entity_Id) return B is
5421 return Uint8 (E) /= No_Uint;
5422 end Known_Normalized_First_Bit;
5424 function Known_Normalized_Position (E : Entity_Id) return B is
5426 return Uint14 (E) /= No_Uint;
5427 end Known_Normalized_Position;
5429 function Known_Normalized_Position_Max (E : Entity_Id) return B is
5431 return Uint10 (E) /= No_Uint;
5432 end Known_Normalized_Position_Max;
5434 function Known_RM_Size (E : Entity_Id) return B is
5436 return Uint13 (E) /= No_Uint
5437 and then (Uint13 (E) /= Uint_0
5438 or else Is_Discrete_Type (E)
5439 or else Is_Fixed_Point_Type (E));
5442 function Known_Static_Component_Bit_Offset (E : Entity_Id) return B is
5444 return Uint11 (E) /= No_Uint
5445 and then Uint11 (E) >= Uint_0;
5446 end Known_Static_Component_Bit_Offset;
5448 function Known_Static_Component_Size (E : Entity_Id) return B is
5450 return Uint22 (Base_Type (E)) > Uint_0;
5451 end Known_Static_Component_Size;
5453 function Known_Static_Esize (E : Entity_Id) return B is
5455 return Uint12 (E) > Uint_0;
5456 end Known_Static_Esize;
5458 function Known_Static_Normalized_First_Bit (E : Entity_Id) return B is
5460 return Uint8 (E) /= No_Uint
5461 and then Uint8 (E) >= Uint_0;
5462 end Known_Static_Normalized_First_Bit;
5464 function Known_Static_Normalized_Position (E : Entity_Id) return B is
5466 return Uint14 (E) /= No_Uint
5467 and then Uint14 (E) >= Uint_0;
5468 end Known_Static_Normalized_Position;
5470 function Known_Static_Normalized_Position_Max (E : Entity_Id) return B is
5472 return Uint10 (E) /= No_Uint
5473 and then Uint10 (E) >= Uint_0;
5474 end Known_Static_Normalized_Position_Max;
5476 function Known_Static_RM_Size (E : Entity_Id) return B is
5478 return Uint13 (E) > Uint_0
5479 or else Is_Discrete_Type (E)
5480 or else Is_Fixed_Point_Type (E);
5481 end Known_Static_RM_Size;
5483 function Unknown_Alignment (E : Entity_Id) return B is
5485 return Uint14 (E) = Uint_0
5486 or else Uint14 (E) = No_Uint;
5487 end Unknown_Alignment;
5489 function Unknown_Component_Bit_Offset (E : Entity_Id) return B is
5491 return Uint11 (E) = No_Uint;
5492 end Unknown_Component_Bit_Offset;
5494 function Unknown_Component_Size (E : Entity_Id) return B is
5496 return Uint22 (Base_Type (E)) = Uint_0
5498 Uint22 (Base_Type (E)) = No_Uint;
5499 end Unknown_Component_Size;
5501 function Unknown_Esize (E : Entity_Id) return B is
5503 return Uint12 (E) = No_Uint
5505 Uint12 (E) = Uint_0;
5508 function Unknown_Normalized_First_Bit (E : Entity_Id) return B is
5510 return Uint8 (E) = No_Uint;
5511 end Unknown_Normalized_First_Bit;
5513 function Unknown_Normalized_Position (E : Entity_Id) return B is
5515 return Uint14 (E) = No_Uint;
5516 end Unknown_Normalized_Position;
5518 function Unknown_Normalized_Position_Max (E : Entity_Id) return B is
5520 return Uint10 (E) = No_Uint;
5521 end Unknown_Normalized_Position_Max;
5523 function Unknown_RM_Size (E : Entity_Id) return B is
5525 return (Uint13 (E) = Uint_0
5526 and then not Is_Discrete_Type (E)
5527 and then not Is_Fixed_Point_Type (E))
5528 or else Uint13 (E) = No_Uint;
5529 end Unknown_RM_Size;
5531 --------------------
5532 -- Address_Clause --
5533 --------------------
5535 function Address_Clause (Id : E) return N is
5537 return Rep_Clause (Id, Name_Address);
5540 ----------------------
5541 -- Alignment_Clause --
5542 ----------------------
5544 function Alignment_Clause (Id : E) return N is
5546 return Rep_Clause (Id, Name_Alignment);
5547 end Alignment_Clause;
5553 procedure Append_Entity (Id : Entity_Id; V : Entity_Id) is
5555 if Last_Entity (V) = Empty then
5556 Set_First_Entity (Id => V, V => Id);
5558 Set_Next_Entity (Last_Entity (V), Id);
5561 Set_Next_Entity (Id, Empty);
5563 Set_Last_Entity (Id => V, V => Id);
5570 function Base_Type (Id : E) return E is
5573 when E_Enumeration_Subtype |
5575 E_Signed_Integer_Subtype |
5576 E_Modular_Integer_Subtype |
5577 E_Floating_Point_Subtype |
5578 E_Ordinary_Fixed_Point_Subtype |
5579 E_Decimal_Fixed_Point_Subtype |
5584 E_Record_Subtype_With_Private |
5585 E_Limited_Private_Subtype |
5587 E_Protected_Subtype |
5589 E_String_Literal_Subtype |
5590 E_Class_Wide_Subtype =>
5598 -------------------------
5599 -- Component_Alignment --
5600 -------------------------
5602 -- Component Alignment is encoded using two flags, Flag128/129 as
5603 -- follows. Note that both flags False = Align_Default, so that the
5604 -- default initialization of flags to False initializes component
5605 -- alignment to the default value as required.
5607 -- Flag128 Flag129 Value
5608 -- ------- ------- -----
5609 -- False False Calign_Default
5610 -- False True Calign_Component_Size
5611 -- True False Calign_Component_Size_4
5612 -- True True Calign_Storage_Unit
5614 function Component_Alignment (Id : E) return C is
5615 BT : constant Node_Id := Base_Type (Id);
5618 pragma Assert (Is_Array_Type (Id) or else Is_Record_Type (Id));
5620 if Flag128 (BT) then
5621 if Flag129 (BT) then
5622 return Calign_Storage_Unit;
5624 return Calign_Component_Size_4;
5628 if Flag129 (BT) then
5629 return Calign_Component_Size;
5631 return Calign_Default;
5634 end Component_Alignment;
5636 ----------------------
5637 -- Declaration_Node --
5638 ----------------------
5640 function Declaration_Node (Id : E) return N is
5644 if Ekind (Id) = E_Incomplete_Type
5645 and then Present (Full_View (Id))
5647 P := Parent (Full_View (Id));
5653 if Nkind (P) /= N_Selected_Component
5654 and then Nkind (P) /= N_Expanded_Name
5656 not (Nkind (P) = N_Defining_Program_Unit_Name
5657 and then Is_Child_Unit (Id))
5664 end Declaration_Node;
5666 ---------------------
5667 -- Designated_Type --
5668 ---------------------
5670 function Designated_Type (Id : E) return E is
5674 Desig_Type := Directly_Designated_Type (Id);
5676 if Ekind (Desig_Type) = E_Incomplete_Type
5677 and then Present (Full_View (Desig_Type))
5679 return Full_View (Desig_Type);
5681 elsif Is_Class_Wide_Type (Desig_Type)
5682 and then Ekind (Etype (Desig_Type)) = E_Incomplete_Type
5683 and then Present (Full_View (Etype (Desig_Type)))
5684 and then Present (Class_Wide_Type (Full_View (Etype (Desig_Type))))
5686 return Class_Wide_Type (Full_View (Etype (Desig_Type)));
5691 end Designated_Type;
5693 ----------------------
5694 -- Entry_Index_Type --
5695 ----------------------
5697 function Entry_Index_Type (Id : E) return N is
5699 pragma Assert (Ekind (Id) = E_Entry_Family);
5700 return Etype (Discrete_Subtype_Definition (Parent (Id)));
5701 end Entry_Index_Type;
5703 ---------------------
5704 -- First_Component --
5705 ---------------------
5707 function First_Component (Id : E) return E is
5712 (Is_Record_Type (Id) or else Is_Incomplete_Or_Private_Type (Id));
5714 Comp_Id := First_Entity (Id);
5715 while Present (Comp_Id) loop
5716 exit when Ekind (Comp_Id) = E_Component;
5717 Comp_Id := Next_Entity (Comp_Id);
5721 end First_Component;
5723 -------------------------------------
5724 -- First_Component_Or_Discriminant --
5725 -------------------------------------
5727 function First_Component_Or_Discriminant (Id : E) return E is
5732 (Is_Record_Type (Id) or else Is_Incomplete_Or_Private_Type (Id));
5734 Comp_Id := First_Entity (Id);
5735 while Present (Comp_Id) loop
5736 exit when Ekind (Comp_Id) = E_Component
5738 Ekind (Comp_Id) = E_Discriminant;
5739 Comp_Id := Next_Entity (Comp_Id);
5743 end First_Component_Or_Discriminant;
5749 function First_Formal (Id : E) return E is
5754 (Is_Overloadable (Id)
5755 or else Ekind (Id) = E_Entry_Family
5756 or else Ekind (Id) = E_Subprogram_Body
5757 or else Ekind (Id) = E_Subprogram_Type);
5759 if Ekind (Id) = E_Enumeration_Literal then
5763 Formal := First_Entity (Id);
5765 if Present (Formal) and then Is_Formal (Formal) then
5773 ------------------------------
5774 -- First_Formal_With_Extras --
5775 ------------------------------
5777 function First_Formal_With_Extras (Id : E) return E is
5782 (Is_Overloadable (Id)
5783 or else Ekind (Id) = E_Entry_Family
5784 or else Ekind (Id) = E_Subprogram_Body
5785 or else Ekind (Id) = E_Subprogram_Type);
5787 if Ekind (Id) = E_Enumeration_Literal then
5791 Formal := First_Entity (Id);
5793 if Present (Formal) and then Is_Formal (Formal) then
5796 return Extra_Formals (Id); -- Empty if no extra formals
5799 end First_Formal_With_Extras;
5801 -------------------------------------
5802 -- Get_Attribute_Definition_Clause --
5803 -------------------------------------
5805 function Get_Attribute_Definition_Clause
5807 Id : Attribute_Id) return Node_Id
5812 N := First_Rep_Item (E);
5813 while Present (N) loop
5814 if Nkind (N) = N_Attribute_Definition_Clause
5815 and then Get_Attribute_Id (Chars (N)) = Id
5824 end Get_Attribute_Definition_Clause;
5830 function Get_Full_View (T : Entity_Id) return Entity_Id is
5832 if Ekind (T) = E_Incomplete_Type
5833 and then Present (Full_View (T))
5835 return Full_View (T);
5837 elsif Is_Class_Wide_Type (T)
5838 and then Ekind (Root_Type (T)) = E_Incomplete_Type
5839 and then Present (Full_View (Root_Type (T)))
5841 return Class_Wide_Type (Full_View (Root_Type (T)));
5848 --------------------
5849 -- Get_Rep_Pragma --
5850 --------------------
5852 function Get_Rep_Pragma (E : Entity_Id; Nam : Name_Id) return Node_Id is
5856 N := First_Rep_Item (E);
5857 while Present (N) loop
5858 if Nkind (N) = N_Pragma and then Pragma_Name (N) = Nam then
5868 ------------------------
5869 -- Has_Attach_Handler --
5870 ------------------------
5872 function Has_Attach_Handler (Id : E) return B is
5876 pragma Assert (Is_Protected_Type (Id));
5878 Ritem := First_Rep_Item (Id);
5879 while Present (Ritem) loop
5880 if Nkind (Ritem) = N_Pragma
5881 and then Pragma_Name (Ritem) = Name_Attach_Handler
5885 Ritem := Next_Rep_Item (Ritem);
5890 end Has_Attach_Handler;
5892 -------------------------------------
5893 -- Has_Attribute_Definition_Clause --
5894 -------------------------------------
5896 function Has_Attribute_Definition_Clause
5898 Id : Attribute_Id) return Boolean
5901 return Present (Get_Attribute_Definition_Clause (E, Id));
5902 end Has_Attribute_Definition_Clause;
5908 function Has_Entries (Id : E) return B is
5912 pragma Assert (Is_Concurrent_Type (Id));
5914 Ent := First_Entity (Id);
5915 while Present (Ent) loop
5916 if Is_Entry (Ent) then
5920 Ent := Next_Entity (Ent);
5926 ----------------------------
5927 -- Has_Foreign_Convention --
5928 ----------------------------
5930 function Has_Foreign_Convention (Id : E) return B is
5932 return Convention (Id) in Foreign_Convention;
5933 end Has_Foreign_Convention;
5935 ---------------------------
5936 -- Has_Interrupt_Handler --
5937 ---------------------------
5939 function Has_Interrupt_Handler (Id : E) return B is
5943 pragma Assert (Is_Protected_Type (Id));
5945 Ritem := First_Rep_Item (Id);
5946 while Present (Ritem) loop
5947 if Nkind (Ritem) = N_Pragma
5948 and then Pragma_Name (Ritem) = Name_Interrupt_Handler
5952 Ritem := Next_Rep_Item (Ritem);
5957 end Has_Interrupt_Handler;
5959 --------------------------
5960 -- Has_Private_Ancestor --
5961 --------------------------
5963 function Has_Private_Ancestor (Id : E) return B is
5964 R : constant Entity_Id := Root_Type (Id);
5965 T1 : Entity_Id := Id;
5968 if Is_Private_Type (T1) then
5976 end Has_Private_Ancestor;
5978 --------------------
5979 -- Has_Rep_Pragma --
5980 --------------------
5982 function Has_Rep_Pragma (E : Entity_Id; Nam : Name_Id) return Boolean is
5984 return Present (Get_Rep_Pragma (E, Nam));
5987 --------------------
5988 -- Has_Unmodified --
5989 --------------------
5991 function Has_Unmodified (E : Entity_Id) return Boolean is
5993 if Has_Pragma_Unmodified (E) then
5995 elsif Warnings_Off (E) then
5996 Set_Warnings_Off_Used_Unmodified (E);
6003 ---------------------
6004 -- Has_Unreferenced --
6005 ---------------------
6007 function Has_Unreferenced (E : Entity_Id) return Boolean is
6009 if Has_Pragma_Unreferenced (E) then
6011 elsif Warnings_Off (E) then
6012 Set_Warnings_Off_Used_Unreferenced (E);
6017 end Has_Unreferenced;
6019 ----------------------
6020 -- Has_Warnings_Off --
6021 ----------------------
6023 function Has_Warnings_Off (E : Entity_Id) return Boolean is
6025 if Warnings_Off (E) then
6026 Set_Warnings_Off_Used (E);
6031 end Has_Warnings_Off;
6033 ------------------------------
6034 -- Implementation_Base_Type --
6035 ------------------------------
6037 function Implementation_Base_Type (Id : E) return E is
6042 Bastyp := Base_Type (Id);
6044 if Is_Incomplete_Or_Private_Type (Bastyp) then
6045 Imptyp := Underlying_Type (Bastyp);
6047 -- If we have an implementation type, then just return it,
6048 -- otherwise we return the Base_Type anyway. This can only
6049 -- happen in error situations and should avoid some error bombs.
6051 if Present (Imptyp) then
6052 return Base_Type (Imptyp);
6060 end Implementation_Base_Type;
6062 ---------------------
6063 -- Is_Boolean_Type --
6064 ---------------------
6066 function Is_Boolean_Type (Id : E) return B is
6068 return Root_Type (Id) = Standard_Boolean;
6069 end Is_Boolean_Type;
6071 ------------------------
6072 -- Is_Constant_Object --
6073 ------------------------
6075 function Is_Constant_Object (Id : E) return B is
6076 K : constant Entity_Kind := Ekind (Id);
6079 K = E_Constant or else K = E_In_Parameter or else K = E_Loop_Parameter;
6080 end Is_Constant_Object;
6082 --------------------
6083 -- Is_Discriminal --
6084 --------------------
6086 function Is_Discriminal (Id : E) return B is
6089 (Ekind (Id) = E_Constant
6090 or else Ekind (Id) = E_In_Parameter)
6091 and then Present (Discriminal_Link (Id));
6094 ----------------------
6095 -- Is_Dynamic_Scope --
6096 ----------------------
6098 function Is_Dynamic_Scope (Id : E) return B is
6101 Ekind (Id) = E_Block
6103 Ekind (Id) = E_Function
6105 Ekind (Id) = E_Procedure
6107 Ekind (Id) = E_Subprogram_Body
6109 Ekind (Id) = E_Task_Type
6111 Ekind (Id) = E_Entry
6113 Ekind (Id) = E_Entry_Family
6115 Ekind (Id) = E_Return_Statement;
6116 end Is_Dynamic_Scope;
6118 --------------------
6119 -- Is_Entity_Name --
6120 --------------------
6122 function Is_Entity_Name (N : Node_Id) return Boolean is
6123 Kind : constant Node_Kind := Nkind (N);
6126 -- Identifiers, operator symbols, expanded names are entity names
6128 return Kind = N_Identifier
6129 or else Kind = N_Operator_Symbol
6130 or else Kind = N_Expanded_Name
6132 -- Attribute references are entity names if they refer to an entity.
6133 -- Note that we don't do this by testing for the presence of the
6134 -- Entity field in the N_Attribute_Reference node, since it may not
6135 -- have been set yet.
6137 or else (Kind = N_Attribute_Reference
6138 and then Is_Entity_Attribute_Name (Attribute_Name (N)));
6141 -----------------------------------
6142 -- Is_Package_Or_Generic_Package --
6143 -----------------------------------
6145 function Is_Package_Or_Generic_Package (Id : E) return B is
6148 Ekind (Id) = E_Package
6150 Ekind (Id) = E_Generic_Package;
6151 end Is_Package_Or_Generic_Package;
6157 function Is_Prival (Id : E) return B is
6160 (Ekind (Id) = E_Constant
6161 or else Ekind (Id) = E_Variable)
6162 and then Present (Prival_Link (Id));
6165 ----------------------------
6166 -- Is_Protected_Component --
6167 ----------------------------
6169 function Is_Protected_Component (Id : E) return B is
6171 return Ekind (Id) = E_Component
6172 and then Is_Protected_Type (Scope (Id));
6173 end Is_Protected_Component;
6175 ------------------------------
6176 -- Is_Protected_Record_Type --
6177 ------------------------------
6179 function Is_Protected_Record_Type (Id : E) return B is
6182 Is_Concurrent_Record_Type (Id)
6183 and then Is_Protected_Type (Corresponding_Concurrent_Type (Id));
6184 end Is_Protected_Record_Type;
6186 --------------------------------
6187 -- Is_Standard_Character_Type --
6188 --------------------------------
6190 function Is_Standard_Character_Type (Id : E) return B is
6192 if Is_Type (Id) then
6194 R : constant Entity_Id := Root_Type (Id);
6197 R = Standard_Character
6199 R = Standard_Wide_Character
6201 R = Standard_Wide_Wide_Character;
6207 end Is_Standard_Character_Type;
6209 --------------------
6210 -- Is_String_Type --
6211 --------------------
6213 function Is_String_Type (Id : E) return B is
6215 return Ekind (Id) in String_Kind
6216 or else (Is_Array_Type (Id)
6217 and then Number_Dimensions (Id) = 1
6218 and then Is_Character_Type (Component_Type (Id)));
6221 -------------------------
6222 -- Is_Task_Record_Type --
6223 -------------------------
6225 function Is_Task_Record_Type (Id : E) return B is
6228 Is_Concurrent_Record_Type (Id)
6229 and then Is_Task_Type (Corresponding_Concurrent_Type (Id));
6230 end Is_Task_Record_Type;
6232 ------------------------
6233 -- Is_Wrapper_Package --
6234 ------------------------
6236 function Is_Wrapper_Package (Id : E) return B is
6238 return (Ekind (Id) = E_Package
6239 and then Present (Related_Instance (Id)));
6240 end Is_Wrapper_Package;
6242 --------------------
6243 -- Next_Component --
6244 --------------------
6246 function Next_Component (Id : E) return E is
6250 Comp_Id := Next_Entity (Id);
6251 while Present (Comp_Id) loop
6252 exit when Ekind (Comp_Id) = E_Component;
6253 Comp_Id := Next_Entity (Comp_Id);
6259 ------------------------------------
6260 -- Next_Component_Or_Discriminant --
6261 ------------------------------------
6263 function Next_Component_Or_Discriminant (Id : E) return E is
6267 Comp_Id := Next_Entity (Id);
6268 while Present (Comp_Id) loop
6269 exit when Ekind (Comp_Id) = E_Component
6271 Ekind (Comp_Id) = E_Discriminant;
6272 Comp_Id := Next_Entity (Comp_Id);
6276 end Next_Component_Or_Discriminant;
6278 -----------------------
6279 -- Next_Discriminant --
6280 -----------------------
6282 -- This function actually implements both Next_Discriminant and
6283 -- Next_Stored_Discriminant by making sure that the Discriminant
6284 -- returned is of the same variety as Id.
6286 function Next_Discriminant (Id : E) return E is
6288 -- Derived Tagged types with private extensions look like this...
6290 -- E_Discriminant d1
6291 -- E_Discriminant d2
6293 -- E_Discriminant d1
6294 -- E_Discriminant d2
6297 -- so it is critical not to go past the leading discriminants
6302 pragma Assert (Ekind (Id) = E_Discriminant);
6305 D := Next_Entity (D);
6307 or else (Ekind (D) /= E_Discriminant
6308 and then not Is_Itype (D))
6313 exit when Ekind (D) = E_Discriminant
6314 and then (Is_Completely_Hidden (D) = Is_Completely_Hidden (Id));
6318 end Next_Discriminant;
6324 function Next_Formal (Id : E) return E is
6328 -- Follow the chain of declared entities as long as the kind of the
6329 -- entity corresponds to a formal parameter. Skip internal entities
6330 -- that may have been created for implicit subtypes, in the process
6331 -- of analyzing default expressions.
6336 P := Next_Entity (P);
6338 if No (P) or else Is_Formal (P) then
6340 elsif not Is_Internal (P) then
6346 -----------------------------
6347 -- Next_Formal_With_Extras --
6348 -----------------------------
6350 function Next_Formal_With_Extras (Id : E) return E is
6352 if Present (Extra_Formal (Id)) then
6353 return Extra_Formal (Id);
6355 return Next_Formal (Id);
6357 end Next_Formal_With_Extras;
6363 function Next_Index (Id : Node_Id) return Node_Id is
6372 function Next_Literal (Id : E) return E is
6374 pragma Assert (Nkind (Id) in N_Entity);
6378 ------------------------------
6379 -- Next_Stored_Discriminant --
6380 ------------------------------
6382 function Next_Stored_Discriminant (Id : E) return E is
6384 -- See comment in Next_Discriminant
6386 return Next_Discriminant (Id);
6387 end Next_Stored_Discriminant;
6389 -----------------------
6390 -- Number_Dimensions --
6391 -----------------------
6393 function Number_Dimensions (Id : E) return Pos is
6398 if Ekind (Id) in String_Kind then
6403 T := First_Index (Id);
6404 while Present (T) loop
6411 end Number_Dimensions;
6413 --------------------
6414 -- Number_Entries --
6415 --------------------
6417 function Number_Entries (Id : E) return Nat is
6422 pragma Assert (Is_Concurrent_Type (Id));
6425 Ent := First_Entity (Id);
6426 while Present (Ent) loop
6427 if Is_Entry (Ent) then
6431 Ent := Next_Entity (Ent);
6437 --------------------
6438 -- Number_Formals --
6439 --------------------
6441 function Number_Formals (Id : E) return Pos is
6447 Formal := First_Formal (Id);
6448 while Present (Formal) loop
6450 Formal := Next_Formal (Formal);
6456 --------------------
6457 -- Parameter_Mode --
6458 --------------------
6460 function Parameter_Mode (Id : E) return Formal_Kind is
6465 ---------------------
6466 -- Record_Rep_Item --
6467 ---------------------
6469 procedure Record_Rep_Item (E : Entity_Id; N : Node_Id) is
6471 Set_Next_Rep_Item (N, First_Rep_Item (E));
6472 Set_First_Rep_Item (E, N);
6473 end Record_Rep_Item;
6479 function Root_Type (Id : E) return E is
6483 pragma Assert (Nkind (Id) in N_Entity);
6485 T := Base_Type (Id);
6487 if Ekind (T) = E_Class_Wide_Type then
6490 elsif Ekind (T) = E_Class_Wide_Subtype then
6491 return Etype (Base_Type (T));
6493 -- ??? T comes from Base_Type, how can it be a subtype?
6494 -- Also Base_Type is supposed to be idempotent, so either way
6495 -- this is equivalent to "return Etype (T)" and should be merged
6496 -- with the E_Class_Wide_Type case.
6507 -- Following test catches some error cases resulting from
6510 elsif No (Etyp) then
6513 elsif Is_Private_Type (T) and then Etyp = Full_View (T) then
6516 elsif Is_Private_Type (Etyp) and then Full_View (Etyp) = T then
6522 -- Return if there is a circularity in the inheritance chain. This
6523 -- happens in some error situations and we do not want to get
6524 -- stuck in this loop.
6526 if T = Base_Type (Id) then
6537 function Scope_Depth (Id : E) return Uint is
6542 while Is_Record_Type (Scop) loop
6543 Scop := Scope (Scop);
6546 return Scope_Depth_Value (Scop);
6549 ---------------------
6550 -- Scope_Depth_Set --
6551 ---------------------
6553 function Scope_Depth_Set (Id : E) return B is
6555 return not Is_Record_Type (Id)
6556 and then Field22 (Id) /= Union_Id (Empty);
6557 end Scope_Depth_Set;
6559 -----------------------------
6560 -- Set_Component_Alignment --
6561 -----------------------------
6563 -- Component Alignment is encoded using two flags, Flag128/129 as
6564 -- follows. Note that both flags False = Align_Default, so that the
6565 -- default initialization of flags to False initializes component
6566 -- alignment to the default value as required.
6568 -- Flag128 Flag129 Value
6569 -- ------- ------- -----
6570 -- False False Calign_Default
6571 -- False True Calign_Component_Size
6572 -- True False Calign_Component_Size_4
6573 -- True True Calign_Storage_Unit
6575 procedure Set_Component_Alignment (Id : E; V : C) is
6577 pragma Assert ((Is_Array_Type (Id) or else Is_Record_Type (Id))
6578 and then Id = Base_Type (Id));
6581 when Calign_Default =>
6582 Set_Flag128 (Id, False);
6583 Set_Flag129 (Id, False);
6585 when Calign_Component_Size =>
6586 Set_Flag128 (Id, False);
6587 Set_Flag129 (Id, True);
6589 when Calign_Component_Size_4 =>
6590 Set_Flag128 (Id, True);
6591 Set_Flag129 (Id, False);
6593 when Calign_Storage_Unit =>
6594 Set_Flag128 (Id, True);
6595 Set_Flag129 (Id, True);
6597 end Set_Component_Alignment;
6603 function Size_Clause (Id : E) return N is
6605 return Rep_Clause (Id, Name_Size);
6608 ------------------------
6609 -- Stream_Size_Clause --
6610 ------------------------
6612 function Stream_Size_Clause (Id : E) return N is
6614 return Rep_Clause (Id, Name_Stream_Size);
6615 end Stream_Size_Clause;
6621 function Subtype_Kind (K : Entity_Kind) return Entity_Kind is
6627 Kind := E_Access_Subtype;
6631 Kind := E_Array_Subtype;
6633 when E_Class_Wide_Type |
6634 E_Class_Wide_Subtype =>
6635 Kind := E_Class_Wide_Subtype;
6637 when E_Decimal_Fixed_Point_Type |
6638 E_Decimal_Fixed_Point_Subtype =>
6639 Kind := E_Decimal_Fixed_Point_Subtype;
6641 when E_Ordinary_Fixed_Point_Type |
6642 E_Ordinary_Fixed_Point_Subtype =>
6643 Kind := E_Ordinary_Fixed_Point_Subtype;
6645 when E_Private_Type |
6646 E_Private_Subtype =>
6647 Kind := E_Private_Subtype;
6649 when E_Limited_Private_Type |
6650 E_Limited_Private_Subtype =>
6651 Kind := E_Limited_Private_Subtype;
6653 when E_Record_Type_With_Private |
6654 E_Record_Subtype_With_Private =>
6655 Kind := E_Record_Subtype_With_Private;
6657 when E_Record_Type |
6659 Kind := E_Record_Subtype;
6661 when E_String_Type |
6663 Kind := E_String_Subtype;
6665 when Enumeration_Kind =>
6666 Kind := E_Enumeration_Subtype;
6669 Kind := E_Floating_Point_Subtype;
6671 when Signed_Integer_Kind =>
6672 Kind := E_Signed_Integer_Subtype;
6674 when Modular_Integer_Kind =>
6675 Kind := E_Modular_Integer_Subtype;
6677 when Protected_Kind =>
6678 Kind := E_Protected_Subtype;
6681 Kind := E_Task_Subtype;
6685 raise Program_Error;
6691 ---------------------
6692 -- Type_High_Bound --
6693 ---------------------
6695 function Type_High_Bound (Id : E) return Node_Id is
6696 Rng : constant Node_Id := Scalar_Range (Id);
6698 if Nkind (Rng) = N_Subtype_Indication then
6699 return High_Bound (Range_Expression (Constraint (Rng)));
6701 return High_Bound (Rng);
6703 end Type_High_Bound;
6705 --------------------
6706 -- Type_Low_Bound --
6707 --------------------
6709 function Type_Low_Bound (Id : E) return Node_Id is
6710 Rng : constant Node_Id := Scalar_Range (Id);
6712 if Nkind (Rng) = N_Subtype_Indication then
6713 return Low_Bound (Range_Expression (Constraint (Rng)));
6715 return Low_Bound (Rng);
6719 ---------------------
6720 -- Underlying_Type --
6721 ---------------------
6723 function Underlying_Type (Id : E) return E is
6725 -- For record_with_private the underlying type is always the direct
6726 -- full view. Never try to take the full view of the parent it
6727 -- doesn't make sense.
6729 if Ekind (Id) = E_Record_Type_With_Private then
6730 return Full_View (Id);
6732 elsif Ekind (Id) in Incomplete_Or_Private_Kind then
6734 -- If we have an incomplete or private type with a full view,
6735 -- then we return the Underlying_Type of this full view
6737 if Present (Full_View (Id)) then
6738 if Id = Full_View (Id) then
6740 -- Previous error in declaration
6745 return Underlying_Type (Full_View (Id));
6748 -- If we have an incomplete entity that comes from the limited
6749 -- view then we return the Underlying_Type of its non-limited
6752 elsif From_With_Type (Id)
6753 and then Present (Non_Limited_View (Id))
6755 return Underlying_Type (Non_Limited_View (Id));
6757 -- Otherwise check for the case where we have a derived type or
6758 -- subtype, and if so get the Underlying_Type of the parent type.
6760 elsif Etype (Id) /= Id then
6761 return Underlying_Type (Etype (Id));
6763 -- Otherwise we have an incomplete or private type that has
6764 -- no full view, which means that we have not encountered the
6765 -- completion, so return Empty to indicate the underlying type
6766 -- is not yet known.
6772 -- For non-incomplete, non-private types, return the type itself
6773 -- Also for entities that are not types at all return the entity
6779 end Underlying_Type;
6781 ------------------------
6782 -- Write_Entity_Flags --
6783 ------------------------
6785 procedure Write_Entity_Flags (Id : Entity_Id; Prefix : String) is
6787 procedure W (Flag_Name : String; Flag : Boolean);
6788 -- Write out given flag if it is set
6794 procedure W (Flag_Name : String; Flag : Boolean) is
6798 Write_Str (Flag_Name);
6799 Write_Str (" = True");
6804 -- Start of processing for Write_Entity_Flags
6807 if (Is_Array_Type (Id) or else Is_Record_Type (Id))
6808 and then Id = Base_Type (Id)
6811 Write_Str ("Component_Alignment = ");
6813 case Component_Alignment (Id) is
6814 when Calign_Default =>
6815 Write_Str ("Calign_Default");
6817 when Calign_Component_Size =>
6818 Write_Str ("Calign_Component_Size");
6820 when Calign_Component_Size_4 =>
6821 Write_Str ("Calign_Component_Size_4");
6823 when Calign_Storage_Unit =>
6824 Write_Str ("Calign_Storage_Unit");
6830 W ("Address_Taken", Flag104 (Id));
6831 W ("Body_Needed_For_SAL", Flag40 (Id));
6832 W ("C_Pass_By_Copy", Flag125 (Id));
6833 W ("Can_Never_Be_Null", Flag38 (Id));
6834 W ("Checks_May_Be_Suppressed", Flag31 (Id));
6835 W ("Debug_Info_Off", Flag166 (Id));
6836 W ("Default_Expressions_Processed", Flag108 (Id));
6837 W ("Delay_Cleanups", Flag114 (Id));
6838 W ("Delay_Subprogram_Descriptors", Flag50 (Id));
6839 W ("Depends_On_Private", Flag14 (Id));
6840 W ("Discard_Names", Flag88 (Id));
6841 W ("Elaboration_Entity_Required", Flag174 (Id));
6842 W ("Elaborate_Body_Desirable", Flag210 (Id));
6843 W ("Entry_Accepted", Flag152 (Id));
6844 W ("Can_Use_Internal_Rep", Flag229 (Id));
6845 W ("Finalize_Storage_Only", Flag158 (Id));
6846 W ("From_With_Type", Flag159 (Id));
6847 W ("Has_Aliased_Components", Flag135 (Id));
6848 W ("Has_Alignment_Clause", Flag46 (Id));
6849 W ("Has_All_Calls_Remote", Flag79 (Id));
6850 W ("Has_Anon_Block_Suffix", Flag201 (Id));
6851 W ("Has_Atomic_Components", Flag86 (Id));
6852 W ("Has_Biased_Representation", Flag139 (Id));
6853 W ("Has_Completion", Flag26 (Id));
6854 W ("Has_Completion_In_Body", Flag71 (Id));
6855 W ("Has_Complex_Representation", Flag140 (Id));
6856 W ("Has_Component_Size_Clause", Flag68 (Id));
6857 W ("Has_Contiguous_Rep", Flag181 (Id));
6858 W ("Has_Controlled_Component", Flag43 (Id));
6859 W ("Has_Controlling_Result", Flag98 (Id));
6860 W ("Has_Convention_Pragma", Flag119 (Id));
6861 W ("Has_Delayed_Freeze", Flag18 (Id));
6862 W ("Has_Discriminants", Flag5 (Id));
6863 W ("Has_Enumeration_Rep_Clause", Flag66 (Id));
6864 W ("Has_Exit", Flag47 (Id));
6865 W ("Has_External_Tag_Rep_Clause", Flag110 (Id));
6866 W ("Has_Forward_Instantiation", Flag175 (Id));
6867 W ("Has_Fully_Qualified_Name", Flag173 (Id));
6868 W ("Has_Gigi_Rep_Item", Flag82 (Id));
6869 W ("Has_Homonym", Flag56 (Id));
6870 W ("Has_Initial_Value", Flag219 (Id));
6871 W ("Has_Machine_Radix_Clause", Flag83 (Id));
6872 W ("Has_Master_Entity", Flag21 (Id));
6873 W ("Has_Missing_Return", Flag142 (Id));
6874 W ("Has_Nested_Block_With_Handler", Flag101 (Id));
6875 W ("Has_Non_Standard_Rep", Flag75 (Id));
6876 W ("Has_Object_Size_Clause", Flag172 (Id));
6877 W ("Has_Per_Object_Constraint", Flag154 (Id));
6878 W ("Has_Persistent_BSS", Flag188 (Id));
6879 W ("Has_Postconditions", Flag240 (Id));
6880 W ("Has_Pragma_Controlled", Flag27 (Id));
6881 W ("Has_Pragma_Elaborate_Body", Flag150 (Id));
6882 W ("Has_Pragma_Inline", Flag157 (Id));
6883 W ("Has_Pragma_Inline_Always", Flag230 (Id));
6884 W ("Has_Pragma_Pack", Flag121 (Id));
6885 W ("Has_Pragma_Preelab_Init", Flag221 (Id));
6886 W ("Has_Pragma_Pure", Flag203 (Id));
6887 W ("Has_Pragma_Pure_Function", Flag179 (Id));
6888 W ("Has_Pragma_Thread_Local_Storage", Flag169 (Id));
6889 W ("Has_Pragma_Unmodified", Flag233 (Id));
6890 W ("Has_Pragma_Unreferenced", Flag180 (Id));
6891 W ("Has_Pragma_Unreferenced_Objects", Flag212 (Id));
6892 W ("Has_Primitive_Operations", Flag120 (Id));
6893 W ("Has_Private_Declaration", Flag155 (Id));
6894 W ("Has_Qualified_Name", Flag161 (Id));
6895 W ("Has_RACW", Flag214 (Id));
6896 W ("Has_Record_Rep_Clause", Flag65 (Id));
6897 W ("Has_Recursive_Call", Flag143 (Id));
6898 W ("Has_Size_Clause", Flag29 (Id));
6899 W ("Has_Small_Clause", Flag67 (Id));
6900 W ("Has_Specified_Layout", Flag100 (Id));
6901 W ("Has_Specified_Stream_Input", Flag190 (Id));
6902 W ("Has_Specified_Stream_Output", Flag191 (Id));
6903 W ("Has_Specified_Stream_Read", Flag192 (Id));
6904 W ("Has_Specified_Stream_Write", Flag193 (Id));
6905 W ("Has_Static_Discriminants", Flag211 (Id));
6906 W ("Has_Storage_Size_Clause", Flag23 (Id));
6907 W ("Has_Stream_Size_Clause", Flag184 (Id));
6908 W ("Has_Subprogram_Descriptor", Flag93 (Id));
6909 W ("Has_Task", Flag30 (Id));
6910 W ("Has_Thunks", Flag228 (Id));
6911 W ("Has_Unchecked_Union", Flag123 (Id));
6912 W ("Has_Unknown_Discriminants", Flag72 (Id));
6913 W ("Has_Up_Level_Access", Flag215 (Id));
6914 W ("Has_Volatile_Components", Flag87 (Id));
6915 W ("Has_Xref_Entry", Flag182 (Id));
6916 W ("Implemented_By_Entry", Flag232 (Id));
6917 W ("In_Package_Body", Flag48 (Id));
6918 W ("In_Private_Part", Flag45 (Id));
6919 W ("In_Use", Flag8 (Id));
6920 W ("Is_AST_Entry", Flag132 (Id));
6921 W ("Is_Abstract_Subprogram", Flag19 (Id));
6922 W ("Is_Abstract_Type", Flag146 (Id));
6923 W ("Is_Local_Anonymous_Access", Flag194 (Id));
6924 W ("Is_Access_Constant", Flag69 (Id));
6925 W ("Is_Ada_2005_Only", Flag185 (Id));
6926 W ("Is_Aliased", Flag15 (Id));
6927 W ("Is_Asynchronous", Flag81 (Id));
6928 W ("Is_Atomic", Flag85 (Id));
6929 W ("Is_Bit_Packed_Array", Flag122 (Id));
6930 W ("Is_CPP_Class", Flag74 (Id));
6931 W ("Is_Called", Flag102 (Id));
6932 W ("Is_Character_Type", Flag63 (Id));
6933 W ("Is_Child_Unit", Flag73 (Id));
6934 W ("Is_Class_Wide_Equivalent_Type", Flag35 (Id));
6935 W ("Is_Compilation_Unit", Flag149 (Id));
6936 W ("Is_Completely_Hidden", Flag103 (Id));
6937 W ("Is_Concurrent_Record_Type", Flag20 (Id));
6938 W ("Is_Constr_Subt_For_UN_Aliased", Flag141 (Id));
6939 W ("Is_Constr_Subt_For_U_Nominal", Flag80 (Id));
6940 W ("Is_Constrained", Flag12 (Id));
6941 W ("Is_Constructor", Flag76 (Id));
6942 W ("Is_Controlled", Flag42 (Id));
6943 W ("Is_Controlling_Formal", Flag97 (Id));
6944 W ("Is_Descendent_Of_Address", Flag223 (Id));
6945 W ("Is_Discrim_SO_Function", Flag176 (Id));
6946 W ("Is_Dispatch_Table_Entity", Flag234 (Id));
6947 W ("Is_Dispatching_Operation", Flag6 (Id));
6948 W ("Is_Eliminated", Flag124 (Id));
6949 W ("Is_Entry_Formal", Flag52 (Id));
6950 W ("Is_Exported", Flag99 (Id));
6951 W ("Is_First_Subtype", Flag70 (Id));
6952 W ("Is_For_Access_Subtype", Flag118 (Id));
6953 W ("Is_Formal_Subprogram", Flag111 (Id));
6954 W ("Is_Frozen", Flag4 (Id));
6955 W ("Is_Generic_Actual_Type", Flag94 (Id));
6956 W ("Is_Generic_Instance", Flag130 (Id));
6957 W ("Is_Generic_Type", Flag13 (Id));
6958 W ("Is_Hidden", Flag57 (Id));
6959 W ("Is_Hidden_Open_Scope", Flag171 (Id));
6960 W ("Is_Immediately_Visible", Flag7 (Id));
6961 W ("Is_Imported", Flag24 (Id));
6962 W ("Is_Inlined", Flag11 (Id));
6963 W ("Is_Instantiated", Flag126 (Id));
6964 W ("Is_Interface", Flag186 (Id));
6965 W ("Is_Internal", Flag17 (Id));
6966 W ("Is_Interrupt_Handler", Flag89 (Id));
6967 W ("Is_Intrinsic_Subprogram", Flag64 (Id));
6968 W ("Is_Itype", Flag91 (Id));
6969 W ("Is_Known_Non_Null", Flag37 (Id));
6970 W ("Is_Known_Null", Flag204 (Id));
6971 W ("Is_Known_Valid", Flag170 (Id));
6972 W ("Is_Limited_Composite", Flag106 (Id));
6973 W ("Is_Limited_Interface", Flag197 (Id));
6974 W ("Is_Limited_Record", Flag25 (Id));
6975 W ("Is_Machine_Code_Subprogram", Flag137 (Id));
6976 W ("Is_Non_Static_Subtype", Flag109 (Id));
6977 W ("Is_Null_Init_Proc", Flag178 (Id));
6978 W ("Is_Obsolescent", Flag153 (Id));
6979 W ("Is_Only_Out_Parameter", Flag226 (Id));
6980 W ("Is_Optional_Parameter", Flag134 (Id));
6981 W ("Is_Overriding_Operation", Flag39 (Id));
6982 W ("Is_Package_Body_Entity", Flag160 (Id));
6983 W ("Is_Packed", Flag51 (Id));
6984 W ("Is_Packed_Array_Type", Flag138 (Id));
6985 W ("Is_Potentially_Use_Visible", Flag9 (Id));
6986 W ("Is_Preelaborated", Flag59 (Id));
6987 W ("Is_Primitive", Flag218 (Id));
6988 W ("Is_Primitive_Wrapper", Flag195 (Id));
6989 W ("Is_Private_Composite", Flag107 (Id));
6990 W ("Is_Private_Descendant", Flag53 (Id));
6991 W ("Is_Private_Primitive", Flag245 (Id));
6992 W ("Is_Protected_Interface", Flag198 (Id));
6993 W ("Is_Public", Flag10 (Id));
6994 W ("Is_Pure", Flag44 (Id));
6995 W ("Is_Pure_Unit_Access_Type", Flag189 (Id));
6996 W ("Is_RACW_Stub_Type", Flag244 (Id));
6997 W ("Is_Raised", Flag224 (Id));
6998 W ("Is_Remote_Call_Interface", Flag62 (Id));
6999 W ("Is_Remote_Types", Flag61 (Id));
7000 W ("Is_Renaming_Of_Object", Flag112 (Id));
7001 W ("Is_Return_Object", Flag209 (Id));
7002 W ("Is_Shared_Passive", Flag60 (Id));
7003 W ("Is_Synchronized_Interface", Flag199 (Id));
7004 W ("Is_Statically_Allocated", Flag28 (Id));
7005 W ("Is_Tag", Flag78 (Id));
7006 W ("Is_Tagged_Type", Flag55 (Id));
7007 W ("Is_Task_Interface", Flag200 (Id));
7008 W ("Is_Thunk", Flag225 (Id));
7009 W ("Is_Trivial_Subprogram", Flag235 (Id));
7010 W ("Is_True_Constant", Flag163 (Id));
7011 W ("Is_Unchecked_Union", Flag117 (Id));
7012 W ("Is_Underlying_Record_View", Flag246 (Id));
7013 W ("Is_Unsigned_Type", Flag144 (Id));
7014 W ("Is_VMS_Exception", Flag133 (Id));
7015 W ("Is_Valued_Procedure", Flag127 (Id));
7016 W ("Is_Visible_Child_Unit", Flag116 (Id));
7017 W ("Is_Visible_Formal", Flag206 (Id));
7018 W ("Is_Volatile", Flag16 (Id));
7019 W ("Itype_Printed", Flag202 (Id));
7020 W ("Kill_Elaboration_Checks", Flag32 (Id));
7021 W ("Kill_Range_Checks", Flag33 (Id));
7022 W ("Kill_Tag_Checks", Flag34 (Id));
7023 W ("Known_To_Have_Preelab_Init", Flag207 (Id));
7024 W ("Low_Bound_Tested", Flag205 (Id));
7025 W ("Machine_Radix_10", Flag84 (Id));
7026 W ("Materialize_Entity", Flag168 (Id));
7027 W ("Must_Be_On_Byte_Boundary", Flag183 (Id));
7028 W ("Must_Have_Preelab_Init", Flag208 (Id));
7029 W ("Needs_Debug_Info", Flag147 (Id));
7030 W ("Needs_No_Actuals", Flag22 (Id));
7031 W ("Never_Set_In_Source", Flag115 (Id));
7032 W ("No_Pool_Assigned", Flag131 (Id));
7033 W ("No_Return", Flag113 (Id));
7034 W ("No_Strict_Aliasing", Flag136 (Id));
7035 W ("Non_Binary_Modulus", Flag58 (Id));
7036 W ("Nonzero_Is_True", Flag162 (Id));
7037 W ("OK_To_Rename", Flag247 (Id));
7038 W ("OK_To_Reorder_Components", Flag239 (Id));
7039 W ("Optimize_Alignment_Space", Flag241 (Id));
7040 W ("Optimize_Alignment_Time", Flag242 (Id));
7041 W ("Overlays_Constant", Flag243 (Id));
7042 W ("Reachable", Flag49 (Id));
7043 W ("Referenced", Flag156 (Id));
7044 W ("Referenced_As_LHS", Flag36 (Id));
7045 W ("Referenced_As_Out_Parameter", Flag227 (Id));
7046 W ("Renamed_In_Spec", Flag231 (Id));
7047 W ("Requires_Overriding", Flag213 (Id));
7048 W ("Return_Present", Flag54 (Id));
7049 W ("Returns_By_Ref", Flag90 (Id));
7050 W ("Reverse_Bit_Order", Flag164 (Id));
7051 W ("Sec_Stack_Needed_For_Return", Flag167 (Id));
7052 W ("Size_Depends_On_Discriminant", Flag177 (Id));
7053 W ("Size_Known_At_Compile_Time", Flag92 (Id));
7054 W ("Static_Elaboration_Desired", Flag77 (Id));
7055 W ("Strict_Alignment", Flag145 (Id));
7056 W ("Suppress_Elaboration_Warnings", Flag148 (Id));
7057 W ("Suppress_Init_Proc", Flag105 (Id));
7058 W ("Suppress_Style_Checks", Flag165 (Id));
7059 W ("Suppress_Value_Tracking_On_Call", Flag217 (Id));
7060 W ("Treat_As_Volatile", Flag41 (Id));
7061 W ("Universal_Aliasing", Flag216 (Id));
7062 W ("Used_As_Generic_Actual", Flag222 (Id));
7063 W ("Uses_Sec_Stack", Flag95 (Id));
7064 W ("Vax_Float", Flag151 (Id));
7065 W ("Warnings_Off", Flag96 (Id));
7066 W ("Warnings_Off_Used", Flag236 (Id));
7067 W ("Warnings_Off_Used_Unmodified", Flag237 (Id));
7068 W ("Warnings_Off_Used_Unreferenced", Flag238 (Id));
7069 W ("Was_Hidden", Flag196 (Id));
7070 end Write_Entity_Flags;
7072 -----------------------
7073 -- Write_Entity_Info --
7074 -----------------------
7076 procedure Write_Entity_Info (Id : Entity_Id; Prefix : String) is
7078 procedure Write_Attribute (Which : String; Nam : E);
7079 -- Write attribute value with given string name
7081 procedure Write_Kind (Id : Entity_Id);
7082 -- Write Ekind field of entity
7084 ---------------------
7085 -- Write_Attribute --
7086 ---------------------
7088 procedure Write_Attribute (Which : String; Nam : E) is
7092 Write_Int (Int (Nam));
7094 Write_Name (Chars (Nam));
7096 end Write_Attribute;
7102 procedure Write_Kind (Id : Entity_Id) is
7103 K : constant String := Entity_Kind'Image (Ekind (Id));
7107 Write_Str (" Kind ");
7109 if Is_Type (Id) and then Is_Tagged_Type (Id) then
7110 Write_Str ("TAGGED ");
7113 Write_Str (K (3 .. K'Length));
7116 if Is_Type (Id) and then Depends_On_Private (Id) then
7117 Write_Str ("Depends_On_Private ");
7121 -- Start of processing for Write_Entity_Info
7125 Write_Attribute ("Name ", Id);
7126 Write_Int (Int (Id));
7130 Write_Attribute (" Type ", Etype (Id));
7132 Write_Attribute (" Scope ", Scope (Id));
7137 when Discrete_Kind =>
7138 Write_Str ("Bounds: Id = ");
7140 if Present (Scalar_Range (Id)) then
7141 Write_Int (Int (Type_Low_Bound (Id)));
7142 Write_Str (" .. Id = ");
7143 Write_Int (Int (Type_High_Bound (Id)));
7145 Write_Str ("Empty");
7156 (" Component Type ", Component_Type (Id));
7159 Write_Str (" Indices ");
7161 Index := First_Index (Id);
7162 while Present (Index) loop
7163 Write_Attribute (" ", Etype (Index));
7164 Index := Next_Index (Index);
7172 (" Directly Designated Type ",
7173 Directly_Designated_Type (Id));
7176 when Overloadable_Kind =>
7177 if Present (Homonym (Id)) then
7178 Write_Str (" Homonym ");
7179 Write_Name (Chars (Homonym (Id)));
7181 Write_Int (Int (Homonym (Id)));
7188 if Ekind (Scope (Id)) in Record_Kind then
7190 " Original_Record_Component ",
7191 Original_Record_Component (Id));
7192 Write_Int (Int (Original_Record_Component (Id)));
7196 when others => null;
7198 end Write_Entity_Info;
7200 -----------------------
7201 -- Write_Field6_Name --
7202 -----------------------
7204 procedure Write_Field6_Name (Id : Entity_Id) is
7205 pragma Warnings (Off, Id);
7207 Write_Str ("First_Rep_Item");
7208 end Write_Field6_Name;
7210 -----------------------
7211 -- Write_Field7_Name --
7212 -----------------------
7214 procedure Write_Field7_Name (Id : Entity_Id) is
7215 pragma Warnings (Off, Id);
7217 Write_Str ("Freeze_Node");
7218 end Write_Field7_Name;
7220 -----------------------
7221 -- Write_Field8_Name --
7222 -----------------------
7224 procedure Write_Field8_Name (Id : Entity_Id) is
7229 Write_Str ("Normalized_First_Bit");
7233 E_Subprogram_Body =>
7234 Write_Str ("Mechanism");
7237 Write_Str ("Associated_Node_For_Itype");
7240 Write_Str ("Dependent_Instances");
7243 Write_Str ("Postcondition_Proc");
7245 when E_Return_Statement =>
7246 Write_Str ("Return_Applies_To");
7249 Write_Str ("Hiding_Loop_Variable");
7252 Write_Str ("Field8??");
7254 end Write_Field8_Name;
7256 -----------------------
7257 -- Write_Field9_Name --
7258 -----------------------
7260 procedure Write_Field9_Name (Id : Entity_Id) is
7264 Write_Str ("Class_Wide_Type");
7267 E_Generic_Function |
7269 E_Generic_Procedure |
7272 Write_Str ("Renaming_Map");
7275 Write_Str ("Current_Value");
7278 Write_Str ("Field9??");
7280 end Write_Field9_Name;
7282 ------------------------
7283 -- Write_Field10_Name --
7284 ------------------------
7286 procedure Write_Field10_Name (Id : Entity_Id) is
7290 Write_Str ("Referenced_Object");
7292 when E_In_Parameter |
7294 Write_Str ("Discriminal_Link");
7300 Write_Str ("Handler_Records");
7304 Write_Str ("Normalized_Position_Max");
7307 Write_Str ("Field10??");
7309 end Write_Field10_Name;
7311 ------------------------
7312 -- Write_Field11_Name --
7313 ------------------------
7315 procedure Write_Field11_Name (Id : Entity_Id) is
7319 Write_Str ("Entry_Component");
7323 Write_Str ("Component_Bit_Offset");
7326 Write_Str ("Full_View");
7328 when E_Enumeration_Literal =>
7329 Write_Str ("Enumeration_Pos");
7332 Write_Str ("Block_Node");
7338 Write_Str ("Protected_Body_Subprogram");
7340 when E_Generic_Package =>
7341 Write_Str ("Generic_Homonym");
7344 Write_Str ("Full_View");
7347 Write_Str ("Field11??");
7349 end Write_Field11_Name;
7351 ------------------------
7352 -- Write_Field12_Name --
7353 ------------------------
7355 procedure Write_Field12_Name (Id : Entity_Id) is
7359 Write_Str ("Barrier_Function");
7361 when E_Enumeration_Literal =>
7362 Write_Str ("Enumeration_Rep");
7370 E_In_Out_Parameter |
7374 Write_Str ("Esize");
7378 Write_Str ("Next_Inlined_Subprogram");
7381 Write_Str ("Associated_Formal_Package");
7384 Write_Str ("Field12??");
7386 end Write_Field12_Name;
7388 ------------------------
7389 -- Write_Field13_Name --
7390 ------------------------
7392 procedure Write_Field13_Name (Id : Entity_Id) is
7396 Write_Str ("RM_Size");
7400 Write_Str ("Component_Clause");
7403 if not Comes_From_Source (Id)
7405 Chars (Id) = Name_Op_Ne
7407 Write_Str ("Corresponding_Equality");
7409 elsif Comes_From_Source (Id) then
7410 Write_Str ("Elaboration_Entity");
7413 Write_Str ("Field13??");
7418 Write_Str ("Extra_Accessibility");
7422 Generic_Unit_Kind =>
7423 Write_Str ("Elaboration_Entity");
7426 Write_Str ("Field13??");
7428 end Write_Field13_Name;
7430 -----------------------
7431 -- Write_Field14_Name --
7432 -----------------------
7434 procedure Write_Field14_Name (Id : Entity_Id) is
7443 Write_Str ("Alignment");
7447 Write_Str ("Normalized_Position");
7451 Write_Str ("First_Optional_Parameter");
7454 E_Generic_Package =>
7455 Write_Str ("Shadow_Entities");
7458 Write_Str ("Field14??");
7460 end Write_Field14_Name;
7462 ------------------------
7463 -- Write_Field15_Name --
7464 ------------------------
7466 procedure Write_Field15_Name (Id : Entity_Id) is
7471 Write_Str ("Storage_Size_Variable");
7473 when Class_Wide_Kind |
7477 Write_Str ("Primitive_Operations");
7480 Write_Str ("DT_Entry_Count");
7482 when Decimal_Fixed_Point_Kind =>
7483 Write_Str ("Scale_Value");
7485 when E_Discriminant =>
7486 Write_Str ("Discriminant_Number");
7489 Write_Str ("Extra_Formal");
7493 Write_Str ("DT_Position");
7496 Write_Str ("Entry_Parameters_Type");
7498 when Enumeration_Kind =>
7499 Write_Str ("Lit_Indexes");
7503 Write_Str ("Related_Instance");
7505 when E_Protected_Type =>
7506 Write_Str ("Entry_Bodies_Array");
7508 when E_String_Literal_Subtype =>
7509 Write_Str ("String_Literal_Low_Bound");
7512 Write_Str ("Field15??");
7514 end Write_Field15_Name;
7516 ------------------------
7517 -- Write_Field16_Name --
7518 ------------------------
7520 procedure Write_Field16_Name (Id : Entity_Id) is
7524 Write_Str ("Entry_Formal");
7528 Write_Str ("DTC_Entity");
7533 Write_Str ("First_Private_Entity");
7535 when E_Record_Type |
7536 E_Record_Type_With_Private =>
7537 Write_Str ("Access_Disp_Table");
7539 when E_String_Literal_Subtype =>
7540 Write_Str ("String_Literal_Length");
7542 when Enumeration_Kind =>
7543 Write_Str ("Lit_Strings");
7547 Write_Str ("Unset_Reference");
7549 when E_Record_Subtype |
7550 E_Class_Wide_Subtype =>
7551 Write_Str ("Cloned_Subtype");
7554 Write_Str ("Field16??");
7556 end Write_Field16_Name;
7558 ------------------------
7559 -- Write_Field17_Name --
7560 ------------------------
7562 procedure Write_Field17_Name (Id : Entity_Id) is
7566 Write_Str ("Digits_Value");
7569 Write_Str ("Prival");
7571 when E_Discriminant =>
7572 Write_Str ("Discriminal");
7581 E_Generic_Function |
7583 E_Generic_Procedure |
7591 E_Return_Statement |
7593 E_Subprogram_Type =>
7594 Write_Str ("First_Entity");
7597 Write_Str ("First_Index");
7599 when Enumeration_Kind =>
7600 Write_Str ("First_Literal");
7603 Write_Str ("Master_Id");
7605 when Modular_Integer_Kind =>
7606 Write_Str ("Modulus");
7610 E_Generic_In_Out_Parameter |
7612 Write_Str ("Actual_Subtype");
7614 when E_Incomplete_Type =>
7615 Write_Str ("Non_Limited_View");
7617 when E_Incomplete_Subtype =>
7618 if From_With_Type (Id) then
7619 Write_Str ("Non_Limited_View");
7623 Write_Str ("Field17??");
7625 end Write_Field17_Name;
7627 ------------------------
7628 -- Write_Field18_Name --
7629 ------------------------
7631 procedure Write_Field18_Name (Id : Entity_Id) is
7634 when E_Enumeration_Literal |
7638 Write_Str ("Alias");
7640 when E_Record_Type =>
7641 Write_Str ("Corresponding_Concurrent_Type");
7643 when E_Entry_Index_Parameter =>
7644 Write_Str ("Entry_Index_Constant");
7646 when E_Class_Wide_Subtype |
7647 E_Access_Protected_Subprogram_Type |
7648 E_Anonymous_Access_Protected_Subprogram_Type |
7649 E_Access_Subprogram_Type |
7651 Write_Str ("Equivalent_Type");
7653 when Fixed_Point_Kind =>
7654 Write_Str ("Delta_Value");
7657 Write_Str ("Renamed_Object");
7661 E_Generic_Function |
7662 E_Generic_Procedure |
7663 E_Generic_Package =>
7664 Write_Str ("Renamed_Entity");
7666 when Incomplete_Or_Private_Kind =>
7667 Write_Str ("Private_Dependents");
7669 when Concurrent_Kind =>
7670 Write_Str ("Corresponding_Record_Type");
7675 Write_Str ("Enclosing_Scope");
7678 Write_Str ("Field18??");
7680 end Write_Field18_Name;
7682 -----------------------
7683 -- Write_Field19_Name --
7684 -----------------------
7686 procedure Write_Field19_Name (Id : Entity_Id) is
7691 Write_Str ("Related_Array_Object");
7697 E_Return_Statement |
7699 Write_Str ("Finalization_Chain_Entity");
7701 when E_Constant | E_Variable =>
7702 Write_Str ("Size_Check_Code");
7704 when E_Discriminant =>
7705 Write_Str ("Corresponding_Discriminant");
7708 E_Generic_Package =>
7709 Write_Str ("Body_Entity");
7711 when E_Package_Body |
7713 Write_Str ("Spec_Entity");
7715 when Private_Kind =>
7716 Write_Str ("Underlying_Full_View");
7718 when E_Record_Type =>
7719 Write_Str ("Parent_Subtype");
7722 Write_Str ("Field19??");
7724 end Write_Field19_Name;
7726 -----------------------
7727 -- Write_Field20_Name --
7728 -----------------------
7730 procedure Write_Field20_Name (Id : Entity_Id) is
7734 Write_Str ("Component_Type");
7736 when E_In_Parameter |
7737 E_Generic_In_Parameter =>
7738 Write_Str ("Default_Value");
7741 Write_Str ("Directly_Designated_Type");
7744 Write_Str ("Discriminant_Checking_Func");
7748 Write_Str ("Prival_Link");
7750 when E_Discriminant =>
7751 Write_Str ("Discriminant_Default_Value");
7760 E_Generic_Function |
7762 E_Generic_Procedure |
7770 E_Return_Statement |
7772 E_Subprogram_Type =>
7774 Write_Str ("Last_Entity");
7777 Write_Str ("Scalar_Range");
7780 Write_Str ("Register_Exception_Call");
7783 Write_Str ("Field20??");
7785 end Write_Field20_Name;
7787 -----------------------
7788 -- Write_Field21_Name --
7789 -----------------------
7791 procedure Write_Field21_Name (Id : Entity_Id) is
7797 E_Generic_Function |
7799 E_Generic_Procedure |
7801 Write_Str ("Interface_Name");
7803 when Concurrent_Kind |
7804 Incomplete_Or_Private_Kind |
7808 Write_Str ("Discriminant_Constraint");
7811 Write_Str ("Accept_Address");
7813 when Fixed_Point_Kind =>
7814 Write_Str ("Small_Value");
7816 when E_In_Parameter =>
7817 Write_Str ("Default_Expr_Function");
7820 Modular_Integer_Kind =>
7821 Write_Str ("Original_Array_Type");
7824 Write_Str ("Field21??");
7826 end Write_Field21_Name;
7828 -----------------------
7829 -- Write_Field22_Name --
7830 -----------------------
7832 procedure Write_Field22_Name (Id : Entity_Id) is
7836 Write_Str ("Associated_Storage_Pool");
7839 Write_Str ("Component_Size");
7843 Write_Str ("Original_Record_Component");
7845 when E_Enumeration_Literal =>
7846 Write_Str ("Enumeration_Rep_Expr");
7849 Write_Str ("Exception_Code");
7852 Write_Str ("Protected_Formal");
7854 when E_Record_Type =>
7855 Write_Str ("Corresponding_Remote_Type");
7865 E_Generic_Function |
7866 E_Generic_Procedure |
7869 E_Return_Statement |
7872 Write_Str ("Scope_Depth_Value");
7874 when E_Record_Type_With_Private |
7875 E_Record_Subtype_With_Private |
7878 E_Limited_Private_Type |
7879 E_Limited_Private_Subtype =>
7880 Write_Str ("Private_View");
7883 Write_Str ("Shared_Var_Procs_Instance");
7886 Write_Str ("Field22??");
7888 end Write_Field22_Name;
7890 ------------------------
7891 -- Write_Field23_Name --
7892 ------------------------
7894 procedure Write_Field23_Name (Id : Entity_Id) is
7898 Write_Str ("Associated_Final_Chain");
7901 Write_Str ("Packed_Array_Type");
7904 Write_Str ("Entry_Cancel_Parameter");
7906 when E_Discriminant =>
7907 Write_Str ("CR_Discriminant");
7909 when E_Enumeration_Type =>
7910 Write_Str ("Enum_Pos_To_Rep");
7914 Write_Str ("Extra_Constrained");
7916 when E_Generic_Function |
7918 E_Generic_Procedure =>
7919 Write_Str ("Inner_Instances");
7921 when Concurrent_Kind |
7922 Incomplete_Or_Private_Kind |
7926 Write_Str ("Stored_Constraint");
7930 if Present (Scope (Id))
7931 and then Is_Protected_Type (Scope (Id))
7933 Write_Str ("Protection_Object");
7935 Write_Str ("Generic_Renamings");
7939 if Is_Generic_Instance (Id) then
7940 Write_Str ("Generic_Renamings");
7942 Write_Str ("Limited_View");
7946 Write_Str ("Protection_Object");
7949 Write_Str ("Field23??");
7951 end Write_Field23_Name;
7953 ------------------------
7954 -- Write_Field24_Name --
7955 ------------------------
7957 procedure Write_Field24_Name (Id : Entity_Id) is
7960 when Subprogram_Kind =>
7961 Write_Str ("Spec_PPC_List");
7963 when E_Record_Type =>
7964 Write_Str ("Underlying record view");
7966 when E_Variable | E_Constant =>
7967 Write_Str ("Related expression");
7972 end Write_Field24_Name;
7974 ------------------------
7975 -- Write_Field25_Name --
7976 ------------------------
7978 procedure Write_Field25_Name (Id : Entity_Id) is
7982 Write_Str ("DT_Offset_To_Top_Func");
7986 Write_Str ("Interface_Alias");
7988 when E_Record_Type |
7990 E_Record_Type_With_Private |
7991 E_Record_Subtype_With_Private =>
7992 Write_Str ("Interfaces");
7995 Write_Str ("Task_Body_Procedure");
7998 Write_Str ("Debug_Renaming_Link");
8001 Write_Str ("Field25??");
8003 end Write_Field25_Name;
8005 ------------------------
8006 -- Write_Field26_Name --
8007 ------------------------
8009 procedure Write_Field26_Name (Id : Entity_Id) is
8014 Write_Str ("Related_Type");
8016 when E_Generic_Package |
8018 Write_Str ("Package_Instantiation");
8023 if Is_Dispatching_Operation (Id) then
8024 Write_Str ("Overridden_Operation");
8026 Write_Str ("Static_Initialization");
8029 when E_Record_Type |
8030 E_Record_Type_With_Private =>
8031 Write_Str ("Dispatch_Table_Wrappers");
8033 when E_In_Out_Parameter |
8036 Write_Str ("Last_Assignment");
8039 Write_Str ("Relative_Deadline_Variable");
8042 Write_Str ("Field26??");
8044 end Write_Field26_Name;
8046 ------------------------
8047 -- Write_Field27_Name --
8048 ------------------------
8050 procedure Write_Field27_Name (Id : Entity_Id) is
8054 Write_Str ("Wrapped_Entity");
8056 when E_Package | Type_Kind =>
8057 Write_Str ("Current_Use_Clause");
8060 Write_Str ("Field27??");
8062 end Write_Field27_Name;
8064 ------------------------
8065 -- Write_Field28_Name --
8066 ------------------------
8068 procedure Write_Field28_Name (Id : Entity_Id) is
8071 when E_Procedure | E_Function | E_Entry =>
8072 Write_Str ("Extra_Formals");
8075 Write_Str ("Field28??");
8077 end Write_Field28_Name;
8079 -------------------------
8080 -- Iterator Procedures --
8081 -------------------------
8083 procedure Proc_Next_Component (N : in out Node_Id) is
8085 N := Next_Component (N);
8086 end Proc_Next_Component;
8088 procedure Proc_Next_Component_Or_Discriminant (N : in out Node_Id) is
8090 N := Next_Entity (N);
8091 while Present (N) loop
8092 exit when Ekind (N) = E_Component
8094 Ekind (N) = E_Discriminant;
8095 N := Next_Entity (N);
8097 end Proc_Next_Component_Or_Discriminant;
8099 procedure Proc_Next_Discriminant (N : in out Node_Id) is
8101 N := Next_Discriminant (N);
8102 end Proc_Next_Discriminant;
8104 procedure Proc_Next_Formal (N : in out Node_Id) is
8106 N := Next_Formal (N);
8107 end Proc_Next_Formal;
8109 procedure Proc_Next_Formal_With_Extras (N : in out Node_Id) is
8111 N := Next_Formal_With_Extras (N);
8112 end Proc_Next_Formal_With_Extras;
8114 procedure Proc_Next_Index (N : in out Node_Id) is
8116 N := Next_Index (N);
8117 end Proc_Next_Index;
8119 procedure Proc_Next_Inlined_Subprogram (N : in out Node_Id) is
8121 N := Next_Inlined_Subprogram (N);
8122 end Proc_Next_Inlined_Subprogram;
8124 procedure Proc_Next_Literal (N : in out Node_Id) is
8126 N := Next_Literal (N);
8127 end Proc_Next_Literal;
8129 procedure Proc_Next_Stored_Discriminant (N : in out Node_Id) is
8131 N := Next_Stored_Discriminant (N);
8132 end Proc_Next_Stored_Discriminant;