1 ------------------------------------------------------------------------------
3 -- GNAT COMPILER COMPONENTS --
9 -- Copyright (C) 1992-2008, 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 2, 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. See the GNU General Public License --
17 -- for more details. You should have received a copy of the GNU General --
18 -- Public License distributed with GNAT; see file COPYING. If not, write --
19 -- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, --
20 -- Boston, MA 02110-1301, USA. --
22 -- As a special exception, if other files instantiate generics from this --
23 -- unit, or you link this unit with other files to produce an executable, --
24 -- this unit does not by itself cause the resulting executable to be --
25 -- covered by the GNU General Public License. This exception does not --
26 -- however invalidate any other reasons why the executable file might be --
27 -- covered by the GNU Public License. --
29 -- GNAT was originally developed by the GNAT team at New York University. --
30 -- Extensive contributions were provided by Ada Core Technologies Inc. --
32 ------------------------------------------------------------------------------
34 pragma Style_Checks
(All_Checks
);
35 -- Turn off subprogram ordering, not used for this unit
37 with Atree
; use Atree
;
38 with Nlists
; use Nlists
;
39 with Output
; use Output
;
40 with Sinfo
; use Sinfo
;
41 with Stand
; use Stand
;
45 use Atree
.Unchecked_Access
;
46 -- This is one of the packages that is allowed direct untyped access to
47 -- the fields in a node, since it provides the next level abstraction
48 -- which incorporates appropriate checks.
50 ----------------------------------------------
51 -- Usage of Fields in Defining Entity Nodes --
52 ----------------------------------------------
54 -- Four of these fields are defined in Sinfo, since they in are the
55 -- base part of the node. The access routines for these fields and
56 -- the corresponding set procedures are defined in Sinfo. These fields
57 -- are present in all entities. Note that Homonym is also in the base
58 -- part of the node, but has access routines that are more properly
59 -- part of Einfo, which is why they are defined here.
66 -- Remaining fields are present only in extended nodes (i.e. entities)
68 -- The following fields are present in all entities
71 -- First_Rep_Item Node6
74 -- The usage of other fields (and the entity kinds to which it applies)
75 -- depends on the particular field (see Einfo spec for details).
77 -- Associated_Node_For_Itype Node8
78 -- Dependent_Instances Elist8
79 -- Hiding_Loop_Variable Node8
80 -- Mechanism Uint8 (but returns Mechanism_Type)
81 -- Normalized_First_Bit Uint8
82 -- Return_Applies_To Node8
84 -- Class_Wide_Type Node9
85 -- Current_Value Node9
88 -- Discriminal_Link Node10
89 -- Handler_Records List10
90 -- Normalized_Position_Max Uint10
91 -- Referenced_Object Node10
93 -- Component_Bit_Offset Uint11
95 -- Entry_Component Node11
96 -- Enumeration_Pos Uint11
97 -- Generic_Homonym Node11
98 -- Protected_Body_Subprogram Node11
101 -- Barrier_Function Node12
102 -- Enumeration_Rep Uint12
104 -- Next_Inlined_Subprogram Node12
106 -- Corresponding_Equality Node13
107 -- Component_Clause Node13
108 -- Elaboration_Entity Node13
109 -- Extra_Accessibility Node13
113 -- First_Optional_Parameter Node14
114 -- Normalized_Position Uint14
115 -- Shadow_Entities List14
117 -- Discriminant_Number Uint15
118 -- DT_Position Uint15
119 -- DT_Entry_Count Uint15
120 -- Entry_Bodies_Array Node15
121 -- Entry_Parameters_Type Node15
122 -- Extra_Formal Node15
123 -- Lit_Indexes Node15
124 -- Primitive_Operations Elist15
125 -- Related_Instance Node15
126 -- Scale_Value Uint15
127 -- Storage_Size_Variable Node15
128 -- String_Literal_Low_Bound Node15
130 -- Access_Disp_Table Elist16
131 -- Cloned_Subtype Node16
133 -- Entry_Formal Node16
134 -- First_Private_Entity Node16
135 -- Lit_Strings Node16
136 -- String_Literal_Length Uint16
137 -- Unset_Reference Node16
139 -- Actual_Subtype Node17
140 -- Digits_Value Uint17
141 -- Discriminal Node17
142 -- First_Entity Node17
143 -- First_Index Node17
144 -- First_Literal Node17
147 -- Non_Limited_View Node17
151 -- Corresponding_Concurrent_Type Node18
152 -- Corresponding_Record_Type Node18
153 -- Delta_Value Ureal18
154 -- Enclosing_Scope Node18
155 -- Equivalent_Type Node18
156 -- Private_Dependents Elist18
157 -- Renamed_Entity Node18
158 -- Renamed_Object Node18
160 -- Body_Entity Node19
161 -- Corresponding_Discriminant Node19
162 -- Finalization_Chain_Entity Node19
163 -- Parent_Subtype Node19
164 -- Related_Array_Object Node19
165 -- Size_Check_Code Node19
166 -- Spec_Entity Node19
167 -- Underlying_Full_View Node19
169 -- Component_Type Node20
170 -- Default_Value Node20
171 -- Directly_Designated_Type Node20
172 -- Discriminant_Checking_Func Node20
173 -- Discriminant_Default_Value Node20
174 -- Last_Entity Node20
175 -- Prival_Link Node20
176 -- Register_Exception_Call Node20
177 -- Scalar_Range Node20
179 -- Accept_Address Elist21
180 -- Default_Expr_Function Node21
181 -- Discriminant_Constraint Elist21
182 -- Interface_Name Node21
183 -- Original_Array_Type Node21
184 -- Small_Value Ureal21
186 -- Associated_Storage_Pool Node22
187 -- Component_Size Uint22
188 -- Corresponding_Remote_Type Node22
189 -- Enumeration_Rep_Expr Node22
190 -- Exception_Code Uint22
191 -- Original_Record_Component Node22
192 -- Private_View Node22
193 -- Protected_Formal Node22
194 -- Scope_Depth_Value Uint22
195 -- Shared_Var_Procs_Instance Node22
197 -- Associated_Final_Chain Node23
198 -- CR_Discriminant Node23
199 -- Entry_Cancel_Parameter Node23
200 -- Enum_Pos_To_Rep Node23
201 -- Extra_Constrained Node23
202 -- Generic_Renamings Elist23
203 -- Inner_Instances Elist23
204 -- Limited_View Node23
205 -- Packed_Array_Type Node23
206 -- Protection_Object Node23
207 -- Stored_Constraint Elist23
209 -- Spec_PPC_List Node24
211 -- Interface_Alias Node25
212 -- Interfaces Elist25
213 -- Debug_Renaming_Link Node25
214 -- DT_Offset_To_Top_Func Node25
215 -- Task_Body_Procedure Node25
217 -- Dispatch_Table_Wrapper Node26
218 -- Last_Assignment Node26
219 -- Overridden_Operation Node26
220 -- Package_Instantiation Node26
221 -- Related_Type Node26
222 -- Relative_Deadline_Variable Node26
223 -- Static_Initialization Node26
225 -- Current_Use_Clause Node27
226 -- Wrapped_Entity Node27
228 -- Extra_Formals Node28
230 ---------------------------------------------
231 -- Usage of Flags in Defining Entity Nodes --
232 ---------------------------------------------
234 -- All flags are unique, there is no overlaying, so each flag is physically
235 -- present in every entity. However, for many of the flags, it only makes
236 -- sense for them to be set true for certain subsets of entity kinds. See
237 -- the spec of Einfo for further details.
239 -- Note: Flag1-Flag3 are absent from this list, since these flag positions
240 -- are used for the flags Analyzed, Comes_From_Source, and Error_Posted,
241 -- which are common to all nodes, including entity nodes.
244 -- Has_Discriminants Flag5
245 -- Is_Dispatching_Operation Flag6
246 -- Is_Immediately_Visible Flag7
248 -- Is_Potentially_Use_Visible Flag9
252 -- Is_Constrained Flag12
253 -- Is_Generic_Type Flag13
254 -- Depends_On_Private Flag14
256 -- Is_Volatile Flag16
257 -- Is_Internal Flag17
258 -- Has_Delayed_Freeze Flag18
259 -- Is_Abstract_Subprogram Flag19
260 -- Is_Concurrent_Record_Type Flag20
262 -- Has_Master_Entity Flag21
263 -- Needs_No_Actuals Flag22
264 -- Has_Storage_Size_Clause Flag23
265 -- Is_Imported Flag24
266 -- Is_Limited_Record Flag25
267 -- Has_Completion Flag26
268 -- Has_Pragma_Controlled Flag27
269 -- Is_Statically_Allocated Flag28
270 -- Has_Size_Clause Flag29
273 -- Checks_May_Be_Suppressed Flag31
274 -- Kill_Elaboration_Checks Flag32
275 -- Kill_Range_Checks Flag33
276 -- Kill_Tag_Checks Flag34
277 -- Is_Class_Wide_Equivalent_Type Flag35
278 -- Referenced_As_LHS Flag36
279 -- Is_Known_Non_Null Flag37
280 -- Can_Never_Be_Null Flag38
281 -- Is_Overriding_Operation Flag39
282 -- Body_Needed_For_SAL Flag40
284 -- Treat_As_Volatile Flag41
285 -- Is_Controlled Flag42
286 -- Has_Controlled_Component Flag43
288 -- In_Private_Part Flag45
289 -- Has_Alignment_Clause Flag46
291 -- In_Package_Body Flag48
293 -- Delay_Subprogram_Descriptors Flag50
296 -- Is_Entry_Formal Flag52
297 -- Is_Private_Descendant Flag53
298 -- Return_Present Flag54
299 -- Is_Tagged_Type Flag55
300 -- Has_Homonym Flag56
302 -- Non_Binary_Modulus Flag58
303 -- Is_Preelaborated Flag59
304 -- Is_Shared_Passive Flag60
306 -- Is_Remote_Types Flag61
307 -- Is_Remote_Call_Interface Flag62
308 -- Is_Character_Type Flag63
309 -- Is_Intrinsic_Subprogram Flag64
310 -- Has_Record_Rep_Clause Flag65
311 -- Has_Enumeration_Rep_Clause Flag66
312 -- Has_Small_Clause Flag67
313 -- Has_Component_Size_Clause Flag68
314 -- Is_Access_Constant Flag69
315 -- Is_First_Subtype Flag70
317 -- Has_Completion_In_Body Flag71
318 -- Has_Unknown_Discriminants Flag72
319 -- Is_Child_Unit Flag73
320 -- Is_CPP_Class Flag74
321 -- Has_Non_Standard_Rep Flag75
322 -- Is_Constructor Flag76
323 -- Static_Elaboration_Desired Flag77
325 -- Has_All_Calls_Remote Flag79
326 -- Is_Constr_Subt_For_U_Nominal Flag80
328 -- Is_Asynchronous Flag81
329 -- Has_Gigi_Rep_Item Flag82
330 -- Has_Machine_Radix_Clause Flag83
331 -- Machine_Radix_10 Flag84
333 -- Has_Atomic_Components Flag86
334 -- Has_Volatile_Components Flag87
335 -- Discard_Names Flag88
336 -- Is_Interrupt_Handler Flag89
337 -- Returns_By_Ref Flag90
340 -- Size_Known_At_Compile_Time Flag92
341 -- Has_Subprogram_Descriptor Flag93
342 -- Is_Generic_Actual_Type Flag94
343 -- Uses_Sec_Stack Flag95
344 -- Warnings_Off Flag96
345 -- Is_Controlling_Formal Flag97
346 -- Has_Controlling_Result Flag98
347 -- Is_Exported Flag99
348 -- Has_Specified_Layout Flag100
350 -- Has_Nested_Block_With_Handler Flag101
352 -- Is_Completely_Hidden Flag103
353 -- Address_Taken Flag104
354 -- Suppress_Init_Proc Flag105
355 -- Is_Limited_Composite Flag106
356 -- Is_Private_Composite Flag107
357 -- Default_Expressions_Processed Flag108
358 -- Is_Non_Static_Subtype Flag109
359 -- Has_External_Tag_Rep_Clause Flag110
361 -- Is_Formal_Subprogram Flag111
362 -- Is_Renaming_Of_Object Flag112
364 -- Delay_Cleanups Flag114
365 -- Never_Set_In_Source Flag115
366 -- Is_Visible_Child_Unit Flag116
367 -- Is_Unchecked_Union Flag117
368 -- Is_For_Access_Subtype Flag118
369 -- Has_Convention_Pragma Flag119
370 -- Has_Primitive_Operations Flag120
372 -- Has_Pragma_Pack Flag121
373 -- Is_Bit_Packed_Array Flag122
374 -- Has_Unchecked_Union Flag123
375 -- Is_Eliminated Flag124
376 -- C_Pass_By_Copy Flag125
377 -- Is_Instantiated Flag126
378 -- Is_Valued_Procedure Flag127
379 -- (used for Component_Alignment) Flag128
380 -- (used for Component_Alignment) Flag129
381 -- Is_Generic_Instance Flag130
383 -- No_Pool_Assigned Flag131
384 -- Is_AST_Entry Flag132
385 -- Is_VMS_Exception Flag133
386 -- Is_Optional_Parameter Flag134
387 -- Has_Aliased_Components Flag135
388 -- No_Strict_Aliasing Flag136
389 -- Is_Machine_Code_Subprogram Flag137
390 -- Is_Packed_Array_Type Flag138
391 -- Has_Biased_Representation Flag139
392 -- Has_Complex_Representation Flag140
394 -- Is_Constr_Subt_For_UN_Aliased Flag141
395 -- Has_Missing_Return Flag142
396 -- Has_Recursive_Call Flag143
397 -- Is_Unsigned_Type Flag144
398 -- Strict_Alignment Flag145
399 -- Is_Abstract_Type Flag146
400 -- Needs_Debug_Info Flag147
401 -- Suppress_Elaboration_Warnings Flag148
402 -- Is_Compilation_Unit Flag149
403 -- Has_Pragma_Elaborate_Body Flag150
406 -- Entry_Accepted Flag152
407 -- Is_Obsolescent Flag153
408 -- Has_Per_Object_Constraint Flag154
409 -- Has_Private_Declaration Flag155
410 -- Referenced Flag156
411 -- Has_Pragma_Inline Flag157
412 -- Finalize_Storage_Only Flag158
413 -- From_With_Type Flag159
414 -- Is_Package_Body_Entity Flag160
416 -- Has_Qualified_Name Flag161
417 -- Nonzero_Is_True Flag162
418 -- Is_True_Constant Flag163
419 -- Reverse_Bit_Order Flag164
420 -- Suppress_Style_Checks Flag165
421 -- Debug_Info_Off Flag166
422 -- Sec_Stack_Needed_For_Return Flag167
423 -- Materialize_Entity Flag168
424 -- Is_Known_Valid Flag170
426 -- Is_Hidden_Open_Scope Flag171
427 -- Has_Object_Size_Clause Flag172
428 -- Has_Fully_Qualified_Name Flag173
429 -- Elaboration_Entity_Required Flag174
430 -- Has_Forward_Instantiation Flag175
431 -- Is_Discrim_SO_Function Flag176
432 -- Size_Depends_On_Discriminant Flag177
433 -- Is_Null_Init_Proc Flag178
434 -- Has_Pragma_Pure_Function Flag179
435 -- Has_Pragma_Unreferenced Flag180
437 -- Has_Contiguous_Rep Flag181
438 -- Has_Xref_Entry Flag182
439 -- Must_Be_On_Byte_Boundary Flag183
440 -- Has_Stream_Size_Clause Flag184
441 -- Is_Ada_2005_Only Flag185
442 -- Is_Interface Flag186
443 -- Has_Constrained_Partial_View Flag187
444 -- Has_Persistent_BSS Flag188
445 -- Is_Pure_Unit_Access_Type Flag189
446 -- Has_Specified_Stream_Input Flag190
448 -- Has_Specified_Stream_Output Flag191
449 -- Has_Specified_Stream_Read Flag192
450 -- Has_Specified_Stream_Write Flag193
451 -- Is_Local_Anonymous_Access Flag194
452 -- Is_Primitive_Wrapper Flag195
453 -- Was_Hidden Flag196
454 -- Is_Limited_Interface Flag197
455 -- Is_Protected_Interface Flag198
456 -- Is_Synchronized_Interface Flag199
457 -- Is_Task_Interface Flag200
459 -- Has_Anon_Block_Suffix Flag201
460 -- Itype_Printed Flag202
461 -- Has_Pragma_Pure Flag203
462 -- Is_Known_Null Flag204
463 -- Low_Bound_Known Flag205
464 -- Is_Visible_Formal Flag206
465 -- Known_To_Have_Preelab_Init Flag207
466 -- Must_Have_Preelab_Init Flag208
467 -- Is_Return_Object Flag209
468 -- Elaborate_Body_Desirable Flag210
470 -- Has_Static_Discriminants Flag211
471 -- Has_Pragma_Unreferenced_Objects Flag212
472 -- Requires_Overriding Flag213
474 -- Has_Up_Level_Access Flag215
475 -- Universal_Aliasing Flag216
476 -- Suppress_Value_Tracking_On_Call Flag217
477 -- Is_Primitive Flag218
478 -- Has_Initial_Value Flag219
479 -- Has_Dispatch_Table Flag220
481 -- Has_Pragma_Preelab_Init Flag221
482 -- Used_As_Generic_Actual Flag222
483 -- Is_Descendent_Of_Address Flag223
486 -- Is_Only_Out_Parameter Flag226
487 -- Referenced_As_Out_Parameter Flag227
488 -- Has_Thunks Flag228
489 -- Can_Use_Internal_Rep Flag229
490 -- Has_Pragma_Inline_Always Flag230
492 -- Renamed_In_Spec Flag231
493 -- Implemented_By_Entry Flag232
494 -- Has_Pragma_Unmodified Flag233
495 -- Is_Dispatch_Table_Entity Flag234
496 -- Is_Trivial_Subprogram Flag235
497 -- Warnings_Off_Used Flag236
498 -- Warnings_Off_Used_Unmodified Flag237
499 -- Warnings_Off_Used_Unreferenced Flag238
500 -- OK_To_Reorder_Components Flag239
501 -- Has_Postconditions Flag240
503 -- Optimize_Alignment_Space Flag241
504 -- Optimize_Alignment_Time Flag242
505 -- Overlays_Constant Flag243
506 -- Is_RACW_Stub_Type Flag244
507 -- Is_Private_Primitive Flag245
512 -----------------------
513 -- Local subprograms --
514 -----------------------
516 function Rep_Clause
(Id
: E
; Rep_Name
: Name_Id
) return N
;
517 -- Returns the attribute definition clause for Id whose name is Rep_Name.
518 -- Returns Empty if no matching attribute definition clause found for Id.
524 function Rep_Clause
(Id
: E
; Rep_Name
: Name_Id
) return N
is
528 Ritem
:= First_Rep_Item
(Id
);
529 while Present
(Ritem
) loop
530 if Nkind
(Ritem
) = N_Attribute_Definition_Clause
531 and then Chars
(Ritem
) = Rep_Name
535 Ritem
:= Next_Rep_Item
(Ritem
);
542 --------------------------------
543 -- Attribute Access Functions --
544 --------------------------------
546 function Accept_Address
(Id
: E
) return L
is
551 function Access_Disp_Table
(Id
: E
) return L
is
553 pragma Assert
(Is_Tagged_Type
(Id
));
554 return Elist16
(Implementation_Base_Type
(Id
));
555 end Access_Disp_Table
;
557 function Actual_Subtype
(Id
: E
) return E
is
560 (Ekind
(Id
) = E_Constant
561 or else Ekind
(Id
) = E_Variable
562 or else Ekind
(Id
) = E_Generic_In_Out_Parameter
563 or else Is_Formal
(Id
));
567 function Address_Taken
(Id
: E
) return B
is
572 function Alias
(Id
: E
) return E
is
575 (Is_Overloadable
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
579 function Alignment
(Id
: E
) return U
is
581 pragma Assert
(Is_Type
(Id
)
582 or else Is_Formal
(Id
)
583 or else Ekind
(Id
) = E_Loop_Parameter
584 or else Ekind
(Id
) = E_Constant
585 or else Ekind
(Id
) = E_Exception
586 or else Ekind
(Id
) = E_Variable
);
590 function Associated_Final_Chain
(Id
: E
) return E
is
592 pragma Assert
(Is_Access_Type
(Id
));
594 end Associated_Final_Chain
;
596 function Associated_Formal_Package
(Id
: E
) return E
is
598 pragma Assert
(Ekind
(Id
) = E_Package
);
600 end Associated_Formal_Package
;
602 function Associated_Node_For_Itype
(Id
: E
) return N
is
605 end Associated_Node_For_Itype
;
607 function Associated_Storage_Pool
(Id
: E
) return E
is
609 pragma Assert
(Is_Access_Type
(Id
));
610 return Node22
(Root_Type
(Id
));
611 end Associated_Storage_Pool
;
613 function Barrier_Function
(Id
: E
) return N
is
615 pragma Assert
(Is_Entry
(Id
));
617 end Barrier_Function
;
619 function Block_Node
(Id
: E
) return N
is
621 pragma Assert
(Ekind
(Id
) = E_Block
);
625 function Body_Entity
(Id
: E
) return E
is
628 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Generic_Package
);
632 function Body_Needed_For_SAL
(Id
: E
) return B
is
635 (Ekind
(Id
) = E_Package
636 or else Is_Subprogram
(Id
)
637 or else Is_Generic_Unit
(Id
));
639 end Body_Needed_For_SAL
;
641 function C_Pass_By_Copy
(Id
: E
) return B
is
643 pragma Assert
(Is_Record_Type
(Id
));
644 return Flag125
(Implementation_Base_Type
(Id
));
647 function Can_Never_Be_Null
(Id
: E
) return B
is
650 end Can_Never_Be_Null
;
652 function Checks_May_Be_Suppressed
(Id
: E
) return B
is
655 end Checks_May_Be_Suppressed
;
657 function Class_Wide_Type
(Id
: E
) return E
is
659 pragma Assert
(Is_Type
(Id
));
663 function Cloned_Subtype
(Id
: E
) return E
is
666 (Ekind
(Id
) = E_Record_Subtype
667 or else Ekind
(Id
) = E_Class_Wide_Subtype
);
671 function Component_Bit_Offset
(Id
: E
) return U
is
674 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
676 end Component_Bit_Offset
;
678 function Component_Clause
(Id
: E
) return N
is
681 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
683 end Component_Clause
;
685 function Component_Size
(Id
: E
) return U
is
687 pragma Assert
(Is_Array_Type
(Id
));
688 return Uint22
(Implementation_Base_Type
(Id
));
691 function Component_Type
(Id
: E
) return E
is
693 return Node20
(Implementation_Base_Type
(Id
));
696 function Corresponding_Concurrent_Type
(Id
: E
) return E
is
698 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
700 end Corresponding_Concurrent_Type
;
702 function Corresponding_Discriminant
(Id
: E
) return E
is
704 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
706 end Corresponding_Discriminant
;
708 function Corresponding_Equality
(Id
: E
) return E
is
711 (Ekind
(Id
) = E_Function
712 and then not Comes_From_Source
(Id
)
713 and then Chars
(Id
) = Name_Op_Ne
);
715 end Corresponding_Equality
;
717 function Corresponding_Record_Type
(Id
: E
) return E
is
719 pragma Assert
(Is_Concurrent_Type
(Id
));
721 end Corresponding_Record_Type
;
723 function Corresponding_Remote_Type
(Id
: E
) return E
is
726 end Corresponding_Remote_Type
;
728 function Current_Use_Clause
(Id
: E
) return E
is
730 pragma Assert
(Ekind
(Id
) = E_Package
or else Is_Type
(Id
));
732 end Current_Use_Clause
;
734 function Current_Value
(Id
: E
) return N
is
736 pragma Assert
(Ekind
(Id
) in Object_Kind
);
740 function CR_Discriminant
(Id
: E
) return E
is
745 function Debug_Info_Off
(Id
: E
) return B
is
750 function Debug_Renaming_Link
(Id
: E
) return E
is
753 end Debug_Renaming_Link
;
755 function Default_Expr_Function
(Id
: E
) return E
is
757 pragma Assert
(Is_Formal
(Id
));
759 end Default_Expr_Function
;
761 function Default_Expressions_Processed
(Id
: E
) return B
is
764 end Default_Expressions_Processed
;
766 function Default_Value
(Id
: E
) return N
is
768 pragma Assert
(Is_Formal
(Id
));
772 function Delay_Cleanups
(Id
: E
) return B
is
777 function Delay_Subprogram_Descriptors
(Id
: E
) return B
is
780 end Delay_Subprogram_Descriptors
;
782 function Delta_Value
(Id
: E
) return R
is
784 pragma Assert
(Is_Fixed_Point_Type
(Id
));
788 function Dependent_Instances
(Id
: E
) return L
is
790 pragma Assert
(Is_Generic_Instance
(Id
));
792 end Dependent_Instances
;
794 function Depends_On_Private
(Id
: E
) return B
is
796 pragma Assert
(Nkind
(Id
) in N_Entity
);
798 end Depends_On_Private
;
800 function Digits_Value
(Id
: E
) return U
is
803 (Is_Floating_Point_Type
(Id
)
804 or else Is_Decimal_Fixed_Point_Type
(Id
));
808 function Directly_Designated_Type
(Id
: E
) return E
is
811 end Directly_Designated_Type
;
813 function Discard_Names
(Id
: E
) return B
is
818 function Discriminal
(Id
: E
) return E
is
820 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
824 function Discriminal_Link
(Id
: E
) return N
is
827 end Discriminal_Link
;
829 function Discriminant_Checking_Func
(Id
: E
) return E
is
831 pragma Assert
(Ekind
(Id
) = E_Component
);
833 end Discriminant_Checking_Func
;
835 function Discriminant_Constraint
(Id
: E
) return L
is
837 pragma Assert
(Is_Composite_Type
(Id
) and then Has_Discriminants
(Id
));
839 end Discriminant_Constraint
;
841 function Discriminant_Default_Value
(Id
: E
) return N
is
843 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
845 end Discriminant_Default_Value
;
847 function Discriminant_Number
(Id
: E
) return U
is
849 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
851 end Discriminant_Number
;
853 function Dispatch_Table_Wrapper
(Id
: E
) return E
is
855 pragma Assert
(Is_Tagged_Type
(Id
));
856 return Node26
(Implementation_Base_Type
(Id
));
857 end Dispatch_Table_Wrapper
;
859 function DT_Entry_Count
(Id
: E
) return U
is
861 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
865 function DT_Offset_To_Top_Func
(Id
: E
) return E
is
867 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
869 end DT_Offset_To_Top_Func
;
871 function DT_Position
(Id
: E
) return U
is
874 ((Ekind
(Id
) = E_Function
875 or else Ekind
(Id
) = E_Procedure
)
876 and then Present
(DTC_Entity
(Id
)));
880 function DTC_Entity
(Id
: E
) return E
is
883 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
887 function Elaborate_Body_Desirable
(Id
: E
) return B
is
889 pragma Assert
(Ekind
(Id
) = E_Package
);
891 end Elaborate_Body_Desirable
;
893 function Elaboration_Entity
(Id
: E
) return E
is
898 Ekind
(Id
) = E_Package
900 Is_Generic_Unit
(Id
));
902 end Elaboration_Entity
;
904 function Elaboration_Entity_Required
(Id
: E
) return B
is
909 Ekind
(Id
) = E_Package
911 Is_Generic_Unit
(Id
));
913 end Elaboration_Entity_Required
;
915 function Enclosing_Scope
(Id
: E
) return E
is
920 function Entry_Accepted
(Id
: E
) return B
is
922 pragma Assert
(Is_Entry
(Id
));
926 function Entry_Bodies_Array
(Id
: E
) return E
is
929 end Entry_Bodies_Array
;
931 function Entry_Cancel_Parameter
(Id
: E
) return E
is
934 end Entry_Cancel_Parameter
;
936 function Entry_Component
(Id
: E
) return E
is
941 function Entry_Formal
(Id
: E
) return E
is
946 function Entry_Index_Constant
(Id
: E
) return N
is
948 pragma Assert
(Ekind
(Id
) = E_Entry_Index_Parameter
);
950 end Entry_Index_Constant
;
952 function Entry_Parameters_Type
(Id
: E
) return E
is
955 end Entry_Parameters_Type
;
957 function Enum_Pos_To_Rep
(Id
: E
) return E
is
959 pragma Assert
(Ekind
(Id
) = E_Enumeration_Type
);
963 function Enumeration_Pos
(Id
: E
) return Uint
is
965 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
969 function Enumeration_Rep
(Id
: E
) return U
is
971 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
975 function Enumeration_Rep_Expr
(Id
: E
) return N
is
977 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
979 end Enumeration_Rep_Expr
;
981 function Equivalent_Type
(Id
: E
) return E
is
984 (Ekind
(Id
) = E_Class_Wide_Subtype
or else
985 Ekind
(Id
) = E_Access_Protected_Subprogram_Type
or else
986 Ekind
(Id
) = E_Anonymous_Access_Protected_Subprogram_Type
or else
987 Ekind
(Id
) = E_Access_Subprogram_Type
or else
988 Ekind
(Id
) = E_Exception_Type
);
992 function Esize
(Id
: E
) return Uint
is
997 function Exception_Code
(Id
: E
) return Uint
is
999 pragma Assert
(Ekind
(Id
) = E_Exception
);
1003 function Extra_Accessibility
(Id
: E
) return E
is
1005 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
1007 end Extra_Accessibility
;
1009 function Extra_Constrained
(Id
: E
) return E
is
1011 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
1013 end Extra_Constrained
;
1015 function Extra_Formal
(Id
: E
) return E
is
1020 function Extra_Formals
(Id
: E
) return E
is
1023 (Is_Overloadable
(Id
)
1024 or else Ekind
(Id
) = E_Entry_Family
1025 or else Ekind
(Id
) = E_Subprogram_Body
1026 or else Ekind
(Id
) = E_Subprogram_Type
);
1030 function Can_Use_Internal_Rep
(Id
: E
) return B
is
1032 pragma Assert
(Is_Access_Subprogram_Type
(Base_Type
(Id
)));
1033 return Flag229
(Base_Type
(Id
));
1034 end Can_Use_Internal_Rep
;
1036 function Finalization_Chain_Entity
(Id
: E
) return E
is
1039 end Finalization_Chain_Entity
;
1041 function Finalize_Storage_Only
(Id
: E
) return B
is
1043 pragma Assert
(Is_Type
(Id
));
1044 return Flag158
(Base_Type
(Id
));
1045 end Finalize_Storage_Only
;
1047 function First_Entity
(Id
: E
) return E
is
1052 function First_Index
(Id
: E
) return N
is
1054 pragma Assert
(Is_Array_Type
(Id
) or else Is_String_Type
(Id
));
1058 function First_Literal
(Id
: E
) return E
is
1060 pragma Assert
(Is_Enumeration_Type
(Id
));
1064 function First_Optional_Parameter
(Id
: E
) return E
is
1067 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
1069 end First_Optional_Parameter
;
1071 function First_Private_Entity
(Id
: E
) return E
is
1073 pragma Assert
(Ekind
(Id
) = E_Package
1074 or else Ekind
(Id
) = E_Generic_Package
1075 or else Ekind
(Id
) in Concurrent_Kind
);
1077 end First_Private_Entity
;
1079 function First_Rep_Item
(Id
: E
) return E
is
1084 function Freeze_Node
(Id
: E
) return N
is
1089 function From_With_Type
(Id
: E
) return B
is
1091 return Flag159
(Id
);
1094 function Full_View
(Id
: E
) return E
is
1096 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Constant
);
1100 function Generic_Homonym
(Id
: E
) return E
is
1102 pragma Assert
(Ekind
(Id
) = E_Generic_Package
);
1104 end Generic_Homonym
;
1106 function Generic_Renamings
(Id
: E
) return L
is
1108 return Elist23
(Id
);
1109 end Generic_Renamings
;
1111 function Handler_Records
(Id
: E
) return S
is
1114 end Handler_Records
;
1116 function Has_Aliased_Components
(Id
: E
) return B
is
1118 return Flag135
(Implementation_Base_Type
(Id
));
1119 end Has_Aliased_Components
;
1121 function Has_Alignment_Clause
(Id
: E
) return B
is
1124 end Has_Alignment_Clause
;
1126 function Has_All_Calls_Remote
(Id
: E
) return B
is
1129 end Has_All_Calls_Remote
;
1131 function Has_Anon_Block_Suffix
(Id
: E
) return B
is
1133 return Flag201
(Id
);
1134 end Has_Anon_Block_Suffix
;
1136 function Has_Atomic_Components
(Id
: E
) return B
is
1138 return Flag86
(Implementation_Base_Type
(Id
));
1139 end Has_Atomic_Components
;
1141 function Has_Biased_Representation
(Id
: E
) return B
is
1143 return Flag139
(Id
);
1144 end Has_Biased_Representation
;
1146 function Has_Completion
(Id
: E
) return B
is
1151 function Has_Completion_In_Body
(Id
: E
) return B
is
1153 pragma Assert
(Is_Type
(Id
));
1155 end Has_Completion_In_Body
;
1157 function Has_Complex_Representation
(Id
: E
) return B
is
1159 pragma Assert
(Is_Type
(Id
));
1160 return Flag140
(Implementation_Base_Type
(Id
));
1161 end Has_Complex_Representation
;
1163 function Has_Component_Size_Clause
(Id
: E
) return B
is
1165 pragma Assert
(Is_Array_Type
(Id
));
1166 return Flag68
(Implementation_Base_Type
(Id
));
1167 end Has_Component_Size_Clause
;
1169 function Has_Constrained_Partial_View
(Id
: E
) return B
is
1171 pragma Assert
(Is_Type
(Id
));
1172 return Flag187
(Id
);
1173 end Has_Constrained_Partial_View
;
1175 function Has_Controlled_Component
(Id
: E
) return B
is
1177 return Flag43
(Base_Type
(Id
));
1178 end Has_Controlled_Component
;
1180 function Has_Contiguous_Rep
(Id
: E
) return B
is
1182 return Flag181
(Id
);
1183 end Has_Contiguous_Rep
;
1185 function Has_Controlling_Result
(Id
: E
) return B
is
1188 end Has_Controlling_Result
;
1190 function Has_Convention_Pragma
(Id
: E
) return B
is
1192 return Flag119
(Id
);
1193 end Has_Convention_Pragma
;
1195 function Has_Delayed_Freeze
(Id
: E
) return B
is
1197 pragma Assert
(Nkind
(Id
) in N_Entity
);
1199 end Has_Delayed_Freeze
;
1201 function Has_Discriminants
(Id
: E
) return B
is
1203 pragma Assert
(Nkind
(Id
) in N_Entity
);
1205 end Has_Discriminants
;
1207 function Has_Dispatch_Table
(Id
: E
) return B
is
1209 pragma Assert
(Is_Tagged_Type
(Id
));
1210 return Flag220
(Id
);
1211 end Has_Dispatch_Table
;
1213 function Has_Enumeration_Rep_Clause
(Id
: E
) return B
is
1215 pragma Assert
(Is_Enumeration_Type
(Id
));
1217 end Has_Enumeration_Rep_Clause
;
1219 function Has_Exit
(Id
: E
) return B
is
1224 function Has_External_Tag_Rep_Clause
(Id
: E
) return B
is
1226 pragma Assert
(Is_Tagged_Type
(Id
));
1227 return Flag110
(Id
);
1228 end Has_External_Tag_Rep_Clause
;
1230 function Has_Forward_Instantiation
(Id
: E
) return B
is
1232 return Flag175
(Id
);
1233 end Has_Forward_Instantiation
;
1235 function Has_Fully_Qualified_Name
(Id
: E
) return B
is
1237 return Flag173
(Id
);
1238 end Has_Fully_Qualified_Name
;
1240 function Has_Gigi_Rep_Item
(Id
: E
) return B
is
1243 end Has_Gigi_Rep_Item
;
1245 function Has_Homonym
(Id
: E
) return B
is
1250 function Has_Initial_Value
(Id
: E
) return B
is
1253 (Ekind
(Id
) = E_Variable
or else Is_Formal
(Id
));
1254 return Flag219
(Id
);
1255 end Has_Initial_Value
;
1257 function Has_Machine_Radix_Clause
(Id
: E
) return B
is
1259 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
1261 end Has_Machine_Radix_Clause
;
1263 function Has_Master_Entity
(Id
: E
) return B
is
1266 end Has_Master_Entity
;
1268 function Has_Missing_Return
(Id
: E
) return B
is
1271 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Generic_Function
);
1272 return Flag142
(Id
);
1273 end Has_Missing_Return
;
1275 function Has_Nested_Block_With_Handler
(Id
: E
) return B
is
1277 return Flag101
(Id
);
1278 end Has_Nested_Block_With_Handler
;
1280 function Has_Non_Standard_Rep
(Id
: E
) return B
is
1282 return Flag75
(Implementation_Base_Type
(Id
));
1283 end Has_Non_Standard_Rep
;
1285 function Has_Object_Size_Clause
(Id
: E
) return B
is
1287 pragma Assert
(Is_Type
(Id
));
1288 return Flag172
(Id
);
1289 end Has_Object_Size_Clause
;
1291 function Has_Per_Object_Constraint
(Id
: E
) return B
is
1293 return Flag154
(Id
);
1294 end Has_Per_Object_Constraint
;
1296 function Has_Persistent_BSS
(Id
: E
) return B
is
1298 return Flag188
(Id
);
1299 end Has_Persistent_BSS
;
1301 function Has_Postconditions
(Id
: E
) return B
is
1303 pragma Assert
(Is_Subprogram
(Id
));
1304 return Flag240
(Id
);
1305 end Has_Postconditions
;
1307 function Has_Pragma_Controlled
(Id
: E
) return B
is
1309 pragma Assert
(Is_Access_Type
(Id
));
1310 return Flag27
(Implementation_Base_Type
(Id
));
1311 end Has_Pragma_Controlled
;
1313 function Has_Pragma_Elaborate_Body
(Id
: E
) return B
is
1315 return Flag150
(Id
);
1316 end Has_Pragma_Elaborate_Body
;
1318 function Has_Pragma_Inline
(Id
: E
) return B
is
1320 return Flag157
(Id
);
1321 end Has_Pragma_Inline
;
1323 function Has_Pragma_Inline_Always
(Id
: E
) return B
is
1325 return Flag230
(Id
);
1326 end Has_Pragma_Inline_Always
;
1328 function Has_Pragma_Pack
(Id
: E
) return B
is
1330 pragma Assert
(Is_Record_Type
(Id
) or else Is_Array_Type
(Id
));
1331 return Flag121
(Implementation_Base_Type
(Id
));
1332 end Has_Pragma_Pack
;
1334 function Has_Pragma_Preelab_Init
(Id
: E
) return B
is
1336 return Flag221
(Id
);
1337 end Has_Pragma_Preelab_Init
;
1339 function Has_Pragma_Pure
(Id
: E
) return B
is
1341 return Flag203
(Id
);
1342 end Has_Pragma_Pure
;
1344 function Has_Pragma_Pure_Function
(Id
: E
) return B
is
1346 return Flag179
(Id
);
1347 end Has_Pragma_Pure_Function
;
1349 function Has_Pragma_Unmodified
(Id
: E
) return B
is
1351 return Flag233
(Id
);
1352 end Has_Pragma_Unmodified
;
1354 function Has_Pragma_Unreferenced
(Id
: E
) return B
is
1356 return Flag180
(Id
);
1357 end Has_Pragma_Unreferenced
;
1359 function Has_Pragma_Unreferenced_Objects
(Id
: E
) return B
is
1361 pragma Assert
(Is_Type
(Id
));
1362 return Flag212
(Id
);
1363 end Has_Pragma_Unreferenced_Objects
;
1365 function Has_Primitive_Operations
(Id
: E
) return B
is
1367 pragma Assert
(Is_Type
(Id
));
1368 return Flag120
(Base_Type
(Id
));
1369 end Has_Primitive_Operations
;
1371 function Has_Private_Declaration
(Id
: E
) return B
is
1373 return Flag155
(Id
);
1374 end Has_Private_Declaration
;
1376 function Has_Qualified_Name
(Id
: E
) return B
is
1378 return Flag161
(Id
);
1379 end Has_Qualified_Name
;
1381 function Has_RACW
(Id
: E
) return B
is
1383 pragma Assert
(Ekind
(Id
) = E_Package
);
1384 return Flag214
(Id
);
1387 function Has_Record_Rep_Clause
(Id
: E
) return B
is
1389 pragma Assert
(Is_Record_Type
(Id
));
1390 return Flag65
(Implementation_Base_Type
(Id
));
1391 end Has_Record_Rep_Clause
;
1393 function Has_Recursive_Call
(Id
: E
) return B
is
1395 pragma Assert
(Is_Subprogram
(Id
));
1396 return Flag143
(Id
);
1397 end Has_Recursive_Call
;
1399 function Has_Size_Clause
(Id
: E
) return B
is
1402 end Has_Size_Clause
;
1404 function Has_Small_Clause
(Id
: E
) return B
is
1407 end Has_Small_Clause
;
1409 function Has_Specified_Layout
(Id
: E
) return B
is
1411 pragma Assert
(Is_Type
(Id
));
1412 return Flag100
(Implementation_Base_Type
(Id
));
1413 end Has_Specified_Layout
;
1415 function Has_Specified_Stream_Input
(Id
: E
) return B
is
1417 pragma Assert
(Is_Type
(Id
));
1418 return Flag190
(Id
);
1419 end Has_Specified_Stream_Input
;
1421 function Has_Specified_Stream_Output
(Id
: E
) return B
is
1423 pragma Assert
(Is_Type
(Id
));
1424 return Flag191
(Id
);
1425 end Has_Specified_Stream_Output
;
1427 function Has_Specified_Stream_Read
(Id
: E
) return B
is
1429 pragma Assert
(Is_Type
(Id
));
1430 return Flag192
(Id
);
1431 end Has_Specified_Stream_Read
;
1433 function Has_Specified_Stream_Write
(Id
: E
) return B
is
1435 pragma Assert
(Is_Type
(Id
));
1436 return Flag193
(Id
);
1437 end Has_Specified_Stream_Write
;
1439 function Has_Static_Discriminants
(Id
: E
) return B
is
1441 pragma Assert
(Is_Type
(Id
));
1442 return Flag211
(Id
);
1443 end Has_Static_Discriminants
;
1445 function Has_Storage_Size_Clause
(Id
: E
) return B
is
1447 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
1448 return Flag23
(Implementation_Base_Type
(Id
));
1449 end Has_Storage_Size_Clause
;
1451 function Has_Stream_Size_Clause
(Id
: E
) return B
is
1453 return Flag184
(Id
);
1454 end Has_Stream_Size_Clause
;
1456 function Has_Subprogram_Descriptor
(Id
: E
) return B
is
1459 end Has_Subprogram_Descriptor
;
1461 function Has_Task
(Id
: E
) return B
is
1463 return Flag30
(Base_Type
(Id
));
1466 function Has_Thunks
(Id
: E
) return B
is
1468 pragma Assert
(Ekind
(Id
) = E_Constant
);
1469 return Flag228
(Id
);
1472 function Has_Unchecked_Union
(Id
: E
) return B
is
1474 return Flag123
(Base_Type
(Id
));
1475 end Has_Unchecked_Union
;
1477 function Has_Unknown_Discriminants
(Id
: E
) return B
is
1479 pragma Assert
(Is_Type
(Id
));
1481 end Has_Unknown_Discriminants
;
1483 function Has_Up_Level_Access
(Id
: E
) return B
is
1486 (Ekind
(Id
) = E_Variable
1487 or else Ekind
(Id
) = E_Constant
1488 or else Ekind
(Id
) = E_Loop_Parameter
);
1489 return Flag215
(Id
);
1490 end Has_Up_Level_Access
;
1492 function Has_Volatile_Components
(Id
: E
) return B
is
1494 return Flag87
(Implementation_Base_Type
(Id
));
1495 end Has_Volatile_Components
;
1497 function Has_Xref_Entry
(Id
: E
) return B
is
1499 return Flag182
(Implementation_Base_Type
(Id
));
1502 function Hiding_Loop_Variable
(Id
: E
) return E
is
1504 pragma Assert
(Ekind
(Id
) = E_Variable
);
1506 end Hiding_Loop_Variable
;
1508 function Homonym
(Id
: E
) return E
is
1513 function Implemented_By_Entry
(Id
: E
) return B
is
1516 (Ekind
(Id
) = E_Function
1517 or else Ekind
(Id
) = E_Procedure
);
1518 return Flag232
(Id
);
1519 end Implemented_By_Entry
;
1521 function Interfaces
(Id
: E
) return L
is
1523 pragma Assert
(Is_Record_Type
(Id
));
1524 return Elist25
(Id
);
1527 function Interface_Alias
(Id
: E
) return E
is
1529 pragma Assert
(Is_Subprogram
(Id
));
1531 end Interface_Alias
;
1533 function In_Package_Body
(Id
: E
) return B
is
1536 end In_Package_Body
;
1538 function In_Private_Part
(Id
: E
) return B
is
1541 end In_Private_Part
;
1543 function In_Use
(Id
: E
) return B
is
1545 pragma Assert
(Nkind
(Id
) in N_Entity
);
1549 function Inner_Instances
(Id
: E
) return L
is
1551 return Elist23
(Id
);
1552 end Inner_Instances
;
1554 function Interface_Name
(Id
: E
) return N
is
1559 function Is_Abstract_Subprogram
(Id
: E
) return B
is
1561 pragma Assert
(Is_Overloadable
(Id
));
1563 end Is_Abstract_Subprogram
;
1565 function Is_Abstract_Type
(Id
: E
) return B
is
1567 pragma Assert
(Is_Type
(Id
));
1568 return Flag146
(Id
);
1569 end Is_Abstract_Type
;
1571 function Is_Local_Anonymous_Access
(Id
: E
) return B
is
1573 pragma Assert
(Is_Access_Type
(Id
));
1574 return Flag194
(Id
);
1575 end Is_Local_Anonymous_Access
;
1577 function Is_Access_Constant
(Id
: E
) return B
is
1579 pragma Assert
(Is_Access_Type
(Id
));
1581 end Is_Access_Constant
;
1583 function Is_Ada_2005_Only
(Id
: E
) return B
is
1585 return Flag185
(Id
);
1586 end Is_Ada_2005_Only
;
1588 function Is_Aliased
(Id
: E
) return B
is
1590 pragma Assert
(Nkind
(Id
) in N_Entity
);
1594 function Is_AST_Entry
(Id
: E
) return B
is
1596 pragma Assert
(Is_Entry
(Id
));
1597 return Flag132
(Id
);
1600 function Is_Asynchronous
(Id
: E
) return B
is
1603 (Ekind
(Id
) = E_Procedure
or else Is_Type
(Id
));
1605 end Is_Asynchronous
;
1607 function Is_Atomic
(Id
: E
) return B
is
1612 function Is_Bit_Packed_Array
(Id
: E
) return B
is
1614 return Flag122
(Implementation_Base_Type
(Id
));
1615 end Is_Bit_Packed_Array
;
1617 function Is_Called
(Id
: E
) return B
is
1620 (Ekind
(Id
) = E_Procedure
or else Ekind
(Id
) = E_Function
);
1621 return Flag102
(Id
);
1624 function Is_Character_Type
(Id
: E
) return B
is
1627 end Is_Character_Type
;
1629 function Is_Child_Unit
(Id
: E
) return B
is
1634 function Is_Class_Wide_Equivalent_Type
(Id
: E
) return B
is
1637 end Is_Class_Wide_Equivalent_Type
;
1639 function Is_Compilation_Unit
(Id
: E
) return B
is
1641 return Flag149
(Id
);
1642 end Is_Compilation_Unit
;
1644 function Is_Completely_Hidden
(Id
: E
) return B
is
1646 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
1647 return Flag103
(Id
);
1648 end Is_Completely_Hidden
;
1650 function Is_Constr_Subt_For_U_Nominal
(Id
: E
) return B
is
1653 end Is_Constr_Subt_For_U_Nominal
;
1655 function Is_Constr_Subt_For_UN_Aliased
(Id
: E
) return B
is
1657 return Flag141
(Id
);
1658 end Is_Constr_Subt_For_UN_Aliased
;
1660 function Is_Constrained
(Id
: E
) return B
is
1662 pragma Assert
(Nkind
(Id
) in N_Entity
);
1666 function Is_Constructor
(Id
: E
) return B
is
1671 function Is_Controlled
(Id
: E
) return B
is
1673 return Flag42
(Base_Type
(Id
));
1676 function Is_Controlling_Formal
(Id
: E
) return B
is
1678 pragma Assert
(Is_Formal
(Id
));
1680 end Is_Controlling_Formal
;
1682 function Is_CPP_Class
(Id
: E
) return B
is
1687 function Is_Descendent_Of_Address
(Id
: E
) return B
is
1689 pragma Assert
(Is_Type
(Id
));
1690 return Flag223
(Id
);
1691 end Is_Descendent_Of_Address
;
1693 function Is_Discrim_SO_Function
(Id
: E
) return B
is
1695 return Flag176
(Id
);
1696 end Is_Discrim_SO_Function
;
1698 function Is_Dispatch_Table_Entity
(Id
: E
) return B
is
1700 return Flag234
(Id
);
1701 end Is_Dispatch_Table_Entity
;
1703 function Is_Dispatching_Operation
(Id
: E
) return B
is
1705 pragma Assert
(Nkind
(Id
) in N_Entity
);
1707 end Is_Dispatching_Operation
;
1709 function Is_Eliminated
(Id
: E
) return B
is
1711 return Flag124
(Id
);
1714 function Is_Entry_Formal
(Id
: E
) return B
is
1717 end Is_Entry_Formal
;
1719 function Is_Exported
(Id
: E
) return B
is
1724 function Is_First_Subtype
(Id
: E
) return B
is
1727 end Is_First_Subtype
;
1729 function Is_For_Access_Subtype
(Id
: E
) return B
is
1732 (Ekind
(Id
) = E_Record_Subtype
1734 Ekind
(Id
) = E_Private_Subtype
);
1735 return Flag118
(Id
);
1736 end Is_For_Access_Subtype
;
1738 function Is_Formal_Subprogram
(Id
: E
) return B
is
1740 return Flag111
(Id
);
1741 end Is_Formal_Subprogram
;
1743 function Is_Frozen
(Id
: E
) return B
is
1748 function Is_Generic_Actual_Type
(Id
: E
) return B
is
1750 pragma Assert
(Is_Type
(Id
));
1752 end Is_Generic_Actual_Type
;
1754 function Is_Generic_Instance
(Id
: E
) return B
is
1756 return Flag130
(Id
);
1757 end Is_Generic_Instance
;
1759 function Is_Generic_Type
(Id
: E
) return B
is
1761 pragma Assert
(Nkind
(Id
) in N_Entity
);
1763 end Is_Generic_Type
;
1765 function Is_Hidden
(Id
: E
) return B
is
1770 function Is_Hidden_Open_Scope
(Id
: E
) return B
is
1772 return Flag171
(Id
);
1773 end Is_Hidden_Open_Scope
;
1775 function Is_Immediately_Visible
(Id
: E
) return B
is
1777 pragma Assert
(Nkind
(Id
) in N_Entity
);
1779 end Is_Immediately_Visible
;
1781 function Is_Imported
(Id
: E
) return B
is
1786 function Is_Inlined
(Id
: E
) return B
is
1791 function Is_Interface
(Id
: E
) return B
is
1793 return Flag186
(Id
);
1796 function Is_Instantiated
(Id
: E
) return B
is
1798 return Flag126
(Id
);
1799 end Is_Instantiated
;
1801 function Is_Internal
(Id
: E
) return B
is
1803 pragma Assert
(Nkind
(Id
) in N_Entity
);
1807 function Is_Interrupt_Handler
(Id
: E
) return B
is
1809 pragma Assert
(Nkind
(Id
) in N_Entity
);
1811 end Is_Interrupt_Handler
;
1813 function Is_Intrinsic_Subprogram
(Id
: E
) return B
is
1816 end Is_Intrinsic_Subprogram
;
1818 function Is_Itype
(Id
: E
) return B
is
1823 function Is_Known_Non_Null
(Id
: E
) return B
is
1826 end Is_Known_Non_Null
;
1828 function Is_Known_Null
(Id
: E
) return B
is
1830 return Flag204
(Id
);
1833 function Is_Known_Valid
(Id
: E
) return B
is
1835 return Flag170
(Id
);
1838 function Is_Limited_Composite
(Id
: E
) return B
is
1840 return Flag106
(Id
);
1841 end Is_Limited_Composite
;
1843 function Is_Limited_Interface
(Id
: E
) return B
is
1845 return Flag197
(Id
);
1846 end Is_Limited_Interface
;
1848 function Is_Limited_Record
(Id
: E
) return B
is
1851 end Is_Limited_Record
;
1853 function Is_Machine_Code_Subprogram
(Id
: E
) return B
is
1855 pragma Assert
(Is_Subprogram
(Id
));
1856 return Flag137
(Id
);
1857 end Is_Machine_Code_Subprogram
;
1859 function Is_Non_Static_Subtype
(Id
: E
) return B
is
1861 pragma Assert
(Is_Type
(Id
));
1862 return Flag109
(Id
);
1863 end Is_Non_Static_Subtype
;
1865 function Is_Null_Init_Proc
(Id
: E
) return B
is
1867 pragma Assert
(Ekind
(Id
) = E_Procedure
);
1868 return Flag178
(Id
);
1869 end Is_Null_Init_Proc
;
1871 function Is_Obsolescent
(Id
: E
) return B
is
1873 return Flag153
(Id
);
1876 function Is_Only_Out_Parameter
(Id
: E
) return B
is
1878 pragma Assert
(Is_Formal
(Id
));
1879 return Flag226
(Id
);
1880 end Is_Only_Out_Parameter
;
1882 function Is_Optional_Parameter
(Id
: E
) return B
is
1884 pragma Assert
(Is_Formal
(Id
));
1885 return Flag134
(Id
);
1886 end Is_Optional_Parameter
;
1888 function Is_Overriding_Operation
(Id
: E
) return B
is
1890 pragma Assert
(Is_Subprogram
(Id
));
1892 end Is_Overriding_Operation
;
1894 function Is_Package_Body_Entity
(Id
: E
) return B
is
1896 return Flag160
(Id
);
1897 end Is_Package_Body_Entity
;
1899 function Is_Packed
(Id
: E
) return B
is
1901 return Flag51
(Implementation_Base_Type
(Id
));
1904 function Is_Packed_Array_Type
(Id
: E
) return B
is
1906 return Flag138
(Id
);
1907 end Is_Packed_Array_Type
;
1909 function Is_Potentially_Use_Visible
(Id
: E
) return B
is
1911 pragma Assert
(Nkind
(Id
) in N_Entity
);
1913 end Is_Potentially_Use_Visible
;
1915 function Is_Preelaborated
(Id
: E
) return B
is
1918 end Is_Preelaborated
;
1920 function Is_Primitive
(Id
: E
) return B
is
1923 (Is_Overloadable
(Id
)
1924 or else Ekind
(Id
) = E_Generic_Function
1925 or else Ekind
(Id
) = E_Generic_Procedure
);
1926 return Flag218
(Id
);
1929 function Is_Primitive_Wrapper
(Id
: E
) return B
is
1931 pragma Assert
(Ekind
(Id
) = E_Function
1932 or else Ekind
(Id
) = E_Procedure
);
1933 return Flag195
(Id
);
1934 end Is_Primitive_Wrapper
;
1936 function Is_Private_Composite
(Id
: E
) return B
is
1938 pragma Assert
(Is_Type
(Id
));
1939 return Flag107
(Id
);
1940 end Is_Private_Composite
;
1942 function Is_Private_Descendant
(Id
: E
) return B
is
1945 end Is_Private_Descendant
;
1947 function Is_Private_Primitive
(Id
: E
) return B
is
1949 pragma Assert
(Ekind
(Id
) = E_Function
1950 or else Ekind
(Id
) = E_Procedure
);
1951 return Flag245
(Id
);
1952 end Is_Private_Primitive
;
1954 function Is_Protected_Interface
(Id
: E
) return B
is
1956 pragma Assert
(Is_Interface
(Id
));
1957 return Flag198
(Id
);
1958 end Is_Protected_Interface
;
1960 function Is_Public
(Id
: E
) return B
is
1962 pragma Assert
(Nkind
(Id
) in N_Entity
);
1966 function Is_Pure
(Id
: E
) return B
is
1971 function Is_Pure_Unit_Access_Type
(Id
: E
) return B
is
1973 pragma Assert
(Is_Access_Type
(Id
));
1974 return Flag189
(Id
);
1975 end Is_Pure_Unit_Access_Type
;
1977 function Is_RACW_Stub_Type
(Id
: E
) return B
is
1979 pragma Assert
(Is_Type
(Id
));
1980 return Flag244
(Id
);
1981 end Is_RACW_Stub_Type
;
1983 function Is_Raised
(Id
: E
) return B
is
1985 pragma Assert
(Ekind
(Id
) = E_Exception
);
1986 return Flag224
(Id
);
1989 function Is_Remote_Call_Interface
(Id
: E
) return B
is
1992 end Is_Remote_Call_Interface
;
1994 function Is_Remote_Types
(Id
: E
) return B
is
1997 end Is_Remote_Types
;
1999 function Is_Renaming_Of_Object
(Id
: E
) return B
is
2001 return Flag112
(Id
);
2002 end Is_Renaming_Of_Object
;
2004 function Is_Return_Object
(Id
: E
) return B
is
2006 return Flag209
(Id
);
2007 end Is_Return_Object
;
2009 function Is_Shared_Passive
(Id
: E
) return B
is
2012 end Is_Shared_Passive
;
2014 function Is_Statically_Allocated
(Id
: E
) return B
is
2017 end Is_Statically_Allocated
;
2019 function Is_Synchronized_Interface
(Id
: E
) return B
is
2021 pragma Assert
(Is_Interface
(Id
));
2022 return Flag199
(Id
);
2023 end Is_Synchronized_Interface
;
2025 function Is_Tag
(Id
: E
) return B
is
2027 pragma Assert
(Nkind
(Id
) in N_Entity
);
2031 function Is_Tagged_Type
(Id
: E
) return B
is
2036 function Is_Task_Interface
(Id
: E
) return B
is
2038 pragma Assert
(Is_Interface
(Id
));
2039 return Flag200
(Id
);
2040 end Is_Task_Interface
;
2042 function Is_Thunk
(Id
: E
) return B
is
2044 pragma Assert
(Is_Subprogram
(Id
));
2045 return Flag225
(Id
);
2048 function Is_Trivial_Subprogram
(Id
: E
) return B
is
2050 return Flag235
(Id
);
2051 end Is_Trivial_Subprogram
;
2053 function Is_True_Constant
(Id
: E
) return B
is
2055 return Flag163
(Id
);
2056 end Is_True_Constant
;
2058 function Is_Unchecked_Union
(Id
: E
) return B
is
2060 return Flag117
(Implementation_Base_Type
(Id
));
2061 end Is_Unchecked_Union
;
2063 function Is_Unsigned_Type
(Id
: E
) return B
is
2065 pragma Assert
(Is_Type
(Id
));
2066 return Flag144
(Id
);
2067 end Is_Unsigned_Type
;
2069 function Is_Valued_Procedure
(Id
: E
) return B
is
2071 pragma Assert
(Ekind
(Id
) = E_Procedure
);
2072 return Flag127
(Id
);
2073 end Is_Valued_Procedure
;
2075 function Is_Visible_Child_Unit
(Id
: E
) return B
is
2077 pragma Assert
(Is_Child_Unit
(Id
));
2078 return Flag116
(Id
);
2079 end Is_Visible_Child_Unit
;
2081 function Is_Visible_Formal
(Id
: E
) return B
is
2083 return Flag206
(Id
);
2084 end Is_Visible_Formal
;
2086 function Is_VMS_Exception
(Id
: E
) return B
is
2088 return Flag133
(Id
);
2089 end Is_VMS_Exception
;
2091 function Is_Volatile
(Id
: E
) return B
is
2093 pragma Assert
(Nkind
(Id
) in N_Entity
);
2095 if Is_Type
(Id
) then
2096 return Flag16
(Base_Type
(Id
));
2102 function Itype_Printed
(Id
: E
) return B
is
2104 pragma Assert
(Is_Itype
(Id
));
2105 return Flag202
(Id
);
2108 function Kill_Elaboration_Checks
(Id
: E
) return B
is
2111 end Kill_Elaboration_Checks
;
2113 function Kill_Range_Checks
(Id
: E
) return B
is
2116 end Kill_Range_Checks
;
2118 function Kill_Tag_Checks
(Id
: E
) return B
is
2121 end Kill_Tag_Checks
;
2123 function Known_To_Have_Preelab_Init
(Id
: E
) return B
is
2125 pragma Assert
(Is_Type
(Id
));
2126 return Flag207
(Id
);
2127 end Known_To_Have_Preelab_Init
;
2129 function Last_Assignment
(Id
: E
) return N
is
2131 pragma Assert
(Is_Assignable
(Id
));
2133 end Last_Assignment
;
2135 function Last_Entity
(Id
: E
) return E
is
2140 function Limited_View
(Id
: E
) return E
is
2142 pragma Assert
(Ekind
(Id
) = E_Package
);
2146 function Lit_Indexes
(Id
: E
) return E
is
2148 pragma Assert
(Is_Enumeration_Type
(Id
));
2152 function Lit_Strings
(Id
: E
) return E
is
2154 pragma Assert
(Is_Enumeration_Type
(Id
));
2158 function Low_Bound_Known
(Id
: E
) return B
is
2160 return Flag205
(Id
);
2161 end Low_Bound_Known
;
2163 function Machine_Radix_10
(Id
: E
) return B
is
2165 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
2167 end Machine_Radix_10
;
2169 function Master_Id
(Id
: E
) return E
is
2171 pragma Assert
(Is_Access_Type
(Id
));
2175 function Materialize_Entity
(Id
: E
) return B
is
2177 return Flag168
(Id
);
2178 end Materialize_Entity
;
2180 function Mechanism
(Id
: E
) return M
is
2182 pragma Assert
(Ekind
(Id
) = E_Function
or else Is_Formal
(Id
));
2183 return UI_To_Int
(Uint8
(Id
));
2186 function Modulus
(Id
: E
) return Uint
is
2188 pragma Assert
(Is_Modular_Integer_Type
(Id
));
2189 return Uint17
(Base_Type
(Id
));
2192 function Must_Be_On_Byte_Boundary
(Id
: E
) return B
is
2194 pragma Assert
(Is_Type
(Id
));
2195 return Flag183
(Id
);
2196 end Must_Be_On_Byte_Boundary
;
2198 function Must_Have_Preelab_Init
(Id
: E
) return B
is
2200 pragma Assert
(Is_Type
(Id
));
2201 return Flag208
(Id
);
2202 end Must_Have_Preelab_Init
;
2204 function Needs_Debug_Info
(Id
: E
) return B
is
2206 return Flag147
(Id
);
2207 end Needs_Debug_Info
;
2209 function Needs_No_Actuals
(Id
: E
) return B
is
2212 (Is_Overloadable
(Id
)
2213 or else Ekind
(Id
) = E_Subprogram_Type
2214 or else Ekind
(Id
) = E_Entry_Family
);
2216 end Needs_No_Actuals
;
2218 function Never_Set_In_Source
(Id
: E
) return B
is
2220 return Flag115
(Id
);
2221 end Never_Set_In_Source
;
2223 function Next_Inlined_Subprogram
(Id
: E
) return E
is
2226 end Next_Inlined_Subprogram
;
2228 function No_Pool_Assigned
(Id
: E
) return B
is
2230 pragma Assert
(Is_Access_Type
(Id
));
2231 return Flag131
(Root_Type
(Id
));
2232 end No_Pool_Assigned
;
2234 function No_Return
(Id
: E
) return B
is
2236 return Flag113
(Id
);
2239 function No_Strict_Aliasing
(Id
: E
) return B
is
2241 pragma Assert
(Is_Access_Type
(Id
));
2242 return Flag136
(Base_Type
(Id
));
2243 end No_Strict_Aliasing
;
2245 function Non_Binary_Modulus
(Id
: E
) return B
is
2247 pragma Assert
(Is_Type
(Id
));
2248 return Flag58
(Base_Type
(Id
));
2249 end Non_Binary_Modulus
;
2251 function Non_Limited_View
(Id
: E
) return E
is
2253 pragma Assert
(Ekind
(Id
) in Incomplete_Kind
);
2255 end Non_Limited_View
;
2257 function Nonzero_Is_True
(Id
: E
) return B
is
2259 pragma Assert
(Root_Type
(Id
) = Standard_Boolean
);
2260 return Flag162
(Base_Type
(Id
));
2261 end Nonzero_Is_True
;
2263 function Normalized_First_Bit
(Id
: E
) return U
is
2266 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
2268 end Normalized_First_Bit
;
2270 function Normalized_Position
(Id
: E
) return U
is
2273 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
2275 end Normalized_Position
;
2277 function Normalized_Position_Max
(Id
: E
) return U
is
2280 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
2282 end Normalized_Position_Max
;
2284 function OK_To_Reorder_Components
(Id
: E
) return B
is
2286 pragma Assert
(Is_Record_Type
(Id
));
2287 return Flag239
(Base_Type
(Id
));
2288 end OK_To_Reorder_Components
;
2290 function Optimize_Alignment_Space
(Id
: E
) return B
is
2294 or else Ekind
(Id
) = E_Constant
2295 or else Ekind
(Id
) = E_Variable
);
2296 return Flag241
(Id
);
2297 end Optimize_Alignment_Space
;
2299 function Optimize_Alignment_Time
(Id
: E
) return B
is
2303 or else Ekind
(Id
) = E_Constant
2304 or else Ekind
(Id
) = E_Variable
);
2305 return Flag242
(Id
);
2306 end Optimize_Alignment_Time
;
2308 function Original_Array_Type
(Id
: E
) return E
is
2310 pragma Assert
(Is_Array_Type
(Id
) or else Is_Modular_Integer_Type
(Id
));
2312 end Original_Array_Type
;
2314 function Original_Record_Component
(Id
: E
) return E
is
2317 (Ekind
(Id
) = E_Void
2318 or else Ekind
(Id
) = E_Component
2319 or else Ekind
(Id
) = E_Discriminant
);
2321 end Original_Record_Component
;
2323 function Overlays_Constant
(Id
: E
) return B
is
2325 return Flag243
(Id
);
2326 end Overlays_Constant
;
2328 function Overridden_Operation
(Id
: E
) return E
is
2331 end Overridden_Operation
;
2333 function Package_Instantiation
(Id
: E
) return N
is
2337 or else Ekind
(Id
) = E_Generic_Package
2338 or else Ekind
(Id
) = E_Package
);
2340 end Package_Instantiation
;
2342 function Packed_Array_Type
(Id
: E
) return E
is
2344 pragma Assert
(Is_Array_Type
(Id
));
2346 end Packed_Array_Type
;
2348 function Parent_Subtype
(Id
: E
) return E
is
2350 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
2354 function Primitive_Operations
(Id
: E
) return L
is
2356 pragma Assert
(Is_Tagged_Type
(Id
));
2357 return Elist15
(Id
);
2358 end Primitive_Operations
;
2360 function Prival
(Id
: E
) return E
is
2362 pragma Assert
(Is_Protected_Component
(Id
));
2366 function Prival_Link
(Id
: E
) return E
is
2368 pragma Assert
(Ekind
(Id
) = E_Constant
2369 or else Ekind
(Id
) = E_Variable
);
2373 function Private_Dependents
(Id
: E
) return L
is
2375 pragma Assert
(Is_Incomplete_Or_Private_Type
(Id
));
2376 return Elist18
(Id
);
2377 end Private_Dependents
;
2379 function Private_View
(Id
: E
) return N
is
2381 pragma Assert
(Is_Private_Type
(Id
));
2385 function Protected_Body_Subprogram
(Id
: E
) return E
is
2387 pragma Assert
(Is_Subprogram
(Id
) or else Is_Entry
(Id
));
2389 end Protected_Body_Subprogram
;
2391 function Protected_Formal
(Id
: E
) return E
is
2393 pragma Assert
(Is_Formal
(Id
));
2395 end Protected_Formal
;
2397 function Protection_Object
(Id
: E
) return E
is
2399 pragma Assert
(Ekind
(Id
) = E_Entry
2400 or else Ekind
(Id
) = E_Entry_Family
2401 or else Ekind
(Id
) = E_Function
2402 or else Ekind
(Id
) = E_Procedure
);
2404 end Protection_Object
;
2406 function Reachable
(Id
: E
) return B
is
2411 function Referenced
(Id
: E
) return B
is
2413 return Flag156
(Id
);
2416 function Referenced_As_LHS
(Id
: E
) return B
is
2419 end Referenced_As_LHS
;
2421 function Referenced_As_Out_Parameter
(Id
: E
) return B
is
2423 return Flag227
(Id
);
2424 end Referenced_As_Out_Parameter
;
2426 function Referenced_Object
(Id
: E
) return N
is
2428 pragma Assert
(Is_Type
(Id
));
2430 end Referenced_Object
;
2432 function Register_Exception_Call
(Id
: E
) return N
is
2434 pragma Assert
(Ekind
(Id
) = E_Exception
);
2436 end Register_Exception_Call
;
2438 function Related_Array_Object
(Id
: E
) return E
is
2440 pragma Assert
(Is_Array_Type
(Id
));
2442 end Related_Array_Object
;
2444 function Related_Instance
(Id
: E
) return E
is
2447 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Package_Body
);
2449 end Related_Instance
;
2451 function Related_Type
(Id
: E
) return E
is
2454 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Constant
);
2458 function Relative_Deadline_Variable
(Id
: E
) return E
is
2460 pragma Assert
(Is_Task_Type
(Id
));
2461 return Node26
(Implementation_Base_Type
(Id
));
2462 end Relative_Deadline_Variable
;
2464 function Renamed_Entity
(Id
: E
) return N
is
2469 function Renamed_In_Spec
(Id
: E
) return B
is
2471 pragma Assert
(Ekind
(Id
) = E_Package
);
2472 return Flag231
(Id
);
2473 end Renamed_In_Spec
;
2475 function Renamed_Object
(Id
: E
) return N
is
2480 function Renaming_Map
(Id
: E
) return U
is
2485 function Requires_Overriding
(Id
: E
) return B
is
2487 pragma Assert
(Is_Overloadable
(Id
));
2488 return Flag213
(Id
);
2489 end Requires_Overriding
;
2491 function Return_Present
(Id
: E
) return B
is
2496 function Return_Applies_To
(Id
: E
) return N
is
2499 end Return_Applies_To
;
2501 function Returns_By_Ref
(Id
: E
) return B
is
2506 function Reverse_Bit_Order
(Id
: E
) return B
is
2508 pragma Assert
(Is_Record_Type
(Id
));
2509 return Flag164
(Base_Type
(Id
));
2510 end Reverse_Bit_Order
;
2512 function RM_Size
(Id
: E
) return U
is
2514 pragma Assert
(Is_Type
(Id
));
2518 function Scalar_Range
(Id
: E
) return N
is
2523 function Scale_Value
(Id
: E
) return U
is
2528 function Scope_Depth_Value
(Id
: E
) return U
is
2531 end Scope_Depth_Value
;
2533 function Sec_Stack_Needed_For_Return
(Id
: E
) return B
is
2535 return Flag167
(Id
);
2536 end Sec_Stack_Needed_For_Return
;
2538 function Shadow_Entities
(Id
: E
) return S
is
2541 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Generic_Package
);
2543 end Shadow_Entities
;
2545 function Shared_Var_Procs_Instance
(Id
: E
) return E
is
2547 pragma Assert
(Ekind
(Id
) = E_Variable
);
2549 end Shared_Var_Procs_Instance
;
2551 function Size_Check_Code
(Id
: E
) return N
is
2553 pragma Assert
(Ekind
(Id
) = E_Constant
or else Ekind
(Id
) = E_Variable
);
2555 end Size_Check_Code
;
2557 function Size_Depends_On_Discriminant
(Id
: E
) return B
is
2559 return Flag177
(Id
);
2560 end Size_Depends_On_Discriminant
;
2562 function Size_Known_At_Compile_Time
(Id
: E
) return B
is
2565 end Size_Known_At_Compile_Time
;
2567 function Small_Value
(Id
: E
) return R
is
2569 pragma Assert
(Is_Fixed_Point_Type
(Id
));
2570 return Ureal21
(Id
);
2573 function Spec_Entity
(Id
: E
) return E
is
2576 (Ekind
(Id
) = E_Package_Body
or else Is_Formal
(Id
));
2580 function Spec_PPC_List
(Id
: E
) return N
is
2582 pragma Assert
(Is_Subprogram
(Id
) or else Is_Generic_Subprogram
(Id
));
2586 function Storage_Size_Variable
(Id
: E
) return E
is
2588 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
2589 return Node15
(Implementation_Base_Type
(Id
));
2590 end Storage_Size_Variable
;
2592 function Static_Elaboration_Desired
(Id
: E
) return B
is
2594 pragma Assert
(Ekind
(Id
) = E_Package
);
2596 end Static_Elaboration_Desired
;
2598 function Static_Initialization
(Id
: E
) return N
is
2601 (Ekind
(Id
) = E_Procedure
and then not Is_Dispatching_Operation
(Id
));
2603 end Static_Initialization
;
2605 function Stored_Constraint
(Id
: E
) return L
is
2608 (Is_Composite_Type
(Id
) and then not Is_Array_Type
(Id
));
2609 return Elist23
(Id
);
2610 end Stored_Constraint
;
2612 function Strict_Alignment
(Id
: E
) return B
is
2614 return Flag145
(Implementation_Base_Type
(Id
));
2615 end Strict_Alignment
;
2617 function String_Literal_Length
(Id
: E
) return U
is
2620 end String_Literal_Length
;
2622 function String_Literal_Low_Bound
(Id
: E
) return N
is
2625 end String_Literal_Low_Bound
;
2627 function Suppress_Elaboration_Warnings
(Id
: E
) return B
is
2629 return Flag148
(Id
);
2630 end Suppress_Elaboration_Warnings
;
2632 function Suppress_Init_Proc
(Id
: E
) return B
is
2634 return Flag105
(Base_Type
(Id
));
2635 end Suppress_Init_Proc
;
2637 function Suppress_Style_Checks
(Id
: E
) return B
is
2639 return Flag165
(Id
);
2640 end Suppress_Style_Checks
;
2642 function Suppress_Value_Tracking_On_Call
(Id
: E
) return B
is
2644 return Flag217
(Id
);
2645 end Suppress_Value_Tracking_On_Call
;
2647 function Task_Body_Procedure
(Id
: E
) return N
is
2649 pragma Assert
(Ekind
(Id
) in Task_Kind
);
2651 end Task_Body_Procedure
;
2653 function Treat_As_Volatile
(Id
: E
) return B
is
2656 end Treat_As_Volatile
;
2658 function Underlying_Full_View
(Id
: E
) return E
is
2660 pragma Assert
(Ekind
(Id
) in Private_Kind
);
2662 end Underlying_Full_View
;
2664 function Universal_Aliasing
(Id
: E
) return B
is
2666 pragma Assert
(Is_Type
(Id
));
2667 return Flag216
(Base_Type
(Id
));
2668 end Universal_Aliasing
;
2670 function Unset_Reference
(Id
: E
) return N
is
2673 end Unset_Reference
;
2675 function Used_As_Generic_Actual
(Id
: E
) return B
is
2677 return Flag222
(Id
);
2678 end Used_As_Generic_Actual
;
2680 function Uses_Sec_Stack
(Id
: E
) return B
is
2685 function Vax_Float
(Id
: E
) return B
is
2687 return Flag151
(Base_Type
(Id
));
2690 function Warnings_Off
(Id
: E
) return B
is
2695 function Warnings_Off_Used
(Id
: E
) return B
is
2697 return Flag236
(Id
);
2698 end Warnings_Off_Used
;
2700 function Warnings_Off_Used_Unmodified
(Id
: E
) return B
is
2702 return Flag237
(Id
);
2703 end Warnings_Off_Used_Unmodified
;
2705 function Warnings_Off_Used_Unreferenced
(Id
: E
) return B
is
2707 return Flag238
(Id
);
2708 end Warnings_Off_Used_Unreferenced
;
2710 function Wrapped_Entity
(Id
: E
) return E
is
2712 pragma Assert
((Ekind
(Id
) = E_Function
2713 or else Ekind
(Id
) = E_Procedure
)
2714 and then Is_Primitive_Wrapper
(Id
));
2718 function Was_Hidden
(Id
: E
) return B
is
2720 return Flag196
(Id
);
2723 ------------------------------
2724 -- Classification Functions --
2725 ------------------------------
2727 function Is_Access_Type
(Id
: E
) return B
is
2729 return Ekind
(Id
) in Access_Kind
;
2732 function Is_Access_Protected_Subprogram_Type
(Id
: E
) return B
is
2734 return Ekind
(Id
) in Access_Protected_Kind
;
2735 end Is_Access_Protected_Subprogram_Type
;
2737 function Is_Access_Subprogram_Type
(Id
: E
) return B
is
2739 return Ekind
(Id
) in Access_Subprogram_Kind
;
2740 end Is_Access_Subprogram_Type
;
2742 function Is_Array_Type
(Id
: E
) return B
is
2744 return Ekind
(Id
) in Array_Kind
;
2747 function Is_Assignable
(Id
: E
) return B
is
2749 return Ekind
(Id
) in Assignable_Kind
;
2752 function Is_Class_Wide_Type
(Id
: E
) return B
is
2754 return Ekind
(Id
) in Class_Wide_Kind
;
2755 end Is_Class_Wide_Type
;
2757 function Is_Composite_Type
(Id
: E
) return B
is
2759 return Ekind
(Id
) in Composite_Kind
;
2760 end Is_Composite_Type
;
2762 function Is_Concurrent_Body
(Id
: E
) return B
is
2764 return Ekind
(Id
) in
2765 Concurrent_Body_Kind
;
2766 end Is_Concurrent_Body
;
2768 function Is_Concurrent_Record_Type
(Id
: E
) return B
is
2771 end Is_Concurrent_Record_Type
;
2773 function Is_Concurrent_Type
(Id
: E
) return B
is
2775 return Ekind
(Id
) in Concurrent_Kind
;
2776 end Is_Concurrent_Type
;
2778 function Is_Decimal_Fixed_Point_Type
(Id
: E
) return B
is
2780 return Ekind
(Id
) in
2781 Decimal_Fixed_Point_Kind
;
2782 end Is_Decimal_Fixed_Point_Type
;
2784 function Is_Digits_Type
(Id
: E
) return B
is
2786 return Ekind
(Id
) in Digits_Kind
;
2789 function Is_Discrete_Or_Fixed_Point_Type
(Id
: E
) return B
is
2791 return Ekind
(Id
) in Discrete_Or_Fixed_Point_Kind
;
2792 end Is_Discrete_Or_Fixed_Point_Type
;
2794 function Is_Discrete_Type
(Id
: E
) return B
is
2796 return Ekind
(Id
) in Discrete_Kind
;
2797 end Is_Discrete_Type
;
2799 function Is_Elementary_Type
(Id
: E
) return B
is
2801 return Ekind
(Id
) in Elementary_Kind
;
2802 end Is_Elementary_Type
;
2804 function Is_Entry
(Id
: E
) return B
is
2806 return Ekind
(Id
) in Entry_Kind
;
2809 function Is_Enumeration_Type
(Id
: E
) return B
is
2811 return Ekind
(Id
) in
2813 end Is_Enumeration_Type
;
2815 function Is_Fixed_Point_Type
(Id
: E
) return B
is
2817 return Ekind
(Id
) in
2819 end Is_Fixed_Point_Type
;
2821 function Is_Floating_Point_Type
(Id
: E
) return B
is
2823 return Ekind
(Id
) in Float_Kind
;
2824 end Is_Floating_Point_Type
;
2826 function Is_Formal
(Id
: E
) return B
is
2828 return Ekind
(Id
) in Formal_Kind
;
2831 function Is_Formal_Object
(Id
: E
) return B
is
2833 return Ekind
(Id
) in Formal_Object_Kind
;
2834 end Is_Formal_Object
;
2836 function Is_Generic_Subprogram
(Id
: E
) return B
is
2838 return Ekind
(Id
) in Generic_Subprogram_Kind
;
2839 end Is_Generic_Subprogram
;
2841 function Is_Generic_Unit
(Id
: E
) return B
is
2843 return Ekind
(Id
) in Generic_Unit_Kind
;
2844 end Is_Generic_Unit
;
2846 function Is_Incomplete_Or_Private_Type
(Id
: E
) return B
is
2848 return Ekind
(Id
) in
2849 Incomplete_Or_Private_Kind
;
2850 end Is_Incomplete_Or_Private_Type
;
2852 function Is_Incomplete_Type
(Id
: E
) return B
is
2854 return Ekind
(Id
) in
2856 end Is_Incomplete_Type
;
2858 function Is_Integer_Type
(Id
: E
) return B
is
2860 return Ekind
(Id
) in Integer_Kind
;
2861 end Is_Integer_Type
;
2863 function Is_Modular_Integer_Type
(Id
: E
) return B
is
2865 return Ekind
(Id
) in
2866 Modular_Integer_Kind
;
2867 end Is_Modular_Integer_Type
;
2869 function Is_Named_Number
(Id
: E
) return B
is
2871 return Ekind
(Id
) in Named_Kind
;
2872 end Is_Named_Number
;
2874 function Is_Numeric_Type
(Id
: E
) return B
is
2876 return Ekind
(Id
) in Numeric_Kind
;
2877 end Is_Numeric_Type
;
2879 function Is_Object
(Id
: E
) return B
is
2881 return Ekind
(Id
) in Object_Kind
;
2884 function Is_Ordinary_Fixed_Point_Type
(Id
: E
) return B
is
2886 return Ekind
(Id
) in
2887 Ordinary_Fixed_Point_Kind
;
2888 end Is_Ordinary_Fixed_Point_Type
;
2890 function Is_Overloadable
(Id
: E
) return B
is
2892 return Ekind
(Id
) in Overloadable_Kind
;
2893 end Is_Overloadable
;
2895 function Is_Private_Type
(Id
: E
) return B
is
2897 return Ekind
(Id
) in Private_Kind
;
2898 end Is_Private_Type
;
2900 function Is_Protected_Type
(Id
: E
) return B
is
2902 return Ekind
(Id
) in Protected_Kind
;
2903 end Is_Protected_Type
;
2905 function Is_Real_Type
(Id
: E
) return B
is
2907 return Ekind
(Id
) in Real_Kind
;
2910 function Is_Record_Type
(Id
: E
) return B
is
2912 return Ekind
(Id
) in Record_Kind
;
2915 function Is_Scalar_Type
(Id
: E
) return B
is
2917 return Ekind
(Id
) in Scalar_Kind
;
2920 function Is_Signed_Integer_Type
(Id
: E
) return B
is
2922 return Ekind
(Id
) in
2923 Signed_Integer_Kind
;
2924 end Is_Signed_Integer_Type
;
2926 function Is_Subprogram
(Id
: E
) return B
is
2928 return Ekind
(Id
) in Subprogram_Kind
;
2931 function Is_Task_Type
(Id
: E
) return B
is
2933 return Ekind
(Id
) in Task_Kind
;
2936 function Is_Type
(Id
: E
) return B
is
2938 return Ekind
(Id
) in Type_Kind
;
2941 ------------------------------
2942 -- Attribute Set Procedures --
2943 ------------------------------
2945 procedure Set_Accept_Address
(Id
: E
; V
: L
) is
2947 Set_Elist21
(Id
, V
);
2948 end Set_Accept_Address
;
2950 procedure Set_Access_Disp_Table
(Id
: E
; V
: L
) is
2952 pragma Assert
(Is_Tagged_Type
(Id
) and then Id
= Base_Type
(Id
));
2953 Set_Elist16
(Id
, V
);
2954 end Set_Access_Disp_Table
;
2956 procedure Set_Associated_Final_Chain
(Id
: E
; V
: E
) is
2958 pragma Assert
(Is_Access_Type
(Id
));
2960 end Set_Associated_Final_Chain
;
2962 procedure Set_Associated_Formal_Package
(Id
: E
; V
: E
) is
2965 end Set_Associated_Formal_Package
;
2967 procedure Set_Associated_Node_For_Itype
(Id
: E
; V
: E
) is
2970 end Set_Associated_Node_For_Itype
;
2972 procedure Set_Associated_Storage_Pool
(Id
: E
; V
: E
) is
2974 pragma Assert
(Is_Access_Type
(Id
) and then Id
= Base_Type
(Id
));
2976 end Set_Associated_Storage_Pool
;
2978 procedure Set_Actual_Subtype
(Id
: E
; V
: E
) is
2981 (Ekind
(Id
) = E_Constant
2982 or else Ekind
(Id
) = E_Variable
2983 or else Ekind
(Id
) = E_Generic_In_Out_Parameter
2984 or else Is_Formal
(Id
));
2986 end Set_Actual_Subtype
;
2988 procedure Set_Address_Taken
(Id
: E
; V
: B
:= True) is
2990 Set_Flag104
(Id
, V
);
2991 end Set_Address_Taken
;
2993 procedure Set_Alias
(Id
: E
; V
: E
) is
2996 (Is_Overloadable
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
3000 procedure Set_Alignment
(Id
: E
; V
: U
) is
3002 pragma Assert
(Is_Type
(Id
)
3003 or else Is_Formal
(Id
)
3004 or else Ekind
(Id
) = E_Loop_Parameter
3005 or else Ekind
(Id
) = E_Constant
3006 or else Ekind
(Id
) = E_Exception
3007 or else Ekind
(Id
) = E_Variable
);
3011 procedure Set_Barrier_Function
(Id
: E
; V
: N
) is
3013 pragma Assert
(Is_Entry
(Id
));
3015 end Set_Barrier_Function
;
3017 procedure Set_Block_Node
(Id
: E
; V
: N
) is
3019 pragma Assert
(Ekind
(Id
) = E_Block
);
3023 procedure Set_Body_Entity
(Id
: E
; V
: E
) is
3026 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Generic_Package
);
3028 end Set_Body_Entity
;
3030 procedure Set_Body_Needed_For_SAL
(Id
: E
; V
: B
:= True) is
3033 (Ekind
(Id
) = E_Package
3034 or else Is_Subprogram
(Id
)
3035 or else Is_Generic_Unit
(Id
));
3037 end Set_Body_Needed_For_SAL
;
3039 procedure Set_C_Pass_By_Copy
(Id
: E
; V
: B
:= True) is
3041 pragma Assert
(Is_Record_Type
(Id
) and then Id
= Base_Type
(Id
));
3042 Set_Flag125
(Id
, V
);
3043 end Set_C_Pass_By_Copy
;
3045 procedure Set_Can_Never_Be_Null
(Id
: E
; V
: B
:= True) is
3048 end Set_Can_Never_Be_Null
;
3050 procedure Set_Checks_May_Be_Suppressed
(Id
: E
; V
: B
:= True) is
3053 end Set_Checks_May_Be_Suppressed
;
3055 procedure Set_Class_Wide_Type
(Id
: E
; V
: E
) is
3057 pragma Assert
(Is_Type
(Id
));
3059 end Set_Class_Wide_Type
;
3061 procedure Set_Cloned_Subtype
(Id
: E
; V
: E
) is
3064 (Ekind
(Id
) = E_Record_Subtype
3065 or else Ekind
(Id
) = E_Class_Wide_Subtype
);
3067 end Set_Cloned_Subtype
;
3069 procedure Set_Component_Bit_Offset
(Id
: E
; V
: U
) is
3072 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
3074 end Set_Component_Bit_Offset
;
3076 procedure Set_Component_Clause
(Id
: E
; V
: N
) is
3079 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
3081 end Set_Component_Clause
;
3083 procedure Set_Component_Size
(Id
: E
; V
: U
) is
3085 pragma Assert
(Is_Array_Type
(Id
) and then Id
= Base_Type
(Id
));
3087 end Set_Component_Size
;
3089 procedure Set_Component_Type
(Id
: E
; V
: E
) is
3091 pragma Assert
(Is_Array_Type
(Id
) and then Id
= Base_Type
(Id
));
3093 end Set_Component_Type
;
3095 procedure Set_Corresponding_Concurrent_Type
(Id
: E
; V
: E
) is
3098 (Ekind
(Id
) = E_Record_Type
and then Is_Concurrent_Type
(V
));
3100 end Set_Corresponding_Concurrent_Type
;
3102 procedure Set_Corresponding_Discriminant
(Id
: E
; V
: E
) is
3104 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
3106 end Set_Corresponding_Discriminant
;
3108 procedure Set_Corresponding_Equality
(Id
: E
; V
: E
) is
3111 (Ekind
(Id
) = E_Function
3112 and then not Comes_From_Source
(Id
)
3113 and then Chars
(Id
) = Name_Op_Ne
);
3115 end Set_Corresponding_Equality
;
3117 procedure Set_Corresponding_Record_Type
(Id
: E
; V
: E
) is
3119 pragma Assert
(Is_Concurrent_Type
(Id
));
3121 end Set_Corresponding_Record_Type
;
3123 procedure Set_Corresponding_Remote_Type
(Id
: E
; V
: E
) is
3126 end Set_Corresponding_Remote_Type
;
3128 procedure Set_Current_Use_Clause
(Id
: E
; V
: E
) is
3130 pragma Assert
(Ekind
(Id
) = E_Package
or else Is_Type
(Id
));
3132 end Set_Current_Use_Clause
;
3134 procedure Set_Current_Value
(Id
: E
; V
: N
) is
3136 pragma Assert
(Ekind
(Id
) in Object_Kind
or else Ekind
(Id
) = E_Void
);
3138 end Set_Current_Value
;
3140 procedure Set_CR_Discriminant
(Id
: E
; V
: E
) is
3143 end Set_CR_Discriminant
;
3145 procedure Set_Debug_Info_Off
(Id
: E
; V
: B
:= True) is
3147 Set_Flag166
(Id
, V
);
3148 end Set_Debug_Info_Off
;
3150 procedure Set_Debug_Renaming_Link
(Id
: E
; V
: E
) is
3153 end Set_Debug_Renaming_Link
;
3155 procedure Set_Default_Expr_Function
(Id
: E
; V
: E
) is
3157 pragma Assert
(Is_Formal
(Id
));
3159 end Set_Default_Expr_Function
;
3161 procedure Set_Default_Expressions_Processed
(Id
: E
; V
: B
:= True) is
3163 Set_Flag108
(Id
, V
);
3164 end Set_Default_Expressions_Processed
;
3166 procedure Set_Default_Value
(Id
: E
; V
: N
) is
3168 pragma Assert
(Is_Formal
(Id
));
3170 end Set_Default_Value
;
3172 procedure Set_Delay_Cleanups
(Id
: E
; V
: B
:= True) is
3176 or else Is_Task_Type
(Id
)
3177 or else Ekind
(Id
) = E_Block
);
3178 Set_Flag114
(Id
, V
);
3179 end Set_Delay_Cleanups
;
3181 procedure Set_Delay_Subprogram_Descriptors
(Id
: E
; V
: B
:= True) is
3185 or else Ekind
(Id
) = E_Package
3186 or else Ekind
(Id
) = E_Package_Body
);
3188 end Set_Delay_Subprogram_Descriptors
;
3190 procedure Set_Delta_Value
(Id
: E
; V
: R
) is
3192 pragma Assert
(Is_Fixed_Point_Type
(Id
));
3193 Set_Ureal18
(Id
, V
);
3194 end Set_Delta_Value
;
3196 procedure Set_Dependent_Instances
(Id
: E
; V
: L
) is
3198 pragma Assert
(Is_Generic_Instance
(Id
));
3200 end Set_Dependent_Instances
;
3202 procedure Set_Depends_On_Private
(Id
: E
; V
: B
:= True) is
3204 pragma Assert
(Nkind
(Id
) in N_Entity
);
3206 end Set_Depends_On_Private
;
3208 procedure Set_Digits_Value
(Id
: E
; V
: U
) is
3211 (Is_Floating_Point_Type
(Id
)
3212 or else Is_Decimal_Fixed_Point_Type
(Id
));
3214 end Set_Digits_Value
;
3216 procedure Set_Directly_Designated_Type
(Id
: E
; V
: E
) is
3219 end Set_Directly_Designated_Type
;
3221 procedure Set_Discard_Names
(Id
: E
; V
: B
:= True) is
3224 end Set_Discard_Names
;
3226 procedure Set_Discriminal
(Id
: E
; V
: E
) is
3228 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
3230 end Set_Discriminal
;
3232 procedure Set_Discriminal_Link
(Id
: E
; V
: E
) is
3235 end Set_Discriminal_Link
;
3237 procedure Set_Discriminant_Checking_Func
(Id
: E
; V
: E
) is
3239 pragma Assert
(Ekind
(Id
) = E_Component
);
3241 end Set_Discriminant_Checking_Func
;
3243 procedure Set_Discriminant_Constraint
(Id
: E
; V
: L
) is
3245 pragma Assert
(Nkind
(Id
) in N_Entity
);
3246 Set_Elist21
(Id
, V
);
3247 end Set_Discriminant_Constraint
;
3249 procedure Set_Discriminant_Default_Value
(Id
: E
; V
: N
) is
3252 end Set_Discriminant_Default_Value
;
3254 procedure Set_Discriminant_Number
(Id
: E
; V
: U
) is
3257 end Set_Discriminant_Number
;
3259 procedure Set_Dispatch_Table_Wrapper
(Id
: E
; V
: E
) is
3261 pragma Assert
(Is_Tagged_Type
(Id
) and then Id
= Base_Type
(Id
));
3263 end Set_Dispatch_Table_Wrapper
;
3265 procedure Set_DT_Entry_Count
(Id
: E
; V
: U
) is
3267 pragma Assert
(Ekind
(Id
) = E_Component
);
3269 end Set_DT_Entry_Count
;
3271 procedure Set_DT_Offset_To_Top_Func
(Id
: E
; V
: E
) is
3273 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
3275 end Set_DT_Offset_To_Top_Func
;
3277 procedure Set_DT_Position
(Id
: E
; V
: U
) is
3279 pragma Assert
(Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
3281 end Set_DT_Position
;
3283 procedure Set_DTC_Entity
(Id
: E
; V
: E
) is
3286 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
3290 procedure Set_Elaborate_Body_Desirable
(Id
: E
; V
: B
:= True) is
3292 pragma Assert
(Ekind
(Id
) = E_Package
);
3293 Set_Flag210
(Id
, V
);
3294 end Set_Elaborate_Body_Desirable
;
3296 procedure Set_Elaboration_Entity
(Id
: E
; V
: E
) is
3301 Ekind
(Id
) = E_Package
3303 Is_Generic_Unit
(Id
));
3305 end Set_Elaboration_Entity
;
3307 procedure Set_Elaboration_Entity_Required
(Id
: E
; V
: B
:= True) is
3312 Ekind
(Id
) = E_Package
3314 Is_Generic_Unit
(Id
));
3315 Set_Flag174
(Id
, V
);
3316 end Set_Elaboration_Entity_Required
;
3318 procedure Set_Enclosing_Scope
(Id
: E
; V
: E
) is
3321 end Set_Enclosing_Scope
;
3323 procedure Set_Entry_Accepted
(Id
: E
; V
: B
:= True) is
3325 pragma Assert
(Is_Entry
(Id
));
3326 Set_Flag152
(Id
, V
);
3327 end Set_Entry_Accepted
;
3329 procedure Set_Entry_Bodies_Array
(Id
: E
; V
: E
) is
3332 end Set_Entry_Bodies_Array
;
3334 procedure Set_Entry_Cancel_Parameter
(Id
: E
; V
: E
) is
3337 end Set_Entry_Cancel_Parameter
;
3339 procedure Set_Entry_Component
(Id
: E
; V
: E
) is
3342 end Set_Entry_Component
;
3344 procedure Set_Entry_Formal
(Id
: E
; V
: E
) is
3347 end Set_Entry_Formal
;
3349 procedure Set_Entry_Index_Constant
(Id
: E
; V
: E
) is
3351 pragma Assert
(Ekind
(Id
) = E_Entry_Index_Parameter
);
3353 end Set_Entry_Index_Constant
;
3355 procedure Set_Entry_Parameters_Type
(Id
: E
; V
: E
) is
3358 end Set_Entry_Parameters_Type
;
3360 procedure Set_Enum_Pos_To_Rep
(Id
: E
; V
: E
) is
3362 pragma Assert
(Ekind
(Id
) = E_Enumeration_Type
);
3364 end Set_Enum_Pos_To_Rep
;
3366 procedure Set_Enumeration_Pos
(Id
: E
; V
: U
) is
3368 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
3370 end Set_Enumeration_Pos
;
3372 procedure Set_Enumeration_Rep
(Id
: E
; V
: U
) is
3374 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
3376 end Set_Enumeration_Rep
;
3378 procedure Set_Enumeration_Rep_Expr
(Id
: E
; V
: N
) is
3380 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
3382 end Set_Enumeration_Rep_Expr
;
3384 procedure Set_Equivalent_Type
(Id
: E
; V
: E
) is
3387 (Ekind
(Id
) = E_Class_Wide_Type
or else
3388 Ekind
(Id
) = E_Class_Wide_Subtype
or else
3389 Ekind
(Id
) = E_Access_Protected_Subprogram_Type
or else
3390 Ekind
(Id
) = E_Anonymous_Access_Protected_Subprogram_Type
or else
3391 Ekind
(Id
) = E_Access_Subprogram_Type
or else
3392 Ekind
(Id
) = E_Exception_Type
);
3394 end Set_Equivalent_Type
;
3396 procedure Set_Esize
(Id
: E
; V
: U
) is
3401 procedure Set_Exception_Code
(Id
: E
; V
: U
) is
3403 pragma Assert
(Ekind
(Id
) = E_Exception
);
3405 end Set_Exception_Code
;
3407 procedure Set_Extra_Accessibility
(Id
: E
; V
: E
) is
3409 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
3411 end Set_Extra_Accessibility
;
3413 procedure Set_Extra_Constrained
(Id
: E
; V
: E
) is
3415 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
3417 end Set_Extra_Constrained
;
3419 procedure Set_Extra_Formal
(Id
: E
; V
: E
) is
3422 end Set_Extra_Formal
;
3424 procedure Set_Extra_Formals
(Id
: E
; V
: E
) is
3427 (Is_Overloadable
(Id
)
3428 or else Ekind
(Id
) = E_Entry_Family
3429 or else Ekind
(Id
) = E_Subprogram_Body
3430 or else Ekind
(Id
) = E_Subprogram_Type
);
3432 end Set_Extra_Formals
;
3434 procedure Set_Can_Use_Internal_Rep
(Id
: E
; V
: B
:= True) is
3437 (Is_Access_Subprogram_Type
(Id
)
3438 and then Id
= Base_Type
(Id
));
3439 Set_Flag229
(Id
, V
);
3440 end Set_Can_Use_Internal_Rep
;
3442 procedure Set_Finalization_Chain_Entity
(Id
: E
; V
: E
) is
3445 end Set_Finalization_Chain_Entity
;
3447 procedure Set_Finalize_Storage_Only
(Id
: E
; V
: B
:= True) is
3449 pragma Assert
(Is_Type
(Id
) and then Id
= Base_Type
(Id
));
3450 Set_Flag158
(Id
, V
);
3451 end Set_Finalize_Storage_Only
;
3453 procedure Set_First_Entity
(Id
: E
; V
: E
) is
3456 end Set_First_Entity
;
3458 procedure Set_First_Index
(Id
: E
; V
: N
) is
3460 pragma Assert
(Is_Array_Type
(Id
) or else Is_String_Type
(Id
));
3462 end Set_First_Index
;
3464 procedure Set_First_Literal
(Id
: E
; V
: E
) is
3466 pragma Assert
(Is_Enumeration_Type
(Id
));
3468 end Set_First_Literal
;
3470 procedure Set_First_Optional_Parameter
(Id
: E
; V
: E
) is
3473 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
3475 end Set_First_Optional_Parameter
;
3477 procedure Set_First_Private_Entity
(Id
: E
; V
: E
) is
3479 pragma Assert
(Ekind
(Id
) = E_Package
3480 or else Ekind
(Id
) = E_Generic_Package
3481 or else Ekind
(Id
) in Concurrent_Kind
);
3483 end Set_First_Private_Entity
;
3485 procedure Set_First_Rep_Item
(Id
: E
; V
: N
) is
3488 end Set_First_Rep_Item
;
3490 procedure Set_Freeze_Node
(Id
: E
; V
: N
) is
3493 end Set_Freeze_Node
;
3495 procedure Set_From_With_Type
(Id
: E
; V
: B
:= True) is
3499 or else Ekind
(Id
) = E_Package
);
3500 Set_Flag159
(Id
, V
);
3501 end Set_From_With_Type
;
3503 procedure Set_Full_View
(Id
: E
; V
: E
) is
3505 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Constant
);
3509 procedure Set_Generic_Homonym
(Id
: E
; V
: E
) is
3512 end Set_Generic_Homonym
;
3514 procedure Set_Generic_Renamings
(Id
: E
; V
: L
) is
3516 Set_Elist23
(Id
, V
);
3517 end Set_Generic_Renamings
;
3519 procedure Set_Handler_Records
(Id
: E
; V
: S
) is
3522 end Set_Handler_Records
;
3524 procedure Set_Has_Aliased_Components
(Id
: E
; V
: B
:= True) is
3526 pragma Assert
(Id
= Base_Type
(Id
));
3527 Set_Flag135
(Id
, V
);
3528 end Set_Has_Aliased_Components
;
3530 procedure Set_Has_Alignment_Clause
(Id
: E
; V
: B
:= True) is
3533 end Set_Has_Alignment_Clause
;
3535 procedure Set_Has_All_Calls_Remote
(Id
: E
; V
: B
:= True) is
3538 end Set_Has_All_Calls_Remote
;
3540 procedure Set_Has_Anon_Block_Suffix
(Id
: E
; V
: B
:= True) is
3542 Set_Flag201
(Id
, V
);
3543 end Set_Has_Anon_Block_Suffix
;
3545 procedure Set_Has_Atomic_Components
(Id
: E
; V
: B
:= True) is
3547 pragma Assert
(not Is_Type
(Id
) or else Id
= Base_Type
(Id
));
3549 end Set_Has_Atomic_Components
;
3551 procedure Set_Has_Biased_Representation
(Id
: E
; V
: B
:= True) is
3554 ((V
= False) or else (Is_Discrete_Type
(Id
) or else Is_Object
(Id
)));
3555 Set_Flag139
(Id
, V
);
3556 end Set_Has_Biased_Representation
;
3558 procedure Set_Has_Completion
(Id
: E
; V
: B
:= True) is
3561 end Set_Has_Completion
;
3563 procedure Set_Has_Completion_In_Body
(Id
: E
; V
: B
:= True) is
3565 pragma Assert
(Is_Type
(Id
));
3567 end Set_Has_Completion_In_Body
;
3569 procedure Set_Has_Complex_Representation
(Id
: E
; V
: B
:= True) is
3571 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
3572 Set_Flag140
(Id
, V
);
3573 end Set_Has_Complex_Representation
;
3575 procedure Set_Has_Component_Size_Clause
(Id
: E
; V
: B
:= True) is
3577 pragma Assert
(Ekind
(Id
) = E_Array_Type
);
3579 end Set_Has_Component_Size_Clause
;
3581 procedure Set_Has_Constrained_Partial_View
(Id
: E
; V
: B
:= True) is
3583 pragma Assert
(Is_Type
(Id
));
3584 Set_Flag187
(Id
, V
);
3585 end Set_Has_Constrained_Partial_View
;
3587 procedure Set_Has_Contiguous_Rep
(Id
: E
; V
: B
:= True) is
3589 Set_Flag181
(Id
, V
);
3590 end Set_Has_Contiguous_Rep
;
3592 procedure Set_Has_Controlled_Component
(Id
: E
; V
: B
:= True) is
3594 pragma Assert
(Id
= Base_Type
(Id
));
3596 end Set_Has_Controlled_Component
;
3598 procedure Set_Has_Controlling_Result
(Id
: E
; V
: B
:= True) is
3601 end Set_Has_Controlling_Result
;
3603 procedure Set_Has_Convention_Pragma
(Id
: E
; V
: B
:= True) is
3605 Set_Flag119
(Id
, V
);
3606 end Set_Has_Convention_Pragma
;
3608 procedure Set_Has_Delayed_Freeze
(Id
: E
; V
: B
:= True) is
3610 pragma Assert
(Nkind
(Id
) in N_Entity
);
3612 end Set_Has_Delayed_Freeze
;
3614 procedure Set_Has_Discriminants
(Id
: E
; V
: B
:= True) is
3616 pragma Assert
(Nkind
(Id
) in N_Entity
);
3618 end Set_Has_Discriminants
;
3620 procedure Set_Has_Dispatch_Table
(Id
: E
; V
: B
:= True) is
3622 pragma Assert
(Ekind
(Id
) = E_Record_Type
3623 and then Is_Tagged_Type
(Id
));
3624 Set_Flag220
(Id
, V
);
3625 end Set_Has_Dispatch_Table
;
3627 procedure Set_Has_Enumeration_Rep_Clause
(Id
: E
; V
: B
:= True) is
3629 pragma Assert
(Is_Enumeration_Type
(Id
));
3631 end Set_Has_Enumeration_Rep_Clause
;
3633 procedure Set_Has_Exit
(Id
: E
; V
: B
:= True) is
3638 procedure Set_Has_External_Tag_Rep_Clause
(Id
: E
; V
: B
:= True) is
3640 pragma Assert
(Is_Tagged_Type
(Id
));
3641 Set_Flag110
(Id
, V
);
3642 end Set_Has_External_Tag_Rep_Clause
;
3644 procedure Set_Has_Forward_Instantiation
(Id
: E
; V
: B
:= True) is
3646 Set_Flag175
(Id
, V
);
3647 end Set_Has_Forward_Instantiation
;
3649 procedure Set_Has_Fully_Qualified_Name
(Id
: E
; V
: B
:= True) is
3651 Set_Flag173
(Id
, V
);
3652 end Set_Has_Fully_Qualified_Name
;
3654 procedure Set_Has_Gigi_Rep_Item
(Id
: E
; V
: B
:= True) is
3657 end Set_Has_Gigi_Rep_Item
;
3659 procedure Set_Has_Homonym
(Id
: E
; V
: B
:= True) is
3662 end Set_Has_Homonym
;
3664 procedure Set_Has_Initial_Value
(Id
: E
; V
: B
:= True) is
3667 (Ekind
(Id
) = E_Variable
or else Ekind
(Id
) = E_Out_Parameter
);
3668 Set_Flag219
(Id
, V
);
3669 end Set_Has_Initial_Value
;
3671 procedure Set_Has_Machine_Radix_Clause
(Id
: E
; V
: B
:= True) is
3673 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
3675 end Set_Has_Machine_Radix_Clause
;
3677 procedure Set_Has_Master_Entity
(Id
: E
; V
: B
:= True) is
3680 end Set_Has_Master_Entity
;
3682 procedure Set_Has_Missing_Return
(Id
: E
; V
: B
:= True) is
3685 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Generic_Function
);
3686 Set_Flag142
(Id
, V
);
3687 end Set_Has_Missing_Return
;
3689 procedure Set_Has_Nested_Block_With_Handler
(Id
: E
; V
: B
:= True) is
3691 Set_Flag101
(Id
, V
);
3692 end Set_Has_Nested_Block_With_Handler
;
3694 procedure Set_Has_Up_Level_Access
(Id
: E
; V
: B
:= True) is
3697 (Ekind
(Id
) = E_Variable
3698 or else Ekind
(Id
) = E_Constant
3699 or else Ekind
(Id
) = E_Loop_Parameter
);
3700 Set_Flag215
(Id
, V
);
3701 end Set_Has_Up_Level_Access
;
3703 procedure Set_Has_Non_Standard_Rep
(Id
: E
; V
: B
:= True) is
3705 pragma Assert
(Id
= Base_Type
(Id
));
3707 end Set_Has_Non_Standard_Rep
;
3709 procedure Set_Has_Object_Size_Clause
(Id
: E
; V
: B
:= True) is
3711 pragma Assert
(Is_Type
(Id
));
3712 Set_Flag172
(Id
, V
);
3713 end Set_Has_Object_Size_Clause
;
3715 procedure Set_Has_Per_Object_Constraint
(Id
: E
; V
: B
:= True) is
3717 Set_Flag154
(Id
, V
);
3718 end Set_Has_Per_Object_Constraint
;
3720 procedure Set_Has_Persistent_BSS
(Id
: E
; V
: B
:= True) is
3722 Set_Flag188
(Id
, V
);
3723 end Set_Has_Persistent_BSS
;
3725 procedure Set_Has_Postconditions
(Id
: E
; V
: B
:= True) is
3727 pragma Assert
(Is_Subprogram
(Id
));
3728 Set_Flag240
(Id
, V
);
3729 end Set_Has_Postconditions
;
3731 procedure Set_Has_Pragma_Controlled
(Id
: E
; V
: B
:= True) is
3733 pragma Assert
(Is_Access_Type
(Id
));
3734 Set_Flag27
(Base_Type
(Id
), V
);
3735 end Set_Has_Pragma_Controlled
;
3737 procedure Set_Has_Pragma_Elaborate_Body
(Id
: E
; V
: B
:= True) is
3739 Set_Flag150
(Id
, V
);
3740 end Set_Has_Pragma_Elaborate_Body
;
3742 procedure Set_Has_Pragma_Inline
(Id
: E
; V
: B
:= True) is
3744 Set_Flag157
(Id
, V
);
3745 end Set_Has_Pragma_Inline
;
3747 procedure Set_Has_Pragma_Inline_Always
(Id
: E
; V
: B
:= True) is
3749 Set_Flag230
(Id
, V
);
3750 end Set_Has_Pragma_Inline_Always
;
3752 procedure Set_Has_Pragma_Pack
(Id
: E
; V
: B
:= True) is
3754 pragma Assert
(Is_Array_Type
(Id
) or else Is_Record_Type
(Id
));
3755 pragma Assert
(Id
= Base_Type
(Id
));
3756 Set_Flag121
(Id
, V
);
3757 end Set_Has_Pragma_Pack
;
3759 procedure Set_Has_Pragma_Preelab_Init
(Id
: E
; V
: B
:= True) is
3761 Set_Flag221
(Id
, V
);
3762 end Set_Has_Pragma_Preelab_Init
;
3764 procedure Set_Has_Pragma_Pure
(Id
: E
; V
: B
:= True) is
3766 Set_Flag203
(Id
, V
);
3767 end Set_Has_Pragma_Pure
;
3769 procedure Set_Has_Pragma_Pure_Function
(Id
: E
; V
: B
:= True) is
3771 Set_Flag179
(Id
, V
);
3772 end Set_Has_Pragma_Pure_Function
;
3774 procedure Set_Has_Pragma_Unmodified
(Id
: E
; V
: B
:= True) is
3776 Set_Flag233
(Id
, V
);
3777 end Set_Has_Pragma_Unmodified
;
3779 procedure Set_Has_Pragma_Unreferenced
(Id
: E
; V
: B
:= True) is
3781 Set_Flag180
(Id
, V
);
3782 end Set_Has_Pragma_Unreferenced
;
3784 procedure Set_Has_Pragma_Unreferenced_Objects
(Id
: E
; V
: B
:= True) is
3786 pragma Assert
(Is_Type
(Id
));
3787 Set_Flag212
(Id
, V
);
3788 end Set_Has_Pragma_Unreferenced_Objects
;
3790 procedure Set_Has_Primitive_Operations
(Id
: E
; V
: B
:= True) is
3792 pragma Assert
(Id
= Base_Type
(Id
));
3793 Set_Flag120
(Id
, V
);
3794 end Set_Has_Primitive_Operations
;
3796 procedure Set_Has_Private_Declaration
(Id
: E
; V
: B
:= True) is
3798 Set_Flag155
(Id
, V
);
3799 end Set_Has_Private_Declaration
;
3801 procedure Set_Has_Qualified_Name
(Id
: E
; V
: B
:= True) is
3803 Set_Flag161
(Id
, V
);
3804 end Set_Has_Qualified_Name
;
3806 procedure Set_Has_RACW
(Id
: E
; V
: B
:= True) is
3808 pragma Assert
(Ekind
(Id
) = E_Package
);
3809 Set_Flag214
(Id
, V
);
3812 procedure Set_Has_Record_Rep_Clause
(Id
: E
; V
: B
:= True) is
3814 pragma Assert
(Id
= Base_Type
(Id
));
3816 end Set_Has_Record_Rep_Clause
;
3818 procedure Set_Has_Recursive_Call
(Id
: E
; V
: B
:= True) is
3820 pragma Assert
(Is_Subprogram
(Id
));
3821 Set_Flag143
(Id
, V
);
3822 end Set_Has_Recursive_Call
;
3824 procedure Set_Has_Size_Clause
(Id
: E
; V
: B
:= True) is
3827 end Set_Has_Size_Clause
;
3829 procedure Set_Has_Small_Clause
(Id
: E
; V
: B
:= True) is
3832 end Set_Has_Small_Clause
;
3834 procedure Set_Has_Specified_Layout
(Id
: E
; V
: B
:= True) is
3836 pragma Assert
(Id
= Base_Type
(Id
));
3837 Set_Flag100
(Id
, V
);
3838 end Set_Has_Specified_Layout
;
3840 procedure Set_Has_Specified_Stream_Input
(Id
: E
; V
: B
:= True) is
3842 pragma Assert
(Is_Type
(Id
));
3843 Set_Flag190
(Id
, V
);
3844 end Set_Has_Specified_Stream_Input
;
3846 procedure Set_Has_Specified_Stream_Output
(Id
: E
; V
: B
:= True) is
3848 pragma Assert
(Is_Type
(Id
));
3849 Set_Flag191
(Id
, V
);
3850 end Set_Has_Specified_Stream_Output
;
3852 procedure Set_Has_Specified_Stream_Read
(Id
: E
; V
: B
:= True) is
3854 pragma Assert
(Is_Type
(Id
));
3855 Set_Flag192
(Id
, V
);
3856 end Set_Has_Specified_Stream_Read
;
3858 procedure Set_Has_Specified_Stream_Write
(Id
: E
; V
: B
:= True) is
3860 pragma Assert
(Is_Type
(Id
));
3861 Set_Flag193
(Id
, V
);
3862 end Set_Has_Specified_Stream_Write
;
3864 procedure Set_Has_Static_Discriminants
(Id
: E
; V
: B
:= True) is
3866 Set_Flag211
(Id
, V
);
3867 end Set_Has_Static_Discriminants
;
3869 procedure Set_Has_Storage_Size_Clause
(Id
: E
; V
: B
:= True) is
3871 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
3872 pragma Assert
(Id
= Base_Type
(Id
));
3874 end Set_Has_Storage_Size_Clause
;
3876 procedure Set_Has_Stream_Size_Clause
(Id
: E
; V
: B
:= True) is
3878 pragma Assert
(Is_Elementary_Type
(Id
));
3879 Set_Flag184
(Id
, V
);
3880 end Set_Has_Stream_Size_Clause
;
3882 procedure Set_Has_Subprogram_Descriptor
(Id
: E
; V
: B
:= True) is
3885 end Set_Has_Subprogram_Descriptor
;
3887 procedure Set_Has_Task
(Id
: E
; V
: B
:= True) is
3889 pragma Assert
(Id
= Base_Type
(Id
));
3893 procedure Set_Has_Thunks
(Id
: E
; V
: B
:= True) is
3895 pragma Assert
(Is_Tag
(Id
)
3896 and then Ekind
(Id
) = E_Constant
);
3897 Set_Flag228
(Id
, V
);
3900 procedure Set_Has_Unchecked_Union
(Id
: E
; V
: B
:= True) is
3902 pragma Assert
(Id
= Base_Type
(Id
));
3903 Set_Flag123
(Id
, V
);
3904 end Set_Has_Unchecked_Union
;
3906 procedure Set_Has_Unknown_Discriminants
(Id
: E
; V
: B
:= True) is
3908 pragma Assert
(Is_Type
(Id
));
3910 end Set_Has_Unknown_Discriminants
;
3912 procedure Set_Has_Volatile_Components
(Id
: E
; V
: B
:= True) is
3914 pragma Assert
(not Is_Type
(Id
) or else Id
= Base_Type
(Id
));
3916 end Set_Has_Volatile_Components
;
3918 procedure Set_Has_Xref_Entry
(Id
: E
; V
: B
:= True) is
3920 Set_Flag182
(Id
, V
);
3921 end Set_Has_Xref_Entry
;
3923 procedure Set_Hiding_Loop_Variable
(Id
: E
; V
: E
) is
3925 pragma Assert
(Ekind
(Id
) = E_Variable
);
3927 end Set_Hiding_Loop_Variable
;
3929 procedure Set_Homonym
(Id
: E
; V
: E
) is
3931 pragma Assert
(Id
/= V
);
3935 procedure Set_Implemented_By_Entry
(Id
: E
; V
: B
:= True) is
3938 (Ekind
(Id
) = E_Function
3939 or else Ekind
(Id
) = E_Procedure
);
3940 Set_Flag232
(Id
, V
);
3941 end Set_Implemented_By_Entry
;
3943 procedure Set_Interfaces
(Id
: E
; V
: L
) is
3945 pragma Assert
(Is_Record_Type
(Id
));
3946 Set_Elist25
(Id
, V
);
3949 procedure Set_Interface_Alias
(Id
: E
; V
: E
) is
3953 and then Is_Hidden
(Id
)
3954 and then (Ekind
(Id
) = E_Procedure
3955 or else Ekind
(Id
) = E_Function
));
3957 end Set_Interface_Alias
;
3959 procedure Set_In_Package_Body
(Id
: E
; V
: B
:= True) is
3962 end Set_In_Package_Body
;
3964 procedure Set_In_Private_Part
(Id
: E
; V
: B
:= True) is
3967 end Set_In_Private_Part
;
3969 procedure Set_In_Use
(Id
: E
; V
: B
:= True) is
3971 pragma Assert
(Nkind
(Id
) in N_Entity
);
3975 procedure Set_Inner_Instances
(Id
: E
; V
: L
) is
3977 Set_Elist23
(Id
, V
);
3978 end Set_Inner_Instances
;
3980 procedure Set_Interface_Name
(Id
: E
; V
: N
) is
3983 end Set_Interface_Name
;
3985 procedure Set_Is_Abstract_Subprogram
(Id
: E
; V
: B
:= True) is
3987 pragma Assert
(Is_Overloadable
(Id
));
3989 end Set_Is_Abstract_Subprogram
;
3991 procedure Set_Is_Abstract_Type
(Id
: E
; V
: B
:= True) is
3993 pragma Assert
(Is_Type
(Id
));
3994 Set_Flag146
(Id
, V
);
3995 end Set_Is_Abstract_Type
;
3997 procedure Set_Is_Local_Anonymous_Access
(Id
: E
; V
: B
:= True) is
3999 pragma Assert
(Is_Access_Type
(Id
));
4000 Set_Flag194
(Id
, V
);
4001 end Set_Is_Local_Anonymous_Access
;
4003 procedure Set_Is_Access_Constant
(Id
: E
; V
: B
:= True) is
4005 pragma Assert
(Is_Access_Type
(Id
));
4007 end Set_Is_Access_Constant
;
4009 procedure Set_Is_Ada_2005_Only
(Id
: E
; V
: B
:= True) is
4011 Set_Flag185
(Id
, V
);
4012 end Set_Is_Ada_2005_Only
;
4014 procedure Set_Is_Aliased
(Id
: E
; V
: B
:= True) is
4016 pragma Assert
(Nkind
(Id
) in N_Entity
);
4020 procedure Set_Is_AST_Entry
(Id
: E
; V
: B
:= True) is
4022 pragma Assert
(Is_Entry
(Id
));
4023 Set_Flag132
(Id
, V
);
4024 end Set_Is_AST_Entry
;
4026 procedure Set_Is_Asynchronous
(Id
: E
; V
: B
:= True) is
4029 (Ekind
(Id
) = E_Procedure
or else Is_Type
(Id
));
4031 end Set_Is_Asynchronous
;
4033 procedure Set_Is_Atomic
(Id
: E
; V
: B
:= True) is
4038 procedure Set_Is_Bit_Packed_Array
(Id
: E
; V
: B
:= True) is
4040 pragma Assert
((not V
)
4041 or else (Is_Array_Type
(Id
) and then Id
= Base_Type
(Id
)));
4043 Set_Flag122
(Id
, V
);
4044 end Set_Is_Bit_Packed_Array
;
4046 procedure Set_Is_Called
(Id
: E
; V
: B
:= True) is
4049 (Ekind
(Id
) = E_Procedure
or else Ekind
(Id
) = E_Function
);
4050 Set_Flag102
(Id
, V
);
4053 procedure Set_Is_Character_Type
(Id
: E
; V
: B
:= True) is
4056 end Set_Is_Character_Type
;
4058 procedure Set_Is_Child_Unit
(Id
: E
; V
: B
:= True) is
4061 end Set_Is_Child_Unit
;
4063 procedure Set_Is_Class_Wide_Equivalent_Type
(Id
: E
; V
: B
:= True) is
4066 end Set_Is_Class_Wide_Equivalent_Type
;
4068 procedure Set_Is_Compilation_Unit
(Id
: E
; V
: B
:= True) is
4070 Set_Flag149
(Id
, V
);
4071 end Set_Is_Compilation_Unit
;
4073 procedure Set_Is_Completely_Hidden
(Id
: E
; V
: B
:= True) is
4075 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
4076 Set_Flag103
(Id
, V
);
4077 end Set_Is_Completely_Hidden
;
4079 procedure Set_Is_Concurrent_Record_Type
(Id
: E
; V
: B
:= True) is
4082 end Set_Is_Concurrent_Record_Type
;
4084 procedure Set_Is_Constr_Subt_For_U_Nominal
(Id
: E
; V
: B
:= True) is
4087 end Set_Is_Constr_Subt_For_U_Nominal
;
4089 procedure Set_Is_Constr_Subt_For_UN_Aliased
(Id
: E
; V
: B
:= True) is
4091 Set_Flag141
(Id
, V
);
4092 end Set_Is_Constr_Subt_For_UN_Aliased
;
4094 procedure Set_Is_Constrained
(Id
: E
; V
: B
:= True) is
4096 pragma Assert
(Nkind
(Id
) in N_Entity
);
4098 end Set_Is_Constrained
;
4100 procedure Set_Is_Constructor
(Id
: E
; V
: B
:= True) is
4103 end Set_Is_Constructor
;
4105 procedure Set_Is_Controlled
(Id
: E
; V
: B
:= True) is
4107 pragma Assert
(Id
= Base_Type
(Id
));
4109 end Set_Is_Controlled
;
4111 procedure Set_Is_Controlling_Formal
(Id
: E
; V
: B
:= True) is
4113 pragma Assert
(Is_Formal
(Id
));
4115 end Set_Is_Controlling_Formal
;
4117 procedure Set_Is_CPP_Class
(Id
: E
; V
: B
:= True) is
4120 end Set_Is_CPP_Class
;
4122 procedure Set_Is_Descendent_Of_Address
(Id
: E
; V
: B
:= True) is
4124 pragma Assert
(Is_Type
(Id
));
4125 Set_Flag223
(Id
, V
);
4126 end Set_Is_Descendent_Of_Address
;
4128 procedure Set_Is_Discrim_SO_Function
(Id
: E
; V
: B
:= True) is
4130 Set_Flag176
(Id
, V
);
4131 end Set_Is_Discrim_SO_Function
;
4133 procedure Set_Is_Dispatch_Table_Entity
(Id
: E
; V
: B
:= True) is
4135 Set_Flag234
(Id
, V
);
4136 end Set_Is_Dispatch_Table_Entity
;
4138 procedure Set_Is_Dispatching_Operation
(Id
: E
; V
: B
:= True) is
4143 Is_Overloadable
(Id
)
4145 Ekind
(Id
) = E_Subprogram_Type
);
4148 end Set_Is_Dispatching_Operation
;
4150 procedure Set_Is_Eliminated
(Id
: E
; V
: B
:= True) is
4152 Set_Flag124
(Id
, V
);
4153 end Set_Is_Eliminated
;
4155 procedure Set_Is_Entry_Formal
(Id
: E
; V
: B
:= True) is
4158 end Set_Is_Entry_Formal
;
4160 procedure Set_Is_Exported
(Id
: E
; V
: B
:= True) is
4163 end Set_Is_Exported
;
4165 procedure Set_Is_First_Subtype
(Id
: E
; V
: B
:= True) is
4168 end Set_Is_First_Subtype
;
4170 procedure Set_Is_For_Access_Subtype
(Id
: E
; V
: B
:= True) is
4173 (Ekind
(Id
) = E_Record_Subtype
4175 Ekind
(Id
) = E_Private_Subtype
);
4176 Set_Flag118
(Id
, V
);
4177 end Set_Is_For_Access_Subtype
;
4179 procedure Set_Is_Formal_Subprogram
(Id
: E
; V
: B
:= True) is
4181 Set_Flag111
(Id
, V
);
4182 end Set_Is_Formal_Subprogram
;
4184 procedure Set_Is_Frozen
(Id
: E
; V
: B
:= True) is
4186 pragma Assert
(Nkind
(Id
) in N_Entity
);
4190 procedure Set_Is_Generic_Actual_Type
(Id
: E
; V
: B
:= True) is
4192 pragma Assert
(Is_Type
(Id
));
4194 end Set_Is_Generic_Actual_Type
;
4196 procedure Set_Is_Generic_Instance
(Id
: E
; V
: B
:= True) is
4198 Set_Flag130
(Id
, V
);
4199 end Set_Is_Generic_Instance
;
4201 procedure Set_Is_Generic_Type
(Id
: E
; V
: B
:= True) is
4203 pragma Assert
(Nkind
(Id
) in N_Entity
);
4205 end Set_Is_Generic_Type
;
4207 procedure Set_Is_Hidden
(Id
: E
; V
: B
:= True) is
4212 procedure Set_Is_Hidden_Open_Scope
(Id
: E
; V
: B
:= True) is
4214 Set_Flag171
(Id
, V
);
4215 end Set_Is_Hidden_Open_Scope
;
4217 procedure Set_Is_Immediately_Visible
(Id
: E
; V
: B
:= True) is
4219 pragma Assert
(Nkind
(Id
) in N_Entity
);
4221 end Set_Is_Immediately_Visible
;
4223 procedure Set_Is_Imported
(Id
: E
; V
: B
:= True) is
4226 end Set_Is_Imported
;
4228 procedure Set_Is_Inlined
(Id
: E
; V
: B
:= True) is
4233 procedure Set_Is_Interface
(Id
: E
; V
: B
:= True) is
4236 (Ekind
(Id
) = E_Record_Type
4237 or else Ekind
(Id
) = E_Record_Subtype
4238 or else Ekind
(Id
) = E_Record_Type_With_Private
4239 or else Ekind
(Id
) = E_Record_Subtype_With_Private
4240 or else Ekind
(Id
) = E_Class_Wide_Type
4241 or else Ekind
(Id
) = E_Class_Wide_Subtype
);
4242 Set_Flag186
(Id
, V
);
4243 end Set_Is_Interface
;
4245 procedure Set_Is_Instantiated
(Id
: E
; V
: B
:= True) is
4247 Set_Flag126
(Id
, V
);
4248 end Set_Is_Instantiated
;
4250 procedure Set_Is_Internal
(Id
: E
; V
: B
:= True) is
4252 pragma Assert
(Nkind
(Id
) in N_Entity
);
4254 end Set_Is_Internal
;
4256 procedure Set_Is_Interrupt_Handler
(Id
: E
; V
: B
:= True) is
4258 pragma Assert
(Nkind
(Id
) in N_Entity
);
4260 end Set_Is_Interrupt_Handler
;
4262 procedure Set_Is_Intrinsic_Subprogram
(Id
: E
; V
: B
:= True) is
4265 end Set_Is_Intrinsic_Subprogram
;
4267 procedure Set_Is_Itype
(Id
: E
; V
: B
:= True) is
4272 procedure Set_Is_Known_Non_Null
(Id
: E
; V
: B
:= True) is
4275 end Set_Is_Known_Non_Null
;
4277 procedure Set_Is_Known_Null
(Id
: E
; V
: B
:= True) is
4279 Set_Flag204
(Id
, V
);
4280 end Set_Is_Known_Null
;
4282 procedure Set_Is_Known_Valid
(Id
: E
; V
: B
:= True) is
4284 Set_Flag170
(Id
, V
);
4285 end Set_Is_Known_Valid
;
4287 procedure Set_Is_Limited_Composite
(Id
: E
; V
: B
:= True) is
4289 pragma Assert
(Is_Type
(Id
));
4290 Set_Flag106
(Id
, V
);
4291 end Set_Is_Limited_Composite
;
4293 procedure Set_Is_Limited_Interface
(Id
: E
; V
: B
:= True) is
4295 pragma Assert
(Is_Interface
(Id
));
4296 Set_Flag197
(Id
, V
);
4297 end Set_Is_Limited_Interface
;
4299 procedure Set_Is_Limited_Record
(Id
: E
; V
: B
:= True) is
4302 end Set_Is_Limited_Record
;
4304 procedure Set_Is_Machine_Code_Subprogram
(Id
: E
; V
: B
:= True) is
4306 pragma Assert
(Is_Subprogram
(Id
));
4307 Set_Flag137
(Id
, V
);
4308 end Set_Is_Machine_Code_Subprogram
;
4310 procedure Set_Is_Non_Static_Subtype
(Id
: E
; V
: B
:= True) is
4312 pragma Assert
(Is_Type
(Id
));
4313 Set_Flag109
(Id
, V
);
4314 end Set_Is_Non_Static_Subtype
;
4316 procedure Set_Is_Null_Init_Proc
(Id
: E
; V
: B
:= True) is
4318 pragma Assert
(Ekind
(Id
) = E_Procedure
);
4319 Set_Flag178
(Id
, V
);
4320 end Set_Is_Null_Init_Proc
;
4322 procedure Set_Is_Obsolescent
(Id
: E
; V
: B
:= True) is
4324 Set_Flag153
(Id
, V
);
4325 end Set_Is_Obsolescent
;
4327 procedure Set_Is_Only_Out_Parameter
(Id
: E
; V
: B
:= True) is
4329 pragma Assert
(Ekind
(Id
) = E_Out_Parameter
);
4330 Set_Flag226
(Id
, V
);
4331 end Set_Is_Only_Out_Parameter
;
4333 procedure Set_Is_Optional_Parameter
(Id
: E
; V
: B
:= True) is
4335 pragma Assert
(Is_Formal
(Id
));
4336 Set_Flag134
(Id
, V
);
4337 end Set_Is_Optional_Parameter
;
4339 procedure Set_Is_Overriding_Operation
(Id
: E
; V
: B
:= True) is
4341 pragma Assert
(Is_Subprogram
(Id
));
4343 end Set_Is_Overriding_Operation
;
4345 procedure Set_Is_Package_Body_Entity
(Id
: E
; V
: B
:= True) is
4347 Set_Flag160
(Id
, V
);
4348 end Set_Is_Package_Body_Entity
;
4350 procedure Set_Is_Packed
(Id
: E
; V
: B
:= True) is
4352 pragma Assert
(Id
= Base_Type
(Id
));
4356 procedure Set_Is_Packed_Array_Type
(Id
: E
; V
: B
:= True) is
4358 Set_Flag138
(Id
, V
);
4359 end Set_Is_Packed_Array_Type
;
4361 procedure Set_Is_Potentially_Use_Visible
(Id
: E
; V
: B
:= True) is
4363 pragma Assert
(Nkind
(Id
) in N_Entity
);
4365 end Set_Is_Potentially_Use_Visible
;
4367 procedure Set_Is_Preelaborated
(Id
: E
; V
: B
:= True) is
4370 end Set_Is_Preelaborated
;
4372 procedure Set_Is_Primitive
(Id
: E
; V
: B
:= True) is
4375 (Is_Overloadable
(Id
)
4376 or else Ekind
(Id
) = E_Generic_Function
4377 or else Ekind
(Id
) = E_Generic_Procedure
);
4378 Set_Flag218
(Id
, V
);
4379 end Set_Is_Primitive
;
4381 procedure Set_Is_Primitive_Wrapper
(Id
: E
; V
: B
:= True) is
4383 pragma Assert
(Ekind
(Id
) = E_Function
4384 or else Ekind
(Id
) = E_Procedure
);
4385 Set_Flag195
(Id
, V
);
4386 end Set_Is_Primitive_Wrapper
;
4388 procedure Set_Is_Private_Composite
(Id
: E
; V
: B
:= True) is
4390 pragma Assert
(Is_Type
(Id
));
4391 Set_Flag107
(Id
, V
);
4392 end Set_Is_Private_Composite
;
4394 procedure Set_Is_Private_Descendant
(Id
: E
; V
: B
:= True) is
4397 end Set_Is_Private_Descendant
;
4399 procedure Set_Is_Private_Primitive
(Id
: E
; V
: B
:= True) is
4401 pragma Assert
(Ekind
(Id
) = E_Function
4402 or else Ekind
(Id
) = E_Procedure
);
4403 Set_Flag245
(Id
, V
);
4404 end Set_Is_Private_Primitive
;
4406 procedure Set_Is_Protected_Interface
(Id
: E
; V
: B
:= True) is
4408 pragma Assert
(Is_Interface
(Id
));
4409 Set_Flag198
(Id
, V
);
4410 end Set_Is_Protected_Interface
;
4412 procedure Set_Is_Public
(Id
: E
; V
: B
:= True) is
4414 pragma Assert
(Nkind
(Id
) in N_Entity
);
4418 procedure Set_Is_Pure
(Id
: E
; V
: B
:= True) is
4423 procedure Set_Is_Pure_Unit_Access_Type
(Id
: E
; V
: B
:= True) is
4425 pragma Assert
(Is_Access_Type
(Id
));
4426 Set_Flag189
(Id
, V
);
4427 end Set_Is_Pure_Unit_Access_Type
;
4429 procedure Set_Is_RACW_Stub_Type
(Id
: E
; V
: B
:= True) is
4431 pragma Assert
(Is_Type
(Id
));
4432 Set_Flag244
(Id
, V
);
4433 end Set_Is_RACW_Stub_Type
;
4435 procedure Set_Is_Raised
(Id
: E
; V
: B
:= True) is
4437 pragma Assert
(Ekind
(Id
) = E_Exception
);
4438 Set_Flag224
(Id
, V
);
4441 procedure Set_Is_Remote_Call_Interface
(Id
: E
; V
: B
:= True) is
4444 end Set_Is_Remote_Call_Interface
;
4446 procedure Set_Is_Remote_Types
(Id
: E
; V
: B
:= True) is
4449 end Set_Is_Remote_Types
;
4451 procedure Set_Is_Renaming_Of_Object
(Id
: E
; V
: B
:= True) is
4453 Set_Flag112
(Id
, V
);
4454 end Set_Is_Renaming_Of_Object
;
4456 procedure Set_Is_Return_Object
(Id
: E
; V
: B
:= True) is
4458 Set_Flag209
(Id
, V
);
4459 end Set_Is_Return_Object
;
4461 procedure Set_Is_Shared_Passive
(Id
: E
; V
: B
:= True) is
4464 end Set_Is_Shared_Passive
;
4466 procedure Set_Is_Statically_Allocated
(Id
: E
; V
: B
:= True) is
4469 (Ekind
(Id
) = E_Exception
4470 or else Ekind
(Id
) = E_Variable
4471 or else Ekind
(Id
) = E_Constant
4472 or else Is_Type
(Id
)
4473 or else Ekind
(Id
) = E_Void
);
4475 end Set_Is_Statically_Allocated
;
4477 procedure Set_Is_Synchronized_Interface
(Id
: E
; V
: B
:= True) is
4479 pragma Assert
(Is_Interface
(Id
));
4480 Set_Flag199
(Id
, V
);
4481 end Set_Is_Synchronized_Interface
;
4483 procedure Set_Is_Tag
(Id
: E
; V
: B
:= True) is
4486 (Ekind
(Id
) = E_Component
4487 or else Ekind
(Id
) = E_Constant
);
4491 procedure Set_Is_Tagged_Type
(Id
: E
; V
: B
:= True) is
4494 end Set_Is_Tagged_Type
;
4496 procedure Set_Is_Task_Interface
(Id
: E
; V
: B
:= True) is
4498 pragma Assert
(Is_Interface
(Id
));
4499 Set_Flag200
(Id
, V
);
4500 end Set_Is_Task_Interface
;
4502 procedure Set_Is_Thunk
(Id
: E
; V
: B
:= True) is
4504 Set_Flag225
(Id
, V
);
4507 procedure Set_Is_Trivial_Subprogram
(Id
: E
; V
: B
:= True) is
4509 Set_Flag235
(Id
, V
);
4510 end Set_Is_Trivial_Subprogram
;
4512 procedure Set_Is_True_Constant
(Id
: E
; V
: B
:= True) is
4514 Set_Flag163
(Id
, V
);
4515 end Set_Is_True_Constant
;
4517 procedure Set_Is_Unchecked_Union
(Id
: E
; V
: B
:= True) is
4519 pragma Assert
(Id
= Base_Type
(Id
));
4520 Set_Flag117
(Id
, V
);
4521 end Set_Is_Unchecked_Union
;
4523 procedure Set_Is_Unsigned_Type
(Id
: E
; V
: B
:= True) is
4525 pragma Assert
(Is_Discrete_Or_Fixed_Point_Type
(Id
));
4526 Set_Flag144
(Id
, V
);
4527 end Set_Is_Unsigned_Type
;
4529 procedure Set_Is_Valued_Procedure
(Id
: E
; V
: B
:= True) is
4531 pragma Assert
(Ekind
(Id
) = E_Procedure
);
4532 Set_Flag127
(Id
, V
);
4533 end Set_Is_Valued_Procedure
;
4535 procedure Set_Is_Visible_Child_Unit
(Id
: E
; V
: B
:= True) is
4537 pragma Assert
(Is_Child_Unit
(Id
));
4538 Set_Flag116
(Id
, V
);
4539 end Set_Is_Visible_Child_Unit
;
4541 procedure Set_Is_Visible_Formal
(Id
: E
; V
: B
:= True) is
4543 Set_Flag206
(Id
, V
);
4544 end Set_Is_Visible_Formal
;
4546 procedure Set_Is_VMS_Exception
(Id
: E
; V
: B
:= True) is
4548 pragma Assert
(Ekind
(Id
) = E_Exception
);
4549 Set_Flag133
(Id
, V
);
4550 end Set_Is_VMS_Exception
;
4552 procedure Set_Is_Volatile
(Id
: E
; V
: B
:= True) is
4554 pragma Assert
(Nkind
(Id
) in N_Entity
);
4556 end Set_Is_Volatile
;
4558 procedure Set_Itype_Printed
(Id
: E
; V
: B
:= True) is
4560 pragma Assert
(Is_Itype
(Id
));
4561 Set_Flag202
(Id
, V
);
4562 end Set_Itype_Printed
;
4564 procedure Set_Kill_Elaboration_Checks
(Id
: E
; V
: B
:= True) is
4567 end Set_Kill_Elaboration_Checks
;
4569 procedure Set_Kill_Range_Checks
(Id
: E
; V
: B
:= True) is
4572 end Set_Kill_Range_Checks
;
4574 procedure Set_Kill_Tag_Checks
(Id
: E
; V
: B
:= True) is
4577 end Set_Kill_Tag_Checks
;
4579 procedure Set_Known_To_Have_Preelab_Init
(Id
: E
; V
: B
:= True) is
4581 pragma Assert
(Is_Type
(Id
));
4582 Set_Flag207
(Id
, V
);
4583 end Set_Known_To_Have_Preelab_Init
;
4585 procedure Set_Last_Assignment
(Id
: E
; V
: N
) is
4587 pragma Assert
(Is_Assignable
(Id
));
4589 end Set_Last_Assignment
;
4591 procedure Set_Last_Entity
(Id
: E
; V
: E
) is
4594 end Set_Last_Entity
;
4596 procedure Set_Limited_View
(Id
: E
; V
: E
) is
4598 pragma Assert
(Ekind
(Id
) = E_Package
);
4600 end Set_Limited_View
;
4602 procedure Set_Lit_Indexes
(Id
: E
; V
: E
) is
4604 pragma Assert
(Is_Enumeration_Type
(Id
) and then Root_Type
(Id
) = Id
);
4606 end Set_Lit_Indexes
;
4608 procedure Set_Lit_Strings
(Id
: E
; V
: E
) is
4610 pragma Assert
(Is_Enumeration_Type
(Id
) and then Root_Type
(Id
) = Id
);
4612 end Set_Lit_Strings
;
4614 procedure Set_Low_Bound_Known
(Id
: E
; V
: B
:= True) is
4616 pragma Assert
(Is_Formal
(Id
));
4617 Set_Flag205
(Id
, V
);
4618 end Set_Low_Bound_Known
;
4620 procedure Set_Machine_Radix_10
(Id
: E
; V
: B
:= True) is
4622 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
4624 end Set_Machine_Radix_10
;
4626 procedure Set_Master_Id
(Id
: E
; V
: E
) is
4628 pragma Assert
(Is_Access_Type
(Id
));
4632 procedure Set_Materialize_Entity
(Id
: E
; V
: B
:= True) is
4634 Set_Flag168
(Id
, V
);
4635 end Set_Materialize_Entity
;
4637 procedure Set_Mechanism
(Id
: E
; V
: M
) is
4639 pragma Assert
(Ekind
(Id
) = E_Function
or else Is_Formal
(Id
));
4640 Set_Uint8
(Id
, UI_From_Int
(V
));
4643 procedure Set_Modulus
(Id
: E
; V
: U
) is
4645 pragma Assert
(Ekind
(Id
) = E_Modular_Integer_Type
);
4649 procedure Set_Must_Be_On_Byte_Boundary
(Id
: E
; V
: B
:= True) is
4651 pragma Assert
(Is_Type
(Id
));
4652 Set_Flag183
(Id
, V
);
4653 end Set_Must_Be_On_Byte_Boundary
;
4655 procedure Set_Must_Have_Preelab_Init
(Id
: E
; V
: B
:= True) is
4657 pragma Assert
(Is_Type
(Id
));
4658 Set_Flag208
(Id
, V
);
4659 end Set_Must_Have_Preelab_Init
;
4661 procedure Set_Needs_Debug_Info
(Id
: E
; V
: B
:= True) is
4663 Set_Flag147
(Id
, V
);
4664 end Set_Needs_Debug_Info
;
4666 procedure Set_Needs_No_Actuals
(Id
: E
; V
: B
:= True) is
4669 (Is_Overloadable
(Id
)
4670 or else Ekind
(Id
) = E_Subprogram_Type
4671 or else Ekind
(Id
) = E_Entry_Family
);
4673 end Set_Needs_No_Actuals
;
4675 procedure Set_Never_Set_In_Source
(Id
: E
; V
: B
:= True) is
4677 Set_Flag115
(Id
, V
);
4678 end Set_Never_Set_In_Source
;
4680 procedure Set_Next_Inlined_Subprogram
(Id
: E
; V
: E
) is
4683 end Set_Next_Inlined_Subprogram
;
4685 procedure Set_No_Pool_Assigned
(Id
: E
; V
: B
:= True) is
4687 pragma Assert
(Is_Access_Type
(Id
) and then Id
= Base_Type
(Id
));
4688 Set_Flag131
(Id
, V
);
4689 end Set_No_Pool_Assigned
;
4691 procedure Set_No_Return
(Id
: E
; V
: B
:= True) is
4695 or else Ekind
(Id
) = E_Procedure
4696 or else Ekind
(Id
) = E_Generic_Procedure
);
4697 Set_Flag113
(Id
, V
);
4700 procedure Set_No_Strict_Aliasing
(Id
: E
; V
: B
:= True) is
4702 pragma Assert
(Is_Access_Type
(Id
) and then Id
= Base_Type
(Id
));
4703 Set_Flag136
(Id
, V
);
4704 end Set_No_Strict_Aliasing
;
4706 procedure Set_Non_Binary_Modulus
(Id
: E
; V
: B
:= True) is
4708 pragma Assert
(Is_Type
(Id
) and then Id
= Base_Type
(Id
));
4710 end Set_Non_Binary_Modulus
;
4712 procedure Set_Non_Limited_View
(Id
: E
; V
: E
) is
4714 pragma Assert
(Ekind
(Id
) in Incomplete_Kind
);
4716 end Set_Non_Limited_View
;
4718 procedure Set_Nonzero_Is_True
(Id
: E
; V
: B
:= True) is
4721 (Root_Type
(Id
) = Standard_Boolean
4722 and then Ekind
(Id
) = E_Enumeration_Type
);
4723 Set_Flag162
(Id
, V
);
4724 end Set_Nonzero_Is_True
;
4726 procedure Set_Normalized_First_Bit
(Id
: E
; V
: U
) is
4729 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
4731 end Set_Normalized_First_Bit
;
4733 procedure Set_Normalized_Position
(Id
: E
; V
: U
) is
4736 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
4738 end Set_Normalized_Position
;
4740 procedure Set_Normalized_Position_Max
(Id
: E
; V
: U
) is
4743 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
4745 end Set_Normalized_Position_Max
;
4747 procedure Set_OK_To_Reorder_Components
(Id
: E
; V
: B
:= True) is
4750 (Is_Record_Type
(Id
) and then Id
= Base_Type
(Id
));
4751 Set_Flag239
(Id
, V
);
4752 end Set_OK_To_Reorder_Components
;
4754 procedure Set_Optimize_Alignment_Space
(Id
: E
; V
: B
:= True) is
4758 or else Ekind
(Id
) = E_Constant
4759 or else Ekind
(Id
) = E_Variable
);
4760 Set_Flag241
(Id
, V
);
4761 end Set_Optimize_Alignment_Space
;
4763 procedure Set_Optimize_Alignment_Time
(Id
: E
; V
: B
:= True) is
4767 or else Ekind
(Id
) = E_Constant
4768 or else Ekind
(Id
) = E_Variable
);
4769 Set_Flag242
(Id
, V
);
4770 end Set_Optimize_Alignment_Time
;
4772 procedure Set_Original_Array_Type
(Id
: E
; V
: E
) is
4774 pragma Assert
(Is_Array_Type
(Id
) or else Is_Modular_Integer_Type
(Id
));
4776 end Set_Original_Array_Type
;
4778 procedure Set_Original_Record_Component
(Id
: E
; V
: E
) is
4781 (Ekind
(Id
) = E_Void
4782 or else Ekind
(Id
) = E_Component
4783 or else Ekind
(Id
) = E_Discriminant
);
4785 end Set_Original_Record_Component
;
4787 procedure Set_Overlays_Constant
(Id
: E
; V
: B
:= True) is
4789 Set_Flag243
(Id
, V
);
4790 end Set_Overlays_Constant
;
4792 procedure Set_Overridden_Operation
(Id
: E
; V
: E
) is
4795 end Set_Overridden_Operation
;
4797 procedure Set_Package_Instantiation
(Id
: E
; V
: N
) is
4800 (Ekind
(Id
) = E_Void
4801 or else Ekind
(Id
) = E_Generic_Package
4802 or else Ekind
(Id
) = E_Package
);
4804 end Set_Package_Instantiation
;
4806 procedure Set_Packed_Array_Type
(Id
: E
; V
: E
) is
4808 pragma Assert
(Is_Array_Type
(Id
));
4810 end Set_Packed_Array_Type
;
4812 procedure Set_Parent_Subtype
(Id
: E
; V
: E
) is
4814 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
4816 end Set_Parent_Subtype
;
4818 procedure Set_Primitive_Operations
(Id
: E
; V
: L
) is
4820 pragma Assert
(Is_Tagged_Type
(Id
));
4821 Set_Elist15
(Id
, V
);
4822 end Set_Primitive_Operations
;
4824 procedure Set_Prival
(Id
: E
; V
: E
) is
4826 pragma Assert
(Is_Protected_Component
(Id
));
4830 procedure Set_Prival_Link
(Id
: E
; V
: E
) is
4832 pragma Assert
(Ekind
(Id
) = E_Constant
4833 or else Ekind
(Id
) = E_Variable
);
4835 end Set_Prival_Link
;
4837 procedure Set_Private_Dependents
(Id
: E
; V
: L
) is
4839 pragma Assert
(Is_Incomplete_Or_Private_Type
(Id
));
4840 Set_Elist18
(Id
, V
);
4841 end Set_Private_Dependents
;
4843 procedure Set_Private_View
(Id
: E
; V
: N
) is
4845 pragma Assert
(Is_Private_Type
(Id
));
4847 end Set_Private_View
;
4849 procedure Set_Protected_Body_Subprogram
(Id
: E
; V
: E
) is
4851 pragma Assert
(Is_Subprogram
(Id
) or else Is_Entry
(Id
));
4853 end Set_Protected_Body_Subprogram
;
4855 procedure Set_Protected_Formal
(Id
: E
; V
: E
) is
4857 pragma Assert
(Is_Formal
(Id
));
4859 end Set_Protected_Formal
;
4861 procedure Set_Protection_Object
(Id
: E
; V
: E
) is
4863 pragma Assert
(Ekind
(Id
) = E_Entry
4864 or else Ekind
(Id
) = E_Entry_Family
4865 or else Ekind
(Id
) = E_Function
4866 or else Ekind
(Id
) = E_Procedure
);
4868 end Set_Protection_Object
;
4870 procedure Set_Reachable
(Id
: E
; V
: B
:= True) is
4875 procedure Set_Referenced
(Id
: E
; V
: B
:= True) is
4877 Set_Flag156
(Id
, V
);
4880 procedure Set_Referenced_As_LHS
(Id
: E
; V
: B
:= True) is
4883 end Set_Referenced_As_LHS
;
4885 procedure Set_Referenced_As_Out_Parameter
(Id
: E
; V
: B
:= True) is
4887 Set_Flag227
(Id
, V
);
4888 end Set_Referenced_As_Out_Parameter
;
4890 procedure Set_Referenced_Object
(Id
: E
; V
: N
) is
4892 pragma Assert
(Is_Type
(Id
));
4894 end Set_Referenced_Object
;
4896 procedure Set_Register_Exception_Call
(Id
: E
; V
: N
) is
4898 pragma Assert
(Ekind
(Id
) = E_Exception
);
4900 end Set_Register_Exception_Call
;
4902 procedure Set_Related_Array_Object
(Id
: E
; V
: E
) is
4904 pragma Assert
(Is_Array_Type
(Id
));
4906 end Set_Related_Array_Object
;
4908 procedure Set_Related_Instance
(Id
: E
; V
: E
) is
4911 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Package_Body
);
4913 end Set_Related_Instance
;
4915 procedure Set_Related_Type
(Id
: E
; V
: E
) is
4918 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Constant
);
4920 end Set_Related_Type
;
4922 procedure Set_Relative_Deadline_Variable
(Id
: E
; V
: E
) is
4924 pragma Assert
(Is_Task_Type
(Id
) and then Id
= Base_Type
(Id
));
4926 end Set_Relative_Deadline_Variable
;
4928 procedure Set_Renamed_Entity
(Id
: E
; V
: N
) is
4931 end Set_Renamed_Entity
;
4933 procedure Set_Renamed_In_Spec
(Id
: E
; V
: B
:= True) is
4935 pragma Assert
(Ekind
(Id
) = E_Package
);
4936 Set_Flag231
(Id
, V
);
4937 end Set_Renamed_In_Spec
;
4939 procedure Set_Renamed_Object
(Id
: E
; V
: N
) is
4942 end Set_Renamed_Object
;
4944 procedure Set_Renaming_Map
(Id
: E
; V
: U
) is
4947 end Set_Renaming_Map
;
4949 procedure Set_Requires_Overriding
(Id
: E
; V
: B
:= True) is
4951 pragma Assert
(Is_Overloadable
(Id
));
4952 Set_Flag213
(Id
, V
);
4953 end Set_Requires_Overriding
;
4955 procedure Set_Return_Present
(Id
: E
; V
: B
:= True) is
4958 end Set_Return_Present
;
4960 procedure Set_Return_Applies_To
(Id
: E
; V
: N
) is
4963 end Set_Return_Applies_To
;
4965 procedure Set_Returns_By_Ref
(Id
: E
; V
: B
:= True) is
4968 end Set_Returns_By_Ref
;
4970 procedure Set_Reverse_Bit_Order
(Id
: E
; V
: B
:= True) is
4973 (Is_Record_Type
(Id
) and then Id
= Base_Type
(Id
));
4974 Set_Flag164
(Id
, V
);
4975 end Set_Reverse_Bit_Order
;
4977 procedure Set_RM_Size
(Id
: E
; V
: U
) is
4979 pragma Assert
(Is_Type
(Id
));
4983 procedure Set_Scalar_Range
(Id
: E
; V
: N
) is
4986 end Set_Scalar_Range
;
4988 procedure Set_Scale_Value
(Id
: E
; V
: U
) is
4991 end Set_Scale_Value
;
4993 procedure Set_Scope_Depth_Value
(Id
: E
; V
: U
) is
4995 pragma Assert
(not Is_Record_Type
(Id
));
4997 end Set_Scope_Depth_Value
;
4999 procedure Set_Sec_Stack_Needed_For_Return
(Id
: E
; V
: B
:= True) is
5001 Set_Flag167
(Id
, V
);
5002 end Set_Sec_Stack_Needed_For_Return
;
5004 procedure Set_Shadow_Entities
(Id
: E
; V
: S
) is
5007 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Generic_Package
);
5009 end Set_Shadow_Entities
;
5011 procedure Set_Shared_Var_Procs_Instance
(Id
: E
; V
: E
) is
5013 pragma Assert
(Ekind
(Id
) = E_Variable
);
5015 end Set_Shared_Var_Procs_Instance
;
5017 procedure Set_Size_Check_Code
(Id
: E
; V
: N
) is
5019 pragma Assert
(Ekind
(Id
) = E_Constant
or else Ekind
(Id
) = E_Variable
);
5021 end Set_Size_Check_Code
;
5023 procedure Set_Size_Depends_On_Discriminant
(Id
: E
; V
: B
:= True) is
5025 Set_Flag177
(Id
, V
);
5026 end Set_Size_Depends_On_Discriminant
;
5028 procedure Set_Size_Known_At_Compile_Time
(Id
: E
; V
: B
:= True) is
5031 end Set_Size_Known_At_Compile_Time
;
5033 procedure Set_Small_Value
(Id
: E
; V
: R
) is
5035 pragma Assert
(Is_Fixed_Point_Type
(Id
));
5036 Set_Ureal21
(Id
, V
);
5037 end Set_Small_Value
;
5039 procedure Set_Spec_Entity
(Id
: E
; V
: E
) is
5041 pragma Assert
(Ekind
(Id
) = E_Package_Body
or else Is_Formal
(Id
));
5043 end Set_Spec_Entity
;
5045 procedure Set_Spec_PPC_List
(Id
: E
; V
: N
) is
5047 pragma Assert
(Is_Subprogram
(Id
) or else Is_Generic_Subprogram
(Id
));
5049 end Set_Spec_PPC_List
;
5051 procedure Set_Storage_Size_Variable
(Id
: E
; V
: E
) is
5053 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
5054 pragma Assert
(Id
= Base_Type
(Id
));
5056 end Set_Storage_Size_Variable
;
5058 procedure Set_Static_Elaboration_Desired
(Id
: E
; V
: B
) is
5060 pragma Assert
(Ekind
(Id
) = E_Package
);
5062 end Set_Static_Elaboration_Desired
;
5064 procedure Set_Static_Initialization
(Id
: E
; V
: N
) is
5067 (Ekind
(Id
) = E_Procedure
and then not Is_Dispatching_Operation
(Id
));
5069 end Set_Static_Initialization
;
5071 procedure Set_Stored_Constraint
(Id
: E
; V
: L
) is
5073 pragma Assert
(Nkind
(Id
) in N_Entity
);
5074 Set_Elist23
(Id
, V
);
5075 end Set_Stored_Constraint
;
5077 procedure Set_Strict_Alignment
(Id
: E
; V
: B
:= True) is
5079 pragma Assert
(Id
= Base_Type
(Id
));
5080 Set_Flag145
(Id
, V
);
5081 end Set_Strict_Alignment
;
5083 procedure Set_String_Literal_Length
(Id
: E
; V
: U
) is
5085 pragma Assert
(Ekind
(Id
) = E_String_Literal_Subtype
);
5087 end Set_String_Literal_Length
;
5089 procedure Set_String_Literal_Low_Bound
(Id
: E
; V
: N
) is
5091 pragma Assert
(Ekind
(Id
) = E_String_Literal_Subtype
);
5093 end Set_String_Literal_Low_Bound
;
5095 procedure Set_Suppress_Elaboration_Warnings
(Id
: E
; V
: B
:= True) is
5097 Set_Flag148
(Id
, V
);
5098 end Set_Suppress_Elaboration_Warnings
;
5100 procedure Set_Suppress_Init_Proc
(Id
: E
; V
: B
:= True) is
5102 pragma Assert
(Id
= Base_Type
(Id
));
5103 Set_Flag105
(Id
, V
);
5104 end Set_Suppress_Init_Proc
;
5106 procedure Set_Suppress_Style_Checks
(Id
: E
; V
: B
:= True) is
5108 Set_Flag165
(Id
, V
);
5109 end Set_Suppress_Style_Checks
;
5111 procedure Set_Suppress_Value_Tracking_On_Call
(Id
: E
; V
: B
:= True) is
5113 Set_Flag217
(Id
, V
);
5114 end Set_Suppress_Value_Tracking_On_Call
;
5116 procedure Set_Task_Body_Procedure
(Id
: E
; V
: N
) is
5118 pragma Assert
(Ekind
(Id
) in Task_Kind
);
5120 end Set_Task_Body_Procedure
;
5122 procedure Set_Treat_As_Volatile
(Id
: E
; V
: B
:= True) is
5125 end Set_Treat_As_Volatile
;
5127 procedure Set_Underlying_Full_View
(Id
: E
; V
: E
) is
5129 pragma Assert
(Ekind
(Id
) in Private_Kind
);
5131 end Set_Underlying_Full_View
;
5133 procedure Set_Universal_Aliasing
(Id
: E
; V
: B
:= True) is
5135 pragma Assert
(Is_Type
(Id
) and then Id
= Base_Type
(Id
));
5136 Set_Flag216
(Id
, V
);
5137 end Set_Universal_Aliasing
;
5139 procedure Set_Unset_Reference
(Id
: E
; V
: N
) is
5142 end Set_Unset_Reference
;
5144 procedure Set_Uses_Sec_Stack
(Id
: E
; V
: B
:= True) is
5147 end Set_Uses_Sec_Stack
;
5149 procedure Set_Used_As_Generic_Actual
(Id
: E
; V
: B
:= True) is
5151 Set_Flag222
(Id
, V
);
5152 end Set_Used_As_Generic_Actual
;
5154 procedure Set_Vax_Float
(Id
: E
; V
: B
:= True) is
5156 pragma Assert
(Id
= Base_Type
(Id
));
5157 Set_Flag151
(Id
, V
);
5160 procedure Set_Warnings_Off
(Id
: E
; V
: B
:= True) is
5163 end Set_Warnings_Off
;
5165 procedure Set_Warnings_Off_Used
(Id
: E
; V
: B
:= True) is
5167 Set_Flag236
(Id
, V
);
5168 end Set_Warnings_Off_Used
;
5170 procedure Set_Warnings_Off_Used_Unmodified
(Id
: E
; V
: B
:= True) is
5172 Set_Flag237
(Id
, V
);
5173 end Set_Warnings_Off_Used_Unmodified
;
5175 procedure Set_Warnings_Off_Used_Unreferenced
(Id
: E
; V
: B
:= True) is
5177 Set_Flag238
(Id
, V
);
5178 end Set_Warnings_Off_Used_Unreferenced
;
5180 procedure Set_Was_Hidden
(Id
: E
; V
: B
:= True) is
5182 Set_Flag196
(Id
, V
);
5185 procedure Set_Wrapped_Entity
(Id
: E
; V
: E
) is
5187 pragma Assert
((Ekind
(Id
) = E_Function
5188 or else Ekind
(Id
) = E_Procedure
)
5189 and then Is_Primitive_Wrapper
(Id
));
5191 end Set_Wrapped_Entity
;
5193 -----------------------------------
5194 -- Field Initialization Routines --
5195 -----------------------------------
5197 procedure Init_Alignment
(Id
: E
) is
5199 Set_Uint14
(Id
, Uint_0
);
5202 procedure Init_Alignment
(Id
: E
; V
: Int
) is
5204 Set_Uint14
(Id
, UI_From_Int
(V
));
5207 procedure Init_Component_Bit_Offset
(Id
: E
) is
5209 Set_Uint11
(Id
, No_Uint
);
5210 end Init_Component_Bit_Offset
;
5212 procedure Init_Component_Bit_Offset
(Id
: E
; V
: Int
) is
5214 Set_Uint11
(Id
, UI_From_Int
(V
));
5215 end Init_Component_Bit_Offset
;
5217 procedure Init_Component_Size
(Id
: E
) is
5219 Set_Uint22
(Id
, Uint_0
);
5220 end Init_Component_Size
;
5222 procedure Init_Component_Size
(Id
: E
; V
: Int
) is
5224 Set_Uint22
(Id
, UI_From_Int
(V
));
5225 end Init_Component_Size
;
5227 procedure Init_Digits_Value
(Id
: E
) is
5229 Set_Uint17
(Id
, Uint_0
);
5230 end Init_Digits_Value
;
5232 procedure Init_Digits_Value
(Id
: E
; V
: Int
) is
5234 Set_Uint17
(Id
, UI_From_Int
(V
));
5235 end Init_Digits_Value
;
5237 procedure Init_Esize
(Id
: E
) is
5239 Set_Uint12
(Id
, Uint_0
);
5242 procedure Init_Esize
(Id
: E
; V
: Int
) is
5244 Set_Uint12
(Id
, UI_From_Int
(V
));
5247 procedure Init_Normalized_First_Bit
(Id
: E
) is
5249 Set_Uint8
(Id
, No_Uint
);
5250 end Init_Normalized_First_Bit
;
5252 procedure Init_Normalized_First_Bit
(Id
: E
; V
: Int
) is
5254 Set_Uint8
(Id
, UI_From_Int
(V
));
5255 end Init_Normalized_First_Bit
;
5257 procedure Init_Normalized_Position
(Id
: E
) is
5259 Set_Uint14
(Id
, No_Uint
);
5260 end Init_Normalized_Position
;
5262 procedure Init_Normalized_Position
(Id
: E
; V
: Int
) is
5264 Set_Uint14
(Id
, UI_From_Int
(V
));
5265 end Init_Normalized_Position
;
5267 procedure Init_Normalized_Position_Max
(Id
: E
) is
5269 Set_Uint10
(Id
, No_Uint
);
5270 end Init_Normalized_Position_Max
;
5272 procedure Init_Normalized_Position_Max
(Id
: E
; V
: Int
) is
5274 Set_Uint10
(Id
, UI_From_Int
(V
));
5275 end Init_Normalized_Position_Max
;
5277 procedure Init_RM_Size
(Id
: E
) is
5279 Set_Uint13
(Id
, Uint_0
);
5282 procedure Init_RM_Size
(Id
: E
; V
: Int
) is
5284 Set_Uint13
(Id
, UI_From_Int
(V
));
5287 -----------------------------
5288 -- Init_Component_Location --
5289 -----------------------------
5291 procedure Init_Component_Location
(Id
: E
) is
5293 Set_Uint8
(Id
, No_Uint
); -- Normalized_First_Bit
5294 Set_Uint10
(Id
, No_Uint
); -- Normalized_Position_Max
5295 Set_Uint11
(Id
, No_Uint
); -- Component_Bit_Offset
5296 Set_Uint12
(Id
, Uint_0
); -- Esize
5297 Set_Uint14
(Id
, No_Uint
); -- Normalized_Position
5298 end Init_Component_Location
;
5304 procedure Init_Size
(Id
: E
; V
: Int
) is
5306 Set_Uint12
(Id
, UI_From_Int
(V
)); -- Esize
5307 Set_Uint13
(Id
, UI_From_Int
(V
)); -- RM_Size
5310 ---------------------
5311 -- Init_Size_Align --
5312 ---------------------
5314 procedure Init_Size_Align
(Id
: E
) is
5316 Set_Uint12
(Id
, Uint_0
); -- Esize
5317 Set_Uint13
(Id
, Uint_0
); -- RM_Size
5318 Set_Uint14
(Id
, Uint_0
); -- Alignment
5319 end Init_Size_Align
;
5321 ----------------------------------------------
5322 -- Type Representation Attribute Predicates --
5323 ----------------------------------------------
5325 function Known_Alignment
(E
: Entity_Id
) return B
is
5327 return Uint14
(E
) /= Uint_0
5328 and then Uint14
(E
) /= No_Uint
;
5329 end Known_Alignment
;
5331 function Known_Component_Bit_Offset
(E
: Entity_Id
) return B
is
5333 return Uint11
(E
) /= No_Uint
;
5334 end Known_Component_Bit_Offset
;
5336 function Known_Component_Size
(E
: Entity_Id
) return B
is
5338 return Uint22
(Base_Type
(E
)) /= Uint_0
5339 and then Uint22
(Base_Type
(E
)) /= No_Uint
;
5340 end Known_Component_Size
;
5342 function Known_Esize
(E
: Entity_Id
) return B
is
5344 return Uint12
(E
) /= Uint_0
5345 and then Uint12
(E
) /= No_Uint
;
5348 function Known_Normalized_First_Bit
(E
: Entity_Id
) return B
is
5350 return Uint8
(E
) /= No_Uint
;
5351 end Known_Normalized_First_Bit
;
5353 function Known_Normalized_Position
(E
: Entity_Id
) return B
is
5355 return Uint14
(E
) /= No_Uint
;
5356 end Known_Normalized_Position
;
5358 function Known_Normalized_Position_Max
(E
: Entity_Id
) return B
is
5360 return Uint10
(E
) /= No_Uint
;
5361 end Known_Normalized_Position_Max
;
5363 function Known_RM_Size
(E
: Entity_Id
) return B
is
5365 return Uint13
(E
) /= No_Uint
5366 and then (Uint13
(E
) /= Uint_0
5367 or else Is_Discrete_Type
(E
)
5368 or else Is_Fixed_Point_Type
(E
));
5371 function Known_Static_Component_Bit_Offset
(E
: Entity_Id
) return B
is
5373 return Uint11
(E
) /= No_Uint
5374 and then Uint11
(E
) >= Uint_0
;
5375 end Known_Static_Component_Bit_Offset
;
5377 function Known_Static_Component_Size
(E
: Entity_Id
) return B
is
5379 return Uint22
(Base_Type
(E
)) > Uint_0
;
5380 end Known_Static_Component_Size
;
5382 function Known_Static_Esize
(E
: Entity_Id
) return B
is
5384 return Uint12
(E
) > Uint_0
;
5385 end Known_Static_Esize
;
5387 function Known_Static_Normalized_First_Bit
(E
: Entity_Id
) return B
is
5389 return Uint8
(E
) /= No_Uint
5390 and then Uint8
(E
) >= Uint_0
;
5391 end Known_Static_Normalized_First_Bit
;
5393 function Known_Static_Normalized_Position
(E
: Entity_Id
) return B
is
5395 return Uint14
(E
) /= No_Uint
5396 and then Uint14
(E
) >= Uint_0
;
5397 end Known_Static_Normalized_Position
;
5399 function Known_Static_Normalized_Position_Max
(E
: Entity_Id
) return B
is
5401 return Uint10
(E
) /= No_Uint
5402 and then Uint10
(E
) >= Uint_0
;
5403 end Known_Static_Normalized_Position_Max
;
5405 function Known_Static_RM_Size
(E
: Entity_Id
) return B
is
5407 return Uint13
(E
) > Uint_0
5408 or else Is_Discrete_Type
(E
)
5409 or else Is_Fixed_Point_Type
(E
);
5410 end Known_Static_RM_Size
;
5412 function Unknown_Alignment
(E
: Entity_Id
) return B
is
5414 return Uint14
(E
) = Uint_0
5415 or else Uint14
(E
) = No_Uint
;
5416 end Unknown_Alignment
;
5418 function Unknown_Component_Bit_Offset
(E
: Entity_Id
) return B
is
5420 return Uint11
(E
) = No_Uint
;
5421 end Unknown_Component_Bit_Offset
;
5423 function Unknown_Component_Size
(E
: Entity_Id
) return B
is
5425 return Uint22
(Base_Type
(E
)) = Uint_0
5427 Uint22
(Base_Type
(E
)) = No_Uint
;
5428 end Unknown_Component_Size
;
5430 function Unknown_Esize
(E
: Entity_Id
) return B
is
5432 return Uint12
(E
) = No_Uint
5434 Uint12
(E
) = Uint_0
;
5437 function Unknown_Normalized_First_Bit
(E
: Entity_Id
) return B
is
5439 return Uint8
(E
) = No_Uint
;
5440 end Unknown_Normalized_First_Bit
;
5442 function Unknown_Normalized_Position
(E
: Entity_Id
) return B
is
5444 return Uint14
(E
) = No_Uint
;
5445 end Unknown_Normalized_Position
;
5447 function Unknown_Normalized_Position_Max
(E
: Entity_Id
) return B
is
5449 return Uint10
(E
) = No_Uint
;
5450 end Unknown_Normalized_Position_Max
;
5452 function Unknown_RM_Size
(E
: Entity_Id
) return B
is
5454 return (Uint13
(E
) = Uint_0
5455 and then not Is_Discrete_Type
(E
)
5456 and then not Is_Fixed_Point_Type
(E
))
5457 or else Uint13
(E
) = No_Uint
;
5458 end Unknown_RM_Size
;
5460 --------------------
5461 -- Address_Clause --
5462 --------------------
5464 function Address_Clause
(Id
: E
) return N
is
5466 return Rep_Clause
(Id
, Name_Address
);
5469 ----------------------
5470 -- Alignment_Clause --
5471 ----------------------
5473 function Alignment_Clause
(Id
: E
) return N
is
5475 return Rep_Clause
(Id
, Name_Alignment
);
5476 end Alignment_Clause
;
5478 ----------------------
5479 -- Ancestor_Subtype --
5480 ----------------------
5482 function Ancestor_Subtype
(Id
: E
) return E
is
5484 -- If this is first subtype, or is a base type, then there is no
5485 -- ancestor subtype, so we return Empty to indicate this fact.
5487 if Is_First_Subtype
(Id
) or else Id
= Base_Type
(Id
) then
5492 D
: constant Node_Id
:= Declaration_Node
(Id
);
5495 -- If we have a subtype declaration, get the ancestor subtype
5497 if Nkind
(D
) = N_Subtype_Declaration
then
5498 if Nkind
(Subtype_Indication
(D
)) = N_Subtype_Indication
then
5499 return Entity
(Subtype_Mark
(Subtype_Indication
(D
)));
5501 return Entity
(Subtype_Indication
(D
));
5504 -- If not, then no subtype indication is available
5510 end Ancestor_Subtype
;
5516 procedure Append_Entity
(Id
: Entity_Id
; V
: Entity_Id
) is
5518 if Last_Entity
(V
) = Empty
then
5519 Set_First_Entity
(Id
=> V
, V
=> Id
);
5521 Set_Next_Entity
(Last_Entity
(V
), Id
);
5524 Set_Next_Entity
(Id
, Empty
);
5526 Set_Last_Entity
(Id
=> V
, V
=> Id
);
5529 --------------------
5530 -- Available_View --
5531 --------------------
5533 function Available_View
(Id
: E
) return E
is
5535 if Is_Incomplete_Type
(Id
)
5536 and then Present
(Non_Limited_View
(Id
))
5538 -- The non-limited view may itself be an incomplete type, in
5539 -- which case get its full view.
5541 return Get_Full_View
(Non_Limited_View
(Id
));
5543 elsif Is_Class_Wide_Type
(Id
)
5544 and then Is_Incomplete_Type
(Etype
(Id
))
5545 and then Present
(Non_Limited_View
(Etype
(Id
)))
5547 return Class_Wide_Type
(Non_Limited_View
(Etype
(Id
)));
5558 function Base_Type
(Id
: E
) return E
is
5561 when E_Enumeration_Subtype |
5563 E_Signed_Integer_Subtype |
5564 E_Modular_Integer_Subtype |
5565 E_Floating_Point_Subtype |
5566 E_Ordinary_Fixed_Point_Subtype |
5567 E_Decimal_Fixed_Point_Subtype |
5572 E_Record_Subtype_With_Private |
5573 E_Limited_Private_Subtype |
5575 E_Protected_Subtype |
5577 E_String_Literal_Subtype |
5578 E_Class_Wide_Subtype
=>
5586 -------------------------
5587 -- Component_Alignment --
5588 -------------------------
5590 -- Component Alignment is encoded using two flags, Flag128/129 as
5591 -- follows. Note that both flags False = Align_Default, so that the
5592 -- default initialization of flags to False initializes component
5593 -- alignment to the default value as required.
5595 -- Flag128 Flag129 Value
5596 -- ------- ------- -----
5597 -- False False Calign_Default
5598 -- False True Calign_Component_Size
5599 -- True False Calign_Component_Size_4
5600 -- True True Calign_Storage_Unit
5602 function Component_Alignment
(Id
: E
) return C
is
5603 BT
: constant Node_Id
:= Base_Type
(Id
);
5606 pragma Assert
(Is_Array_Type
(Id
) or else Is_Record_Type
(Id
));
5608 if Flag128
(BT
) then
5609 if Flag129
(BT
) then
5610 return Calign_Storage_Unit
;
5612 return Calign_Component_Size_4
;
5616 if Flag129
(BT
) then
5617 return Calign_Component_Size
;
5619 return Calign_Default
;
5622 end Component_Alignment
;
5624 --------------------
5625 -- Constant_Value --
5626 --------------------
5628 function Constant_Value
(Id
: E
) return N
is
5629 D
: constant Node_Id
:= Declaration_Node
(Id
);
5633 -- If we have no declaration node, then return no constant value.
5634 -- Not clear how this can happen, but it does sometimes ???
5635 -- To investigate, remove this check and compile discrim_po.adb.
5640 -- Normal case where a declaration node is present
5642 elsif Nkind
(D
) = N_Object_Renaming_Declaration
then
5643 return Renamed_Object
(Id
);
5645 -- If this is a component declaration whose entity is constant, it
5646 -- is a prival within a protected function. It does not have
5647 -- a constant value.
5649 elsif Nkind
(D
) = N_Component_Declaration
then
5652 -- If there is an expression, return it
5654 elsif Present
(Expression
(D
)) then
5655 return (Expression
(D
));
5657 -- For a constant, see if we have a full view
5659 elsif Ekind
(Id
) = E_Constant
5660 and then Present
(Full_View
(Id
))
5662 Full_D
:= Parent
(Full_View
(Id
));
5664 -- The full view may have been rewritten as an object renaming
5666 if Nkind
(Full_D
) = N_Object_Renaming_Declaration
then
5667 return Name
(Full_D
);
5669 return Expression
(Full_D
);
5672 -- Otherwise we have no expression to return
5679 ----------------------
5680 -- Declaration_Node --
5681 ----------------------
5683 function Declaration_Node
(Id
: E
) return N
is
5687 if Ekind
(Id
) = E_Incomplete_Type
5688 and then Present
(Full_View
(Id
))
5690 P
:= Parent
(Full_View
(Id
));
5696 if Nkind
(P
) /= N_Selected_Component
5697 and then Nkind
(P
) /= N_Expanded_Name
5699 not (Nkind
(P
) = N_Defining_Program_Unit_Name
5700 and then Is_Child_Unit
(Id
))
5707 end Declaration_Node
;
5709 ---------------------
5710 -- Designated_Type --
5711 ---------------------
5713 function Designated_Type
(Id
: E
) return E
is
5717 Desig_Type
:= Directly_Designated_Type
(Id
);
5719 if Ekind
(Desig_Type
) = E_Incomplete_Type
5720 and then Present
(Full_View
(Desig_Type
))
5722 return Full_View
(Desig_Type
);
5724 elsif Is_Class_Wide_Type
(Desig_Type
)
5725 and then Ekind
(Etype
(Desig_Type
)) = E_Incomplete_Type
5726 and then Present
(Full_View
(Etype
(Desig_Type
)))
5727 and then Present
(Class_Wide_Type
(Full_View
(Etype
(Desig_Type
))))
5729 return Class_Wide_Type
(Full_View
(Etype
(Desig_Type
)));
5734 end Designated_Type
;
5736 -----------------------------
5737 -- Enclosing_Dynamic_Scope --
5738 -----------------------------
5740 function Enclosing_Dynamic_Scope
(Id
: E
) return E
is
5744 -- The following test is an error defense against some syntax
5745 -- errors that can leave scopes very messed up.
5747 if Id
= Standard_Standard
then
5751 -- Normal case, search enclosing scopes
5753 -- Note: the test for Present (S) should not be required, it is a
5754 -- defence against an ill-formed tree.
5758 -- If we somehow got an empty value for Scope, the tree must be
5759 -- malformed. Rather than blow up we return Standard in this case.
5762 return Standard_Standard
;
5764 -- Quit if we get to standard or a dynamic scope
5766 elsif S
= Standard_Standard
5767 or else Is_Dynamic_Scope
(S
)
5771 -- Otherwise keep climbing
5777 end Enclosing_Dynamic_Scope
;
5779 ----------------------
5780 -- Entry_Index_Type --
5781 ----------------------
5783 function Entry_Index_Type
(Id
: E
) return N
is
5785 pragma Assert
(Ekind
(Id
) = E_Entry_Family
);
5786 return Etype
(Discrete_Subtype_Definition
(Parent
(Id
)));
5787 end Entry_Index_Type
;
5789 ---------------------
5790 -- First_Component --
5791 ---------------------
5793 function First_Component
(Id
: E
) return E
is
5798 (Is_Record_Type
(Id
) or else Is_Incomplete_Or_Private_Type
(Id
));
5800 Comp_Id
:= First_Entity
(Id
);
5801 while Present
(Comp_Id
) loop
5802 exit when Ekind
(Comp_Id
) = E_Component
;
5803 Comp_Id
:= Next_Entity
(Comp_Id
);
5807 end First_Component
;
5809 -------------------------------------
5810 -- First_Component_Or_Discriminant --
5811 -------------------------------------
5813 function First_Component_Or_Discriminant
(Id
: E
) return E
is
5818 (Is_Record_Type
(Id
) or else Is_Incomplete_Or_Private_Type
(Id
));
5820 Comp_Id
:= First_Entity
(Id
);
5821 while Present
(Comp_Id
) loop
5822 exit when Ekind
(Comp_Id
) = E_Component
5824 Ekind
(Comp_Id
) = E_Discriminant
;
5825 Comp_Id
:= Next_Entity
(Comp_Id
);
5829 end First_Component_Or_Discriminant
;
5831 ------------------------
5832 -- First_Discriminant --
5833 ------------------------
5835 function First_Discriminant
(Id
: E
) return E
is
5840 (Has_Discriminants
(Id
)
5841 or else Has_Unknown_Discriminants
(Id
));
5843 Ent
:= First_Entity
(Id
);
5845 -- The discriminants are not necessarily contiguous, because access
5846 -- discriminants will generate itypes. They are not the first entities
5847 -- either, because tag and controller record must be ahead of them.
5849 if Chars
(Ent
) = Name_uTag
then
5850 Ent
:= Next_Entity
(Ent
);
5853 if Chars
(Ent
) = Name_uController
then
5854 Ent
:= Next_Entity
(Ent
);
5857 -- Skip all hidden stored discriminants if any
5859 while Present
(Ent
) loop
5860 exit when Ekind
(Ent
) = E_Discriminant
5861 and then not Is_Completely_Hidden
(Ent
);
5863 Ent
:= Next_Entity
(Ent
);
5866 pragma Assert
(Ekind
(Ent
) = E_Discriminant
);
5869 end First_Discriminant
;
5875 function First_Formal
(Id
: E
) return E
is
5880 (Is_Overloadable
(Id
)
5881 or else Ekind
(Id
) = E_Entry_Family
5882 or else Ekind
(Id
) = E_Subprogram_Body
5883 or else Ekind
(Id
) = E_Subprogram_Type
);
5885 if Ekind
(Id
) = E_Enumeration_Literal
then
5889 Formal
:= First_Entity
(Id
);
5891 if Present
(Formal
) and then Is_Formal
(Formal
) then
5899 ------------------------------
5900 -- First_Formal_With_Extras --
5901 ------------------------------
5903 function First_Formal_With_Extras
(Id
: E
) return E
is
5908 (Is_Overloadable
(Id
)
5909 or else Ekind
(Id
) = E_Entry_Family
5910 or else Ekind
(Id
) = E_Subprogram_Body
5911 or else Ekind
(Id
) = E_Subprogram_Type
);
5913 if Ekind
(Id
) = E_Enumeration_Literal
then
5917 Formal
:= First_Entity
(Id
);
5919 if Present
(Formal
) and then Is_Formal
(Formal
) then
5922 return Extra_Formals
(Id
); -- Empty if no extra formals
5925 end First_Formal_With_Extras
;
5927 -------------------------------
5928 -- First_Stored_Discriminant --
5929 -------------------------------
5931 function First_Stored_Discriminant
(Id
: E
) return E
is
5934 function Has_Completely_Hidden_Discriminant
(Id
: E
) return Boolean;
5935 -- Scans the Discriminants to see whether any are Completely_Hidden
5936 -- (the mechanism for describing non-specified stored discriminants)
5938 ----------------------------------------
5939 -- Has_Completely_Hidden_Discriminant --
5940 ----------------------------------------
5942 function Has_Completely_Hidden_Discriminant
(Id
: E
) return Boolean is
5943 Ent
: Entity_Id
:= Id
;
5946 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
5948 while Present
(Ent
) and then Ekind
(Ent
) = E_Discriminant
loop
5949 if Is_Completely_Hidden
(Ent
) then
5953 Ent
:= Next_Entity
(Ent
);
5957 end Has_Completely_Hidden_Discriminant
;
5959 -- Start of processing for First_Stored_Discriminant
5963 (Has_Discriminants
(Id
)
5964 or else Has_Unknown_Discriminants
(Id
));
5966 Ent
:= First_Entity
(Id
);
5968 if Chars
(Ent
) = Name_uTag
then
5969 Ent
:= Next_Entity
(Ent
);
5972 if Chars
(Ent
) = Name_uController
then
5973 Ent
:= Next_Entity
(Ent
);
5976 if Has_Completely_Hidden_Discriminant
(Ent
) then
5978 while Present
(Ent
) loop
5979 exit when Is_Completely_Hidden
(Ent
);
5980 Ent
:= Next_Entity
(Ent
);
5985 pragma Assert
(Ekind
(Ent
) = E_Discriminant
);
5988 end First_Stored_Discriminant
;
5994 function First_Subtype
(Id
: E
) return E
is
5995 B
: constant Entity_Id
:= Base_Type
(Id
);
5996 F
: constant Node_Id
:= Freeze_Node
(B
);
6000 -- If the base type has no freeze node, it is a type in standard,
6001 -- and always acts as its own first subtype unless it is one of
6002 -- the predefined integer types. If the type is formal, it is also
6003 -- a first subtype, and its base type has no freeze node. On the other
6004 -- hand, a subtype of a generic formal is not its own first_subtype.
6005 -- Its base type, if anonymous, is attached to the formal type decl.
6006 -- from which the first subtype is obtained.
6010 if B
= Base_Type
(Standard_Integer
) then
6011 return Standard_Integer
;
6013 elsif B
= Base_Type
(Standard_Long_Integer
) then
6014 return Standard_Long_Integer
;
6016 elsif B
= Base_Type
(Standard_Short_Short_Integer
) then
6017 return Standard_Short_Short_Integer
;
6019 elsif B
= Base_Type
(Standard_Short_Integer
) then
6020 return Standard_Short_Integer
;
6022 elsif B
= Base_Type
(Standard_Long_Long_Integer
) then
6023 return Standard_Long_Long_Integer
;
6025 elsif Is_Generic_Type
(Id
) then
6026 if Present
(Parent
(B
)) then
6027 return Defining_Identifier
(Parent
(B
));
6029 return Defining_Identifier
(Associated_Node_For_Itype
(B
));
6036 -- Otherwise we check the freeze node, if it has a First_Subtype_Link
6037 -- then we use that link, otherwise (happens with some Itypes), we use
6038 -- the base type itself.
6041 Ent
:= First_Subtype_Link
(F
);
6043 if Present
(Ent
) then
6051 -------------------------------------
6052 -- Get_Attribute_Definition_Clause --
6053 -------------------------------------
6055 function Get_Attribute_Definition_Clause
6057 Id
: Attribute_Id
) return Node_Id
6062 N
:= First_Rep_Item
(E
);
6063 while Present
(N
) loop
6064 if Nkind
(N
) = N_Attribute_Definition_Clause
6065 and then Get_Attribute_Id
(Chars
(N
)) = Id
6074 end Get_Attribute_Definition_Clause
;
6080 function Get_Full_View
(T
: Entity_Id
) return Entity_Id
is
6082 if Ekind
(T
) = E_Incomplete_Type
6083 and then Present
(Full_View
(T
))
6085 return Full_View
(T
);
6087 elsif Is_Class_Wide_Type
(T
)
6088 and then Ekind
(Root_Type
(T
)) = E_Incomplete_Type
6089 and then Present
(Full_View
(Root_Type
(T
)))
6091 return Class_Wide_Type
(Full_View
(Root_Type
(T
)));
6098 --------------------
6099 -- Get_Rep_Pragma --
6100 --------------------
6102 function Get_Rep_Pragma
(E
: Entity_Id
; Nam
: Name_Id
) return Node_Id
is
6106 N
:= First_Rep_Item
(E
);
6107 while Present
(N
) loop
6108 if Nkind
(N
) = N_Pragma
and then Pragma_Name
(N
) = Nam
then
6118 ------------------------
6119 -- Has_Attach_Handler --
6120 ------------------------
6122 function Has_Attach_Handler
(Id
: E
) return B
is
6126 pragma Assert
(Is_Protected_Type
(Id
));
6128 Ritem
:= First_Rep_Item
(Id
);
6129 while Present
(Ritem
) loop
6130 if Nkind
(Ritem
) = N_Pragma
6131 and then Pragma_Name
(Ritem
) = Name_Attach_Handler
6135 Ritem
:= Next_Rep_Item
(Ritem
);
6140 end Has_Attach_Handler
;
6142 -------------------------------------
6143 -- Has_Attribute_Definition_Clause --
6144 -------------------------------------
6146 function Has_Attribute_Definition_Clause
6148 Id
: Attribute_Id
) return Boolean
6151 return Present
(Get_Attribute_Definition_Clause
(E
, Id
));
6152 end Has_Attribute_Definition_Clause
;
6158 function Has_Entries
(Id
: E
) return B
is
6162 pragma Assert
(Is_Concurrent_Type
(Id
));
6164 Ent
:= First_Entity
(Id
);
6165 while Present
(Ent
) loop
6166 if Is_Entry
(Ent
) then
6170 Ent
:= Next_Entity
(Ent
);
6176 ----------------------------
6177 -- Has_Foreign_Convention --
6178 ----------------------------
6180 function Has_Foreign_Convention
(Id
: E
) return B
is
6182 return Convention
(Id
) in Foreign_Convention
;
6183 end Has_Foreign_Convention
;
6185 ---------------------------
6186 -- Has_Interrupt_Handler --
6187 ---------------------------
6189 function Has_Interrupt_Handler
(Id
: E
) return B
is
6193 pragma Assert
(Is_Protected_Type
(Id
));
6195 Ritem
:= First_Rep_Item
(Id
);
6196 while Present
(Ritem
) loop
6197 if Nkind
(Ritem
) = N_Pragma
6198 and then Pragma_Name
(Ritem
) = Name_Interrupt_Handler
6202 Ritem
:= Next_Rep_Item
(Ritem
);
6207 end Has_Interrupt_Handler
;
6209 --------------------------
6210 -- Has_Private_Ancestor --
6211 --------------------------
6213 function Has_Private_Ancestor
(Id
: E
) return B
is
6214 R
: constant Entity_Id
:= Root_Type
(Id
);
6215 T1
: Entity_Id
:= Id
;
6218 if Is_Private_Type
(T1
) then
6226 end Has_Private_Ancestor
;
6228 --------------------
6229 -- Has_Rep_Pragma --
6230 --------------------
6232 function Has_Rep_Pragma
(E
: Entity_Id
; Nam
: Name_Id
) return Boolean is
6234 return Present
(Get_Rep_Pragma
(E
, Nam
));
6237 --------------------
6238 -- Has_Unmodified --
6239 --------------------
6241 function Has_Unmodified
(E
: Entity_Id
) return Boolean is
6243 if Has_Pragma_Unmodified
(E
) then
6245 elsif Warnings_Off
(E
) then
6246 Set_Warnings_Off_Used_Unmodified
(E
);
6253 ---------------------
6254 -- Has_Unreferenced --
6255 ---------------------
6257 function Has_Unreferenced
(E
: Entity_Id
) return Boolean is
6259 if Has_Pragma_Unreferenced
(E
) then
6261 elsif Warnings_Off
(E
) then
6262 Set_Warnings_Off_Used_Unreferenced
(E
);
6267 end Has_Unreferenced
;
6269 ----------------------
6270 -- Has_Warnings_Off --
6271 ----------------------
6273 function Has_Warnings_Off
(E
: Entity_Id
) return Boolean is
6275 if Warnings_Off
(E
) then
6276 Set_Warnings_Off_Used
(E
);
6281 end Has_Warnings_Off
;
6283 ------------------------------
6284 -- Implementation_Base_Type --
6285 ------------------------------
6287 function Implementation_Base_Type
(Id
: E
) return E
is
6292 Bastyp
:= Base_Type
(Id
);
6294 if Is_Incomplete_Or_Private_Type
(Bastyp
) then
6295 Imptyp
:= Underlying_Type
(Bastyp
);
6297 -- If we have an implementation type, then just return it,
6298 -- otherwise we return the Base_Type anyway. This can only
6299 -- happen in error situations and should avoid some error bombs.
6301 if Present
(Imptyp
) then
6302 return Base_Type
(Imptyp
);
6310 end Implementation_Base_Type
;
6312 ---------------------
6313 -- Is_Boolean_Type --
6314 ---------------------
6316 function Is_Boolean_Type
(Id
: E
) return B
is
6318 return Root_Type
(Id
) = Standard_Boolean
;
6319 end Is_Boolean_Type
;
6321 ---------------------
6322 -- Is_By_Copy_Type --
6323 ---------------------
6325 function Is_By_Copy_Type
(Id
: E
) return B
is
6327 -- If Id is a private type whose full declaration has not been seen,
6328 -- we assume for now that it is not a By_Copy type. Clearly this
6329 -- attribute should not be used before the type is frozen, but it is
6330 -- needed to build the associated record of a protected type. Another
6331 -- place where some lookahead for a full view is needed ???
6334 Is_Elementary_Type
(Id
)
6335 or else (Is_Private_Type
(Id
)
6336 and then Present
(Underlying_Type
(Id
))
6337 and then Is_Elementary_Type
(Underlying_Type
(Id
)));
6338 end Is_By_Copy_Type
;
6340 --------------------------
6341 -- Is_By_Reference_Type --
6342 --------------------------
6344 -- This function knows too much semantics, it should be in sem_util ???
6346 function Is_By_Reference_Type
(Id
: E
) return B
is
6347 Btype
: constant Entity_Id
:= Base_Type
(Id
);
6350 if Error_Posted
(Id
)
6351 or else Error_Posted
(Btype
)
6355 elsif Is_Private_Type
(Btype
) then
6357 Utyp
: constant Entity_Id
:= Underlying_Type
(Btype
);
6362 return Is_By_Reference_Type
(Utyp
);
6366 elsif Is_Incomplete_Type
(Btype
) then
6368 Ftyp
: constant Entity_Id
:= Full_View
(Btype
);
6373 return Is_By_Reference_Type
(Ftyp
);
6377 elsif Is_Concurrent_Type
(Btype
) then
6380 elsif Is_Record_Type
(Btype
) then
6381 if Is_Limited_Record
(Btype
)
6382 or else Is_Tagged_Type
(Btype
)
6383 or else Is_Volatile
(Btype
)
6392 C
:= First_Component
(Btype
);
6393 while Present
(C
) loop
6394 if Is_By_Reference_Type
(Etype
(C
))
6395 or else Is_Volatile
(Etype
(C
))
6400 C
:= Next_Component
(C
);
6407 elsif Is_Array_Type
(Btype
) then
6410 or else Is_By_Reference_Type
(Component_Type
(Btype
))
6411 or else Is_Volatile
(Component_Type
(Btype
))
6412 or else Has_Volatile_Components
(Btype
);
6417 end Is_By_Reference_Type
;
6419 ------------------------
6420 -- Is_Constant_Object --
6421 ------------------------
6423 function Is_Constant_Object
(Id
: E
) return B
is
6424 K
: constant Entity_Kind
:= Ekind
(Id
);
6427 K
= E_Constant
or else K
= E_In_Parameter
or else K
= E_Loop_Parameter
;
6428 end Is_Constant_Object
;
6430 ---------------------
6431 -- Is_Derived_Type --
6432 ---------------------
6434 function Is_Derived_Type
(Id
: E
) return B
is
6439 and then Base_Type
(Id
) /= Root_Type
(Id
)
6440 and then not Is_Class_Wide_Type
(Id
)
6442 if not Is_Numeric_Type
(Root_Type
(Id
)) then
6446 Par
:= Parent
(First_Subtype
(Id
));
6448 return Present
(Par
)
6449 and then Nkind
(Par
) = N_Full_Type_Declaration
6450 and then Nkind
(Type_Definition
(Par
)) =
6451 N_Derived_Type_Definition
;
6457 end Is_Derived_Type
;
6459 --------------------
6460 -- Is_Discriminal --
6461 --------------------
6463 function Is_Discriminal
(Id
: E
) return B
is
6466 (Ekind
(Id
) = E_Constant
6467 or else Ekind
(Id
) = E_In_Parameter
)
6468 and then Present
(Discriminal_Link
(Id
));
6471 ----------------------
6472 -- Is_Dynamic_Scope --
6473 ----------------------
6475 function Is_Dynamic_Scope
(Id
: E
) return B
is
6478 Ekind
(Id
) = E_Block
6480 Ekind
(Id
) = E_Function
6482 Ekind
(Id
) = E_Procedure
6484 Ekind
(Id
) = E_Subprogram_Body
6486 Ekind
(Id
) = E_Task_Type
6488 Ekind
(Id
) = E_Entry
6490 Ekind
(Id
) = E_Entry_Family
6492 Ekind
(Id
) = E_Return_Statement
;
6493 end Is_Dynamic_Scope
;
6495 --------------------
6496 -- Is_Entity_Name --
6497 --------------------
6499 function Is_Entity_Name
(N
: Node_Id
) return Boolean is
6500 Kind
: constant Node_Kind
:= Nkind
(N
);
6503 -- Identifiers, operator symbols, expanded names are entity names
6505 return Kind
= N_Identifier
6506 or else Kind
= N_Operator_Symbol
6507 or else Kind
= N_Expanded_Name
6509 -- Attribute references are entity names if they refer to an entity.
6510 -- Note that we don't do this by testing for the presence of the
6511 -- Entity field in the N_Attribute_Reference node, since it may not
6512 -- have been set yet.
6514 or else (Kind
= N_Attribute_Reference
6515 and then Is_Entity_Attribute_Name
(Attribute_Name
(N
)));
6518 ---------------------------
6519 -- Is_Indefinite_Subtype --
6520 ---------------------------
6522 function Is_Indefinite_Subtype
(Id
: Entity_Id
) return B
is
6523 K
: constant Entity_Kind
:= Ekind
(Id
);
6526 if Is_Constrained
(Id
) then
6529 elsif K
in Array_Kind
6530 or else K
in Class_Wide_Kind
6531 or else Has_Unknown_Discriminants
(Id
)
6535 -- Known discriminants: indefinite if there are no default values
6537 elsif K
in Record_Kind
6538 or else Is_Incomplete_Or_Private_Type
(Id
)
6539 or else Is_Concurrent_Type
(Id
)
6541 return (Has_Discriminants
(Id
)
6542 and then No
(Discriminant_Default_Value
(First_Discriminant
(Id
))));
6547 end Is_Indefinite_Subtype
;
6549 --------------------------------
6550 -- Is_Inherently_Limited_Type --
6551 --------------------------------
6553 function Is_Inherently_Limited_Type
(Id
: E
) return B
is
6554 Btype
: constant Entity_Id
:= Base_Type
(Id
);
6557 if Is_Private_Type
(Btype
) then
6559 Utyp
: constant Entity_Id
:= Underlying_Type
(Btype
);
6564 return Is_Inherently_Limited_Type
(Utyp
);
6568 elsif Is_Concurrent_Type
(Btype
) then
6571 elsif Is_Record_Type
(Btype
) then
6572 if Is_Limited_Record
(Btype
) then
6573 return not Is_Interface
(Btype
)
6574 or else Is_Protected_Interface
(Btype
)
6575 or else Is_Synchronized_Interface
(Btype
)
6576 or else Is_Task_Interface
(Btype
);
6578 elsif Is_Class_Wide_Type
(Btype
) then
6579 return Is_Inherently_Limited_Type
(Root_Type
(Btype
));
6586 C
:= First_Component
(Btype
);
6587 while Present
(C
) loop
6588 if Is_Inherently_Limited_Type
(Etype
(C
)) then
6592 C
:= Next_Component
(C
);
6599 elsif Is_Array_Type
(Btype
) then
6600 return Is_Inherently_Limited_Type
(Component_Type
(Btype
));
6605 end Is_Inherently_Limited_Type
;
6607 ---------------------
6608 -- Is_Limited_Type --
6609 ---------------------
6611 function Is_Limited_Type
(Id
: E
) return B
is
6612 Btype
: constant E
:= Base_Type
(Id
);
6613 Rtype
: constant E
:= Root_Type
(Btype
);
6616 if not Is_Type
(Id
) then
6619 elsif Ekind
(Btype
) = E_Limited_Private_Type
6620 or else Is_Limited_Composite
(Btype
)
6624 elsif Is_Concurrent_Type
(Btype
) then
6627 -- The Is_Limited_Record flag normally indicates that the type is
6628 -- limited. The exception is that a type does not inherit limitedness
6629 -- from its interface ancestor. So the type may be derived from a
6630 -- limited interface, but is not limited.
6632 elsif Is_Limited_Record
(Id
)
6633 and then not Is_Interface
(Id
)
6637 -- Otherwise we will look around to see if there is some other reason
6638 -- for it to be limited, except that if an error was posted on the
6639 -- entity, then just assume it is non-limited, because it can cause
6640 -- trouble to recurse into a murky erroneous entity!
6642 elsif Error_Posted
(Id
) then
6645 elsif Is_Record_Type
(Btype
) then
6647 if Is_Limited_Interface
(Id
) then
6650 -- AI-419: limitedness is not inherited from a limited interface
6652 elsif Is_Limited_Record
(Rtype
) then
6653 return not Is_Interface
(Rtype
)
6654 or else Is_Protected_Interface
(Rtype
)
6655 or else Is_Synchronized_Interface
(Rtype
)
6656 or else Is_Task_Interface
(Rtype
);
6658 elsif Is_Class_Wide_Type
(Btype
) then
6659 return Is_Limited_Type
(Rtype
);
6666 C
:= First_Component
(Btype
);
6667 while Present
(C
) loop
6668 if Is_Limited_Type
(Etype
(C
)) then
6672 C
:= Next_Component
(C
);
6679 elsif Is_Array_Type
(Btype
) then
6680 return Is_Limited_Type
(Component_Type
(Btype
));
6685 end Is_Limited_Type
;
6687 -----------------------------------
6688 -- Is_Package_Or_Generic_Package --
6689 -----------------------------------
6691 function Is_Package_Or_Generic_Package
(Id
: E
) return B
is
6694 Ekind
(Id
) = E_Package
6696 Ekind
(Id
) = E_Generic_Package
;
6697 end Is_Package_Or_Generic_Package
;
6703 function Is_Prival
(Id
: E
) return B
is
6706 (Ekind
(Id
) = E_Constant
6707 or else Ekind
(Id
) = E_Variable
)
6708 and then Present
(Prival_Link
(Id
));
6711 ----------------------------
6712 -- Is_Protected_Component --
6713 ----------------------------
6715 function Is_Protected_Component
(Id
: E
) return B
is
6717 return Ekind
(Id
) = E_Component
6718 and then Is_Protected_Type
(Scope
(Id
));
6719 end Is_Protected_Component
;
6721 ------------------------------
6722 -- Is_Protected_Record_Type --
6723 ------------------------------
6725 function Is_Protected_Record_Type
(Id
: E
) return B
is
6728 Is_Concurrent_Record_Type
(Id
)
6729 and then Is_Protected_Type
(Corresponding_Concurrent_Type
(Id
));
6730 end Is_Protected_Record_Type
;
6732 --------------------------------
6733 -- Is_Standard_Character_Type --
6734 --------------------------------
6736 function Is_Standard_Character_Type
(Id
: E
) return B
is
6738 if Is_Type
(Id
) then
6740 R
: constant Entity_Id
:= Root_Type
(Id
);
6743 R
= Standard_Character
6745 R
= Standard_Wide_Character
6747 R
= Standard_Wide_Wide_Character
;
6753 end Is_Standard_Character_Type
;
6755 --------------------
6756 -- Is_String_Type --
6757 --------------------
6759 function Is_String_Type
(Id
: E
) return B
is
6761 return Ekind
(Id
) in String_Kind
6762 or else (Is_Array_Type
(Id
)
6763 and then Number_Dimensions
(Id
) = 1
6764 and then Is_Character_Type
(Component_Type
(Id
)));
6767 -------------------------
6768 -- Is_Task_Record_Type --
6769 -------------------------
6771 function Is_Task_Record_Type
(Id
: E
) return B
is
6774 Is_Concurrent_Record_Type
(Id
)
6775 and then Is_Task_Type
(Corresponding_Concurrent_Type
(Id
));
6776 end Is_Task_Record_Type
;
6778 ------------------------
6779 -- Is_Wrapper_Package --
6780 ------------------------
6782 function Is_Wrapper_Package
(Id
: E
) return B
is
6784 return (Ekind
(Id
) = E_Package
6785 and then Present
(Related_Instance
(Id
)));
6786 end Is_Wrapper_Package
;
6788 --------------------
6789 -- Next_Component --
6790 --------------------
6792 function Next_Component
(Id
: E
) return E
is
6796 Comp_Id
:= Next_Entity
(Id
);
6797 while Present
(Comp_Id
) loop
6798 exit when Ekind
(Comp_Id
) = E_Component
;
6799 Comp_Id
:= Next_Entity
(Comp_Id
);
6805 ------------------------------------
6806 -- Next_Component_Or_Discriminant --
6807 ------------------------------------
6809 function Next_Component_Or_Discriminant
(Id
: E
) return E
is
6813 Comp_Id
:= Next_Entity
(Id
);
6814 while Present
(Comp_Id
) loop
6815 exit when Ekind
(Comp_Id
) = E_Component
6817 Ekind
(Comp_Id
) = E_Discriminant
;
6818 Comp_Id
:= Next_Entity
(Comp_Id
);
6822 end Next_Component_Or_Discriminant
;
6824 -----------------------
6825 -- Next_Discriminant --
6826 -----------------------
6828 -- This function actually implements both Next_Discriminant and
6829 -- Next_Stored_Discriminant by making sure that the Discriminant
6830 -- returned is of the same variety as Id.
6832 function Next_Discriminant
(Id
: E
) return E
is
6834 -- Derived Tagged types with private extensions look like this...
6836 -- E_Discriminant d1
6837 -- E_Discriminant d2
6839 -- E_Discriminant d1
6840 -- E_Discriminant d2
6843 -- so it is critical not to go past the leading discriminants
6848 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
6851 D
:= Next_Entity
(D
);
6853 or else (Ekind
(D
) /= E_Discriminant
6854 and then not Is_Itype
(D
))
6859 exit when Ekind
(D
) = E_Discriminant
6860 and then (Is_Completely_Hidden
(D
) = Is_Completely_Hidden
(Id
));
6864 end Next_Discriminant
;
6870 function Next_Formal
(Id
: E
) return E
is
6874 -- Follow the chain of declared entities as long as the kind of the
6875 -- entity corresponds to a formal parameter. Skip internal entities
6876 -- that may have been created for implicit subtypes, in the process
6877 -- of analyzing default expressions.
6882 P
:= Next_Entity
(P
);
6884 if No
(P
) or else Is_Formal
(P
) then
6886 elsif not Is_Internal
(P
) then
6892 -----------------------------
6893 -- Next_Formal_With_Extras --
6894 -----------------------------
6896 function Next_Formal_With_Extras
(Id
: E
) return E
is
6898 if Present
(Extra_Formal
(Id
)) then
6899 return Extra_Formal
(Id
);
6901 return Next_Formal
(Id
);
6903 end Next_Formal_With_Extras
;
6909 function Next_Index
(Id
: Node_Id
) return Node_Id
is
6918 function Next_Literal
(Id
: E
) return E
is
6920 pragma Assert
(Nkind
(Id
) in N_Entity
);
6924 ------------------------------
6925 -- Next_Stored_Discriminant --
6926 ------------------------------
6928 function Next_Stored_Discriminant
(Id
: E
) return E
is
6930 -- See comment in Next_Discriminant
6932 return Next_Discriminant
(Id
);
6933 end Next_Stored_Discriminant
;
6935 -----------------------
6936 -- Number_Dimensions --
6937 -----------------------
6939 function Number_Dimensions
(Id
: E
) return Pos
is
6944 if Ekind
(Id
) in String_Kind
then
6949 T
:= First_Index
(Id
);
6950 while Present
(T
) loop
6957 end Number_Dimensions
;
6959 --------------------------
6960 -- Number_Discriminants --
6961 --------------------------
6963 function Number_Discriminants
(Id
: E
) return Pos
is
6969 Discr
:= First_Discriminant
(Id
);
6970 while Present
(Discr
) loop
6972 Discr
:= Next_Discriminant
(Discr
);
6976 end Number_Discriminants
;
6978 --------------------
6979 -- Number_Entries --
6980 --------------------
6982 function Number_Entries
(Id
: E
) return Nat
is
6987 pragma Assert
(Is_Concurrent_Type
(Id
));
6990 Ent
:= First_Entity
(Id
);
6991 while Present
(Ent
) loop
6992 if Is_Entry
(Ent
) then
6996 Ent
:= Next_Entity
(Ent
);
7002 --------------------
7003 -- Number_Formals --
7004 --------------------
7006 function Number_Formals
(Id
: E
) return Pos
is
7012 Formal
:= First_Formal
(Id
);
7013 while Present
(Formal
) loop
7015 Formal
:= Next_Formal
(Formal
);
7021 --------------------
7022 -- Parameter_Mode --
7023 --------------------
7025 function Parameter_Mode
(Id
: E
) return Formal_Kind
is
7030 ---------------------
7031 -- Record_Rep_Item --
7032 ---------------------
7034 procedure Record_Rep_Item
(E
: Entity_Id
; N
: Node_Id
) is
7036 Set_Next_Rep_Item
(N
, First_Rep_Item
(E
));
7037 Set_First_Rep_Item
(E
, N
);
7038 end Record_Rep_Item
;
7044 function Root_Type
(Id
: E
) return E
is
7048 pragma Assert
(Nkind
(Id
) in N_Entity
);
7050 T
:= Base_Type
(Id
);
7052 if Ekind
(T
) = E_Class_Wide_Type
then
7055 elsif Ekind
(T
) = E_Class_Wide_Subtype
then
7056 return Etype
(Base_Type
(T
));
7058 -- ??? T comes from Base_Type, how can it be a subtype?
7059 -- Also Base_Type is supposed to be idempotent, so either way
7060 -- this is equivalent to "return Etype (T)" and should be merged
7061 -- with the E_Class_Wide_Type case.
7072 -- Following test catches some error cases resulting from
7075 elsif No
(Etyp
) then
7078 elsif Is_Private_Type
(T
) and then Etyp
= Full_View
(T
) then
7081 elsif Is_Private_Type
(Etyp
) and then Full_View
(Etyp
) = T
then
7087 -- Return if there is a circularity in the inheritance chain. This
7088 -- happens in some error situations and we do not want to get
7089 -- stuck in this loop.
7091 if T
= Base_Type
(Id
) then
7102 function Scope_Depth
(Id
: E
) return Uint
is
7107 while Is_Record_Type
(Scop
) loop
7108 Scop
:= Scope
(Scop
);
7111 return Scope_Depth_Value
(Scop
);
7114 ---------------------
7115 -- Scope_Depth_Set --
7116 ---------------------
7118 function Scope_Depth_Set
(Id
: E
) return B
is
7120 return not Is_Record_Type
(Id
)
7121 and then Field22
(Id
) /= Union_Id
(Empty
);
7122 end Scope_Depth_Set
;
7124 -----------------------------
7125 -- Set_Component_Alignment --
7126 -----------------------------
7128 -- Component Alignment is encoded using two flags, Flag128/129 as
7129 -- follows. Note that both flags False = Align_Default, so that the
7130 -- default initialization of flags to False initializes component
7131 -- alignment to the default value as required.
7133 -- Flag128 Flag129 Value
7134 -- ------- ------- -----
7135 -- False False Calign_Default
7136 -- False True Calign_Component_Size
7137 -- True False Calign_Component_Size_4
7138 -- True True Calign_Storage_Unit
7140 procedure Set_Component_Alignment
(Id
: E
; V
: C
) is
7142 pragma Assert
((Is_Array_Type
(Id
) or else Is_Record_Type
(Id
))
7143 and then Id
= Base_Type
(Id
));
7146 when Calign_Default
=>
7147 Set_Flag128
(Id
, False);
7148 Set_Flag129
(Id
, False);
7150 when Calign_Component_Size
=>
7151 Set_Flag128
(Id
, False);
7152 Set_Flag129
(Id
, True);
7154 when Calign_Component_Size_4
=>
7155 Set_Flag128
(Id
, True);
7156 Set_Flag129
(Id
, False);
7158 when Calign_Storage_Unit
=>
7159 Set_Flag128
(Id
, True);
7160 Set_Flag129
(Id
, True);
7162 end Set_Component_Alignment
;
7168 function Size_Clause
(Id
: E
) return N
is
7170 return Rep_Clause
(Id
, Name_Size
);
7173 ------------------------
7174 -- Stream_Size_Clause --
7175 ------------------------
7177 function Stream_Size_Clause
(Id
: E
) return N
is
7179 return Rep_Clause
(Id
, Name_Stream_Size
);
7180 end Stream_Size_Clause
;
7186 function Subtype_Kind
(K
: Entity_Kind
) return Entity_Kind
is
7192 Kind
:= E_Access_Subtype
;
7196 Kind
:= E_Array_Subtype
;
7198 when E_Class_Wide_Type |
7199 E_Class_Wide_Subtype
=>
7200 Kind
:= E_Class_Wide_Subtype
;
7202 when E_Decimal_Fixed_Point_Type |
7203 E_Decimal_Fixed_Point_Subtype
=>
7204 Kind
:= E_Decimal_Fixed_Point_Subtype
;
7206 when E_Ordinary_Fixed_Point_Type |
7207 E_Ordinary_Fixed_Point_Subtype
=>
7208 Kind
:= E_Ordinary_Fixed_Point_Subtype
;
7210 when E_Private_Type |
7211 E_Private_Subtype
=>
7212 Kind
:= E_Private_Subtype
;
7214 when E_Limited_Private_Type |
7215 E_Limited_Private_Subtype
=>
7216 Kind
:= E_Limited_Private_Subtype
;
7218 when E_Record_Type_With_Private |
7219 E_Record_Subtype_With_Private
=>
7220 Kind
:= E_Record_Subtype_With_Private
;
7222 when E_Record_Type |
7224 Kind
:= E_Record_Subtype
;
7226 when E_String_Type |
7228 Kind
:= E_String_Subtype
;
7230 when Enumeration_Kind
=>
7231 Kind
:= E_Enumeration_Subtype
;
7234 Kind
:= E_Floating_Point_Subtype
;
7236 when Signed_Integer_Kind
=>
7237 Kind
:= E_Signed_Integer_Subtype
;
7239 when Modular_Integer_Kind
=>
7240 Kind
:= E_Modular_Integer_Subtype
;
7242 when Protected_Kind
=>
7243 Kind
:= E_Protected_Subtype
;
7246 Kind
:= E_Task_Subtype
;
7250 raise Program_Error
;
7256 -------------------------
7257 -- First_Tag_Component --
7258 -------------------------
7260 function First_Tag_Component
(Id
: E
) return E
is
7262 Typ
: Entity_Id
:= Id
;
7265 pragma Assert
(Is_Tagged_Type
(Typ
));
7267 if Is_Class_Wide_Type
(Typ
) then
7268 Typ
:= Root_Type
(Typ
);
7271 if Is_Private_Type
(Typ
) then
7272 Typ
:= Underlying_Type
(Typ
);
7274 -- If the underlying type is missing then the source program has
7275 -- errors and there is nothing else to do (the full-type declaration
7276 -- associated with the private type declaration is missing).
7283 Comp
:= First_Entity
(Typ
);
7284 while Present
(Comp
) loop
7285 if Is_Tag
(Comp
) then
7289 Comp
:= Next_Entity
(Comp
);
7292 -- No tag component found
7295 end First_Tag_Component
;
7297 ------------------------
7298 -- Next_Tag_Component --
7299 ------------------------
7301 function Next_Tag_Component
(Id
: E
) return E
is
7305 pragma Assert
(Is_Tag
(Id
));
7307 Comp
:= Next_Entity
(Id
);
7308 while Present
(Comp
) loop
7309 if Is_Tag
(Comp
) then
7310 pragma Assert
(Chars
(Comp
) /= Name_uTag
);
7314 Comp
:= Next_Entity
(Comp
);
7317 -- No tag component found
7320 end Next_Tag_Component
;
7322 ---------------------
7323 -- Type_High_Bound --
7324 ---------------------
7326 function Type_High_Bound
(Id
: E
) return Node_Id
is
7327 Rng
: constant Node_Id
:= Scalar_Range
(Id
);
7329 if Nkind
(Rng
) = N_Subtype_Indication
then
7330 return High_Bound
(Range_Expression
(Constraint
(Rng
)));
7332 return High_Bound
(Rng
);
7334 end Type_High_Bound
;
7336 --------------------
7337 -- Type_Low_Bound --
7338 --------------------
7340 function Type_Low_Bound
(Id
: E
) return Node_Id
is
7341 Rng
: constant Node_Id
:= Scalar_Range
(Id
);
7343 if Nkind
(Rng
) = N_Subtype_Indication
then
7344 return Low_Bound
(Range_Expression
(Constraint
(Rng
)));
7346 return Low_Bound
(Rng
);
7350 ---------------------
7351 -- Underlying_Type --
7352 ---------------------
7354 function Underlying_Type
(Id
: E
) return E
is
7356 -- For record_with_private the underlying type is always the direct
7357 -- full view. Never try to take the full view of the parent it
7358 -- doesn't make sense.
7360 if Ekind
(Id
) = E_Record_Type_With_Private
then
7361 return Full_View
(Id
);
7363 elsif Ekind
(Id
) in Incomplete_Or_Private_Kind
then
7365 -- If we have an incomplete or private type with a full view,
7366 -- then we return the Underlying_Type of this full view
7368 if Present
(Full_View
(Id
)) then
7369 if Id
= Full_View
(Id
) then
7371 -- Previous error in declaration
7376 return Underlying_Type
(Full_View
(Id
));
7379 -- If we have an incomplete entity that comes from the limited
7380 -- view then we return the Underlying_Type of its non-limited
7383 elsif From_With_Type
(Id
)
7384 and then Present
(Non_Limited_View
(Id
))
7386 return Underlying_Type
(Non_Limited_View
(Id
));
7388 -- Otherwise check for the case where we have a derived type or
7389 -- subtype, and if so get the Underlying_Type of the parent type.
7391 elsif Etype
(Id
) /= Id
then
7392 return Underlying_Type
(Etype
(Id
));
7394 -- Otherwise we have an incomplete or private type that has
7395 -- no full view, which means that we have not encountered the
7396 -- completion, so return Empty to indicate the underlying type
7397 -- is not yet known.
7403 -- For non-incomplete, non-private types, return the type itself
7404 -- Also for entities that are not types at all return the entity
7410 end Underlying_Type
;
7412 ------------------------
7413 -- Write_Entity_Flags --
7414 ------------------------
7416 procedure Write_Entity_Flags
(Id
: Entity_Id
; Prefix
: String) is
7418 procedure W
(Flag_Name
: String; Flag
: Boolean);
7419 -- Write out given flag if it is set
7425 procedure W
(Flag_Name
: String; Flag
: Boolean) is
7429 Write_Str
(Flag_Name
);
7430 Write_Str
(" = True");
7435 -- Start of processing for Write_Entity_Flags
7438 if (Is_Array_Type
(Id
) or else Is_Record_Type
(Id
))
7439 and then Id
= Base_Type
(Id
)
7442 Write_Str
("Component_Alignment = ");
7444 case Component_Alignment
(Id
) is
7445 when Calign_Default
=>
7446 Write_Str
("Calign_Default");
7448 when Calign_Component_Size
=>
7449 Write_Str
("Calign_Component_Size");
7451 when Calign_Component_Size_4
=>
7452 Write_Str
("Calign_Component_Size_4");
7454 when Calign_Storage_Unit
=>
7455 Write_Str
("Calign_Storage_Unit");
7461 W
("Address_Taken", Flag104
(Id
));
7462 W
("Body_Needed_For_SAL", Flag40
(Id
));
7463 W
("C_Pass_By_Copy", Flag125
(Id
));
7464 W
("Can_Never_Be_Null", Flag38
(Id
));
7465 W
("Checks_May_Be_Suppressed", Flag31
(Id
));
7466 W
("Debug_Info_Off", Flag166
(Id
));
7467 W
("Default_Expressions_Processed", Flag108
(Id
));
7468 W
("Delay_Cleanups", Flag114
(Id
));
7469 W
("Delay_Subprogram_Descriptors", Flag50
(Id
));
7470 W
("Depends_On_Private", Flag14
(Id
));
7471 W
("Discard_Names", Flag88
(Id
));
7472 W
("Elaboration_Entity_Required", Flag174
(Id
));
7473 W
("Elaborate_Body_Desirable", Flag210
(Id
));
7474 W
("Entry_Accepted", Flag152
(Id
));
7475 W
("Can_Use_Internal_Rep", Flag229
(Id
));
7476 W
("Finalize_Storage_Only", Flag158
(Id
));
7477 W
("From_With_Type", Flag159
(Id
));
7478 W
("Has_Aliased_Components", Flag135
(Id
));
7479 W
("Has_Alignment_Clause", Flag46
(Id
));
7480 W
("Has_All_Calls_Remote", Flag79
(Id
));
7481 W
("Has_Anon_Block_Suffix", Flag201
(Id
));
7482 W
("Has_Atomic_Components", Flag86
(Id
));
7483 W
("Has_Biased_Representation", Flag139
(Id
));
7484 W
("Has_Completion", Flag26
(Id
));
7485 W
("Has_Completion_In_Body", Flag71
(Id
));
7486 W
("Has_Complex_Representation", Flag140
(Id
));
7487 W
("Has_Component_Size_Clause", Flag68
(Id
));
7488 W
("Has_Contiguous_Rep", Flag181
(Id
));
7489 W
("Has_Controlled_Component", Flag43
(Id
));
7490 W
("Has_Controlling_Result", Flag98
(Id
));
7491 W
("Has_Convention_Pragma", Flag119
(Id
));
7492 W
("Has_Delayed_Freeze", Flag18
(Id
));
7493 W
("Has_Discriminants", Flag5
(Id
));
7494 W
("Has_Enumeration_Rep_Clause", Flag66
(Id
));
7495 W
("Has_Exit", Flag47
(Id
));
7496 W
("Has_External_Tag_Rep_Clause", Flag110
(Id
));
7497 W
("Has_Forward_Instantiation", Flag175
(Id
));
7498 W
("Has_Fully_Qualified_Name", Flag173
(Id
));
7499 W
("Has_Gigi_Rep_Item", Flag82
(Id
));
7500 W
("Has_Homonym", Flag56
(Id
));
7501 W
("Has_Initial_Value", Flag219
(Id
));
7502 W
("Has_Machine_Radix_Clause", Flag83
(Id
));
7503 W
("Has_Master_Entity", Flag21
(Id
));
7504 W
("Has_Missing_Return", Flag142
(Id
));
7505 W
("Has_Nested_Block_With_Handler", Flag101
(Id
));
7506 W
("Has_Non_Standard_Rep", Flag75
(Id
));
7507 W
("Has_Object_Size_Clause", Flag172
(Id
));
7508 W
("Has_Per_Object_Constraint", Flag154
(Id
));
7509 W
("Has_Persistent_BSS", Flag188
(Id
));
7510 W
("Has_Postconditions", Flag240
(Id
));
7511 W
("Has_Pragma_Controlled", Flag27
(Id
));
7512 W
("Has_Pragma_Elaborate_Body", Flag150
(Id
));
7513 W
("Has_Pragma_Inline", Flag157
(Id
));
7514 W
("Has_Pragma_Inline_Always", Flag230
(Id
));
7515 W
("Has_Pragma_Pack", Flag121
(Id
));
7516 W
("Has_Pragma_Preelab_Init", Flag221
(Id
));
7517 W
("Has_Pragma_Pure", Flag203
(Id
));
7518 W
("Has_Pragma_Pure_Function", Flag179
(Id
));
7519 W
("Has_Pragma_Unmodified", Flag233
(Id
));
7520 W
("Has_Pragma_Unreferenced", Flag180
(Id
));
7521 W
("Has_Pragma_Unreferenced_Objects", Flag212
(Id
));
7522 W
("Has_Primitive_Operations", Flag120
(Id
));
7523 W
("Has_Private_Declaration", Flag155
(Id
));
7524 W
("Has_Qualified_Name", Flag161
(Id
));
7525 W
("Has_RACW", Flag214
(Id
));
7526 W
("Has_Record_Rep_Clause", Flag65
(Id
));
7527 W
("Has_Recursive_Call", Flag143
(Id
));
7528 W
("Has_Size_Clause", Flag29
(Id
));
7529 W
("Has_Small_Clause", Flag67
(Id
));
7530 W
("Has_Specified_Layout", Flag100
(Id
));
7531 W
("Has_Specified_Stream_Input", Flag190
(Id
));
7532 W
("Has_Specified_Stream_Output", Flag191
(Id
));
7533 W
("Has_Specified_Stream_Read", Flag192
(Id
));
7534 W
("Has_Specified_Stream_Write", Flag193
(Id
));
7535 W
("Has_Static_Discriminants", Flag211
(Id
));
7536 W
("Has_Storage_Size_Clause", Flag23
(Id
));
7537 W
("Has_Stream_Size_Clause", Flag184
(Id
));
7538 W
("Has_Subprogram_Descriptor", Flag93
(Id
));
7539 W
("Has_Task", Flag30
(Id
));
7540 W
("Has_Thunks", Flag228
(Id
));
7541 W
("Has_Unchecked_Union", Flag123
(Id
));
7542 W
("Has_Unknown_Discriminants", Flag72
(Id
));
7543 W
("Has_Up_Level_Access", Flag215
(Id
));
7544 W
("Has_Volatile_Components", Flag87
(Id
));
7545 W
("Has_Xref_Entry", Flag182
(Id
));
7546 W
("Implemented_By_Entry", Flag232
(Id
));
7547 W
("In_Package_Body", Flag48
(Id
));
7548 W
("In_Private_Part", Flag45
(Id
));
7549 W
("In_Use", Flag8
(Id
));
7550 W
("Is_AST_Entry", Flag132
(Id
));
7551 W
("Is_Abstract_Subprogram", Flag19
(Id
));
7552 W
("Is_Abstract_Type", Flag146
(Id
));
7553 W
("Is_Local_Anonymous_Access", Flag194
(Id
));
7554 W
("Is_Access_Constant", Flag69
(Id
));
7555 W
("Is_Ada_2005_Only", Flag185
(Id
));
7556 W
("Is_Aliased", Flag15
(Id
));
7557 W
("Is_Asynchronous", Flag81
(Id
));
7558 W
("Is_Atomic", Flag85
(Id
));
7559 W
("Is_Bit_Packed_Array", Flag122
(Id
));
7560 W
("Is_CPP_Class", Flag74
(Id
));
7561 W
("Is_Called", Flag102
(Id
));
7562 W
("Is_Character_Type", Flag63
(Id
));
7563 W
("Is_Child_Unit", Flag73
(Id
));
7564 W
("Is_Class_Wide_Equivalent_Type", Flag35
(Id
));
7565 W
("Is_Compilation_Unit", Flag149
(Id
));
7566 W
("Is_Completely_Hidden", Flag103
(Id
));
7567 W
("Is_Concurrent_Record_Type", Flag20
(Id
));
7568 W
("Is_Constr_Subt_For_UN_Aliased", Flag141
(Id
));
7569 W
("Is_Constr_Subt_For_U_Nominal", Flag80
(Id
));
7570 W
("Is_Constrained", Flag12
(Id
));
7571 W
("Is_Constructor", Flag76
(Id
));
7572 W
("Is_Controlled", Flag42
(Id
));
7573 W
("Is_Controlling_Formal", Flag97
(Id
));
7574 W
("Is_Descendent_Of_Address", Flag223
(Id
));
7575 W
("Is_Discrim_SO_Function", Flag176
(Id
));
7576 W
("Is_Dispatch_Table_Entity", Flag234
(Id
));
7577 W
("Is_Dispatching_Operation", Flag6
(Id
));
7578 W
("Is_Eliminated", Flag124
(Id
));
7579 W
("Is_Entry_Formal", Flag52
(Id
));
7580 W
("Is_Exported", Flag99
(Id
));
7581 W
("Is_First_Subtype", Flag70
(Id
));
7582 W
("Is_For_Access_Subtype", Flag118
(Id
));
7583 W
("Is_Formal_Subprogram", Flag111
(Id
));
7584 W
("Is_Frozen", Flag4
(Id
));
7585 W
("Is_Generic_Actual_Type", Flag94
(Id
));
7586 W
("Is_Generic_Instance", Flag130
(Id
));
7587 W
("Is_Generic_Type", Flag13
(Id
));
7588 W
("Is_Hidden", Flag57
(Id
));
7589 W
("Is_Hidden_Open_Scope", Flag171
(Id
));
7590 W
("Is_Immediately_Visible", Flag7
(Id
));
7591 W
("Is_Imported", Flag24
(Id
));
7592 W
("Is_Inlined", Flag11
(Id
));
7593 W
("Is_Instantiated", Flag126
(Id
));
7594 W
("Is_Interface", Flag186
(Id
));
7595 W
("Is_Internal", Flag17
(Id
));
7596 W
("Is_Interrupt_Handler", Flag89
(Id
));
7597 W
("Is_Intrinsic_Subprogram", Flag64
(Id
));
7598 W
("Is_Itype", Flag91
(Id
));
7599 W
("Is_Known_Non_Null", Flag37
(Id
));
7600 W
("Is_Known_Null", Flag204
(Id
));
7601 W
("Is_Known_Valid", Flag170
(Id
));
7602 W
("Is_Limited_Composite", Flag106
(Id
));
7603 W
("Is_Limited_Interface", Flag197
(Id
));
7604 W
("Is_Limited_Record", Flag25
(Id
));
7605 W
("Is_Machine_Code_Subprogram", Flag137
(Id
));
7606 W
("Is_Non_Static_Subtype", Flag109
(Id
));
7607 W
("Is_Null_Init_Proc", Flag178
(Id
));
7608 W
("Is_Obsolescent", Flag153
(Id
));
7609 W
("Is_Only_Out_Parameter", Flag226
(Id
));
7610 W
("Is_Optional_Parameter", Flag134
(Id
));
7611 W
("Is_Overriding_Operation", Flag39
(Id
));
7612 W
("Is_Package_Body_Entity", Flag160
(Id
));
7613 W
("Is_Packed", Flag51
(Id
));
7614 W
("Is_Packed_Array_Type", Flag138
(Id
));
7615 W
("Is_Potentially_Use_Visible", Flag9
(Id
));
7616 W
("Is_Preelaborated", Flag59
(Id
));
7617 W
("Is_Primitive", Flag218
(Id
));
7618 W
("Is_Primitive_Wrapper", Flag195
(Id
));
7619 W
("Is_Private_Composite", Flag107
(Id
));
7620 W
("Is_Private_Descendant", Flag53
(Id
));
7621 W
("Is_Private_Primitive", Flag245
(Id
));
7622 W
("Is_Protected_Interface", Flag198
(Id
));
7623 W
("Is_Public", Flag10
(Id
));
7624 W
("Is_Pure", Flag44
(Id
));
7625 W
("Is_Pure_Unit_Access_Type", Flag189
(Id
));
7626 W
("Is_RACW_Stub_Type", Flag244
(Id
));
7627 W
("Is_Raised", Flag224
(Id
));
7628 W
("Is_Remote_Call_Interface", Flag62
(Id
));
7629 W
("Is_Remote_Types", Flag61
(Id
));
7630 W
("Is_Renaming_Of_Object", Flag112
(Id
));
7631 W
("Is_Return_Object", Flag209
(Id
));
7632 W
("Is_Shared_Passive", Flag60
(Id
));
7633 W
("Is_Synchronized_Interface", Flag199
(Id
));
7634 W
("Is_Statically_Allocated", Flag28
(Id
));
7635 W
("Is_Tag", Flag78
(Id
));
7636 W
("Is_Tagged_Type", Flag55
(Id
));
7637 W
("Is_Task_Interface", Flag200
(Id
));
7638 W
("Is_Thunk", Flag225
(Id
));
7639 W
("Is_Trivial_Subprogram", Flag235
(Id
));
7640 W
("Is_True_Constant", Flag163
(Id
));
7641 W
("Is_Unchecked_Union", Flag117
(Id
));
7642 W
("Is_Unsigned_Type", Flag144
(Id
));
7643 W
("Is_VMS_Exception", Flag133
(Id
));
7644 W
("Is_Valued_Procedure", Flag127
(Id
));
7645 W
("Is_Visible_Child_Unit", Flag116
(Id
));
7646 W
("Is_Visible_Formal", Flag206
(Id
));
7647 W
("Is_Volatile", Flag16
(Id
));
7648 W
("Itype_Printed", Flag202
(Id
));
7649 W
("Kill_Elaboration_Checks", Flag32
(Id
));
7650 W
("Kill_Range_Checks", Flag33
(Id
));
7651 W
("Kill_Tag_Checks", Flag34
(Id
));
7652 W
("Known_To_Have_Preelab_Init", Flag207
(Id
));
7653 W
("Low_Bound_Known", Flag205
(Id
));
7654 W
("Machine_Radix_10", Flag84
(Id
));
7655 W
("Materialize_Entity", Flag168
(Id
));
7656 W
("Must_Be_On_Byte_Boundary", Flag183
(Id
));
7657 W
("Must_Have_Preelab_Init", Flag208
(Id
));
7658 W
("Needs_Debug_Info", Flag147
(Id
));
7659 W
("Needs_No_Actuals", Flag22
(Id
));
7660 W
("Never_Set_In_Source", Flag115
(Id
));
7661 W
("No_Pool_Assigned", Flag131
(Id
));
7662 W
("No_Return", Flag113
(Id
));
7663 W
("No_Strict_Aliasing", Flag136
(Id
));
7664 W
("Non_Binary_Modulus", Flag58
(Id
));
7665 W
("Nonzero_Is_True", Flag162
(Id
));
7666 W
("OK_To_Reorder_Components", Flag239
(Id
));
7667 W
("Optimize_Alignment_Space", Flag241
(Id
));
7668 W
("Optimize_Alignment_Time", Flag242
(Id
));
7669 W
("Overlays_Constant", Flag243
(Id
));
7670 W
("Reachable", Flag49
(Id
));
7671 W
("Referenced", Flag156
(Id
));
7672 W
("Referenced_As_LHS", Flag36
(Id
));
7673 W
("Referenced_As_Out_Parameter", Flag227
(Id
));
7674 W
("Renamed_In_Spec", Flag231
(Id
));
7675 W
("Requires_Overriding", Flag213
(Id
));
7676 W
("Return_Present", Flag54
(Id
));
7677 W
("Returns_By_Ref", Flag90
(Id
));
7678 W
("Reverse_Bit_Order", Flag164
(Id
));
7679 W
("Sec_Stack_Needed_For_Return", Flag167
(Id
));
7680 W
("Size_Depends_On_Discriminant", Flag177
(Id
));
7681 W
("Size_Known_At_Compile_Time", Flag92
(Id
));
7682 W
("Static_Elaboration_Desired", Flag77
(Id
));
7683 W
("Strict_Alignment", Flag145
(Id
));
7684 W
("Suppress_Elaboration_Warnings", Flag148
(Id
));
7685 W
("Suppress_Init_Proc", Flag105
(Id
));
7686 W
("Suppress_Style_Checks", Flag165
(Id
));
7687 W
("Suppress_Value_Tracking_On_Call", Flag217
(Id
));
7688 W
("Treat_As_Volatile", Flag41
(Id
));
7689 W
("Universal_Aliasing", Flag216
(Id
));
7690 W
("Used_As_Generic_Actual", Flag222
(Id
));
7691 W
("Uses_Sec_Stack", Flag95
(Id
));
7692 W
("Vax_Float", Flag151
(Id
));
7693 W
("Warnings_Off", Flag96
(Id
));
7694 W
("Warnings_Off_Used", Flag236
(Id
));
7695 W
("Warnings_Off_Used_Unmodified", Flag237
(Id
));
7696 W
("Warnings_Off_Used_Unreferenced", Flag238
(Id
));
7697 W
("Was_Hidden", Flag196
(Id
));
7698 end Write_Entity_Flags
;
7700 -----------------------
7701 -- Write_Entity_Info --
7702 -----------------------
7704 procedure Write_Entity_Info
(Id
: Entity_Id
; Prefix
: String) is
7706 procedure Write_Attribute
(Which
: String; Nam
: E
);
7707 -- Write attribute value with given string name
7709 procedure Write_Kind
(Id
: Entity_Id
);
7710 -- Write Ekind field of entity
7712 ---------------------
7713 -- Write_Attribute --
7714 ---------------------
7716 procedure Write_Attribute
(Which
: String; Nam
: E
) is
7720 Write_Int
(Int
(Nam
));
7722 Write_Name
(Chars
(Nam
));
7724 end Write_Attribute
;
7730 procedure Write_Kind
(Id
: Entity_Id
) is
7731 K
: constant String := Entity_Kind
'Image (Ekind
(Id
));
7735 Write_Str
(" Kind ");
7737 if Is_Type
(Id
) and then Is_Tagged_Type
(Id
) then
7738 Write_Str
("TAGGED ");
7741 Write_Str
(K
(3 .. K
'Length));
7744 if Is_Type
(Id
) and then Depends_On_Private
(Id
) then
7745 Write_Str
("Depends_On_Private ");
7749 -- Start of processing for Write_Entity_Info
7753 Write_Attribute
("Name ", Id
);
7754 Write_Int
(Int
(Id
));
7758 Write_Attribute
(" Type ", Etype
(Id
));
7760 Write_Attribute
(" Scope ", Scope
(Id
));
7765 when Discrete_Kind
=>
7766 Write_Str
("Bounds: Id = ");
7768 if Present
(Scalar_Range
(Id
)) then
7769 Write_Int
(Int
(Type_Low_Bound
(Id
)));
7770 Write_Str
(" .. Id = ");
7771 Write_Int
(Int
(Type_High_Bound
(Id
)));
7773 Write_Str
("Empty");
7784 (" Component Type ", Component_Type
(Id
));
7787 Write_Str
(" Indices ");
7789 Index
:= First_Index
(Id
);
7790 while Present
(Index
) loop
7791 Write_Attribute
(" ", Etype
(Index
));
7792 Index
:= Next_Index
(Index
);
7800 (" Directly Designated Type ",
7801 Directly_Designated_Type
(Id
));
7804 when Overloadable_Kind
=>
7805 if Present
(Homonym
(Id
)) then
7806 Write_Str
(" Homonym ");
7807 Write_Name
(Chars
(Homonym
(Id
)));
7809 Write_Int
(Int
(Homonym
(Id
)));
7816 if Ekind
(Scope
(Id
)) in Record_Kind
then
7818 " Original_Record_Component ",
7819 Original_Record_Component
(Id
));
7820 Write_Int
(Int
(Original_Record_Component
(Id
)));
7824 when others => null;
7826 end Write_Entity_Info
;
7828 -----------------------
7829 -- Write_Field6_Name --
7830 -----------------------
7832 procedure Write_Field6_Name
(Id
: Entity_Id
) is
7833 pragma Warnings
(Off
, Id
);
7835 Write_Str
("First_Rep_Item");
7836 end Write_Field6_Name
;
7838 -----------------------
7839 -- Write_Field7_Name --
7840 -----------------------
7842 procedure Write_Field7_Name
(Id
: Entity_Id
) is
7843 pragma Warnings
(Off
, Id
);
7845 Write_Str
("Freeze_Node");
7846 end Write_Field7_Name
;
7848 -----------------------
7849 -- Write_Field8_Name --
7850 -----------------------
7852 procedure Write_Field8_Name
(Id
: Entity_Id
) is
7857 Write_Str
("Normalized_First_Bit");
7861 E_Subprogram_Body
=>
7862 Write_Str
("Mechanism");
7865 Write_Str
("Associated_Node_For_Itype");
7868 Write_Str
("Dependent_Instances");
7870 when E_Return_Statement
=>
7871 Write_Str
("Return_Applies_To");
7874 Write_Str
("Hiding_Loop_Variable");
7877 Write_Str
("Field8??");
7879 end Write_Field8_Name
;
7881 -----------------------
7882 -- Write_Field9_Name --
7883 -----------------------
7885 procedure Write_Field9_Name
(Id
: Entity_Id
) is
7889 Write_Str
("Class_Wide_Type");
7892 E_Generic_Function |
7894 E_Generic_Procedure |
7897 Write_Str
("Renaming_Map");
7900 Write_Str
("Current_Value");
7903 Write_Str
("Field9??");
7905 end Write_Field9_Name
;
7907 ------------------------
7908 -- Write_Field10_Name --
7909 ------------------------
7911 procedure Write_Field10_Name
(Id
: Entity_Id
) is
7915 Write_Str
("Referenced_Object");
7917 when E_In_Parameter |
7919 Write_Str
("Discriminal_Link");
7925 Write_Str
("Handler_Records");
7929 Write_Str
("Normalized_Position_Max");
7932 Write_Str
("Field10??");
7934 end Write_Field10_Name
;
7936 ------------------------
7937 -- Write_Field11_Name --
7938 ------------------------
7940 procedure Write_Field11_Name
(Id
: Entity_Id
) is
7944 Write_Str
("Entry_Component");
7948 Write_Str
("Component_Bit_Offset");
7951 Write_Str
("Full_View");
7953 when E_Enumeration_Literal
=>
7954 Write_Str
("Enumeration_Pos");
7957 Write_Str
("Block_Node");
7963 Write_Str
("Protected_Body_Subprogram");
7965 when E_Generic_Package
=>
7966 Write_Str
("Generic_Homonym");
7969 Write_Str
("Full_View");
7972 Write_Str
("Field11??");
7974 end Write_Field11_Name
;
7976 ------------------------
7977 -- Write_Field12_Name --
7978 ------------------------
7980 procedure Write_Field12_Name
(Id
: Entity_Id
) is
7984 Write_Str
("Barrier_Function");
7986 when E_Enumeration_Literal
=>
7987 Write_Str
("Enumeration_Rep");
7995 E_In_Out_Parameter |
7999 Write_Str
("Esize");
8003 Write_Str
("Next_Inlined_Subprogram");
8006 Write_Str
("Associated_Formal_Package");
8009 Write_Str
("Field12??");
8011 end Write_Field12_Name
;
8013 ------------------------
8014 -- Write_Field13_Name --
8015 ------------------------
8017 procedure Write_Field13_Name
(Id
: Entity_Id
) is
8021 Write_Str
("RM_Size");
8025 Write_Str
("Component_Clause");
8028 if not Comes_From_Source
(Id
)
8030 Chars
(Id
) = Name_Op_Ne
8032 Write_Str
("Corresponding_Equality");
8034 elsif Comes_From_Source
(Id
) then
8035 Write_Str
("Elaboration_Entity");
8038 Write_Str
("Field13??");
8043 Write_Str
("Extra_Accessibility");
8047 Generic_Unit_Kind
=>
8048 Write_Str
("Elaboration_Entity");
8051 Write_Str
("Field13??");
8053 end Write_Field13_Name
;
8055 -----------------------
8056 -- Write_Field14_Name --
8057 -----------------------
8059 procedure Write_Field14_Name
(Id
: Entity_Id
) is
8068 Write_Str
("Alignment");
8072 Write_Str
("Normalized_Position");
8076 Write_Str
("First_Optional_Parameter");
8079 E_Generic_Package
=>
8080 Write_Str
("Shadow_Entities");
8083 Write_Str
("Field14??");
8085 end Write_Field14_Name
;
8087 ------------------------
8088 -- Write_Field15_Name --
8089 ------------------------
8091 procedure Write_Field15_Name
(Id
: Entity_Id
) is
8096 Write_Str
("Storage_Size_Variable");
8098 when Class_Wide_Kind |
8102 Write_Str
("Primitive_Operations");
8105 Write_Str
("DT_Entry_Count");
8107 when Decimal_Fixed_Point_Kind
=>
8108 Write_Str
("Scale_Value");
8110 when E_Discriminant
=>
8111 Write_Str
("Discriminant_Number");
8114 Write_Str
("Extra_Formal");
8118 Write_Str
("DT_Position");
8121 Write_Str
("Entry_Parameters_Type");
8123 when Enumeration_Kind
=>
8124 Write_Str
("Lit_Indexes");
8128 Write_Str
("Related_Instance");
8130 when E_Protected_Type
=>
8131 Write_Str
("Entry_Bodies_Array");
8133 when E_String_Literal_Subtype
=>
8134 Write_Str
("String_Literal_Low_Bound");
8137 Write_Str
("Field15??");
8139 end Write_Field15_Name
;
8141 ------------------------
8142 -- Write_Field16_Name --
8143 ------------------------
8145 procedure Write_Field16_Name
(Id
: Entity_Id
) is
8149 Write_Str
("Entry_Formal");
8153 Write_Str
("DTC_Entity");
8158 Write_Str
("First_Private_Entity");
8160 when E_Record_Type |
8161 E_Record_Type_With_Private
=>
8162 Write_Str
("Access_Disp_Table");
8164 when E_String_Literal_Subtype
=>
8165 Write_Str
("String_Literal_Length");
8167 when Enumeration_Kind
=>
8168 Write_Str
("Lit_Strings");
8172 Write_Str
("Unset_Reference");
8174 when E_Record_Subtype |
8175 E_Class_Wide_Subtype
=>
8176 Write_Str
("Cloned_Subtype");
8179 Write_Str
("Field16??");
8181 end Write_Field16_Name
;
8183 ------------------------
8184 -- Write_Field17_Name --
8185 ------------------------
8187 procedure Write_Field17_Name
(Id
: Entity_Id
) is
8191 Write_Str
("Digits_Value");
8194 Write_Str
("Prival");
8196 when E_Discriminant
=>
8197 Write_Str
("Discriminal");
8206 E_Generic_Function |
8208 E_Generic_Procedure |
8216 E_Return_Statement |
8218 E_Subprogram_Type
=>
8219 Write_Str
("First_Entity");
8222 Write_Str
("First_Index");
8224 when Enumeration_Kind
=>
8225 Write_Str
("First_Literal");
8228 Write_Str
("Master_Id");
8230 when Modular_Integer_Kind
=>
8231 Write_Str
("Modulus");
8235 E_Generic_In_Out_Parameter |
8237 Write_Str
("Actual_Subtype");
8239 when E_Incomplete_Type
=>
8240 Write_Str
("Non_Limited_View");
8242 when E_Incomplete_Subtype
=>
8243 if From_With_Type
(Id
) then
8244 Write_Str
("Non_Limited_View");
8248 Write_Str
("Field17??");
8250 end Write_Field17_Name
;
8252 ------------------------
8253 -- Write_Field18_Name --
8254 ------------------------
8256 procedure Write_Field18_Name
(Id
: Entity_Id
) is
8259 when E_Enumeration_Literal |
8263 Write_Str
("Alias");
8265 when E_Record_Type
=>
8266 Write_Str
("Corresponding_Concurrent_Type");
8268 when E_Entry_Index_Parameter
=>
8269 Write_Str
("Entry_Index_Constant");
8271 when E_Class_Wide_Subtype |
8272 E_Access_Protected_Subprogram_Type |
8273 E_Anonymous_Access_Protected_Subprogram_Type |
8274 E_Access_Subprogram_Type |
8276 Write_Str
("Equivalent_Type");
8278 when Fixed_Point_Kind
=>
8279 Write_Str
("Delta_Value");
8282 Write_Str
("Renamed_Object");
8286 E_Generic_Function |
8287 E_Generic_Procedure |
8288 E_Generic_Package
=>
8289 Write_Str
("Renamed_Entity");
8291 when Incomplete_Or_Private_Kind
=>
8292 Write_Str
("Private_Dependents");
8294 when Concurrent_Kind
=>
8295 Write_Str
("Corresponding_Record_Type");
8300 Write_Str
("Enclosing_Scope");
8303 Write_Str
("Field18??");
8305 end Write_Field18_Name
;
8307 -----------------------
8308 -- Write_Field19_Name --
8309 -----------------------
8311 procedure Write_Field19_Name
(Id
: Entity_Id
) is
8316 Write_Str
("Related_Array_Object");
8322 E_Return_Statement |
8324 Write_Str
("Finalization_Chain_Entity");
8326 when E_Constant | E_Variable
=>
8327 Write_Str
("Size_Check_Code");
8329 when E_Discriminant
=>
8330 Write_Str
("Corresponding_Discriminant");
8333 E_Generic_Package
=>
8334 Write_Str
("Body_Entity");
8336 when E_Package_Body |
8338 Write_Str
("Spec_Entity");
8340 when Private_Kind
=>
8341 Write_Str
("Underlying_Full_View");
8343 when E_Record_Type
=>
8344 Write_Str
("Parent_Subtype");
8347 Write_Str
("Field19??");
8349 end Write_Field19_Name
;
8351 -----------------------
8352 -- Write_Field20_Name --
8353 -----------------------
8355 procedure Write_Field20_Name
(Id
: Entity_Id
) is
8359 Write_Str
("Component_Type");
8361 when E_In_Parameter |
8362 E_Generic_In_Parameter
=>
8363 Write_Str
("Default_Value");
8366 Write_Str
("Directly_Designated_Type");
8369 Write_Str
("Discriminant_Checking_Func");
8373 Write_Str
("Prival_Link");
8375 when E_Discriminant
=>
8376 Write_Str
("Discriminant_Default_Value");
8385 E_Generic_Function |
8387 E_Generic_Procedure |
8395 E_Return_Statement |
8397 E_Subprogram_Type
=>
8399 Write_Str
("Last_Entity");
8402 Write_Str
("Scalar_Range");
8405 Write_Str
("Register_Exception_Call");
8408 Write_Str
("Field20??");
8410 end Write_Field20_Name
;
8412 -----------------------
8413 -- Write_Field21_Name --
8414 -----------------------
8416 procedure Write_Field21_Name
(Id
: Entity_Id
) is
8422 E_Generic_Function |
8424 E_Generic_Procedure |
8426 Write_Str
("Interface_Name");
8428 when Concurrent_Kind |
8429 Incomplete_Or_Private_Kind |
8433 Write_Str
("Discriminant_Constraint");
8436 Write_Str
("Accept_Address");
8438 when Fixed_Point_Kind
=>
8439 Write_Str
("Small_Value");
8441 when E_In_Parameter
=>
8442 Write_Str
("Default_Expr_Function");
8445 Modular_Integer_Kind
=>
8446 Write_Str
("Original_Array_Type");
8449 Write_Str
("Field21??");
8451 end Write_Field21_Name
;
8453 -----------------------
8454 -- Write_Field22_Name --
8455 -----------------------
8457 procedure Write_Field22_Name
(Id
: Entity_Id
) is
8461 Write_Str
("Associated_Storage_Pool");
8464 Write_Str
("Component_Size");
8468 Write_Str
("Original_Record_Component");
8470 when E_Enumeration_Literal
=>
8471 Write_Str
("Enumeration_Rep_Expr");
8474 Write_Str
("Exception_Code");
8477 Write_Str
("Protected_Formal");
8479 when E_Record_Type
=>
8480 Write_Str
("Corresponding_Remote_Type");
8490 E_Generic_Function |
8491 E_Generic_Procedure |
8494 E_Return_Statement |
8497 Write_Str
("Scope_Depth_Value");
8499 when E_Record_Type_With_Private |
8500 E_Record_Subtype_With_Private |
8503 E_Limited_Private_Type |
8504 E_Limited_Private_Subtype
=>
8505 Write_Str
("Private_View");
8508 Write_Str
("Shared_Var_Procs_Instance");
8511 Write_Str
("Field22??");
8513 end Write_Field22_Name
;
8515 ------------------------
8516 -- Write_Field23_Name --
8517 ------------------------
8519 procedure Write_Field23_Name
(Id
: Entity_Id
) is
8523 Write_Str
("Associated_Final_Chain");
8526 Write_Str
("Packed_Array_Type");
8529 Write_Str
("Entry_Cancel_Parameter");
8531 when E_Discriminant
=>
8532 Write_Str
("CR_Discriminant");
8534 when E_Enumeration_Type
=>
8535 Write_Str
("Enum_Pos_To_Rep");
8539 Write_Str
("Extra_Constrained");
8541 when E_Generic_Function |
8543 E_Generic_Procedure
=>
8544 Write_Str
("Inner_Instances");
8546 when Concurrent_Kind |
8547 Incomplete_Or_Private_Kind |
8551 Write_Str
("Stored_Constraint");
8555 if Present
(Scope
(Id
))
8556 and then Is_Protected_Type
(Scope
(Id
))
8558 Write_Str
("Protection_Object");
8560 Write_Str
("Generic_Renamings");
8564 if Is_Generic_Instance
(Id
) then
8565 Write_Str
("Generic_Renamings");
8567 Write_Str
("Limited_View");
8571 Write_Str
("Protection_Object");
8574 Write_Str
("Field23??");
8576 end Write_Field23_Name
;
8578 ------------------------
8579 -- Write_Field24_Name --
8580 ------------------------
8582 procedure Write_Field24_Name
(Id
: Entity_Id
) is
8585 when Subprogram_Kind
=>
8586 Write_Str
("Spec_PPC_List");
8591 end Write_Field24_Name
;
8593 ------------------------
8594 -- Write_Field25_Name --
8595 ------------------------
8597 procedure Write_Field25_Name
(Id
: Entity_Id
) is
8601 Write_Str
("DT_Offset_To_Top_Func");
8605 Write_Str
("Interface_Alias");
8607 when E_Record_Type |
8609 E_Record_Type_With_Private |
8610 E_Record_Subtype_With_Private
=>
8611 Write_Str
("Interfaces");
8614 Write_Str
("Task_Body_Procedure");
8617 Write_Str
("Debug_Renaming_Link");
8620 Write_Str
("Field25??");
8622 end Write_Field25_Name
;
8624 ------------------------
8625 -- Write_Field26_Name --
8626 ------------------------
8628 procedure Write_Field26_Name
(Id
: Entity_Id
) is
8633 Write_Str
("Related_Type");
8635 when E_Generic_Package |
8637 Write_Str
("Package_Instantiation");
8642 if Is_Dispatching_Operation
(Id
) then
8643 Write_Str
("Overridden_Operation");
8645 Write_Str
("Static_Initialization");
8648 when E_Record_Type |
8649 E_Record_Type_With_Private
=>
8650 Write_Str
("Dispatch_Table_Wrapper");
8652 when E_In_Out_Parameter |
8655 Write_Str
("Last_Assignment");
8658 Write_Str
("Relative_Deadline_Variable");
8661 Write_Str
("Field26??");
8663 end Write_Field26_Name
;
8665 ------------------------
8666 -- Write_Field27_Name --
8667 ------------------------
8669 procedure Write_Field27_Name
(Id
: Entity_Id
) is
8673 Write_Str
("Wrapped_Entity");
8675 when E_Package | Type_Kind
=>
8676 Write_Str
("Current_Use_Clause");
8679 Write_Str
("Field27??");
8681 end Write_Field27_Name
;
8683 ------------------------
8684 -- Write_Field28_Name --
8685 ------------------------
8687 procedure Write_Field28_Name
(Id
: Entity_Id
) is
8690 when E_Procedure | E_Function | E_Entry
=>
8691 Write_Str
("Extra_Formals");
8694 Write_Str
("Field28??");
8696 end Write_Field28_Name
;
8698 -------------------------
8699 -- Iterator Procedures --
8700 -------------------------
8702 procedure Proc_Next_Component
(N
: in out Node_Id
) is
8704 N
:= Next_Component
(N
);
8705 end Proc_Next_Component
;
8707 procedure Proc_Next_Component_Or_Discriminant
(N
: in out Node_Id
) is
8709 N
:= Next_Entity
(N
);
8710 while Present
(N
) loop
8711 exit when Ekind
(N
) = E_Component
8713 Ekind
(N
) = E_Discriminant
;
8714 N
:= Next_Entity
(N
);
8716 end Proc_Next_Component_Or_Discriminant
;
8718 procedure Proc_Next_Discriminant
(N
: in out Node_Id
) is
8720 N
:= Next_Discriminant
(N
);
8721 end Proc_Next_Discriminant
;
8723 procedure Proc_Next_Formal
(N
: in out Node_Id
) is
8725 N
:= Next_Formal
(N
);
8726 end Proc_Next_Formal
;
8728 procedure Proc_Next_Formal_With_Extras
(N
: in out Node_Id
) is
8730 N
:= Next_Formal_With_Extras
(N
);
8731 end Proc_Next_Formal_With_Extras
;
8733 procedure Proc_Next_Index
(N
: in out Node_Id
) is
8735 N
:= Next_Index
(N
);
8736 end Proc_Next_Index
;
8738 procedure Proc_Next_Inlined_Subprogram
(N
: in out Node_Id
) is
8740 N
:= Next_Inlined_Subprogram
(N
);
8741 end Proc_Next_Inlined_Subprogram
;
8743 procedure Proc_Next_Literal
(N
: in out Node_Id
) is
8745 N
:= Next_Literal
(N
);
8746 end Proc_Next_Literal
;
8748 procedure Proc_Next_Stored_Discriminant
(N
: in out Node_Id
) is
8750 N
:= Next_Stored_Discriminant
(N
);
8751 end Proc_Next_Stored_Discriminant
;