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 -- Function_Returns_With_DSP Flag169
425 -- Is_Known_Valid Flag170
427 -- Is_Hidden_Open_Scope Flag171
428 -- Has_Object_Size_Clause Flag172
429 -- Has_Fully_Qualified_Name Flag173
430 -- Elaboration_Entity_Required Flag174
431 -- Has_Forward_Instantiation Flag175
432 -- Is_Discrim_SO_Function Flag176
433 -- Size_Depends_On_Discriminant Flag177
434 -- Is_Null_Init_Proc Flag178
435 -- Has_Pragma_Pure_Function Flag179
436 -- Has_Pragma_Unreferenced Flag180
438 -- Has_Contiguous_Rep Flag181
439 -- Has_Xref_Entry Flag182
440 -- Must_Be_On_Byte_Boundary Flag183
441 -- Has_Stream_Size_Clause Flag184
442 -- Is_Ada_2005_Only Flag185
443 -- Is_Interface Flag186
444 -- Has_Constrained_Partial_View Flag187
445 -- Has_Persistent_BSS Flag188
446 -- Is_Pure_Unit_Access_Type Flag189
447 -- Has_Specified_Stream_Input Flag190
449 -- Has_Specified_Stream_Output Flag191
450 -- Has_Specified_Stream_Read Flag192
451 -- Has_Specified_Stream_Write Flag193
452 -- Is_Local_Anonymous_Access Flag194
453 -- Is_Primitive_Wrapper Flag195
454 -- Was_Hidden Flag196
455 -- Is_Limited_Interface Flag197
456 -- Is_Protected_Interface Flag198
457 -- Is_Synchronized_Interface Flag199
458 -- Is_Task_Interface Flag200
460 -- Has_Anon_Block_Suffix Flag201
461 -- Itype_Printed Flag202
462 -- Has_Pragma_Pure Flag203
463 -- Is_Known_Null Flag204
464 -- Low_Bound_Known Flag205
465 -- Is_Visible_Formal Flag206
466 -- Known_To_Have_Preelab_Init Flag207
467 -- Must_Have_Preelab_Init Flag208
468 -- Is_Return_Object Flag209
469 -- Elaborate_Body_Desirable Flag210
471 -- Has_Static_Discriminants Flag211
472 -- Has_Pragma_Unreferenced_Objects Flag212
473 -- Requires_Overriding Flag213
475 -- Has_Up_Level_Access Flag215
476 -- Universal_Aliasing Flag216
477 -- Suppress_Value_Tracking_On_Call Flag217
478 -- Is_Primitive Flag218
479 -- Has_Initial_Value Flag219
480 -- Has_Dispatch_Table Flag220
482 -- Has_Pragma_Preelab_Init Flag221
483 -- Used_As_Generic_Actual Flag222
484 -- Is_Descendent_Of_Address Flag223
487 -- Is_Only_Out_Parameter Flag226
488 -- Referenced_As_Out_Parameter Flag227
489 -- Has_Thunks Flag228
490 -- Can_Use_Internal_Rep Flag229
491 -- Has_Pragma_Inline_Always Flag230
493 -- Renamed_In_Spec Flag231
494 -- Implemented_By_Entry Flag232
495 -- Has_Pragma_Unmodified Flag233
496 -- Is_Dispatch_Table_Entity Flag234
497 -- Is_Trivial_Subprogram Flag235
498 -- Warnings_Off_Used Flag236
499 -- Warnings_Off_Used_Unmodified Flag237
500 -- Warnings_Off_Used_Unreferenced Flag238
501 -- OK_To_Reorder_Components Flag239
502 -- Has_Postconditions Flag240
504 -- Optimize_Alignment_Space Flag241
505 -- Optimize_Alignment_Time Flag242
506 -- Overlays_Constant Flag243
507 -- Is_RACW_Stub_Type Flag244
513 -----------------------
514 -- Local subprograms --
515 -----------------------
517 function Rep_Clause
(Id
: E
; Rep_Name
: Name_Id
) return N
;
518 -- Returns the attribute definition clause for Id whose name is Rep_Name.
519 -- Returns Empty if no matching attribute definition clause found for Id.
525 function Rep_Clause
(Id
: E
; Rep_Name
: Name_Id
) return N
is
529 Ritem
:= First_Rep_Item
(Id
);
530 while Present
(Ritem
) loop
531 if Nkind
(Ritem
) = N_Attribute_Definition_Clause
532 and then Chars
(Ritem
) = Rep_Name
536 Ritem
:= Next_Rep_Item
(Ritem
);
543 --------------------------------
544 -- Attribute Access Functions --
545 --------------------------------
547 function Accept_Address
(Id
: E
) return L
is
552 function Access_Disp_Table
(Id
: E
) return L
is
554 pragma Assert
(Is_Tagged_Type
(Id
));
555 return Elist16
(Implementation_Base_Type
(Id
));
556 end Access_Disp_Table
;
558 function Actual_Subtype
(Id
: E
) return E
is
561 (Ekind
(Id
) = E_Constant
562 or else Ekind
(Id
) = E_Variable
563 or else Ekind
(Id
) = E_Generic_In_Out_Parameter
564 or else Is_Formal
(Id
));
568 function Address_Taken
(Id
: E
) return B
is
573 function Alias
(Id
: E
) return E
is
576 (Is_Overloadable
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
580 function Alignment
(Id
: E
) return U
is
582 pragma Assert
(Is_Type
(Id
)
583 or else Is_Formal
(Id
)
584 or else Ekind
(Id
) = E_Loop_Parameter
585 or else Ekind
(Id
) = E_Constant
586 or else Ekind
(Id
) = E_Exception
587 or else Ekind
(Id
) = E_Variable
);
591 function Associated_Final_Chain
(Id
: E
) return E
is
593 pragma Assert
(Is_Access_Type
(Id
));
595 end Associated_Final_Chain
;
597 function Associated_Formal_Package
(Id
: E
) return E
is
599 pragma Assert
(Ekind
(Id
) = E_Package
);
601 end Associated_Formal_Package
;
603 function Associated_Node_For_Itype
(Id
: E
) return N
is
606 end Associated_Node_For_Itype
;
608 function Associated_Storage_Pool
(Id
: E
) return E
is
610 pragma Assert
(Is_Access_Type
(Id
));
611 return Node22
(Root_Type
(Id
));
612 end Associated_Storage_Pool
;
614 function Barrier_Function
(Id
: E
) return N
is
616 pragma Assert
(Is_Entry
(Id
));
618 end Barrier_Function
;
620 function Block_Node
(Id
: E
) return N
is
622 pragma Assert
(Ekind
(Id
) = E_Block
);
626 function Body_Entity
(Id
: E
) return E
is
629 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Generic_Package
);
633 function Body_Needed_For_SAL
(Id
: E
) return B
is
636 (Ekind
(Id
) = E_Package
637 or else Is_Subprogram
(Id
)
638 or else Is_Generic_Unit
(Id
));
640 end Body_Needed_For_SAL
;
642 function C_Pass_By_Copy
(Id
: E
) return B
is
644 pragma Assert
(Is_Record_Type
(Id
));
645 return Flag125
(Implementation_Base_Type
(Id
));
648 function Can_Never_Be_Null
(Id
: E
) return B
is
651 end Can_Never_Be_Null
;
653 function Checks_May_Be_Suppressed
(Id
: E
) return B
is
656 end Checks_May_Be_Suppressed
;
658 function Class_Wide_Type
(Id
: E
) return E
is
660 pragma Assert
(Is_Type
(Id
));
664 function Cloned_Subtype
(Id
: E
) return E
is
667 (Ekind
(Id
) = E_Record_Subtype
668 or else Ekind
(Id
) = E_Class_Wide_Subtype
);
672 function Component_Bit_Offset
(Id
: E
) return U
is
675 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
677 end Component_Bit_Offset
;
679 function Component_Clause
(Id
: E
) return N
is
682 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
684 end Component_Clause
;
686 function Component_Size
(Id
: E
) return U
is
688 pragma Assert
(Is_Array_Type
(Id
));
689 return Uint22
(Implementation_Base_Type
(Id
));
692 function Component_Type
(Id
: E
) return E
is
694 return Node20
(Implementation_Base_Type
(Id
));
697 function Corresponding_Concurrent_Type
(Id
: E
) return E
is
699 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
701 end Corresponding_Concurrent_Type
;
703 function Corresponding_Discriminant
(Id
: E
) return E
is
705 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
707 end Corresponding_Discriminant
;
709 function Corresponding_Equality
(Id
: E
) return E
is
712 (Ekind
(Id
) = E_Function
713 and then not Comes_From_Source
(Id
)
714 and then Chars
(Id
) = Name_Op_Ne
);
716 end Corresponding_Equality
;
718 function Corresponding_Record_Type
(Id
: E
) return E
is
720 pragma Assert
(Is_Concurrent_Type
(Id
));
722 end Corresponding_Record_Type
;
724 function Corresponding_Remote_Type
(Id
: E
) return E
is
727 end Corresponding_Remote_Type
;
729 function Current_Use_Clause
(Id
: E
) return E
is
731 pragma Assert
(Ekind
(Id
) = E_Package
or else Is_Type
(Id
));
733 end Current_Use_Clause
;
735 function Current_Value
(Id
: E
) return N
is
737 pragma Assert
(Ekind
(Id
) in Object_Kind
);
741 function CR_Discriminant
(Id
: E
) return E
is
746 function Debug_Info_Off
(Id
: E
) return B
is
751 function Debug_Renaming_Link
(Id
: E
) return E
is
754 end Debug_Renaming_Link
;
756 function Default_Expr_Function
(Id
: E
) return E
is
758 pragma Assert
(Is_Formal
(Id
));
760 end Default_Expr_Function
;
762 function Default_Expressions_Processed
(Id
: E
) return B
is
765 end Default_Expressions_Processed
;
767 function Default_Value
(Id
: E
) return N
is
769 pragma Assert
(Is_Formal
(Id
));
773 function Delay_Cleanups
(Id
: E
) return B
is
778 function Delay_Subprogram_Descriptors
(Id
: E
) return B
is
781 end Delay_Subprogram_Descriptors
;
783 function Delta_Value
(Id
: E
) return R
is
785 pragma Assert
(Is_Fixed_Point_Type
(Id
));
789 function Dependent_Instances
(Id
: E
) return L
is
791 pragma Assert
(Is_Generic_Instance
(Id
));
793 end Dependent_Instances
;
795 function Depends_On_Private
(Id
: E
) return B
is
797 pragma Assert
(Nkind
(Id
) in N_Entity
);
799 end Depends_On_Private
;
801 function Digits_Value
(Id
: E
) return U
is
804 (Is_Floating_Point_Type
(Id
)
805 or else Is_Decimal_Fixed_Point_Type
(Id
));
809 function Directly_Designated_Type
(Id
: E
) return E
is
812 end Directly_Designated_Type
;
814 function Discard_Names
(Id
: E
) return B
is
819 function Discriminal
(Id
: E
) return E
is
821 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
825 function Discriminal_Link
(Id
: E
) return N
is
828 end Discriminal_Link
;
830 function Discriminant_Checking_Func
(Id
: E
) return E
is
832 pragma Assert
(Ekind
(Id
) = E_Component
);
834 end Discriminant_Checking_Func
;
836 function Discriminant_Constraint
(Id
: E
) return L
is
838 pragma Assert
(Is_Composite_Type
(Id
) and then Has_Discriminants
(Id
));
840 end Discriminant_Constraint
;
842 function Discriminant_Default_Value
(Id
: E
) return N
is
844 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
846 end Discriminant_Default_Value
;
848 function Discriminant_Number
(Id
: E
) return U
is
850 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
852 end Discriminant_Number
;
854 function Dispatch_Table_Wrapper
(Id
: E
) return E
is
856 pragma Assert
(Is_Tagged_Type
(Id
));
857 return Node26
(Implementation_Base_Type
(Id
));
858 end Dispatch_Table_Wrapper
;
860 function DT_Entry_Count
(Id
: E
) return U
is
862 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
866 function DT_Offset_To_Top_Func
(Id
: E
) return E
is
868 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
870 end DT_Offset_To_Top_Func
;
872 function DT_Position
(Id
: E
) return U
is
875 ((Ekind
(Id
) = E_Function
876 or else Ekind
(Id
) = E_Procedure
)
877 and then Present
(DTC_Entity
(Id
)));
881 function DTC_Entity
(Id
: E
) return E
is
884 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
888 function Elaborate_Body_Desirable
(Id
: E
) return B
is
890 pragma Assert
(Ekind
(Id
) = E_Package
);
892 end Elaborate_Body_Desirable
;
894 function Elaboration_Entity
(Id
: E
) return E
is
899 Ekind
(Id
) = E_Package
901 Is_Generic_Unit
(Id
));
903 end Elaboration_Entity
;
905 function Elaboration_Entity_Required
(Id
: E
) return B
is
910 Ekind
(Id
) = E_Package
912 Is_Generic_Unit
(Id
));
914 end Elaboration_Entity_Required
;
916 function Enclosing_Scope
(Id
: E
) return E
is
921 function Entry_Accepted
(Id
: E
) return B
is
923 pragma Assert
(Is_Entry
(Id
));
927 function Entry_Bodies_Array
(Id
: E
) return E
is
930 end Entry_Bodies_Array
;
932 function Entry_Cancel_Parameter
(Id
: E
) return E
is
935 end Entry_Cancel_Parameter
;
937 function Entry_Component
(Id
: E
) return E
is
942 function Entry_Formal
(Id
: E
) return E
is
947 function Entry_Index_Constant
(Id
: E
) return N
is
949 pragma Assert
(Ekind
(Id
) = E_Entry_Index_Parameter
);
951 end Entry_Index_Constant
;
953 function Entry_Parameters_Type
(Id
: E
) return E
is
956 end Entry_Parameters_Type
;
958 function Enum_Pos_To_Rep
(Id
: E
) return E
is
960 pragma Assert
(Ekind
(Id
) = E_Enumeration_Type
);
964 function Enumeration_Pos
(Id
: E
) return Uint
is
966 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
970 function Enumeration_Rep
(Id
: E
) return U
is
972 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
976 function Enumeration_Rep_Expr
(Id
: E
) return N
is
978 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
980 end Enumeration_Rep_Expr
;
982 function Equivalent_Type
(Id
: E
) return E
is
985 (Ekind
(Id
) = E_Class_Wide_Subtype
or else
986 Ekind
(Id
) = E_Access_Protected_Subprogram_Type
or else
987 Ekind
(Id
) = E_Anonymous_Access_Protected_Subprogram_Type
or else
988 Ekind
(Id
) = E_Access_Subprogram_Type
or else
989 Ekind
(Id
) = E_Exception_Type
);
993 function Esize
(Id
: E
) return Uint
is
998 function Exception_Code
(Id
: E
) return Uint
is
1000 pragma Assert
(Ekind
(Id
) = E_Exception
);
1004 function Extra_Accessibility
(Id
: E
) return E
is
1006 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
1008 end Extra_Accessibility
;
1010 function Extra_Constrained
(Id
: E
) return E
is
1012 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
1014 end Extra_Constrained
;
1016 function Extra_Formal
(Id
: E
) return E
is
1021 function Extra_Formals
(Id
: E
) return E
is
1024 (Is_Overloadable
(Id
)
1025 or else Ekind
(Id
) = E_Entry_Family
1026 or else Ekind
(Id
) = E_Subprogram_Body
1027 or else Ekind
(Id
) = E_Subprogram_Type
);
1031 function Can_Use_Internal_Rep
(Id
: E
) return B
is
1033 pragma Assert
(Is_Access_Subprogram_Type
(Base_Type
(Id
)));
1034 return Flag229
(Base_Type
(Id
));
1035 end Can_Use_Internal_Rep
;
1037 function Finalization_Chain_Entity
(Id
: E
) return E
is
1040 end Finalization_Chain_Entity
;
1042 function Finalize_Storage_Only
(Id
: E
) return B
is
1044 pragma Assert
(Is_Type
(Id
));
1045 return Flag158
(Base_Type
(Id
));
1046 end Finalize_Storage_Only
;
1048 function First_Entity
(Id
: E
) return E
is
1053 function First_Index
(Id
: E
) return N
is
1055 pragma Assert
(Is_Array_Type
(Id
) or else Is_String_Type
(Id
));
1059 function First_Literal
(Id
: E
) return E
is
1061 pragma Assert
(Is_Enumeration_Type
(Id
));
1065 function First_Optional_Parameter
(Id
: E
) return E
is
1068 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
1070 end First_Optional_Parameter
;
1072 function First_Private_Entity
(Id
: E
) return E
is
1074 pragma Assert
(Ekind
(Id
) = E_Package
1075 or else Ekind
(Id
) = E_Generic_Package
1076 or else Ekind
(Id
) in Concurrent_Kind
);
1078 end First_Private_Entity
;
1080 function First_Rep_Item
(Id
: E
) return E
is
1085 function Freeze_Node
(Id
: E
) return N
is
1090 function From_With_Type
(Id
: E
) return B
is
1092 return Flag159
(Id
);
1095 function Full_View
(Id
: E
) return E
is
1097 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Constant
);
1101 function Function_Returns_With_DSP
(Id
: E
) return B
is
1104 (Is_Subprogram
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
1105 return Flag169
(Id
);
1106 end Function_Returns_With_DSP
;
1108 function Generic_Homonym
(Id
: E
) return E
is
1110 pragma Assert
(Ekind
(Id
) = E_Generic_Package
);
1112 end Generic_Homonym
;
1114 function Generic_Renamings
(Id
: E
) return L
is
1116 return Elist23
(Id
);
1117 end Generic_Renamings
;
1119 function Handler_Records
(Id
: E
) return S
is
1122 end Handler_Records
;
1124 function Has_Aliased_Components
(Id
: E
) return B
is
1126 return Flag135
(Implementation_Base_Type
(Id
));
1127 end Has_Aliased_Components
;
1129 function Has_Alignment_Clause
(Id
: E
) return B
is
1132 end Has_Alignment_Clause
;
1134 function Has_All_Calls_Remote
(Id
: E
) return B
is
1137 end Has_All_Calls_Remote
;
1139 function Has_Anon_Block_Suffix
(Id
: E
) return B
is
1141 return Flag201
(Id
);
1142 end Has_Anon_Block_Suffix
;
1144 function Has_Atomic_Components
(Id
: E
) return B
is
1146 return Flag86
(Implementation_Base_Type
(Id
));
1147 end Has_Atomic_Components
;
1149 function Has_Biased_Representation
(Id
: E
) return B
is
1151 return Flag139
(Id
);
1152 end Has_Biased_Representation
;
1154 function Has_Completion
(Id
: E
) return B
is
1159 function Has_Completion_In_Body
(Id
: E
) return B
is
1161 pragma Assert
(Is_Type
(Id
));
1163 end Has_Completion_In_Body
;
1165 function Has_Complex_Representation
(Id
: E
) return B
is
1167 pragma Assert
(Is_Type
(Id
));
1168 return Flag140
(Implementation_Base_Type
(Id
));
1169 end Has_Complex_Representation
;
1171 function Has_Component_Size_Clause
(Id
: E
) return B
is
1173 pragma Assert
(Is_Array_Type
(Id
));
1174 return Flag68
(Implementation_Base_Type
(Id
));
1175 end Has_Component_Size_Clause
;
1177 function Has_Constrained_Partial_View
(Id
: E
) return B
is
1179 pragma Assert
(Is_Type
(Id
));
1180 return Flag187
(Id
);
1181 end Has_Constrained_Partial_View
;
1183 function Has_Controlled_Component
(Id
: E
) return B
is
1185 return Flag43
(Base_Type
(Id
));
1186 end Has_Controlled_Component
;
1188 function Has_Contiguous_Rep
(Id
: E
) return B
is
1190 return Flag181
(Id
);
1191 end Has_Contiguous_Rep
;
1193 function Has_Controlling_Result
(Id
: E
) return B
is
1196 end Has_Controlling_Result
;
1198 function Has_Convention_Pragma
(Id
: E
) return B
is
1200 return Flag119
(Id
);
1201 end Has_Convention_Pragma
;
1203 function Has_Delayed_Freeze
(Id
: E
) return B
is
1205 pragma Assert
(Nkind
(Id
) in N_Entity
);
1207 end Has_Delayed_Freeze
;
1209 function Has_Discriminants
(Id
: E
) return B
is
1211 pragma Assert
(Nkind
(Id
) in N_Entity
);
1213 end Has_Discriminants
;
1215 function Has_Dispatch_Table
(Id
: E
) return B
is
1217 pragma Assert
(Is_Tagged_Type
(Id
));
1218 return Flag220
(Id
);
1219 end Has_Dispatch_Table
;
1221 function Has_Enumeration_Rep_Clause
(Id
: E
) return B
is
1223 pragma Assert
(Is_Enumeration_Type
(Id
));
1225 end Has_Enumeration_Rep_Clause
;
1227 function Has_Exit
(Id
: E
) return B
is
1232 function Has_External_Tag_Rep_Clause
(Id
: E
) return B
is
1234 pragma Assert
(Is_Tagged_Type
(Id
));
1235 return Flag110
(Id
);
1236 end Has_External_Tag_Rep_Clause
;
1238 function Has_Forward_Instantiation
(Id
: E
) return B
is
1240 return Flag175
(Id
);
1241 end Has_Forward_Instantiation
;
1243 function Has_Fully_Qualified_Name
(Id
: E
) return B
is
1245 return Flag173
(Id
);
1246 end Has_Fully_Qualified_Name
;
1248 function Has_Gigi_Rep_Item
(Id
: E
) return B
is
1251 end Has_Gigi_Rep_Item
;
1253 function Has_Homonym
(Id
: E
) return B
is
1258 function Has_Initial_Value
(Id
: E
) return B
is
1261 (Ekind
(Id
) = E_Variable
or else Is_Formal
(Id
));
1262 return Flag219
(Id
);
1263 end Has_Initial_Value
;
1265 function Has_Machine_Radix_Clause
(Id
: E
) return B
is
1267 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
1269 end Has_Machine_Radix_Clause
;
1271 function Has_Master_Entity
(Id
: E
) return B
is
1274 end Has_Master_Entity
;
1276 function Has_Missing_Return
(Id
: E
) return B
is
1279 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Generic_Function
);
1280 return Flag142
(Id
);
1281 end Has_Missing_Return
;
1283 function Has_Nested_Block_With_Handler
(Id
: E
) return B
is
1285 return Flag101
(Id
);
1286 end Has_Nested_Block_With_Handler
;
1288 function Has_Non_Standard_Rep
(Id
: E
) return B
is
1290 return Flag75
(Implementation_Base_Type
(Id
));
1291 end Has_Non_Standard_Rep
;
1293 function Has_Object_Size_Clause
(Id
: E
) return B
is
1295 pragma Assert
(Is_Type
(Id
));
1296 return Flag172
(Id
);
1297 end Has_Object_Size_Clause
;
1299 function Has_Per_Object_Constraint
(Id
: E
) return B
is
1301 return Flag154
(Id
);
1302 end Has_Per_Object_Constraint
;
1304 function Has_Persistent_BSS
(Id
: E
) return B
is
1306 return Flag188
(Id
);
1307 end Has_Persistent_BSS
;
1309 function Has_Postconditions
(Id
: E
) return B
is
1311 pragma Assert
(Is_Subprogram
(Id
));
1312 return Flag240
(Id
);
1313 end Has_Postconditions
;
1315 function Has_Pragma_Controlled
(Id
: E
) return B
is
1317 pragma Assert
(Is_Access_Type
(Id
));
1318 return Flag27
(Implementation_Base_Type
(Id
));
1319 end Has_Pragma_Controlled
;
1321 function Has_Pragma_Elaborate_Body
(Id
: E
) return B
is
1323 return Flag150
(Id
);
1324 end Has_Pragma_Elaborate_Body
;
1326 function Has_Pragma_Inline
(Id
: E
) return B
is
1328 return Flag157
(Id
);
1329 end Has_Pragma_Inline
;
1331 function Has_Pragma_Inline_Always
(Id
: E
) return B
is
1333 return Flag230
(Id
);
1334 end Has_Pragma_Inline_Always
;
1336 function Has_Pragma_Pack
(Id
: E
) return B
is
1338 pragma Assert
(Is_Record_Type
(Id
) or else Is_Array_Type
(Id
));
1339 return Flag121
(Implementation_Base_Type
(Id
));
1340 end Has_Pragma_Pack
;
1342 function Has_Pragma_Preelab_Init
(Id
: E
) return B
is
1344 return Flag221
(Id
);
1345 end Has_Pragma_Preelab_Init
;
1347 function Has_Pragma_Pure
(Id
: E
) return B
is
1349 return Flag203
(Id
);
1350 end Has_Pragma_Pure
;
1352 function Has_Pragma_Pure_Function
(Id
: E
) return B
is
1354 return Flag179
(Id
);
1355 end Has_Pragma_Pure_Function
;
1357 function Has_Pragma_Unmodified
(Id
: E
) return B
is
1359 return Flag233
(Id
);
1360 end Has_Pragma_Unmodified
;
1362 function Has_Pragma_Unreferenced
(Id
: E
) return B
is
1364 return Flag180
(Id
);
1365 end Has_Pragma_Unreferenced
;
1367 function Has_Pragma_Unreferenced_Objects
(Id
: E
) return B
is
1369 pragma Assert
(Is_Type
(Id
));
1370 return Flag212
(Id
);
1371 end Has_Pragma_Unreferenced_Objects
;
1373 function Has_Primitive_Operations
(Id
: E
) return B
is
1375 pragma Assert
(Is_Type
(Id
));
1376 return Flag120
(Base_Type
(Id
));
1377 end Has_Primitive_Operations
;
1379 function Has_Private_Declaration
(Id
: E
) return B
is
1381 return Flag155
(Id
);
1382 end Has_Private_Declaration
;
1384 function Has_Qualified_Name
(Id
: E
) return B
is
1386 return Flag161
(Id
);
1387 end Has_Qualified_Name
;
1389 function Has_RACW
(Id
: E
) return B
is
1391 pragma Assert
(Ekind
(Id
) = E_Package
);
1392 return Flag214
(Id
);
1395 function Has_Record_Rep_Clause
(Id
: E
) return B
is
1397 pragma Assert
(Is_Record_Type
(Id
));
1398 return Flag65
(Implementation_Base_Type
(Id
));
1399 end Has_Record_Rep_Clause
;
1401 function Has_Recursive_Call
(Id
: E
) return B
is
1403 pragma Assert
(Is_Subprogram
(Id
));
1404 return Flag143
(Id
);
1405 end Has_Recursive_Call
;
1407 function Has_Size_Clause
(Id
: E
) return B
is
1410 end Has_Size_Clause
;
1412 function Has_Small_Clause
(Id
: E
) return B
is
1415 end Has_Small_Clause
;
1417 function Has_Specified_Layout
(Id
: E
) return B
is
1419 pragma Assert
(Is_Type
(Id
));
1420 return Flag100
(Implementation_Base_Type
(Id
));
1421 end Has_Specified_Layout
;
1423 function Has_Specified_Stream_Input
(Id
: E
) return B
is
1425 pragma Assert
(Is_Type
(Id
));
1426 return Flag190
(Id
);
1427 end Has_Specified_Stream_Input
;
1429 function Has_Specified_Stream_Output
(Id
: E
) return B
is
1431 pragma Assert
(Is_Type
(Id
));
1432 return Flag191
(Id
);
1433 end Has_Specified_Stream_Output
;
1435 function Has_Specified_Stream_Read
(Id
: E
) return B
is
1437 pragma Assert
(Is_Type
(Id
));
1438 return Flag192
(Id
);
1439 end Has_Specified_Stream_Read
;
1441 function Has_Specified_Stream_Write
(Id
: E
) return B
is
1443 pragma Assert
(Is_Type
(Id
));
1444 return Flag193
(Id
);
1445 end Has_Specified_Stream_Write
;
1447 function Has_Static_Discriminants
(Id
: E
) return B
is
1449 pragma Assert
(Is_Type
(Id
));
1450 return Flag211
(Id
);
1451 end Has_Static_Discriminants
;
1453 function Has_Storage_Size_Clause
(Id
: E
) return B
is
1455 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
1456 return Flag23
(Implementation_Base_Type
(Id
));
1457 end Has_Storage_Size_Clause
;
1459 function Has_Stream_Size_Clause
(Id
: E
) return B
is
1461 return Flag184
(Id
);
1462 end Has_Stream_Size_Clause
;
1464 function Has_Subprogram_Descriptor
(Id
: E
) return B
is
1467 end Has_Subprogram_Descriptor
;
1469 function Has_Task
(Id
: E
) return B
is
1471 return Flag30
(Base_Type
(Id
));
1474 function Has_Thunks
(Id
: E
) return B
is
1476 pragma Assert
(Ekind
(Id
) = E_Constant
);
1477 return Flag228
(Id
);
1480 function Has_Unchecked_Union
(Id
: E
) return B
is
1482 return Flag123
(Base_Type
(Id
));
1483 end Has_Unchecked_Union
;
1485 function Has_Unknown_Discriminants
(Id
: E
) return B
is
1487 pragma Assert
(Is_Type
(Id
));
1489 end Has_Unknown_Discriminants
;
1491 function Has_Up_Level_Access
(Id
: E
) return B
is
1494 (Ekind
(Id
) = E_Variable
1495 or else Ekind
(Id
) = E_Constant
1496 or else Ekind
(Id
) = E_Loop_Parameter
);
1497 return Flag215
(Id
);
1498 end Has_Up_Level_Access
;
1500 function Has_Volatile_Components
(Id
: E
) return B
is
1502 return Flag87
(Implementation_Base_Type
(Id
));
1503 end Has_Volatile_Components
;
1505 function Has_Xref_Entry
(Id
: E
) return B
is
1507 return Flag182
(Implementation_Base_Type
(Id
));
1510 function Hiding_Loop_Variable
(Id
: E
) return E
is
1512 pragma Assert
(Ekind
(Id
) = E_Variable
);
1514 end Hiding_Loop_Variable
;
1516 function Homonym
(Id
: E
) return E
is
1521 function Implemented_By_Entry
(Id
: E
) return B
is
1524 (Ekind
(Id
) = E_Function
1525 or else Ekind
(Id
) = E_Procedure
);
1526 return Flag232
(Id
);
1527 end Implemented_By_Entry
;
1529 function Interfaces
(Id
: E
) return L
is
1531 pragma Assert
(Is_Record_Type
(Id
));
1532 return Elist25
(Id
);
1535 function Interface_Alias
(Id
: E
) return E
is
1537 pragma Assert
(Is_Subprogram
(Id
));
1539 end Interface_Alias
;
1541 function In_Package_Body
(Id
: E
) return B
is
1544 end In_Package_Body
;
1546 function In_Private_Part
(Id
: E
) return B
is
1549 end In_Private_Part
;
1551 function In_Use
(Id
: E
) return B
is
1553 pragma Assert
(Nkind
(Id
) in N_Entity
);
1557 function Inner_Instances
(Id
: E
) return L
is
1559 return Elist23
(Id
);
1560 end Inner_Instances
;
1562 function Interface_Name
(Id
: E
) return N
is
1567 function Is_Abstract_Subprogram
(Id
: E
) return B
is
1569 pragma Assert
(Is_Overloadable
(Id
));
1571 end Is_Abstract_Subprogram
;
1573 function Is_Abstract_Type
(Id
: E
) return B
is
1575 pragma Assert
(Is_Type
(Id
));
1576 return Flag146
(Id
);
1577 end Is_Abstract_Type
;
1579 function Is_Local_Anonymous_Access
(Id
: E
) return B
is
1581 pragma Assert
(Is_Access_Type
(Id
));
1582 return Flag194
(Id
);
1583 end Is_Local_Anonymous_Access
;
1585 function Is_Access_Constant
(Id
: E
) return B
is
1587 pragma Assert
(Is_Access_Type
(Id
));
1589 end Is_Access_Constant
;
1591 function Is_Ada_2005_Only
(Id
: E
) return B
is
1593 return Flag185
(Id
);
1594 end Is_Ada_2005_Only
;
1596 function Is_Aliased
(Id
: E
) return B
is
1598 pragma Assert
(Nkind
(Id
) in N_Entity
);
1602 function Is_AST_Entry
(Id
: E
) return B
is
1604 pragma Assert
(Is_Entry
(Id
));
1605 return Flag132
(Id
);
1608 function Is_Asynchronous
(Id
: E
) return B
is
1611 (Ekind
(Id
) = E_Procedure
or else Is_Type
(Id
));
1613 end Is_Asynchronous
;
1615 function Is_Atomic
(Id
: E
) return B
is
1620 function Is_Bit_Packed_Array
(Id
: E
) return B
is
1622 return Flag122
(Implementation_Base_Type
(Id
));
1623 end Is_Bit_Packed_Array
;
1625 function Is_Called
(Id
: E
) return B
is
1628 (Ekind
(Id
) = E_Procedure
or else Ekind
(Id
) = E_Function
);
1629 return Flag102
(Id
);
1632 function Is_Character_Type
(Id
: E
) return B
is
1635 end Is_Character_Type
;
1637 function Is_Child_Unit
(Id
: E
) return B
is
1642 function Is_Class_Wide_Equivalent_Type
(Id
: E
) return B
is
1645 end Is_Class_Wide_Equivalent_Type
;
1647 function Is_Compilation_Unit
(Id
: E
) return B
is
1649 return Flag149
(Id
);
1650 end Is_Compilation_Unit
;
1652 function Is_Completely_Hidden
(Id
: E
) return B
is
1654 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
1655 return Flag103
(Id
);
1656 end Is_Completely_Hidden
;
1658 function Is_Constr_Subt_For_U_Nominal
(Id
: E
) return B
is
1661 end Is_Constr_Subt_For_U_Nominal
;
1663 function Is_Constr_Subt_For_UN_Aliased
(Id
: E
) return B
is
1665 return Flag141
(Id
);
1666 end Is_Constr_Subt_For_UN_Aliased
;
1668 function Is_Constrained
(Id
: E
) return B
is
1670 pragma Assert
(Nkind
(Id
) in N_Entity
);
1674 function Is_Constructor
(Id
: E
) return B
is
1679 function Is_Controlled
(Id
: E
) return B
is
1681 return Flag42
(Base_Type
(Id
));
1684 function Is_Controlling_Formal
(Id
: E
) return B
is
1686 pragma Assert
(Is_Formal
(Id
));
1688 end Is_Controlling_Formal
;
1690 function Is_CPP_Class
(Id
: E
) return B
is
1695 function Is_Descendent_Of_Address
(Id
: E
) return B
is
1697 pragma Assert
(Is_Type
(Id
));
1698 return Flag223
(Id
);
1699 end Is_Descendent_Of_Address
;
1701 function Is_Discrim_SO_Function
(Id
: E
) return B
is
1703 return Flag176
(Id
);
1704 end Is_Discrim_SO_Function
;
1706 function Is_Dispatch_Table_Entity
(Id
: E
) return B
is
1708 return Flag234
(Id
);
1709 end Is_Dispatch_Table_Entity
;
1711 function Is_Dispatching_Operation
(Id
: E
) return B
is
1713 pragma Assert
(Nkind
(Id
) in N_Entity
);
1715 end Is_Dispatching_Operation
;
1717 function Is_Eliminated
(Id
: E
) return B
is
1719 return Flag124
(Id
);
1722 function Is_Entry_Formal
(Id
: E
) return B
is
1725 end Is_Entry_Formal
;
1727 function Is_Exported
(Id
: E
) return B
is
1732 function Is_First_Subtype
(Id
: E
) return B
is
1735 end Is_First_Subtype
;
1737 function Is_For_Access_Subtype
(Id
: E
) return B
is
1740 (Ekind
(Id
) = E_Record_Subtype
1742 Ekind
(Id
) = E_Private_Subtype
);
1743 return Flag118
(Id
);
1744 end Is_For_Access_Subtype
;
1746 function Is_Formal_Subprogram
(Id
: E
) return B
is
1748 return Flag111
(Id
);
1749 end Is_Formal_Subprogram
;
1751 function Is_Frozen
(Id
: E
) return B
is
1756 function Is_Generic_Actual_Type
(Id
: E
) return B
is
1758 pragma Assert
(Is_Type
(Id
));
1760 end Is_Generic_Actual_Type
;
1762 function Is_Generic_Instance
(Id
: E
) return B
is
1764 return Flag130
(Id
);
1765 end Is_Generic_Instance
;
1767 function Is_Generic_Type
(Id
: E
) return B
is
1769 pragma Assert
(Nkind
(Id
) in N_Entity
);
1771 end Is_Generic_Type
;
1773 function Is_Hidden
(Id
: E
) return B
is
1778 function Is_Hidden_Open_Scope
(Id
: E
) return B
is
1780 return Flag171
(Id
);
1781 end Is_Hidden_Open_Scope
;
1783 function Is_Immediately_Visible
(Id
: E
) return B
is
1785 pragma Assert
(Nkind
(Id
) in N_Entity
);
1787 end Is_Immediately_Visible
;
1789 function Is_Imported
(Id
: E
) return B
is
1794 function Is_Inlined
(Id
: E
) return B
is
1799 function Is_Interface
(Id
: E
) return B
is
1801 return Flag186
(Id
);
1804 function Is_Instantiated
(Id
: E
) return B
is
1806 return Flag126
(Id
);
1807 end Is_Instantiated
;
1809 function Is_Internal
(Id
: E
) return B
is
1811 pragma Assert
(Nkind
(Id
) in N_Entity
);
1815 function Is_Interrupt_Handler
(Id
: E
) return B
is
1817 pragma Assert
(Nkind
(Id
) in N_Entity
);
1819 end Is_Interrupt_Handler
;
1821 function Is_Intrinsic_Subprogram
(Id
: E
) return B
is
1824 end Is_Intrinsic_Subprogram
;
1826 function Is_Itype
(Id
: E
) return B
is
1831 function Is_Known_Non_Null
(Id
: E
) return B
is
1834 end Is_Known_Non_Null
;
1836 function Is_Known_Null
(Id
: E
) return B
is
1838 return Flag204
(Id
);
1841 function Is_Known_Valid
(Id
: E
) return B
is
1843 return Flag170
(Id
);
1846 function Is_Limited_Composite
(Id
: E
) return B
is
1848 return Flag106
(Id
);
1849 end Is_Limited_Composite
;
1851 function Is_Limited_Interface
(Id
: E
) return B
is
1853 return Flag197
(Id
);
1854 end Is_Limited_Interface
;
1856 function Is_Limited_Record
(Id
: E
) return B
is
1859 end Is_Limited_Record
;
1861 function Is_Machine_Code_Subprogram
(Id
: E
) return B
is
1863 pragma Assert
(Is_Subprogram
(Id
));
1864 return Flag137
(Id
);
1865 end Is_Machine_Code_Subprogram
;
1867 function Is_Non_Static_Subtype
(Id
: E
) return B
is
1869 pragma Assert
(Is_Type
(Id
));
1870 return Flag109
(Id
);
1871 end Is_Non_Static_Subtype
;
1873 function Is_Null_Init_Proc
(Id
: E
) return B
is
1875 pragma Assert
(Ekind
(Id
) = E_Procedure
);
1876 return Flag178
(Id
);
1877 end Is_Null_Init_Proc
;
1879 function Is_Obsolescent
(Id
: E
) return B
is
1881 return Flag153
(Id
);
1884 function Is_Only_Out_Parameter
(Id
: E
) return B
is
1886 pragma Assert
(Is_Formal
(Id
));
1887 return Flag226
(Id
);
1888 end Is_Only_Out_Parameter
;
1890 function Is_Optional_Parameter
(Id
: E
) return B
is
1892 pragma Assert
(Is_Formal
(Id
));
1893 return Flag134
(Id
);
1894 end Is_Optional_Parameter
;
1896 function Is_Overriding_Operation
(Id
: E
) return B
is
1898 pragma Assert
(Is_Subprogram
(Id
));
1900 end Is_Overriding_Operation
;
1902 function Is_Package_Body_Entity
(Id
: E
) return B
is
1904 return Flag160
(Id
);
1905 end Is_Package_Body_Entity
;
1907 function Is_Packed
(Id
: E
) return B
is
1909 return Flag51
(Implementation_Base_Type
(Id
));
1912 function Is_Packed_Array_Type
(Id
: E
) return B
is
1914 return Flag138
(Id
);
1915 end Is_Packed_Array_Type
;
1917 function Is_Potentially_Use_Visible
(Id
: E
) return B
is
1919 pragma Assert
(Nkind
(Id
) in N_Entity
);
1921 end Is_Potentially_Use_Visible
;
1923 function Is_Preelaborated
(Id
: E
) return B
is
1926 end Is_Preelaborated
;
1928 function Is_Primitive
(Id
: E
) return B
is
1931 (Is_Overloadable
(Id
)
1932 or else Ekind
(Id
) = E_Generic_Function
1933 or else Ekind
(Id
) = E_Generic_Procedure
);
1934 return Flag218
(Id
);
1937 function Is_Primitive_Wrapper
(Id
: E
) return B
is
1939 pragma Assert
(Ekind
(Id
) = E_Procedure
);
1940 return Flag195
(Id
);
1941 end Is_Primitive_Wrapper
;
1943 function Is_Private_Composite
(Id
: E
) return B
is
1945 pragma Assert
(Is_Type
(Id
));
1946 return Flag107
(Id
);
1947 end Is_Private_Composite
;
1949 function Is_Private_Descendant
(Id
: E
) return B
is
1952 end Is_Private_Descendant
;
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
));
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_Procedure
2713 and then Is_Primitive_Wrapper
(Id
));
2717 function Was_Hidden
(Id
: E
) return B
is
2719 return Flag196
(Id
);
2722 ------------------------------
2723 -- Classification Functions --
2724 ------------------------------
2726 function Is_Access_Type
(Id
: E
) return B
is
2728 return Ekind
(Id
) in Access_Kind
;
2731 function Is_Access_Protected_Subprogram_Type
(Id
: E
) return B
is
2733 return Ekind
(Id
) in Access_Protected_Kind
;
2734 end Is_Access_Protected_Subprogram_Type
;
2736 function Is_Access_Subprogram_Type
(Id
: E
) return B
is
2738 return Ekind
(Id
) in Access_Subprogram_Kind
;
2739 end Is_Access_Subprogram_Type
;
2741 function Is_Array_Type
(Id
: E
) return B
is
2743 return Ekind
(Id
) in Array_Kind
;
2746 function Is_Assignable
(Id
: E
) return B
is
2748 return Ekind
(Id
) in Assignable_Kind
;
2751 function Is_Class_Wide_Type
(Id
: E
) return B
is
2753 return Ekind
(Id
) in Class_Wide_Kind
;
2754 end Is_Class_Wide_Type
;
2756 function Is_Composite_Type
(Id
: E
) return B
is
2758 return Ekind
(Id
) in Composite_Kind
;
2759 end Is_Composite_Type
;
2761 function Is_Concurrent_Body
(Id
: E
) return B
is
2763 return Ekind
(Id
) in
2764 Concurrent_Body_Kind
;
2765 end Is_Concurrent_Body
;
2767 function Is_Concurrent_Record_Type
(Id
: E
) return B
is
2770 end Is_Concurrent_Record_Type
;
2772 function Is_Concurrent_Type
(Id
: E
) return B
is
2774 return Ekind
(Id
) in Concurrent_Kind
;
2775 end Is_Concurrent_Type
;
2777 function Is_Decimal_Fixed_Point_Type
(Id
: E
) return B
is
2779 return Ekind
(Id
) in
2780 Decimal_Fixed_Point_Kind
;
2781 end Is_Decimal_Fixed_Point_Type
;
2783 function Is_Digits_Type
(Id
: E
) return B
is
2785 return Ekind
(Id
) in Digits_Kind
;
2788 function Is_Discrete_Or_Fixed_Point_Type
(Id
: E
) return B
is
2790 return Ekind
(Id
) in Discrete_Or_Fixed_Point_Kind
;
2791 end Is_Discrete_Or_Fixed_Point_Type
;
2793 function Is_Discrete_Type
(Id
: E
) return B
is
2795 return Ekind
(Id
) in Discrete_Kind
;
2796 end Is_Discrete_Type
;
2798 function Is_Elementary_Type
(Id
: E
) return B
is
2800 return Ekind
(Id
) in Elementary_Kind
;
2801 end Is_Elementary_Type
;
2803 function Is_Entry
(Id
: E
) return B
is
2805 return Ekind
(Id
) in Entry_Kind
;
2808 function Is_Enumeration_Type
(Id
: E
) return B
is
2810 return Ekind
(Id
) in
2812 end Is_Enumeration_Type
;
2814 function Is_Fixed_Point_Type
(Id
: E
) return B
is
2816 return Ekind
(Id
) in
2818 end Is_Fixed_Point_Type
;
2820 function Is_Floating_Point_Type
(Id
: E
) return B
is
2822 return Ekind
(Id
) in Float_Kind
;
2823 end Is_Floating_Point_Type
;
2825 function Is_Formal
(Id
: E
) return B
is
2827 return Ekind
(Id
) in Formal_Kind
;
2830 function Is_Formal_Object
(Id
: E
) return B
is
2832 return Ekind
(Id
) in Formal_Object_Kind
;
2833 end Is_Formal_Object
;
2835 function Is_Generic_Subprogram
(Id
: E
) return B
is
2837 return Ekind
(Id
) in Generic_Subprogram_Kind
;
2838 end Is_Generic_Subprogram
;
2840 function Is_Generic_Unit
(Id
: E
) return B
is
2842 return Ekind
(Id
) in Generic_Unit_Kind
;
2843 end Is_Generic_Unit
;
2845 function Is_Incomplete_Or_Private_Type
(Id
: E
) return B
is
2847 return Ekind
(Id
) in
2848 Incomplete_Or_Private_Kind
;
2849 end Is_Incomplete_Or_Private_Type
;
2851 function Is_Incomplete_Type
(Id
: E
) return B
is
2853 return Ekind
(Id
) in
2855 end Is_Incomplete_Type
;
2857 function Is_Integer_Type
(Id
: E
) return B
is
2859 return Ekind
(Id
) in Integer_Kind
;
2860 end Is_Integer_Type
;
2862 function Is_Modular_Integer_Type
(Id
: E
) return B
is
2864 return Ekind
(Id
) in
2865 Modular_Integer_Kind
;
2866 end Is_Modular_Integer_Type
;
2868 function Is_Named_Number
(Id
: E
) return B
is
2870 return Ekind
(Id
) in Named_Kind
;
2871 end Is_Named_Number
;
2873 function Is_Numeric_Type
(Id
: E
) return B
is
2875 return Ekind
(Id
) in Numeric_Kind
;
2876 end Is_Numeric_Type
;
2878 function Is_Object
(Id
: E
) return B
is
2880 return Ekind
(Id
) in Object_Kind
;
2883 function Is_Ordinary_Fixed_Point_Type
(Id
: E
) return B
is
2885 return Ekind
(Id
) in
2886 Ordinary_Fixed_Point_Kind
;
2887 end Is_Ordinary_Fixed_Point_Type
;
2889 function Is_Overloadable
(Id
: E
) return B
is
2891 return Ekind
(Id
) in Overloadable_Kind
;
2892 end Is_Overloadable
;
2894 function Is_Private_Type
(Id
: E
) return B
is
2896 return Ekind
(Id
) in Private_Kind
;
2897 end Is_Private_Type
;
2899 function Is_Protected_Type
(Id
: E
) return B
is
2901 return Ekind
(Id
) in Protected_Kind
;
2902 end Is_Protected_Type
;
2904 function Is_Real_Type
(Id
: E
) return B
is
2906 return Ekind
(Id
) in Real_Kind
;
2909 function Is_Record_Type
(Id
: E
) return B
is
2911 return Ekind
(Id
) in Record_Kind
;
2914 function Is_Scalar_Type
(Id
: E
) return B
is
2916 return Ekind
(Id
) in Scalar_Kind
;
2919 function Is_Signed_Integer_Type
(Id
: E
) return B
is
2921 return Ekind
(Id
) in
2922 Signed_Integer_Kind
;
2923 end Is_Signed_Integer_Type
;
2925 function Is_Subprogram
(Id
: E
) return B
is
2927 return Ekind
(Id
) in Subprogram_Kind
;
2930 function Is_Task_Type
(Id
: E
) return B
is
2932 return Ekind
(Id
) in Task_Kind
;
2935 function Is_Type
(Id
: E
) return B
is
2937 return Ekind
(Id
) in Type_Kind
;
2940 ------------------------------
2941 -- Attribute Set Procedures --
2942 ------------------------------
2944 procedure Set_Accept_Address
(Id
: E
; V
: L
) is
2946 Set_Elist21
(Id
, V
);
2947 end Set_Accept_Address
;
2949 procedure Set_Access_Disp_Table
(Id
: E
; V
: L
) is
2951 pragma Assert
(Is_Tagged_Type
(Id
) and then Id
= Base_Type
(Id
));
2952 Set_Elist16
(Id
, V
);
2953 end Set_Access_Disp_Table
;
2955 procedure Set_Associated_Final_Chain
(Id
: E
; V
: E
) is
2957 pragma Assert
(Is_Access_Type
(Id
));
2959 end Set_Associated_Final_Chain
;
2961 procedure Set_Associated_Formal_Package
(Id
: E
; V
: E
) is
2964 end Set_Associated_Formal_Package
;
2966 procedure Set_Associated_Node_For_Itype
(Id
: E
; V
: E
) is
2969 end Set_Associated_Node_For_Itype
;
2971 procedure Set_Associated_Storage_Pool
(Id
: E
; V
: E
) is
2973 pragma Assert
(Is_Access_Type
(Id
) and then Id
= Base_Type
(Id
));
2975 end Set_Associated_Storage_Pool
;
2977 procedure Set_Actual_Subtype
(Id
: E
; V
: E
) is
2980 (Ekind
(Id
) = E_Constant
2981 or else Ekind
(Id
) = E_Variable
2982 or else Ekind
(Id
) = E_Generic_In_Out_Parameter
2983 or else Is_Formal
(Id
));
2985 end Set_Actual_Subtype
;
2987 procedure Set_Address_Taken
(Id
: E
; V
: B
:= True) is
2989 Set_Flag104
(Id
, V
);
2990 end Set_Address_Taken
;
2992 procedure Set_Alias
(Id
: E
; V
: E
) is
2995 (Is_Overloadable
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
2999 procedure Set_Alignment
(Id
: E
; V
: U
) is
3001 pragma Assert
(Is_Type
(Id
)
3002 or else Is_Formal
(Id
)
3003 or else Ekind
(Id
) = E_Loop_Parameter
3004 or else Ekind
(Id
) = E_Constant
3005 or else Ekind
(Id
) = E_Exception
3006 or else Ekind
(Id
) = E_Variable
);
3010 procedure Set_Barrier_Function
(Id
: E
; V
: N
) is
3012 pragma Assert
(Is_Entry
(Id
));
3014 end Set_Barrier_Function
;
3016 procedure Set_Block_Node
(Id
: E
; V
: N
) is
3018 pragma Assert
(Ekind
(Id
) = E_Block
);
3022 procedure Set_Body_Entity
(Id
: E
; V
: E
) is
3025 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Generic_Package
);
3027 end Set_Body_Entity
;
3029 procedure Set_Body_Needed_For_SAL
(Id
: E
; V
: B
:= True) is
3032 (Ekind
(Id
) = E_Package
3033 or else Is_Subprogram
(Id
)
3034 or else Is_Generic_Unit
(Id
));
3036 end Set_Body_Needed_For_SAL
;
3038 procedure Set_C_Pass_By_Copy
(Id
: E
; V
: B
:= True) is
3040 pragma Assert
(Is_Record_Type
(Id
) and then Id
= Base_Type
(Id
));
3041 Set_Flag125
(Id
, V
);
3042 end Set_C_Pass_By_Copy
;
3044 procedure Set_Can_Never_Be_Null
(Id
: E
; V
: B
:= True) is
3047 end Set_Can_Never_Be_Null
;
3049 procedure Set_Checks_May_Be_Suppressed
(Id
: E
; V
: B
:= True) is
3052 end Set_Checks_May_Be_Suppressed
;
3054 procedure Set_Class_Wide_Type
(Id
: E
; V
: E
) is
3056 pragma Assert
(Is_Type
(Id
));
3058 end Set_Class_Wide_Type
;
3060 procedure Set_Cloned_Subtype
(Id
: E
; V
: E
) is
3063 (Ekind
(Id
) = E_Record_Subtype
3064 or else Ekind
(Id
) = E_Class_Wide_Subtype
);
3066 end Set_Cloned_Subtype
;
3068 procedure Set_Component_Bit_Offset
(Id
: E
; V
: U
) is
3071 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
3073 end Set_Component_Bit_Offset
;
3075 procedure Set_Component_Clause
(Id
: E
; V
: N
) is
3078 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
3080 end Set_Component_Clause
;
3082 procedure Set_Component_Size
(Id
: E
; V
: U
) is
3084 pragma Assert
(Is_Array_Type
(Id
) and then Id
= Base_Type
(Id
));
3086 end Set_Component_Size
;
3088 procedure Set_Component_Type
(Id
: E
; V
: E
) is
3090 pragma Assert
(Is_Array_Type
(Id
) and then Id
= Base_Type
(Id
));
3092 end Set_Component_Type
;
3094 procedure Set_Corresponding_Concurrent_Type
(Id
: E
; V
: E
) is
3097 (Ekind
(Id
) = E_Record_Type
and then Is_Concurrent_Type
(V
));
3099 end Set_Corresponding_Concurrent_Type
;
3101 procedure Set_Corresponding_Discriminant
(Id
: E
; V
: E
) is
3103 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
3105 end Set_Corresponding_Discriminant
;
3107 procedure Set_Corresponding_Equality
(Id
: E
; V
: E
) is
3110 (Ekind
(Id
) = E_Function
3111 and then not Comes_From_Source
(Id
)
3112 and then Chars
(Id
) = Name_Op_Ne
);
3114 end Set_Corresponding_Equality
;
3116 procedure Set_Corresponding_Record_Type
(Id
: E
; V
: E
) is
3118 pragma Assert
(Is_Concurrent_Type
(Id
));
3120 end Set_Corresponding_Record_Type
;
3122 procedure Set_Corresponding_Remote_Type
(Id
: E
; V
: E
) is
3125 end Set_Corresponding_Remote_Type
;
3127 procedure Set_Current_Use_Clause
(Id
: E
; V
: E
) is
3129 pragma Assert
(Ekind
(Id
) = E_Package
or else Is_Type
(Id
));
3131 end Set_Current_Use_Clause
;
3133 procedure Set_Current_Value
(Id
: E
; V
: N
) is
3135 pragma Assert
(Ekind
(Id
) in Object_Kind
or else Ekind
(Id
) = E_Void
);
3137 end Set_Current_Value
;
3139 procedure Set_CR_Discriminant
(Id
: E
; V
: E
) is
3142 end Set_CR_Discriminant
;
3144 procedure Set_Debug_Info_Off
(Id
: E
; V
: B
:= True) is
3146 Set_Flag166
(Id
, V
);
3147 end Set_Debug_Info_Off
;
3149 procedure Set_Debug_Renaming_Link
(Id
: E
; V
: E
) is
3152 end Set_Debug_Renaming_Link
;
3154 procedure Set_Default_Expr_Function
(Id
: E
; V
: E
) is
3156 pragma Assert
(Is_Formal
(Id
));
3158 end Set_Default_Expr_Function
;
3160 procedure Set_Default_Expressions_Processed
(Id
: E
; V
: B
:= True) is
3162 Set_Flag108
(Id
, V
);
3163 end Set_Default_Expressions_Processed
;
3165 procedure Set_Default_Value
(Id
: E
; V
: N
) is
3167 pragma Assert
(Is_Formal
(Id
));
3169 end Set_Default_Value
;
3171 procedure Set_Delay_Cleanups
(Id
: E
; V
: B
:= True) is
3175 or else Is_Task_Type
(Id
)
3176 or else Ekind
(Id
) = E_Block
);
3177 Set_Flag114
(Id
, V
);
3178 end Set_Delay_Cleanups
;
3180 procedure Set_Delay_Subprogram_Descriptors
(Id
: E
; V
: B
:= True) is
3184 or else Ekind
(Id
) = E_Package
3185 or else Ekind
(Id
) = E_Package_Body
);
3187 end Set_Delay_Subprogram_Descriptors
;
3189 procedure Set_Delta_Value
(Id
: E
; V
: R
) is
3191 pragma Assert
(Is_Fixed_Point_Type
(Id
));
3192 Set_Ureal18
(Id
, V
);
3193 end Set_Delta_Value
;
3195 procedure Set_Dependent_Instances
(Id
: E
; V
: L
) is
3197 pragma Assert
(Is_Generic_Instance
(Id
));
3199 end Set_Dependent_Instances
;
3201 procedure Set_Depends_On_Private
(Id
: E
; V
: B
:= True) is
3203 pragma Assert
(Nkind
(Id
) in N_Entity
);
3205 end Set_Depends_On_Private
;
3207 procedure Set_Digits_Value
(Id
: E
; V
: U
) is
3210 (Is_Floating_Point_Type
(Id
)
3211 or else Is_Decimal_Fixed_Point_Type
(Id
));
3213 end Set_Digits_Value
;
3215 procedure Set_Directly_Designated_Type
(Id
: E
; V
: E
) is
3218 end Set_Directly_Designated_Type
;
3220 procedure Set_Discard_Names
(Id
: E
; V
: B
:= True) is
3223 end Set_Discard_Names
;
3225 procedure Set_Discriminal
(Id
: E
; V
: E
) is
3227 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
3229 end Set_Discriminal
;
3231 procedure Set_Discriminal_Link
(Id
: E
; V
: E
) is
3234 end Set_Discriminal_Link
;
3236 procedure Set_Discriminant_Checking_Func
(Id
: E
; V
: E
) is
3238 pragma Assert
(Ekind
(Id
) = E_Component
);
3240 end Set_Discriminant_Checking_Func
;
3242 procedure Set_Discriminant_Constraint
(Id
: E
; V
: L
) is
3244 pragma Assert
(Nkind
(Id
) in N_Entity
);
3245 Set_Elist21
(Id
, V
);
3246 end Set_Discriminant_Constraint
;
3248 procedure Set_Discriminant_Default_Value
(Id
: E
; V
: N
) is
3251 end Set_Discriminant_Default_Value
;
3253 procedure Set_Discriminant_Number
(Id
: E
; V
: U
) is
3256 end Set_Discriminant_Number
;
3258 procedure Set_Dispatch_Table_Wrapper
(Id
: E
; V
: E
) is
3260 pragma Assert
(Is_Tagged_Type
(Id
) and then Id
= Base_Type
(Id
));
3262 end Set_Dispatch_Table_Wrapper
;
3264 procedure Set_DT_Entry_Count
(Id
: E
; V
: U
) is
3266 pragma Assert
(Ekind
(Id
) = E_Component
);
3268 end Set_DT_Entry_Count
;
3270 procedure Set_DT_Offset_To_Top_Func
(Id
: E
; V
: E
) is
3272 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
3274 end Set_DT_Offset_To_Top_Func
;
3276 procedure Set_DT_Position
(Id
: E
; V
: U
) is
3278 pragma Assert
(Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
3280 end Set_DT_Position
;
3282 procedure Set_DTC_Entity
(Id
: E
; V
: E
) is
3285 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
3289 procedure Set_Elaborate_Body_Desirable
(Id
: E
; V
: B
:= True) is
3291 pragma Assert
(Ekind
(Id
) = E_Package
);
3292 Set_Flag210
(Id
, V
);
3293 end Set_Elaborate_Body_Desirable
;
3295 procedure Set_Elaboration_Entity
(Id
: E
; V
: E
) is
3300 Ekind
(Id
) = E_Package
3302 Is_Generic_Unit
(Id
));
3304 end Set_Elaboration_Entity
;
3306 procedure Set_Elaboration_Entity_Required
(Id
: E
; V
: B
:= True) is
3311 Ekind
(Id
) = E_Package
3313 Is_Generic_Unit
(Id
));
3314 Set_Flag174
(Id
, V
);
3315 end Set_Elaboration_Entity_Required
;
3317 procedure Set_Enclosing_Scope
(Id
: E
; V
: E
) is
3320 end Set_Enclosing_Scope
;
3322 procedure Set_Entry_Accepted
(Id
: E
; V
: B
:= True) is
3324 pragma Assert
(Is_Entry
(Id
));
3325 Set_Flag152
(Id
, V
);
3326 end Set_Entry_Accepted
;
3328 procedure Set_Entry_Bodies_Array
(Id
: E
; V
: E
) is
3331 end Set_Entry_Bodies_Array
;
3333 procedure Set_Entry_Cancel_Parameter
(Id
: E
; V
: E
) is
3336 end Set_Entry_Cancel_Parameter
;
3338 procedure Set_Entry_Component
(Id
: E
; V
: E
) is
3341 end Set_Entry_Component
;
3343 procedure Set_Entry_Formal
(Id
: E
; V
: E
) is
3346 end Set_Entry_Formal
;
3348 procedure Set_Entry_Index_Constant
(Id
: E
; V
: E
) is
3350 pragma Assert
(Ekind
(Id
) = E_Entry_Index_Parameter
);
3352 end Set_Entry_Index_Constant
;
3354 procedure Set_Entry_Parameters_Type
(Id
: E
; V
: E
) is
3357 end Set_Entry_Parameters_Type
;
3359 procedure Set_Enum_Pos_To_Rep
(Id
: E
; V
: E
) is
3361 pragma Assert
(Ekind
(Id
) = E_Enumeration_Type
);
3363 end Set_Enum_Pos_To_Rep
;
3365 procedure Set_Enumeration_Pos
(Id
: E
; V
: U
) is
3367 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
3369 end Set_Enumeration_Pos
;
3371 procedure Set_Enumeration_Rep
(Id
: E
; V
: U
) is
3373 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
3375 end Set_Enumeration_Rep
;
3377 procedure Set_Enumeration_Rep_Expr
(Id
: E
; V
: N
) is
3379 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
3381 end Set_Enumeration_Rep_Expr
;
3383 procedure Set_Equivalent_Type
(Id
: E
; V
: E
) is
3386 (Ekind
(Id
) = E_Class_Wide_Type
or else
3387 Ekind
(Id
) = E_Class_Wide_Subtype
or else
3388 Ekind
(Id
) = E_Access_Protected_Subprogram_Type
or else
3389 Ekind
(Id
) = E_Anonymous_Access_Protected_Subprogram_Type
or else
3390 Ekind
(Id
) = E_Access_Subprogram_Type
or else
3391 Ekind
(Id
) = E_Exception_Type
);
3393 end Set_Equivalent_Type
;
3395 procedure Set_Esize
(Id
: E
; V
: U
) is
3400 procedure Set_Exception_Code
(Id
: E
; V
: U
) is
3402 pragma Assert
(Ekind
(Id
) = E_Exception
);
3404 end Set_Exception_Code
;
3406 procedure Set_Extra_Accessibility
(Id
: E
; V
: E
) is
3408 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
3410 end Set_Extra_Accessibility
;
3412 procedure Set_Extra_Constrained
(Id
: E
; V
: E
) is
3414 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
3416 end Set_Extra_Constrained
;
3418 procedure Set_Extra_Formal
(Id
: E
; V
: E
) is
3421 end Set_Extra_Formal
;
3423 procedure Set_Extra_Formals
(Id
: E
; V
: E
) is
3426 (Is_Overloadable
(Id
)
3427 or else Ekind
(Id
) = E_Entry_Family
3428 or else Ekind
(Id
) = E_Subprogram_Body
3429 or else Ekind
(Id
) = E_Subprogram_Type
);
3431 end Set_Extra_Formals
;
3433 procedure Set_Can_Use_Internal_Rep
(Id
: E
; V
: B
:= True) is
3436 (Is_Access_Subprogram_Type
(Id
)
3437 and then Id
= Base_Type
(Id
));
3438 Set_Flag229
(Id
, V
);
3439 end Set_Can_Use_Internal_Rep
;
3441 procedure Set_Finalization_Chain_Entity
(Id
: E
; V
: E
) is
3444 end Set_Finalization_Chain_Entity
;
3446 procedure Set_Finalize_Storage_Only
(Id
: E
; V
: B
:= True) is
3448 pragma Assert
(Is_Type
(Id
) and then Id
= Base_Type
(Id
));
3449 Set_Flag158
(Id
, V
);
3450 end Set_Finalize_Storage_Only
;
3452 procedure Set_First_Entity
(Id
: E
; V
: E
) is
3455 end Set_First_Entity
;
3457 procedure Set_First_Index
(Id
: E
; V
: N
) is
3459 pragma Assert
(Is_Array_Type
(Id
) or else Is_String_Type
(Id
));
3461 end Set_First_Index
;
3463 procedure Set_First_Literal
(Id
: E
; V
: E
) is
3465 pragma Assert
(Is_Enumeration_Type
(Id
));
3467 end Set_First_Literal
;
3469 procedure Set_First_Optional_Parameter
(Id
: E
; V
: E
) is
3472 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
3474 end Set_First_Optional_Parameter
;
3476 procedure Set_First_Private_Entity
(Id
: E
; V
: E
) is
3478 pragma Assert
(Ekind
(Id
) = E_Package
3479 or else Ekind
(Id
) = E_Generic_Package
3480 or else Ekind
(Id
) in Concurrent_Kind
);
3482 end Set_First_Private_Entity
;
3484 procedure Set_First_Rep_Item
(Id
: E
; V
: N
) is
3487 end Set_First_Rep_Item
;
3489 procedure Set_Freeze_Node
(Id
: E
; V
: N
) is
3492 end Set_Freeze_Node
;
3494 procedure Set_From_With_Type
(Id
: E
; V
: B
:= True) is
3498 or else Ekind
(Id
) = E_Package
);
3499 Set_Flag159
(Id
, V
);
3500 end Set_From_With_Type
;
3502 procedure Set_Full_View
(Id
: E
; V
: E
) is
3504 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Constant
);
3508 procedure Set_Function_Returns_With_DSP
(Id
: E
; V
: B
:= True) is
3511 (Is_Subprogram
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
3512 Set_Flag169
(Id
, V
);
3513 end Set_Function_Returns_With_DSP
;
3515 procedure Set_Generic_Homonym
(Id
: E
; V
: E
) is
3518 end Set_Generic_Homonym
;
3520 procedure Set_Generic_Renamings
(Id
: E
; V
: L
) is
3522 Set_Elist23
(Id
, V
);
3523 end Set_Generic_Renamings
;
3525 procedure Set_Handler_Records
(Id
: E
; V
: S
) is
3528 end Set_Handler_Records
;
3530 procedure Set_Has_Aliased_Components
(Id
: E
; V
: B
:= True) is
3532 pragma Assert
(Id
= Base_Type
(Id
));
3533 Set_Flag135
(Id
, V
);
3534 end Set_Has_Aliased_Components
;
3536 procedure Set_Has_Alignment_Clause
(Id
: E
; V
: B
:= True) is
3539 end Set_Has_Alignment_Clause
;
3541 procedure Set_Has_All_Calls_Remote
(Id
: E
; V
: B
:= True) is
3544 end Set_Has_All_Calls_Remote
;
3546 procedure Set_Has_Anon_Block_Suffix
(Id
: E
; V
: B
:= True) is
3548 Set_Flag201
(Id
, V
);
3549 end Set_Has_Anon_Block_Suffix
;
3551 procedure Set_Has_Atomic_Components
(Id
: E
; V
: B
:= True) is
3553 pragma Assert
(not Is_Type
(Id
) or else Id
= Base_Type
(Id
));
3555 end Set_Has_Atomic_Components
;
3557 procedure Set_Has_Biased_Representation
(Id
: E
; V
: B
:= True) is
3560 ((V
= False) or else (Is_Discrete_Type
(Id
) or else Is_Object
(Id
)));
3561 Set_Flag139
(Id
, V
);
3562 end Set_Has_Biased_Representation
;
3564 procedure Set_Has_Completion
(Id
: E
; V
: B
:= True) is
3567 end Set_Has_Completion
;
3569 procedure Set_Has_Completion_In_Body
(Id
: E
; V
: B
:= True) is
3571 pragma Assert
(Is_Type
(Id
));
3573 end Set_Has_Completion_In_Body
;
3575 procedure Set_Has_Complex_Representation
(Id
: E
; V
: B
:= True) is
3577 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
3578 Set_Flag140
(Id
, V
);
3579 end Set_Has_Complex_Representation
;
3581 procedure Set_Has_Component_Size_Clause
(Id
: E
; V
: B
:= True) is
3583 pragma Assert
(Ekind
(Id
) = E_Array_Type
);
3585 end Set_Has_Component_Size_Clause
;
3587 procedure Set_Has_Constrained_Partial_View
(Id
: E
; V
: B
:= True) is
3589 pragma Assert
(Is_Type
(Id
));
3590 Set_Flag187
(Id
, V
);
3591 end Set_Has_Constrained_Partial_View
;
3593 procedure Set_Has_Contiguous_Rep
(Id
: E
; V
: B
:= True) is
3595 Set_Flag181
(Id
, V
);
3596 end Set_Has_Contiguous_Rep
;
3598 procedure Set_Has_Controlled_Component
(Id
: E
; V
: B
:= True) is
3600 pragma Assert
(Id
= Base_Type
(Id
));
3602 end Set_Has_Controlled_Component
;
3604 procedure Set_Has_Controlling_Result
(Id
: E
; V
: B
:= True) is
3607 end Set_Has_Controlling_Result
;
3609 procedure Set_Has_Convention_Pragma
(Id
: E
; V
: B
:= True) is
3611 Set_Flag119
(Id
, V
);
3612 end Set_Has_Convention_Pragma
;
3614 procedure Set_Has_Delayed_Freeze
(Id
: E
; V
: B
:= True) is
3616 pragma Assert
(Nkind
(Id
) in N_Entity
);
3618 end Set_Has_Delayed_Freeze
;
3620 procedure Set_Has_Discriminants
(Id
: E
; V
: B
:= True) is
3622 pragma Assert
(Nkind
(Id
) in N_Entity
);
3624 end Set_Has_Discriminants
;
3626 procedure Set_Has_Dispatch_Table
(Id
: E
; V
: B
:= True) is
3628 pragma Assert
(Ekind
(Id
) = E_Record_Type
3629 and then Is_Tagged_Type
(Id
));
3630 Set_Flag220
(Id
, V
);
3631 end Set_Has_Dispatch_Table
;
3633 procedure Set_Has_Enumeration_Rep_Clause
(Id
: E
; V
: B
:= True) is
3635 pragma Assert
(Is_Enumeration_Type
(Id
));
3637 end Set_Has_Enumeration_Rep_Clause
;
3639 procedure Set_Has_Exit
(Id
: E
; V
: B
:= True) is
3644 procedure Set_Has_External_Tag_Rep_Clause
(Id
: E
; V
: B
:= True) is
3646 pragma Assert
(Is_Tagged_Type
(Id
));
3647 Set_Flag110
(Id
, V
);
3648 end Set_Has_External_Tag_Rep_Clause
;
3650 procedure Set_Has_Forward_Instantiation
(Id
: E
; V
: B
:= True) is
3652 Set_Flag175
(Id
, V
);
3653 end Set_Has_Forward_Instantiation
;
3655 procedure Set_Has_Fully_Qualified_Name
(Id
: E
; V
: B
:= True) is
3657 Set_Flag173
(Id
, V
);
3658 end Set_Has_Fully_Qualified_Name
;
3660 procedure Set_Has_Gigi_Rep_Item
(Id
: E
; V
: B
:= True) is
3663 end Set_Has_Gigi_Rep_Item
;
3665 procedure Set_Has_Homonym
(Id
: E
; V
: B
:= True) is
3668 end Set_Has_Homonym
;
3670 procedure Set_Has_Initial_Value
(Id
: E
; V
: B
:= True) is
3673 (Ekind
(Id
) = E_Variable
or else Ekind
(Id
) = E_Out_Parameter
);
3674 Set_Flag219
(Id
, V
);
3675 end Set_Has_Initial_Value
;
3677 procedure Set_Has_Machine_Radix_Clause
(Id
: E
; V
: B
:= True) is
3679 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
3681 end Set_Has_Machine_Radix_Clause
;
3683 procedure Set_Has_Master_Entity
(Id
: E
; V
: B
:= True) is
3686 end Set_Has_Master_Entity
;
3688 procedure Set_Has_Missing_Return
(Id
: E
; V
: B
:= True) is
3691 (Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Generic_Function
);
3692 Set_Flag142
(Id
, V
);
3693 end Set_Has_Missing_Return
;
3695 procedure Set_Has_Nested_Block_With_Handler
(Id
: E
; V
: B
:= True) is
3697 Set_Flag101
(Id
, V
);
3698 end Set_Has_Nested_Block_With_Handler
;
3700 procedure Set_Has_Up_Level_Access
(Id
: E
; V
: B
:= True) is
3703 (Ekind
(Id
) = E_Variable
3704 or else Ekind
(Id
) = E_Constant
3705 or else Ekind
(Id
) = E_Loop_Parameter
);
3706 Set_Flag215
(Id
, V
);
3707 end Set_Has_Up_Level_Access
;
3709 procedure Set_Has_Non_Standard_Rep
(Id
: E
; V
: B
:= True) is
3711 pragma Assert
(Id
= Base_Type
(Id
));
3713 end Set_Has_Non_Standard_Rep
;
3715 procedure Set_Has_Object_Size_Clause
(Id
: E
; V
: B
:= True) is
3717 pragma Assert
(Is_Type
(Id
));
3718 Set_Flag172
(Id
, V
);
3719 end Set_Has_Object_Size_Clause
;
3721 procedure Set_Has_Per_Object_Constraint
(Id
: E
; V
: B
:= True) is
3723 Set_Flag154
(Id
, V
);
3724 end Set_Has_Per_Object_Constraint
;
3726 procedure Set_Has_Persistent_BSS
(Id
: E
; V
: B
:= True) is
3728 Set_Flag188
(Id
, V
);
3729 end Set_Has_Persistent_BSS
;
3731 procedure Set_Has_Postconditions
(Id
: E
; V
: B
:= True) is
3733 pragma Assert
(Is_Subprogram
(Id
));
3734 Set_Flag240
(Id
, V
);
3735 end Set_Has_Postconditions
;
3737 procedure Set_Has_Pragma_Controlled
(Id
: E
; V
: B
:= True) is
3739 pragma Assert
(Is_Access_Type
(Id
));
3740 Set_Flag27
(Base_Type
(Id
), V
);
3741 end Set_Has_Pragma_Controlled
;
3743 procedure Set_Has_Pragma_Elaborate_Body
(Id
: E
; V
: B
:= True) is
3745 Set_Flag150
(Id
, V
);
3746 end Set_Has_Pragma_Elaborate_Body
;
3748 procedure Set_Has_Pragma_Inline
(Id
: E
; V
: B
:= True) is
3750 Set_Flag157
(Id
, V
);
3751 end Set_Has_Pragma_Inline
;
3753 procedure Set_Has_Pragma_Inline_Always
(Id
: E
; V
: B
:= True) is
3755 Set_Flag230
(Id
, V
);
3756 end Set_Has_Pragma_Inline_Always
;
3758 procedure Set_Has_Pragma_Pack
(Id
: E
; V
: B
:= True) is
3760 pragma Assert
(Is_Array_Type
(Id
) or else Is_Record_Type
(Id
));
3761 pragma Assert
(Id
= Base_Type
(Id
));
3762 Set_Flag121
(Id
, V
);
3763 end Set_Has_Pragma_Pack
;
3765 procedure Set_Has_Pragma_Preelab_Init
(Id
: E
; V
: B
:= True) is
3767 Set_Flag221
(Id
, V
);
3768 end Set_Has_Pragma_Preelab_Init
;
3770 procedure Set_Has_Pragma_Pure
(Id
: E
; V
: B
:= True) is
3772 Set_Flag203
(Id
, V
);
3773 end Set_Has_Pragma_Pure
;
3775 procedure Set_Has_Pragma_Pure_Function
(Id
: E
; V
: B
:= True) is
3777 Set_Flag179
(Id
, V
);
3778 end Set_Has_Pragma_Pure_Function
;
3780 procedure Set_Has_Pragma_Unmodified
(Id
: E
; V
: B
:= True) is
3782 Set_Flag233
(Id
, V
);
3783 end Set_Has_Pragma_Unmodified
;
3785 procedure Set_Has_Pragma_Unreferenced
(Id
: E
; V
: B
:= True) is
3787 Set_Flag180
(Id
, V
);
3788 end Set_Has_Pragma_Unreferenced
;
3790 procedure Set_Has_Pragma_Unreferenced_Objects
(Id
: E
; V
: B
:= True) is
3792 pragma Assert
(Is_Type
(Id
));
3793 Set_Flag212
(Id
, V
);
3794 end Set_Has_Pragma_Unreferenced_Objects
;
3796 procedure Set_Has_Primitive_Operations
(Id
: E
; V
: B
:= True) is
3798 pragma Assert
(Id
= Base_Type
(Id
));
3799 Set_Flag120
(Id
, V
);
3800 end Set_Has_Primitive_Operations
;
3802 procedure Set_Has_Private_Declaration
(Id
: E
; V
: B
:= True) is
3804 Set_Flag155
(Id
, V
);
3805 end Set_Has_Private_Declaration
;
3807 procedure Set_Has_Qualified_Name
(Id
: E
; V
: B
:= True) is
3809 Set_Flag161
(Id
, V
);
3810 end Set_Has_Qualified_Name
;
3812 procedure Set_Has_RACW
(Id
: E
; V
: B
:= True) is
3814 pragma Assert
(Ekind
(Id
) = E_Package
);
3815 Set_Flag214
(Id
, V
);
3818 procedure Set_Has_Record_Rep_Clause
(Id
: E
; V
: B
:= True) is
3820 pragma Assert
(Id
= Base_Type
(Id
));
3822 end Set_Has_Record_Rep_Clause
;
3824 procedure Set_Has_Recursive_Call
(Id
: E
; V
: B
:= True) is
3826 pragma Assert
(Is_Subprogram
(Id
));
3827 Set_Flag143
(Id
, V
);
3828 end Set_Has_Recursive_Call
;
3830 procedure Set_Has_Size_Clause
(Id
: E
; V
: B
:= True) is
3833 end Set_Has_Size_Clause
;
3835 procedure Set_Has_Small_Clause
(Id
: E
; V
: B
:= True) is
3838 end Set_Has_Small_Clause
;
3840 procedure Set_Has_Specified_Layout
(Id
: E
; V
: B
:= True) is
3842 pragma Assert
(Id
= Base_Type
(Id
));
3843 Set_Flag100
(Id
, V
);
3844 end Set_Has_Specified_Layout
;
3846 procedure Set_Has_Specified_Stream_Input
(Id
: E
; V
: B
:= True) is
3848 pragma Assert
(Is_Type
(Id
));
3849 Set_Flag190
(Id
, V
);
3850 end Set_Has_Specified_Stream_Input
;
3852 procedure Set_Has_Specified_Stream_Output
(Id
: E
; V
: B
:= True) is
3854 pragma Assert
(Is_Type
(Id
));
3855 Set_Flag191
(Id
, V
);
3856 end Set_Has_Specified_Stream_Output
;
3858 procedure Set_Has_Specified_Stream_Read
(Id
: E
; V
: B
:= True) is
3860 pragma Assert
(Is_Type
(Id
));
3861 Set_Flag192
(Id
, V
);
3862 end Set_Has_Specified_Stream_Read
;
3864 procedure Set_Has_Specified_Stream_Write
(Id
: E
; V
: B
:= True) is
3866 pragma Assert
(Is_Type
(Id
));
3867 Set_Flag193
(Id
, V
);
3868 end Set_Has_Specified_Stream_Write
;
3870 procedure Set_Has_Static_Discriminants
(Id
: E
; V
: B
:= True) is
3872 Set_Flag211
(Id
, V
);
3873 end Set_Has_Static_Discriminants
;
3875 procedure Set_Has_Storage_Size_Clause
(Id
: E
; V
: B
:= True) is
3877 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
3878 pragma Assert
(Id
= Base_Type
(Id
));
3880 end Set_Has_Storage_Size_Clause
;
3882 procedure Set_Has_Stream_Size_Clause
(Id
: E
; V
: B
:= True) is
3884 pragma Assert
(Is_Elementary_Type
(Id
));
3885 Set_Flag184
(Id
, V
);
3886 end Set_Has_Stream_Size_Clause
;
3888 procedure Set_Has_Subprogram_Descriptor
(Id
: E
; V
: B
:= True) is
3891 end Set_Has_Subprogram_Descriptor
;
3893 procedure Set_Has_Task
(Id
: E
; V
: B
:= True) is
3895 pragma Assert
(Id
= Base_Type
(Id
));
3899 procedure Set_Has_Thunks
(Id
: E
; V
: B
:= True) is
3901 pragma Assert
(Is_Tag
(Id
)
3902 and then Ekind
(Id
) = E_Constant
);
3903 Set_Flag228
(Id
, V
);
3906 procedure Set_Has_Unchecked_Union
(Id
: E
; V
: B
:= True) is
3908 pragma Assert
(Id
= Base_Type
(Id
));
3909 Set_Flag123
(Id
, V
);
3910 end Set_Has_Unchecked_Union
;
3912 procedure Set_Has_Unknown_Discriminants
(Id
: E
; V
: B
:= True) is
3914 pragma Assert
(Is_Type
(Id
));
3916 end Set_Has_Unknown_Discriminants
;
3918 procedure Set_Has_Volatile_Components
(Id
: E
; V
: B
:= True) is
3920 pragma Assert
(not Is_Type
(Id
) or else Id
= Base_Type
(Id
));
3922 end Set_Has_Volatile_Components
;
3924 procedure Set_Has_Xref_Entry
(Id
: E
; V
: B
:= True) is
3926 Set_Flag182
(Id
, V
);
3927 end Set_Has_Xref_Entry
;
3929 procedure Set_Hiding_Loop_Variable
(Id
: E
; V
: E
) is
3931 pragma Assert
(Ekind
(Id
) = E_Variable
);
3933 end Set_Hiding_Loop_Variable
;
3935 procedure Set_Homonym
(Id
: E
; V
: E
) is
3937 pragma Assert
(Id
/= V
);
3941 procedure Set_Implemented_By_Entry
(Id
: E
; V
: B
:= True) is
3944 (Ekind
(Id
) = E_Function
3945 or else Ekind
(Id
) = E_Procedure
);
3946 Set_Flag232
(Id
, V
);
3947 end Set_Implemented_By_Entry
;
3949 procedure Set_Interfaces
(Id
: E
; V
: L
) is
3951 pragma Assert
(Is_Record_Type
(Id
));
3952 Set_Elist25
(Id
, V
);
3955 procedure Set_Interface_Alias
(Id
: E
; V
: E
) is
3959 and then Is_Hidden
(Id
)
3960 and then (Ekind
(Id
) = E_Procedure
3961 or else Ekind
(Id
) = E_Function
));
3963 end Set_Interface_Alias
;
3965 procedure Set_In_Package_Body
(Id
: E
; V
: B
:= True) is
3968 end Set_In_Package_Body
;
3970 procedure Set_In_Private_Part
(Id
: E
; V
: B
:= True) is
3973 end Set_In_Private_Part
;
3975 procedure Set_In_Use
(Id
: E
; V
: B
:= True) is
3977 pragma Assert
(Nkind
(Id
) in N_Entity
);
3981 procedure Set_Inner_Instances
(Id
: E
; V
: L
) is
3983 Set_Elist23
(Id
, V
);
3984 end Set_Inner_Instances
;
3986 procedure Set_Interface_Name
(Id
: E
; V
: N
) is
3989 end Set_Interface_Name
;
3991 procedure Set_Is_Abstract_Subprogram
(Id
: E
; V
: B
:= True) is
3993 pragma Assert
(Is_Overloadable
(Id
));
3995 end Set_Is_Abstract_Subprogram
;
3997 procedure Set_Is_Abstract_Type
(Id
: E
; V
: B
:= True) is
3999 pragma Assert
(Is_Type
(Id
));
4000 Set_Flag146
(Id
, V
);
4001 end Set_Is_Abstract_Type
;
4003 procedure Set_Is_Local_Anonymous_Access
(Id
: E
; V
: B
:= True) is
4005 pragma Assert
(Is_Access_Type
(Id
));
4006 Set_Flag194
(Id
, V
);
4007 end Set_Is_Local_Anonymous_Access
;
4009 procedure Set_Is_Access_Constant
(Id
: E
; V
: B
:= True) is
4011 pragma Assert
(Is_Access_Type
(Id
));
4013 end Set_Is_Access_Constant
;
4015 procedure Set_Is_Ada_2005_Only
(Id
: E
; V
: B
:= True) is
4017 Set_Flag185
(Id
, V
);
4018 end Set_Is_Ada_2005_Only
;
4020 procedure Set_Is_Aliased
(Id
: E
; V
: B
:= True) is
4022 pragma Assert
(Nkind
(Id
) in N_Entity
);
4026 procedure Set_Is_AST_Entry
(Id
: E
; V
: B
:= True) is
4028 pragma Assert
(Is_Entry
(Id
));
4029 Set_Flag132
(Id
, V
);
4030 end Set_Is_AST_Entry
;
4032 procedure Set_Is_Asynchronous
(Id
: E
; V
: B
:= True) is
4035 (Ekind
(Id
) = E_Procedure
or else Is_Type
(Id
));
4037 end Set_Is_Asynchronous
;
4039 procedure Set_Is_Atomic
(Id
: E
; V
: B
:= True) is
4044 procedure Set_Is_Bit_Packed_Array
(Id
: E
; V
: B
:= True) is
4046 pragma Assert
((not V
)
4047 or else (Is_Array_Type
(Id
) and then Id
= Base_Type
(Id
)));
4049 Set_Flag122
(Id
, V
);
4050 end Set_Is_Bit_Packed_Array
;
4052 procedure Set_Is_Called
(Id
: E
; V
: B
:= True) is
4055 (Ekind
(Id
) = E_Procedure
or else Ekind
(Id
) = E_Function
);
4056 Set_Flag102
(Id
, V
);
4059 procedure Set_Is_Character_Type
(Id
: E
; V
: B
:= True) is
4062 end Set_Is_Character_Type
;
4064 procedure Set_Is_Child_Unit
(Id
: E
; V
: B
:= True) is
4067 end Set_Is_Child_Unit
;
4069 procedure Set_Is_Class_Wide_Equivalent_Type
(Id
: E
; V
: B
:= True) is
4072 end Set_Is_Class_Wide_Equivalent_Type
;
4074 procedure Set_Is_Compilation_Unit
(Id
: E
; V
: B
:= True) is
4076 Set_Flag149
(Id
, V
);
4077 end Set_Is_Compilation_Unit
;
4079 procedure Set_Is_Completely_Hidden
(Id
: E
; V
: B
:= True) is
4081 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
4082 Set_Flag103
(Id
, V
);
4083 end Set_Is_Completely_Hidden
;
4085 procedure Set_Is_Concurrent_Record_Type
(Id
: E
; V
: B
:= True) is
4088 end Set_Is_Concurrent_Record_Type
;
4090 procedure Set_Is_Constr_Subt_For_U_Nominal
(Id
: E
; V
: B
:= True) is
4093 end Set_Is_Constr_Subt_For_U_Nominal
;
4095 procedure Set_Is_Constr_Subt_For_UN_Aliased
(Id
: E
; V
: B
:= True) is
4097 Set_Flag141
(Id
, V
);
4098 end Set_Is_Constr_Subt_For_UN_Aliased
;
4100 procedure Set_Is_Constrained
(Id
: E
; V
: B
:= True) is
4102 pragma Assert
(Nkind
(Id
) in N_Entity
);
4104 end Set_Is_Constrained
;
4106 procedure Set_Is_Constructor
(Id
: E
; V
: B
:= True) is
4109 end Set_Is_Constructor
;
4111 procedure Set_Is_Controlled
(Id
: E
; V
: B
:= True) is
4113 pragma Assert
(Id
= Base_Type
(Id
));
4115 end Set_Is_Controlled
;
4117 procedure Set_Is_Controlling_Formal
(Id
: E
; V
: B
:= True) is
4119 pragma Assert
(Is_Formal
(Id
));
4121 end Set_Is_Controlling_Formal
;
4123 procedure Set_Is_CPP_Class
(Id
: E
; V
: B
:= True) is
4126 end Set_Is_CPP_Class
;
4128 procedure Set_Is_Descendent_Of_Address
(Id
: E
; V
: B
:= True) is
4130 pragma Assert
(Is_Type
(Id
));
4131 Set_Flag223
(Id
, V
);
4132 end Set_Is_Descendent_Of_Address
;
4134 procedure Set_Is_Discrim_SO_Function
(Id
: E
; V
: B
:= True) is
4136 Set_Flag176
(Id
, V
);
4137 end Set_Is_Discrim_SO_Function
;
4139 procedure Set_Is_Dispatch_Table_Entity
(Id
: E
; V
: B
:= True) is
4141 Set_Flag234
(Id
, V
);
4142 end Set_Is_Dispatch_Table_Entity
;
4144 procedure Set_Is_Dispatching_Operation
(Id
: E
; V
: B
:= True) is
4149 Is_Overloadable
(Id
)
4151 Ekind
(Id
) = E_Subprogram_Type
);
4154 end Set_Is_Dispatching_Operation
;
4156 procedure Set_Is_Eliminated
(Id
: E
; V
: B
:= True) is
4158 Set_Flag124
(Id
, V
);
4159 end Set_Is_Eliminated
;
4161 procedure Set_Is_Entry_Formal
(Id
: E
; V
: B
:= True) is
4164 end Set_Is_Entry_Formal
;
4166 procedure Set_Is_Exported
(Id
: E
; V
: B
:= True) is
4169 end Set_Is_Exported
;
4171 procedure Set_Is_First_Subtype
(Id
: E
; V
: B
:= True) is
4174 end Set_Is_First_Subtype
;
4176 procedure Set_Is_For_Access_Subtype
(Id
: E
; V
: B
:= True) is
4179 (Ekind
(Id
) = E_Record_Subtype
4181 Ekind
(Id
) = E_Private_Subtype
);
4182 Set_Flag118
(Id
, V
);
4183 end Set_Is_For_Access_Subtype
;
4185 procedure Set_Is_Formal_Subprogram
(Id
: E
; V
: B
:= True) is
4187 Set_Flag111
(Id
, V
);
4188 end Set_Is_Formal_Subprogram
;
4190 procedure Set_Is_Frozen
(Id
: E
; V
: B
:= True) is
4192 pragma Assert
(Nkind
(Id
) in N_Entity
);
4196 procedure Set_Is_Generic_Actual_Type
(Id
: E
; V
: B
:= True) is
4198 pragma Assert
(Is_Type
(Id
));
4200 end Set_Is_Generic_Actual_Type
;
4202 procedure Set_Is_Generic_Instance
(Id
: E
; V
: B
:= True) is
4204 Set_Flag130
(Id
, V
);
4205 end Set_Is_Generic_Instance
;
4207 procedure Set_Is_Generic_Type
(Id
: E
; V
: B
:= True) is
4209 pragma Assert
(Nkind
(Id
) in N_Entity
);
4211 end Set_Is_Generic_Type
;
4213 procedure Set_Is_Hidden
(Id
: E
; V
: B
:= True) is
4218 procedure Set_Is_Hidden_Open_Scope
(Id
: E
; V
: B
:= True) is
4220 Set_Flag171
(Id
, V
);
4221 end Set_Is_Hidden_Open_Scope
;
4223 procedure Set_Is_Immediately_Visible
(Id
: E
; V
: B
:= True) is
4225 pragma Assert
(Nkind
(Id
) in N_Entity
);
4227 end Set_Is_Immediately_Visible
;
4229 procedure Set_Is_Imported
(Id
: E
; V
: B
:= True) is
4232 end Set_Is_Imported
;
4234 procedure Set_Is_Inlined
(Id
: E
; V
: B
:= True) is
4239 procedure Set_Is_Interface
(Id
: E
; V
: B
:= True) is
4242 (Ekind
(Id
) = E_Record_Type
4243 or else Ekind
(Id
) = E_Record_Subtype
4244 or else Ekind
(Id
) = E_Record_Type_With_Private
4245 or else Ekind
(Id
) = E_Record_Subtype_With_Private
4246 or else Ekind
(Id
) = E_Class_Wide_Type
4247 or else Ekind
(Id
) = E_Class_Wide_Subtype
);
4248 Set_Flag186
(Id
, V
);
4249 end Set_Is_Interface
;
4251 procedure Set_Is_Instantiated
(Id
: E
; V
: B
:= True) is
4253 Set_Flag126
(Id
, V
);
4254 end Set_Is_Instantiated
;
4256 procedure Set_Is_Internal
(Id
: E
; V
: B
:= True) is
4258 pragma Assert
(Nkind
(Id
) in N_Entity
);
4260 end Set_Is_Internal
;
4262 procedure Set_Is_Interrupt_Handler
(Id
: E
; V
: B
:= True) is
4264 pragma Assert
(Nkind
(Id
) in N_Entity
);
4266 end Set_Is_Interrupt_Handler
;
4268 procedure Set_Is_Intrinsic_Subprogram
(Id
: E
; V
: B
:= True) is
4271 end Set_Is_Intrinsic_Subprogram
;
4273 procedure Set_Is_Itype
(Id
: E
; V
: B
:= True) is
4278 procedure Set_Is_Known_Non_Null
(Id
: E
; V
: B
:= True) is
4281 end Set_Is_Known_Non_Null
;
4283 procedure Set_Is_Known_Null
(Id
: E
; V
: B
:= True) is
4285 Set_Flag204
(Id
, V
);
4286 end Set_Is_Known_Null
;
4288 procedure Set_Is_Known_Valid
(Id
: E
; V
: B
:= True) is
4290 Set_Flag170
(Id
, V
);
4291 end Set_Is_Known_Valid
;
4293 procedure Set_Is_Limited_Composite
(Id
: E
; V
: B
:= True) is
4295 pragma Assert
(Is_Type
(Id
));
4296 Set_Flag106
(Id
, V
);
4297 end Set_Is_Limited_Composite
;
4299 procedure Set_Is_Limited_Interface
(Id
: E
; V
: B
:= True) is
4301 pragma Assert
(Is_Interface
(Id
));
4302 Set_Flag197
(Id
, V
);
4303 end Set_Is_Limited_Interface
;
4305 procedure Set_Is_Limited_Record
(Id
: E
; V
: B
:= True) is
4308 end Set_Is_Limited_Record
;
4310 procedure Set_Is_Machine_Code_Subprogram
(Id
: E
; V
: B
:= True) is
4312 pragma Assert
(Is_Subprogram
(Id
));
4313 Set_Flag137
(Id
, V
);
4314 end Set_Is_Machine_Code_Subprogram
;
4316 procedure Set_Is_Non_Static_Subtype
(Id
: E
; V
: B
:= True) is
4318 pragma Assert
(Is_Type
(Id
));
4319 Set_Flag109
(Id
, V
);
4320 end Set_Is_Non_Static_Subtype
;
4322 procedure Set_Is_Null_Init_Proc
(Id
: E
; V
: B
:= True) is
4324 pragma Assert
(Ekind
(Id
) = E_Procedure
);
4325 Set_Flag178
(Id
, V
);
4326 end Set_Is_Null_Init_Proc
;
4328 procedure Set_Is_Obsolescent
(Id
: E
; V
: B
:= True) is
4330 Set_Flag153
(Id
, V
);
4331 end Set_Is_Obsolescent
;
4333 procedure Set_Is_Only_Out_Parameter
(Id
: E
; V
: B
:= True) is
4335 pragma Assert
(Ekind
(Id
) = E_Out_Parameter
);
4336 Set_Flag226
(Id
, V
);
4337 end Set_Is_Only_Out_Parameter
;
4339 procedure Set_Is_Optional_Parameter
(Id
: E
; V
: B
:= True) is
4341 pragma Assert
(Is_Formal
(Id
));
4342 Set_Flag134
(Id
, V
);
4343 end Set_Is_Optional_Parameter
;
4345 procedure Set_Is_Overriding_Operation
(Id
: E
; V
: B
:= True) is
4347 pragma Assert
(Is_Subprogram
(Id
));
4349 end Set_Is_Overriding_Operation
;
4351 procedure Set_Is_Package_Body_Entity
(Id
: E
; V
: B
:= True) is
4353 Set_Flag160
(Id
, V
);
4354 end Set_Is_Package_Body_Entity
;
4356 procedure Set_Is_Packed
(Id
: E
; V
: B
:= True) is
4358 pragma Assert
(Id
= Base_Type
(Id
));
4362 procedure Set_Is_Packed_Array_Type
(Id
: E
; V
: B
:= True) is
4364 Set_Flag138
(Id
, V
);
4365 end Set_Is_Packed_Array_Type
;
4367 procedure Set_Is_Potentially_Use_Visible
(Id
: E
; V
: B
:= True) is
4369 pragma Assert
(Nkind
(Id
) in N_Entity
);
4371 end Set_Is_Potentially_Use_Visible
;
4373 procedure Set_Is_Preelaborated
(Id
: E
; V
: B
:= True) is
4376 end Set_Is_Preelaborated
;
4378 procedure Set_Is_Primitive
(Id
: E
; V
: B
:= True) is
4381 (Is_Overloadable
(Id
)
4382 or else Ekind
(Id
) = E_Generic_Function
4383 or else Ekind
(Id
) = E_Generic_Procedure
);
4384 Set_Flag218
(Id
, V
);
4385 end Set_Is_Primitive
;
4387 procedure Set_Is_Primitive_Wrapper
(Id
: E
; V
: B
:= True) is
4389 pragma Assert
(Ekind
(Id
) = E_Procedure
);
4390 Set_Flag195
(Id
, V
);
4391 end Set_Is_Primitive_Wrapper
;
4393 procedure Set_Is_Private_Composite
(Id
: E
; V
: B
:= True) is
4395 pragma Assert
(Is_Type
(Id
));
4396 Set_Flag107
(Id
, V
);
4397 end Set_Is_Private_Composite
;
4399 procedure Set_Is_Private_Descendant
(Id
: E
; V
: B
:= True) is
4402 end Set_Is_Private_Descendant
;
4404 procedure Set_Is_Protected_Interface
(Id
: E
; V
: B
:= True) is
4406 pragma Assert
(Is_Interface
(Id
));
4407 Set_Flag198
(Id
, V
);
4408 end Set_Is_Protected_Interface
;
4410 procedure Set_Is_Public
(Id
: E
; V
: B
:= True) is
4412 pragma Assert
(Nkind
(Id
) in N_Entity
);
4416 procedure Set_Is_Pure
(Id
: E
; V
: B
:= True) is
4421 procedure Set_Is_Pure_Unit_Access_Type
(Id
: E
; V
: B
:= True) is
4423 pragma Assert
(Is_Access_Type
(Id
));
4424 Set_Flag189
(Id
, V
);
4425 end Set_Is_Pure_Unit_Access_Type
;
4427 procedure Set_Is_RACW_Stub_Type
(Id
: E
; V
: B
:= True) is
4429 pragma Assert
(Is_Type
(Id
));
4430 Set_Flag244
(Id
, V
);
4431 end Set_Is_RACW_Stub_Type
;
4433 procedure Set_Is_Raised
(Id
: E
; V
: B
:= True) is
4435 pragma Assert
(Ekind
(Id
) = E_Exception
);
4436 Set_Flag224
(Id
, V
);
4439 procedure Set_Is_Remote_Call_Interface
(Id
: E
; V
: B
:= True) is
4442 end Set_Is_Remote_Call_Interface
;
4444 procedure Set_Is_Remote_Types
(Id
: E
; V
: B
:= True) is
4447 end Set_Is_Remote_Types
;
4449 procedure Set_Is_Renaming_Of_Object
(Id
: E
; V
: B
:= True) is
4451 Set_Flag112
(Id
, V
);
4452 end Set_Is_Renaming_Of_Object
;
4454 procedure Set_Is_Return_Object
(Id
: E
; V
: B
:= True) is
4456 Set_Flag209
(Id
, V
);
4457 end Set_Is_Return_Object
;
4459 procedure Set_Is_Shared_Passive
(Id
: E
; V
: B
:= True) is
4462 end Set_Is_Shared_Passive
;
4464 procedure Set_Is_Statically_Allocated
(Id
: E
; V
: B
:= True) is
4467 (Ekind
(Id
) = E_Exception
4468 or else Ekind
(Id
) = E_Variable
4469 or else Ekind
(Id
) = E_Constant
4470 or else Is_Type
(Id
)
4471 or else Ekind
(Id
) = E_Void
);
4473 end Set_Is_Statically_Allocated
;
4475 procedure Set_Is_Synchronized_Interface
(Id
: E
; V
: B
:= True) is
4477 pragma Assert
(Is_Interface
(Id
));
4478 Set_Flag199
(Id
, V
);
4479 end Set_Is_Synchronized_Interface
;
4481 procedure Set_Is_Tag
(Id
: E
; V
: B
:= True) is
4484 (Ekind
(Id
) = E_Component
4485 or else Ekind
(Id
) = E_Constant
);
4489 procedure Set_Is_Tagged_Type
(Id
: E
; V
: B
:= True) is
4492 end Set_Is_Tagged_Type
;
4494 procedure Set_Is_Task_Interface
(Id
: E
; V
: B
:= True) is
4496 pragma Assert
(Is_Interface
(Id
));
4497 Set_Flag200
(Id
, V
);
4498 end Set_Is_Task_Interface
;
4500 procedure Set_Is_Thunk
(Id
: E
; V
: B
:= True) is
4502 Set_Flag225
(Id
, V
);
4505 procedure Set_Is_Trivial_Subprogram
(Id
: E
; V
: B
:= True) is
4507 Set_Flag235
(Id
, V
);
4508 end Set_Is_Trivial_Subprogram
;
4510 procedure Set_Is_True_Constant
(Id
: E
; V
: B
:= True) is
4512 Set_Flag163
(Id
, V
);
4513 end Set_Is_True_Constant
;
4515 procedure Set_Is_Unchecked_Union
(Id
: E
; V
: B
:= True) is
4517 pragma Assert
(Id
= Base_Type
(Id
));
4518 Set_Flag117
(Id
, V
);
4519 end Set_Is_Unchecked_Union
;
4521 procedure Set_Is_Unsigned_Type
(Id
: E
; V
: B
:= True) is
4523 pragma Assert
(Is_Discrete_Or_Fixed_Point_Type
(Id
));
4524 Set_Flag144
(Id
, V
);
4525 end Set_Is_Unsigned_Type
;
4527 procedure Set_Is_Valued_Procedure
(Id
: E
; V
: B
:= True) is
4529 pragma Assert
(Ekind
(Id
) = E_Procedure
);
4530 Set_Flag127
(Id
, V
);
4531 end Set_Is_Valued_Procedure
;
4533 procedure Set_Is_Visible_Child_Unit
(Id
: E
; V
: B
:= True) is
4535 pragma Assert
(Is_Child_Unit
(Id
));
4536 Set_Flag116
(Id
, V
);
4537 end Set_Is_Visible_Child_Unit
;
4539 procedure Set_Is_Visible_Formal
(Id
: E
; V
: B
:= True) is
4541 Set_Flag206
(Id
, V
);
4542 end Set_Is_Visible_Formal
;
4544 procedure Set_Is_VMS_Exception
(Id
: E
; V
: B
:= True) is
4546 pragma Assert
(Ekind
(Id
) = E_Exception
);
4547 Set_Flag133
(Id
, V
);
4548 end Set_Is_VMS_Exception
;
4550 procedure Set_Is_Volatile
(Id
: E
; V
: B
:= True) is
4552 pragma Assert
(Nkind
(Id
) in N_Entity
);
4554 end Set_Is_Volatile
;
4556 procedure Set_Itype_Printed
(Id
: E
; V
: B
:= True) is
4558 pragma Assert
(Is_Itype
(Id
));
4559 Set_Flag202
(Id
, V
);
4560 end Set_Itype_Printed
;
4562 procedure Set_Kill_Elaboration_Checks
(Id
: E
; V
: B
:= True) is
4565 end Set_Kill_Elaboration_Checks
;
4567 procedure Set_Kill_Range_Checks
(Id
: E
; V
: B
:= True) is
4570 end Set_Kill_Range_Checks
;
4572 procedure Set_Kill_Tag_Checks
(Id
: E
; V
: B
:= True) is
4575 end Set_Kill_Tag_Checks
;
4577 procedure Set_Known_To_Have_Preelab_Init
(Id
: E
; V
: B
:= True) is
4579 pragma Assert
(Is_Type
(Id
));
4580 Set_Flag207
(Id
, V
);
4581 end Set_Known_To_Have_Preelab_Init
;
4583 procedure Set_Last_Assignment
(Id
: E
; V
: N
) is
4585 pragma Assert
(Is_Assignable
(Id
));
4587 end Set_Last_Assignment
;
4589 procedure Set_Last_Entity
(Id
: E
; V
: E
) is
4592 end Set_Last_Entity
;
4594 procedure Set_Limited_View
(Id
: E
; V
: E
) is
4596 pragma Assert
(Ekind
(Id
) = E_Package
);
4598 end Set_Limited_View
;
4600 procedure Set_Lit_Indexes
(Id
: E
; V
: E
) is
4602 pragma Assert
(Is_Enumeration_Type
(Id
) and then Root_Type
(Id
) = Id
);
4604 end Set_Lit_Indexes
;
4606 procedure Set_Lit_Strings
(Id
: E
; V
: E
) is
4608 pragma Assert
(Is_Enumeration_Type
(Id
) and then Root_Type
(Id
) = Id
);
4610 end Set_Lit_Strings
;
4612 procedure Set_Low_Bound_Known
(Id
: E
; V
: B
:= True) is
4614 pragma Assert
(Is_Formal
(Id
));
4615 Set_Flag205
(Id
, V
);
4616 end Set_Low_Bound_Known
;
4618 procedure Set_Machine_Radix_10
(Id
: E
; V
: B
:= True) is
4620 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
4622 end Set_Machine_Radix_10
;
4624 procedure Set_Master_Id
(Id
: E
; V
: E
) is
4626 pragma Assert
(Is_Access_Type
(Id
));
4630 procedure Set_Materialize_Entity
(Id
: E
; V
: B
:= True) is
4632 Set_Flag168
(Id
, V
);
4633 end Set_Materialize_Entity
;
4635 procedure Set_Mechanism
(Id
: E
; V
: M
) is
4637 pragma Assert
(Ekind
(Id
) = E_Function
or else Is_Formal
(Id
));
4638 Set_Uint8
(Id
, UI_From_Int
(V
));
4641 procedure Set_Modulus
(Id
: E
; V
: U
) is
4643 pragma Assert
(Ekind
(Id
) = E_Modular_Integer_Type
);
4647 procedure Set_Must_Be_On_Byte_Boundary
(Id
: E
; V
: B
:= True) is
4649 pragma Assert
(Is_Type
(Id
));
4650 Set_Flag183
(Id
, V
);
4651 end Set_Must_Be_On_Byte_Boundary
;
4653 procedure Set_Must_Have_Preelab_Init
(Id
: E
; V
: B
:= True) is
4655 pragma Assert
(Is_Type
(Id
));
4656 Set_Flag208
(Id
, V
);
4657 end Set_Must_Have_Preelab_Init
;
4659 procedure Set_Needs_Debug_Info
(Id
: E
; V
: B
:= True) is
4661 Set_Flag147
(Id
, V
);
4662 end Set_Needs_Debug_Info
;
4664 procedure Set_Needs_No_Actuals
(Id
: E
; V
: B
:= True) is
4667 (Is_Overloadable
(Id
)
4668 or else Ekind
(Id
) = E_Subprogram_Type
4669 or else Ekind
(Id
) = E_Entry_Family
);
4671 end Set_Needs_No_Actuals
;
4673 procedure Set_Never_Set_In_Source
(Id
: E
; V
: B
:= True) is
4675 Set_Flag115
(Id
, V
);
4676 end Set_Never_Set_In_Source
;
4678 procedure Set_Next_Inlined_Subprogram
(Id
: E
; V
: E
) is
4681 end Set_Next_Inlined_Subprogram
;
4683 procedure Set_No_Pool_Assigned
(Id
: E
; V
: B
:= True) is
4685 pragma Assert
(Is_Access_Type
(Id
) and then Id
= Base_Type
(Id
));
4686 Set_Flag131
(Id
, V
);
4687 end Set_No_Pool_Assigned
;
4689 procedure Set_No_Return
(Id
: E
; V
: B
:= True) is
4693 or else Ekind
(Id
) = E_Procedure
4694 or else Ekind
(Id
) = E_Generic_Procedure
);
4695 Set_Flag113
(Id
, V
);
4698 procedure Set_No_Strict_Aliasing
(Id
: E
; V
: B
:= True) is
4700 pragma Assert
(Is_Access_Type
(Id
) and then Id
= Base_Type
(Id
));
4701 Set_Flag136
(Id
, V
);
4702 end Set_No_Strict_Aliasing
;
4704 procedure Set_Non_Binary_Modulus
(Id
: E
; V
: B
:= True) is
4706 pragma Assert
(Is_Type
(Id
) and then Id
= Base_Type
(Id
));
4708 end Set_Non_Binary_Modulus
;
4710 procedure Set_Non_Limited_View
(Id
: E
; V
: E
) is
4712 pragma Assert
(Ekind
(Id
) in Incomplete_Kind
);
4714 end Set_Non_Limited_View
;
4716 procedure Set_Nonzero_Is_True
(Id
: E
; V
: B
:= True) is
4719 (Root_Type
(Id
) = Standard_Boolean
4720 and then Ekind
(Id
) = E_Enumeration_Type
);
4721 Set_Flag162
(Id
, V
);
4722 end Set_Nonzero_Is_True
;
4724 procedure Set_Normalized_First_Bit
(Id
: E
; V
: U
) is
4727 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
4729 end Set_Normalized_First_Bit
;
4731 procedure Set_Normalized_Position
(Id
: E
; V
: U
) is
4734 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
4736 end Set_Normalized_Position
;
4738 procedure Set_Normalized_Position_Max
(Id
: E
; V
: U
) is
4741 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Discriminant
);
4743 end Set_Normalized_Position_Max
;
4745 procedure Set_OK_To_Reorder_Components
(Id
: E
; V
: B
:= True) is
4748 (Is_Record_Type
(Id
) and then Id
= Base_Type
(Id
));
4749 Set_Flag239
(Id
, V
);
4750 end Set_OK_To_Reorder_Components
;
4752 procedure Set_Optimize_Alignment_Space
(Id
: E
; V
: B
:= True) is
4756 or else Ekind
(Id
) = E_Constant
4757 or else Ekind
(Id
) = E_Variable
);
4758 Set_Flag241
(Id
, V
);
4759 end Set_Optimize_Alignment_Space
;
4761 procedure Set_Optimize_Alignment_Time
(Id
: E
; V
: B
:= True) is
4765 or else Ekind
(Id
) = E_Constant
4766 or else Ekind
(Id
) = E_Variable
);
4767 Set_Flag242
(Id
, V
);
4768 end Set_Optimize_Alignment_Time
;
4770 procedure Set_Original_Array_Type
(Id
: E
; V
: E
) is
4772 pragma Assert
(Is_Array_Type
(Id
) or else Is_Modular_Integer_Type
(Id
));
4774 end Set_Original_Array_Type
;
4776 procedure Set_Original_Record_Component
(Id
: E
; V
: E
) is
4779 (Ekind
(Id
) = E_Void
4780 or else Ekind
(Id
) = E_Component
4781 or else Ekind
(Id
) = E_Discriminant
);
4783 end Set_Original_Record_Component
;
4785 procedure Set_Overlays_Constant
(Id
: E
; V
: B
:= True) is
4787 Set_Flag243
(Id
, V
);
4788 end Set_Overlays_Constant
;
4790 procedure Set_Overridden_Operation
(Id
: E
; V
: E
) is
4793 end Set_Overridden_Operation
;
4795 procedure Set_Package_Instantiation
(Id
: E
; V
: N
) is
4798 (Ekind
(Id
) = E_Void
4799 or else Ekind
(Id
) = E_Generic_Package
4800 or else Ekind
(Id
) = E_Package
);
4802 end Set_Package_Instantiation
;
4804 procedure Set_Packed_Array_Type
(Id
: E
; V
: E
) is
4806 pragma Assert
(Is_Array_Type
(Id
));
4808 end Set_Packed_Array_Type
;
4810 procedure Set_Parent_Subtype
(Id
: E
; V
: E
) is
4812 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
4814 end Set_Parent_Subtype
;
4816 procedure Set_Primitive_Operations
(Id
: E
; V
: L
) is
4818 pragma Assert
(Is_Tagged_Type
(Id
));
4819 Set_Elist15
(Id
, V
);
4820 end Set_Primitive_Operations
;
4822 procedure Set_Prival
(Id
: E
; V
: E
) is
4824 pragma Assert
(Is_Protected_Component
(Id
));
4828 procedure Set_Prival_Link
(Id
: E
; V
: E
) is
4830 pragma Assert
(Ekind
(Id
) = E_Constant
4831 or else Ekind
(Id
) = E_Variable
);
4833 end Set_Prival_Link
;
4835 procedure Set_Private_Dependents
(Id
: E
; V
: L
) is
4837 pragma Assert
(Is_Incomplete_Or_Private_Type
(Id
));
4838 Set_Elist18
(Id
, V
);
4839 end Set_Private_Dependents
;
4841 procedure Set_Private_View
(Id
: E
; V
: N
) is
4843 pragma Assert
(Is_Private_Type
(Id
));
4845 end Set_Private_View
;
4847 procedure Set_Protected_Body_Subprogram
(Id
: E
; V
: E
) is
4849 pragma Assert
(Is_Subprogram
(Id
) or else Is_Entry
(Id
));
4851 end Set_Protected_Body_Subprogram
;
4853 procedure Set_Protected_Formal
(Id
: E
; V
: E
) is
4855 pragma Assert
(Is_Formal
(Id
));
4857 end Set_Protected_Formal
;
4859 procedure Set_Protection_Object
(Id
: E
; V
: E
) is
4861 pragma Assert
(Ekind
(Id
) = E_Entry
4862 or else Ekind
(Id
) = E_Entry_Family
4863 or else Ekind
(Id
) = E_Function
4864 or else Ekind
(Id
) = E_Procedure
);
4866 end Set_Protection_Object
;
4868 procedure Set_Reachable
(Id
: E
; V
: B
:= True) is
4873 procedure Set_Referenced
(Id
: E
; V
: B
:= True) is
4875 Set_Flag156
(Id
, V
);
4878 procedure Set_Referenced_As_LHS
(Id
: E
; V
: B
:= True) is
4881 end Set_Referenced_As_LHS
;
4883 procedure Set_Referenced_As_Out_Parameter
(Id
: E
; V
: B
:= True) is
4885 Set_Flag227
(Id
, V
);
4886 end Set_Referenced_As_Out_Parameter
;
4888 procedure Set_Referenced_Object
(Id
: E
; V
: N
) is
4890 pragma Assert
(Is_Type
(Id
));
4892 end Set_Referenced_Object
;
4894 procedure Set_Register_Exception_Call
(Id
: E
; V
: N
) is
4896 pragma Assert
(Ekind
(Id
) = E_Exception
);
4898 end Set_Register_Exception_Call
;
4900 procedure Set_Related_Array_Object
(Id
: E
; V
: E
) is
4902 pragma Assert
(Is_Array_Type
(Id
));
4904 end Set_Related_Array_Object
;
4906 procedure Set_Related_Instance
(Id
: E
; V
: E
) is
4909 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Package_Body
);
4911 end Set_Related_Instance
;
4913 procedure Set_Related_Type
(Id
: E
; V
: E
) is
4916 (Ekind
(Id
) = E_Component
or else Ekind
(Id
) = E_Constant
);
4918 end Set_Related_Type
;
4920 procedure Set_Relative_Deadline_Variable
(Id
: E
; V
: E
) is
4922 pragma Assert
(Is_Task_Type
(Id
) and then Id
= Base_Type
(Id
));
4924 end Set_Relative_Deadline_Variable
;
4926 procedure Set_Renamed_Entity
(Id
: E
; V
: N
) is
4929 end Set_Renamed_Entity
;
4931 procedure Set_Renamed_In_Spec
(Id
: E
; V
: B
:= True) is
4933 pragma Assert
(Ekind
(Id
) = E_Package
);
4934 Set_Flag231
(Id
, V
);
4935 end Set_Renamed_In_Spec
;
4937 procedure Set_Renamed_Object
(Id
: E
; V
: N
) is
4940 end Set_Renamed_Object
;
4942 procedure Set_Renaming_Map
(Id
: E
; V
: U
) is
4945 end Set_Renaming_Map
;
4947 procedure Set_Requires_Overriding
(Id
: E
; V
: B
:= True) is
4949 pragma Assert
(Is_Overloadable
(Id
));
4950 Set_Flag213
(Id
, V
);
4951 end Set_Requires_Overriding
;
4953 procedure Set_Return_Present
(Id
: E
; V
: B
:= True) is
4956 end Set_Return_Present
;
4958 procedure Set_Return_Applies_To
(Id
: E
; V
: N
) is
4961 end Set_Return_Applies_To
;
4963 procedure Set_Returns_By_Ref
(Id
: E
; V
: B
:= True) is
4966 end Set_Returns_By_Ref
;
4968 procedure Set_Reverse_Bit_Order
(Id
: E
; V
: B
:= True) is
4971 (Is_Record_Type
(Id
) and then Id
= Base_Type
(Id
));
4972 Set_Flag164
(Id
, V
);
4973 end Set_Reverse_Bit_Order
;
4975 procedure Set_RM_Size
(Id
: E
; V
: U
) is
4977 pragma Assert
(Is_Type
(Id
));
4981 procedure Set_Scalar_Range
(Id
: E
; V
: N
) is
4984 end Set_Scalar_Range
;
4986 procedure Set_Scale_Value
(Id
: E
; V
: U
) is
4989 end Set_Scale_Value
;
4991 procedure Set_Scope_Depth_Value
(Id
: E
; V
: U
) is
4993 pragma Assert
(not Is_Record_Type
(Id
));
4995 end Set_Scope_Depth_Value
;
4997 procedure Set_Sec_Stack_Needed_For_Return
(Id
: E
; V
: B
:= True) is
4999 Set_Flag167
(Id
, V
);
5000 end Set_Sec_Stack_Needed_For_Return
;
5002 procedure Set_Shadow_Entities
(Id
: E
; V
: S
) is
5005 (Ekind
(Id
) = E_Package
or else Ekind
(Id
) = E_Generic_Package
);
5007 end Set_Shadow_Entities
;
5009 procedure Set_Shared_Var_Procs_Instance
(Id
: E
; V
: E
) is
5011 pragma Assert
(Ekind
(Id
) = E_Variable
);
5013 end Set_Shared_Var_Procs_Instance
;
5015 procedure Set_Size_Check_Code
(Id
: E
; V
: N
) is
5017 pragma Assert
(Ekind
(Id
) = E_Constant
or else Ekind
(Id
) = E_Variable
);
5019 end Set_Size_Check_Code
;
5021 procedure Set_Size_Depends_On_Discriminant
(Id
: E
; V
: B
:= True) is
5023 Set_Flag177
(Id
, V
);
5024 end Set_Size_Depends_On_Discriminant
;
5026 procedure Set_Size_Known_At_Compile_Time
(Id
: E
; V
: B
:= True) is
5029 end Set_Size_Known_At_Compile_Time
;
5031 procedure Set_Small_Value
(Id
: E
; V
: R
) is
5033 pragma Assert
(Is_Fixed_Point_Type
(Id
));
5034 Set_Ureal21
(Id
, V
);
5035 end Set_Small_Value
;
5037 procedure Set_Spec_Entity
(Id
: E
; V
: E
) is
5039 pragma Assert
(Ekind
(Id
) = E_Package_Body
or else Is_Formal
(Id
));
5041 end Set_Spec_Entity
;
5043 procedure Set_Spec_PPC_List
(Id
: E
; V
: N
) is
5045 pragma Assert
(Is_Subprogram
(Id
));
5047 end Set_Spec_PPC_List
;
5049 procedure Set_Storage_Size_Variable
(Id
: E
; V
: E
) is
5051 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
5052 pragma Assert
(Id
= Base_Type
(Id
));
5054 end Set_Storage_Size_Variable
;
5056 procedure Set_Static_Elaboration_Desired
(Id
: E
; V
: B
) is
5058 pragma Assert
(Ekind
(Id
) = E_Package
);
5060 end Set_Static_Elaboration_Desired
;
5062 procedure Set_Static_Initialization
(Id
: E
; V
: N
) is
5065 (Ekind
(Id
) = E_Procedure
and then not Is_Dispatching_Operation
(Id
));
5067 end Set_Static_Initialization
;
5069 procedure Set_Stored_Constraint
(Id
: E
; V
: L
) is
5071 pragma Assert
(Nkind
(Id
) in N_Entity
);
5072 Set_Elist23
(Id
, V
);
5073 end Set_Stored_Constraint
;
5075 procedure Set_Strict_Alignment
(Id
: E
; V
: B
:= True) is
5077 pragma Assert
(Id
= Base_Type
(Id
));
5078 Set_Flag145
(Id
, V
);
5079 end Set_Strict_Alignment
;
5081 procedure Set_String_Literal_Length
(Id
: E
; V
: U
) is
5083 pragma Assert
(Ekind
(Id
) = E_String_Literal_Subtype
);
5085 end Set_String_Literal_Length
;
5087 procedure Set_String_Literal_Low_Bound
(Id
: E
; V
: N
) is
5089 pragma Assert
(Ekind
(Id
) = E_String_Literal_Subtype
);
5091 end Set_String_Literal_Low_Bound
;
5093 procedure Set_Suppress_Elaboration_Warnings
(Id
: E
; V
: B
:= True) is
5095 Set_Flag148
(Id
, V
);
5096 end Set_Suppress_Elaboration_Warnings
;
5098 procedure Set_Suppress_Init_Proc
(Id
: E
; V
: B
:= True) is
5100 pragma Assert
(Id
= Base_Type
(Id
));
5101 Set_Flag105
(Id
, V
);
5102 end Set_Suppress_Init_Proc
;
5104 procedure Set_Suppress_Style_Checks
(Id
: E
; V
: B
:= True) is
5106 Set_Flag165
(Id
, V
);
5107 end Set_Suppress_Style_Checks
;
5109 procedure Set_Suppress_Value_Tracking_On_Call
(Id
: E
; V
: B
:= True) is
5111 Set_Flag217
(Id
, V
);
5112 end Set_Suppress_Value_Tracking_On_Call
;
5114 procedure Set_Task_Body_Procedure
(Id
: E
; V
: N
) is
5116 pragma Assert
(Ekind
(Id
) in Task_Kind
);
5118 end Set_Task_Body_Procedure
;
5120 procedure Set_Treat_As_Volatile
(Id
: E
; V
: B
:= True) is
5123 end Set_Treat_As_Volatile
;
5125 procedure Set_Underlying_Full_View
(Id
: E
; V
: E
) is
5127 pragma Assert
(Ekind
(Id
) in Private_Kind
);
5129 end Set_Underlying_Full_View
;
5131 procedure Set_Universal_Aliasing
(Id
: E
; V
: B
:= True) is
5133 pragma Assert
(Is_Type
(Id
) and then Id
= Base_Type
(Id
));
5134 Set_Flag216
(Id
, V
);
5135 end Set_Universal_Aliasing
;
5137 procedure Set_Unset_Reference
(Id
: E
; V
: N
) is
5140 end Set_Unset_Reference
;
5142 procedure Set_Uses_Sec_Stack
(Id
: E
; V
: B
:= True) is
5145 end Set_Uses_Sec_Stack
;
5147 procedure Set_Used_As_Generic_Actual
(Id
: E
; V
: B
:= True) is
5149 Set_Flag222
(Id
, V
);
5150 end Set_Used_As_Generic_Actual
;
5152 procedure Set_Vax_Float
(Id
: E
; V
: B
:= True) is
5154 pragma Assert
(Id
= Base_Type
(Id
));
5155 Set_Flag151
(Id
, V
);
5158 procedure Set_Warnings_Off
(Id
: E
; V
: B
:= True) is
5161 end Set_Warnings_Off
;
5163 procedure Set_Warnings_Off_Used
(Id
: E
; V
: B
:= True) is
5165 Set_Flag236
(Id
, V
);
5166 end Set_Warnings_Off_Used
;
5168 procedure Set_Warnings_Off_Used_Unmodified
(Id
: E
; V
: B
:= True) is
5170 Set_Flag237
(Id
, V
);
5171 end Set_Warnings_Off_Used_Unmodified
;
5173 procedure Set_Warnings_Off_Used_Unreferenced
(Id
: E
; V
: B
:= True) is
5175 Set_Flag238
(Id
, V
);
5176 end Set_Warnings_Off_Used_Unreferenced
;
5178 procedure Set_Was_Hidden
(Id
: E
; V
: B
:= True) is
5180 Set_Flag196
(Id
, V
);
5183 procedure Set_Wrapped_Entity
(Id
: E
; V
: E
) is
5185 pragma Assert
(Ekind
(Id
) = E_Procedure
5186 and then Is_Primitive_Wrapper
(Id
));
5188 end Set_Wrapped_Entity
;
5190 -----------------------------------
5191 -- Field Initialization Routines --
5192 -----------------------------------
5194 procedure Init_Alignment
(Id
: E
) is
5196 Set_Uint14
(Id
, Uint_0
);
5199 procedure Init_Alignment
(Id
: E
; V
: Int
) is
5201 Set_Uint14
(Id
, UI_From_Int
(V
));
5204 procedure Init_Component_Bit_Offset
(Id
: E
) is
5206 Set_Uint11
(Id
, No_Uint
);
5207 end Init_Component_Bit_Offset
;
5209 procedure Init_Component_Bit_Offset
(Id
: E
; V
: Int
) is
5211 Set_Uint11
(Id
, UI_From_Int
(V
));
5212 end Init_Component_Bit_Offset
;
5214 procedure Init_Component_Size
(Id
: E
) is
5216 Set_Uint22
(Id
, Uint_0
);
5217 end Init_Component_Size
;
5219 procedure Init_Component_Size
(Id
: E
; V
: Int
) is
5221 Set_Uint22
(Id
, UI_From_Int
(V
));
5222 end Init_Component_Size
;
5224 procedure Init_Digits_Value
(Id
: E
) is
5226 Set_Uint17
(Id
, Uint_0
);
5227 end Init_Digits_Value
;
5229 procedure Init_Digits_Value
(Id
: E
; V
: Int
) is
5231 Set_Uint17
(Id
, UI_From_Int
(V
));
5232 end Init_Digits_Value
;
5234 procedure Init_Esize
(Id
: E
) is
5236 Set_Uint12
(Id
, Uint_0
);
5239 procedure Init_Esize
(Id
: E
; V
: Int
) is
5241 Set_Uint12
(Id
, UI_From_Int
(V
));
5244 procedure Init_Normalized_First_Bit
(Id
: E
) is
5246 Set_Uint8
(Id
, No_Uint
);
5247 end Init_Normalized_First_Bit
;
5249 procedure Init_Normalized_First_Bit
(Id
: E
; V
: Int
) is
5251 Set_Uint8
(Id
, UI_From_Int
(V
));
5252 end Init_Normalized_First_Bit
;
5254 procedure Init_Normalized_Position
(Id
: E
) is
5256 Set_Uint14
(Id
, No_Uint
);
5257 end Init_Normalized_Position
;
5259 procedure Init_Normalized_Position
(Id
: E
; V
: Int
) is
5261 Set_Uint14
(Id
, UI_From_Int
(V
));
5262 end Init_Normalized_Position
;
5264 procedure Init_Normalized_Position_Max
(Id
: E
) is
5266 Set_Uint10
(Id
, No_Uint
);
5267 end Init_Normalized_Position_Max
;
5269 procedure Init_Normalized_Position_Max
(Id
: E
; V
: Int
) is
5271 Set_Uint10
(Id
, UI_From_Int
(V
));
5272 end Init_Normalized_Position_Max
;
5274 procedure Init_RM_Size
(Id
: E
) is
5276 Set_Uint13
(Id
, Uint_0
);
5279 procedure Init_RM_Size
(Id
: E
; V
: Int
) is
5281 Set_Uint13
(Id
, UI_From_Int
(V
));
5284 -----------------------------
5285 -- Init_Component_Location --
5286 -----------------------------
5288 procedure Init_Component_Location
(Id
: E
) is
5290 Set_Uint8
(Id
, No_Uint
); -- Normalized_First_Bit
5291 Set_Uint10
(Id
, No_Uint
); -- Normalized_Position_Max
5292 Set_Uint11
(Id
, No_Uint
); -- Component_Bit_Offset
5293 Set_Uint12
(Id
, Uint_0
); -- Esize
5294 Set_Uint14
(Id
, No_Uint
); -- Normalized_Position
5295 end Init_Component_Location
;
5301 procedure Init_Size
(Id
: E
; V
: Int
) is
5303 Set_Uint12
(Id
, UI_From_Int
(V
)); -- Esize
5304 Set_Uint13
(Id
, UI_From_Int
(V
)); -- RM_Size
5307 ---------------------
5308 -- Init_Size_Align --
5309 ---------------------
5311 procedure Init_Size_Align
(Id
: E
) is
5313 Set_Uint12
(Id
, Uint_0
); -- Esize
5314 Set_Uint13
(Id
, Uint_0
); -- RM_Size
5315 Set_Uint14
(Id
, Uint_0
); -- Alignment
5316 end Init_Size_Align
;
5318 ----------------------------------------------
5319 -- Type Representation Attribute Predicates --
5320 ----------------------------------------------
5322 function Known_Alignment
(E
: Entity_Id
) return B
is
5324 return Uint14
(E
) /= Uint_0
5325 and then Uint14
(E
) /= No_Uint
;
5326 end Known_Alignment
;
5328 function Known_Component_Bit_Offset
(E
: Entity_Id
) return B
is
5330 return Uint11
(E
) /= No_Uint
;
5331 end Known_Component_Bit_Offset
;
5333 function Known_Component_Size
(E
: Entity_Id
) return B
is
5335 return Uint22
(Base_Type
(E
)) /= Uint_0
5336 and then Uint22
(Base_Type
(E
)) /= No_Uint
;
5337 end Known_Component_Size
;
5339 function Known_Esize
(E
: Entity_Id
) return B
is
5341 return Uint12
(E
) /= Uint_0
5342 and then Uint12
(E
) /= No_Uint
;
5345 function Known_Normalized_First_Bit
(E
: Entity_Id
) return B
is
5347 return Uint8
(E
) /= No_Uint
;
5348 end Known_Normalized_First_Bit
;
5350 function Known_Normalized_Position
(E
: Entity_Id
) return B
is
5352 return Uint14
(E
) /= No_Uint
;
5353 end Known_Normalized_Position
;
5355 function Known_Normalized_Position_Max
(E
: Entity_Id
) return B
is
5357 return Uint10
(E
) /= No_Uint
;
5358 end Known_Normalized_Position_Max
;
5360 function Known_RM_Size
(E
: Entity_Id
) return B
is
5362 return Uint13
(E
) /= No_Uint
5363 and then (Uint13
(E
) /= Uint_0
5364 or else Is_Discrete_Type
(E
)
5365 or else Is_Fixed_Point_Type
(E
));
5368 function Known_Static_Component_Bit_Offset
(E
: Entity_Id
) return B
is
5370 return Uint11
(E
) /= No_Uint
5371 and then Uint11
(E
) >= Uint_0
;
5372 end Known_Static_Component_Bit_Offset
;
5374 function Known_Static_Component_Size
(E
: Entity_Id
) return B
is
5376 return Uint22
(Base_Type
(E
)) > Uint_0
;
5377 end Known_Static_Component_Size
;
5379 function Known_Static_Esize
(E
: Entity_Id
) return B
is
5381 return Uint12
(E
) > Uint_0
;
5382 end Known_Static_Esize
;
5384 function Known_Static_Normalized_First_Bit
(E
: Entity_Id
) return B
is
5386 return Uint8
(E
) /= No_Uint
5387 and then Uint8
(E
) >= Uint_0
;
5388 end Known_Static_Normalized_First_Bit
;
5390 function Known_Static_Normalized_Position
(E
: Entity_Id
) return B
is
5392 return Uint14
(E
) /= No_Uint
5393 and then Uint14
(E
) >= Uint_0
;
5394 end Known_Static_Normalized_Position
;
5396 function Known_Static_Normalized_Position_Max
(E
: Entity_Id
) return B
is
5398 return Uint10
(E
) /= No_Uint
5399 and then Uint10
(E
) >= Uint_0
;
5400 end Known_Static_Normalized_Position_Max
;
5402 function Known_Static_RM_Size
(E
: Entity_Id
) return B
is
5404 return Uint13
(E
) > Uint_0
5405 or else Is_Discrete_Type
(E
)
5406 or else Is_Fixed_Point_Type
(E
);
5407 end Known_Static_RM_Size
;
5409 function Unknown_Alignment
(E
: Entity_Id
) return B
is
5411 return Uint14
(E
) = Uint_0
5412 or else Uint14
(E
) = No_Uint
;
5413 end Unknown_Alignment
;
5415 function Unknown_Component_Bit_Offset
(E
: Entity_Id
) return B
is
5417 return Uint11
(E
) = No_Uint
;
5418 end Unknown_Component_Bit_Offset
;
5420 function Unknown_Component_Size
(E
: Entity_Id
) return B
is
5422 return Uint22
(Base_Type
(E
)) = Uint_0
5424 Uint22
(Base_Type
(E
)) = No_Uint
;
5425 end Unknown_Component_Size
;
5427 function Unknown_Esize
(E
: Entity_Id
) return B
is
5429 return Uint12
(E
) = No_Uint
5431 Uint12
(E
) = Uint_0
;
5434 function Unknown_Normalized_First_Bit
(E
: Entity_Id
) return B
is
5436 return Uint8
(E
) = No_Uint
;
5437 end Unknown_Normalized_First_Bit
;
5439 function Unknown_Normalized_Position
(E
: Entity_Id
) return B
is
5441 return Uint14
(E
) = No_Uint
;
5442 end Unknown_Normalized_Position
;
5444 function Unknown_Normalized_Position_Max
(E
: Entity_Id
) return B
is
5446 return Uint10
(E
) = No_Uint
;
5447 end Unknown_Normalized_Position_Max
;
5449 function Unknown_RM_Size
(E
: Entity_Id
) return B
is
5451 return (Uint13
(E
) = Uint_0
5452 and then not Is_Discrete_Type
(E
)
5453 and then not Is_Fixed_Point_Type
(E
))
5454 or else Uint13
(E
) = No_Uint
;
5455 end Unknown_RM_Size
;
5457 --------------------
5458 -- Address_Clause --
5459 --------------------
5461 function Address_Clause
(Id
: E
) return N
is
5463 return Rep_Clause
(Id
, Name_Address
);
5466 ----------------------
5467 -- Alignment_Clause --
5468 ----------------------
5470 function Alignment_Clause
(Id
: E
) return N
is
5472 return Rep_Clause
(Id
, Name_Alignment
);
5473 end Alignment_Clause
;
5475 ----------------------
5476 -- Ancestor_Subtype --
5477 ----------------------
5479 function Ancestor_Subtype
(Id
: E
) return E
is
5481 -- If this is first subtype, or is a base type, then there is no
5482 -- ancestor subtype, so we return Empty to indicate this fact.
5484 if Is_First_Subtype
(Id
) or else Id
= Base_Type
(Id
) then
5489 D
: constant Node_Id
:= Declaration_Node
(Id
);
5492 -- If we have a subtype declaration, get the ancestor subtype
5494 if Nkind
(D
) = N_Subtype_Declaration
then
5495 if Nkind
(Subtype_Indication
(D
)) = N_Subtype_Indication
then
5496 return Entity
(Subtype_Mark
(Subtype_Indication
(D
)));
5498 return Entity
(Subtype_Indication
(D
));
5501 -- If not, then no subtype indication is available
5507 end Ancestor_Subtype
;
5513 procedure Append_Entity
(Id
: Entity_Id
; V
: Entity_Id
) is
5515 if Last_Entity
(V
) = Empty
then
5516 Set_First_Entity
(Id
=> V
, V
=> Id
);
5518 Set_Next_Entity
(Last_Entity
(V
), Id
);
5521 Set_Next_Entity
(Id
, Empty
);
5523 Set_Last_Entity
(Id
=> V
, V
=> Id
);
5526 --------------------
5527 -- Available_View --
5528 --------------------
5530 function Available_View
(Id
: E
) return E
is
5532 if Is_Incomplete_Type
(Id
)
5533 and then Present
(Non_Limited_View
(Id
))
5535 -- The non-limited view may itself be an incomplete type, in
5536 -- which case get its full view.
5538 return Get_Full_View
(Non_Limited_View
(Id
));
5540 elsif Is_Class_Wide_Type
(Id
)
5541 and then Is_Incomplete_Type
(Etype
(Id
))
5542 and then Present
(Non_Limited_View
(Etype
(Id
)))
5544 return Class_Wide_Type
(Non_Limited_View
(Etype
(Id
)));
5555 function Base_Type
(Id
: E
) return E
is
5558 when E_Enumeration_Subtype |
5560 E_Signed_Integer_Subtype |
5561 E_Modular_Integer_Subtype |
5562 E_Floating_Point_Subtype |
5563 E_Ordinary_Fixed_Point_Subtype |
5564 E_Decimal_Fixed_Point_Subtype |
5569 E_Record_Subtype_With_Private |
5570 E_Limited_Private_Subtype |
5572 E_Protected_Subtype |
5574 E_String_Literal_Subtype |
5575 E_Class_Wide_Subtype
=>
5583 -------------------------
5584 -- Component_Alignment --
5585 -------------------------
5587 -- Component Alignment is encoded using two flags, Flag128/129 as
5588 -- follows. Note that both flags False = Align_Default, so that the
5589 -- default initialization of flags to False initializes component
5590 -- alignment to the default value as required.
5592 -- Flag128 Flag129 Value
5593 -- ------- ------- -----
5594 -- False False Calign_Default
5595 -- False True Calign_Component_Size
5596 -- True False Calign_Component_Size_4
5597 -- True True Calign_Storage_Unit
5599 function Component_Alignment
(Id
: E
) return C
is
5600 BT
: constant Node_Id
:= Base_Type
(Id
);
5603 pragma Assert
(Is_Array_Type
(Id
) or else Is_Record_Type
(Id
));
5605 if Flag128
(BT
) then
5606 if Flag129
(BT
) then
5607 return Calign_Storage_Unit
;
5609 return Calign_Component_Size_4
;
5613 if Flag129
(BT
) then
5614 return Calign_Component_Size
;
5616 return Calign_Default
;
5619 end Component_Alignment
;
5621 --------------------
5622 -- Constant_Value --
5623 --------------------
5625 function Constant_Value
(Id
: E
) return N
is
5626 D
: constant Node_Id
:= Declaration_Node
(Id
);
5630 -- If we have no declaration node, then return no constant value.
5631 -- Not clear how this can happen, but it does sometimes ???
5632 -- To investigate, remove this check and compile discrim_po.adb.
5637 -- Normal case where a declaration node is present
5639 elsif Nkind
(D
) = N_Object_Renaming_Declaration
then
5640 return Renamed_Object
(Id
);
5642 -- If this is a component declaration whose entity is constant, it
5643 -- is a prival within a protected function. It does not have
5644 -- a constant value.
5646 elsif Nkind
(D
) = N_Component_Declaration
then
5649 -- If there is an expression, return it
5651 elsif Present
(Expression
(D
)) then
5652 return (Expression
(D
));
5654 -- For a constant, see if we have a full view
5656 elsif Ekind
(Id
) = E_Constant
5657 and then Present
(Full_View
(Id
))
5659 Full_D
:= Parent
(Full_View
(Id
));
5661 -- The full view may have been rewritten as an object renaming
5663 if Nkind
(Full_D
) = N_Object_Renaming_Declaration
then
5664 return Name
(Full_D
);
5666 return Expression
(Full_D
);
5669 -- Otherwise we have no expression to return
5676 ----------------------
5677 -- Declaration_Node --
5678 ----------------------
5680 function Declaration_Node
(Id
: E
) return N
is
5684 if Ekind
(Id
) = E_Incomplete_Type
5685 and then Present
(Full_View
(Id
))
5687 P
:= Parent
(Full_View
(Id
));
5693 if Nkind
(P
) /= N_Selected_Component
5694 and then Nkind
(P
) /= N_Expanded_Name
5696 not (Nkind
(P
) = N_Defining_Program_Unit_Name
5697 and then Is_Child_Unit
(Id
))
5704 end Declaration_Node
;
5706 ---------------------
5707 -- Designated_Type --
5708 ---------------------
5710 function Designated_Type
(Id
: E
) return E
is
5714 Desig_Type
:= Directly_Designated_Type
(Id
);
5716 if Ekind
(Desig_Type
) = E_Incomplete_Type
5717 and then Present
(Full_View
(Desig_Type
))
5719 return Full_View
(Desig_Type
);
5721 elsif Is_Class_Wide_Type
(Desig_Type
)
5722 and then Ekind
(Etype
(Desig_Type
)) = E_Incomplete_Type
5723 and then Present
(Full_View
(Etype
(Desig_Type
)))
5724 and then Present
(Class_Wide_Type
(Full_View
(Etype
(Desig_Type
))))
5726 return Class_Wide_Type
(Full_View
(Etype
(Desig_Type
)));
5731 end Designated_Type
;
5733 -----------------------------
5734 -- Enclosing_Dynamic_Scope --
5735 -----------------------------
5737 function Enclosing_Dynamic_Scope
(Id
: E
) return E
is
5741 -- The following test is an error defense against some syntax
5742 -- errors that can leave scopes very messed up.
5744 if Id
= Standard_Standard
then
5748 -- Normal case, search enclosing scopes
5750 -- Note: the test for Present (S) should not be required, it is a
5751 -- defence against an ill-formed tree.
5755 -- If we somehow got an empty value for Scope, the tree must be
5756 -- malformed. Rather than blow up we return Standard in this case.
5759 return Standard_Standard
;
5761 -- Quit if we get to standard or a dynamic scope
5763 elsif S
= Standard_Standard
5764 or else Is_Dynamic_Scope
(S
)
5768 -- Otherwise keep climbing
5774 end Enclosing_Dynamic_Scope
;
5776 ----------------------
5777 -- Entry_Index_Type --
5778 ----------------------
5780 function Entry_Index_Type
(Id
: E
) return N
is
5782 pragma Assert
(Ekind
(Id
) = E_Entry_Family
);
5783 return Etype
(Discrete_Subtype_Definition
(Parent
(Id
)));
5784 end Entry_Index_Type
;
5786 ---------------------
5787 -- First_Component --
5788 ---------------------
5790 function First_Component
(Id
: E
) return E
is
5795 (Is_Record_Type
(Id
) or else Is_Incomplete_Or_Private_Type
(Id
));
5797 Comp_Id
:= First_Entity
(Id
);
5798 while Present
(Comp_Id
) loop
5799 exit when Ekind
(Comp_Id
) = E_Component
;
5800 Comp_Id
:= Next_Entity
(Comp_Id
);
5804 end First_Component
;
5806 -------------------------------------
5807 -- First_Component_Or_Discriminant --
5808 -------------------------------------
5810 function First_Component_Or_Discriminant
(Id
: E
) return E
is
5815 (Is_Record_Type
(Id
) or else Is_Incomplete_Or_Private_Type
(Id
));
5817 Comp_Id
:= First_Entity
(Id
);
5818 while Present
(Comp_Id
) loop
5819 exit when Ekind
(Comp_Id
) = E_Component
5821 Ekind
(Comp_Id
) = E_Discriminant
;
5822 Comp_Id
:= Next_Entity
(Comp_Id
);
5826 end First_Component_Or_Discriminant
;
5828 ------------------------
5829 -- First_Discriminant --
5830 ------------------------
5832 function First_Discriminant
(Id
: E
) return E
is
5837 (Has_Discriminants
(Id
)
5838 or else Has_Unknown_Discriminants
(Id
));
5840 Ent
:= First_Entity
(Id
);
5842 -- The discriminants are not necessarily contiguous, because access
5843 -- discriminants will generate itypes. They are not the first entities
5844 -- either, because tag and controller record must be ahead of them.
5846 if Chars
(Ent
) = Name_uTag
then
5847 Ent
:= Next_Entity
(Ent
);
5850 if Chars
(Ent
) = Name_uController
then
5851 Ent
:= Next_Entity
(Ent
);
5854 -- Skip all hidden stored discriminants if any
5856 while Present
(Ent
) loop
5857 exit when Ekind
(Ent
) = E_Discriminant
5858 and then not Is_Completely_Hidden
(Ent
);
5860 Ent
:= Next_Entity
(Ent
);
5863 pragma Assert
(Ekind
(Ent
) = E_Discriminant
);
5866 end First_Discriminant
;
5872 function First_Formal
(Id
: E
) return E
is
5877 (Is_Overloadable
(Id
)
5878 or else Ekind
(Id
) = E_Entry_Family
5879 or else Ekind
(Id
) = E_Subprogram_Body
5880 or else Ekind
(Id
) = E_Subprogram_Type
);
5882 if Ekind
(Id
) = E_Enumeration_Literal
then
5886 Formal
:= First_Entity
(Id
);
5888 if Present
(Formal
) and then Is_Formal
(Formal
) then
5896 ------------------------------
5897 -- First_Formal_With_Extras --
5898 ------------------------------
5900 function First_Formal_With_Extras
(Id
: E
) return E
is
5905 (Is_Overloadable
(Id
)
5906 or else Ekind
(Id
) = E_Entry_Family
5907 or else Ekind
(Id
) = E_Subprogram_Body
5908 or else Ekind
(Id
) = E_Subprogram_Type
);
5910 if Ekind
(Id
) = E_Enumeration_Literal
then
5914 Formal
:= First_Entity
(Id
);
5916 if Present
(Formal
) and then Is_Formal
(Formal
) then
5919 return Extra_Formals
(Id
); -- Empty if no extra formals
5922 end First_Formal_With_Extras
;
5924 -------------------------------
5925 -- First_Stored_Discriminant --
5926 -------------------------------
5928 function First_Stored_Discriminant
(Id
: E
) return E
is
5931 function Has_Completely_Hidden_Discriminant
(Id
: E
) return Boolean;
5932 -- Scans the Discriminants to see whether any are Completely_Hidden
5933 -- (the mechanism for describing non-specified stored discriminants)
5935 ----------------------------------------
5936 -- Has_Completely_Hidden_Discriminant --
5937 ----------------------------------------
5939 function Has_Completely_Hidden_Discriminant
(Id
: E
) return Boolean is
5940 Ent
: Entity_Id
:= Id
;
5943 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
5945 while Present
(Ent
) and then Ekind
(Ent
) = E_Discriminant
loop
5946 if Is_Completely_Hidden
(Ent
) then
5950 Ent
:= Next_Entity
(Ent
);
5954 end Has_Completely_Hidden_Discriminant
;
5956 -- Start of processing for First_Stored_Discriminant
5960 (Has_Discriminants
(Id
)
5961 or else Has_Unknown_Discriminants
(Id
));
5963 Ent
:= First_Entity
(Id
);
5965 if Chars
(Ent
) = Name_uTag
then
5966 Ent
:= Next_Entity
(Ent
);
5969 if Chars
(Ent
) = Name_uController
then
5970 Ent
:= Next_Entity
(Ent
);
5973 if Has_Completely_Hidden_Discriminant
(Ent
) then
5975 while Present
(Ent
) loop
5976 exit when Is_Completely_Hidden
(Ent
);
5977 Ent
:= Next_Entity
(Ent
);
5982 pragma Assert
(Ekind
(Ent
) = E_Discriminant
);
5985 end First_Stored_Discriminant
;
5991 function First_Subtype
(Id
: E
) return E
is
5992 B
: constant Entity_Id
:= Base_Type
(Id
);
5993 F
: constant Node_Id
:= Freeze_Node
(B
);
5997 -- If the base type has no freeze node, it is a type in standard,
5998 -- and always acts as its own first subtype unless it is one of
5999 -- the predefined integer types. If the type is formal, it is also
6000 -- a first subtype, and its base type has no freeze node. On the other
6001 -- hand, a subtype of a generic formal is not its own first_subtype.
6002 -- Its base type, if anonymous, is attached to the formal type decl.
6003 -- from which the first subtype is obtained.
6007 if B
= Base_Type
(Standard_Integer
) then
6008 return Standard_Integer
;
6010 elsif B
= Base_Type
(Standard_Long_Integer
) then
6011 return Standard_Long_Integer
;
6013 elsif B
= Base_Type
(Standard_Short_Short_Integer
) then
6014 return Standard_Short_Short_Integer
;
6016 elsif B
= Base_Type
(Standard_Short_Integer
) then
6017 return Standard_Short_Integer
;
6019 elsif B
= Base_Type
(Standard_Long_Long_Integer
) then
6020 return Standard_Long_Long_Integer
;
6022 elsif Is_Generic_Type
(Id
) then
6023 if Present
(Parent
(B
)) then
6024 return Defining_Identifier
(Parent
(B
));
6026 return Defining_Identifier
(Associated_Node_For_Itype
(B
));
6033 -- Otherwise we check the freeze node, if it has a First_Subtype_Link
6034 -- then we use that link, otherwise (happens with some Itypes), we use
6035 -- the base type itself.
6038 Ent
:= First_Subtype_Link
(F
);
6040 if Present
(Ent
) then
6048 -------------------------------------
6049 -- Get_Attribute_Definition_Clause --
6050 -------------------------------------
6052 function Get_Attribute_Definition_Clause
6054 Id
: Attribute_Id
) return Node_Id
6059 N
:= First_Rep_Item
(E
);
6060 while Present
(N
) loop
6061 if Nkind
(N
) = N_Attribute_Definition_Clause
6062 and then Get_Attribute_Id
(Chars
(N
)) = Id
6071 end Get_Attribute_Definition_Clause
;
6077 function Get_Full_View
(T
: Entity_Id
) return Entity_Id
is
6079 if Ekind
(T
) = E_Incomplete_Type
6080 and then Present
(Full_View
(T
))
6082 return Full_View
(T
);
6084 elsif Is_Class_Wide_Type
(T
)
6085 and then Ekind
(Root_Type
(T
)) = E_Incomplete_Type
6086 and then Present
(Full_View
(Root_Type
(T
)))
6088 return Class_Wide_Type
(Full_View
(Root_Type
(T
)));
6095 --------------------
6096 -- Get_Rep_Pragma --
6097 --------------------
6099 function Get_Rep_Pragma
(E
: Entity_Id
; Nam
: Name_Id
) return Node_Id
is
6103 N
:= First_Rep_Item
(E
);
6104 while Present
(N
) loop
6105 if Nkind
(N
) = N_Pragma
and then Pragma_Name
(N
) = Nam
then
6115 ------------------------
6116 -- Has_Attach_Handler --
6117 ------------------------
6119 function Has_Attach_Handler
(Id
: E
) return B
is
6123 pragma Assert
(Is_Protected_Type
(Id
));
6125 Ritem
:= First_Rep_Item
(Id
);
6126 while Present
(Ritem
) loop
6127 if Nkind
(Ritem
) = N_Pragma
6128 and then Pragma_Name
(Ritem
) = Name_Attach_Handler
6132 Ritem
:= Next_Rep_Item
(Ritem
);
6137 end Has_Attach_Handler
;
6139 -------------------------------------
6140 -- Has_Attribute_Definition_Clause --
6141 -------------------------------------
6143 function Has_Attribute_Definition_Clause
6145 Id
: Attribute_Id
) return Boolean
6148 return Present
(Get_Attribute_Definition_Clause
(E
, Id
));
6149 end Has_Attribute_Definition_Clause
;
6155 function Has_Entries
(Id
: E
) return B
is
6159 pragma Assert
(Is_Concurrent_Type
(Id
));
6161 Ent
:= First_Entity
(Id
);
6162 while Present
(Ent
) loop
6163 if Is_Entry
(Ent
) then
6167 Ent
:= Next_Entity
(Ent
);
6173 ----------------------------
6174 -- Has_Foreign_Convention --
6175 ----------------------------
6177 function Has_Foreign_Convention
(Id
: E
) return B
is
6179 return Convention
(Id
) in Foreign_Convention
;
6180 end Has_Foreign_Convention
;
6182 ---------------------------
6183 -- Has_Interrupt_Handler --
6184 ---------------------------
6186 function Has_Interrupt_Handler
(Id
: E
) return B
is
6190 pragma Assert
(Is_Protected_Type
(Id
));
6192 Ritem
:= First_Rep_Item
(Id
);
6193 while Present
(Ritem
) loop
6194 if Nkind
(Ritem
) = N_Pragma
6195 and then Pragma_Name
(Ritem
) = Name_Interrupt_Handler
6199 Ritem
:= Next_Rep_Item
(Ritem
);
6204 end Has_Interrupt_Handler
;
6206 --------------------------
6207 -- Has_Private_Ancestor --
6208 --------------------------
6210 function Has_Private_Ancestor
(Id
: E
) return B
is
6211 R
: constant Entity_Id
:= Root_Type
(Id
);
6212 T1
: Entity_Id
:= Id
;
6215 if Is_Private_Type
(T1
) then
6223 end Has_Private_Ancestor
;
6225 --------------------
6226 -- Has_Rep_Pragma --
6227 --------------------
6229 function Has_Rep_Pragma
(E
: Entity_Id
; Nam
: Name_Id
) return Boolean is
6231 return Present
(Get_Rep_Pragma
(E
, Nam
));
6234 --------------------
6235 -- Has_Unmodified --
6236 --------------------
6238 function Has_Unmodified
(E
: Entity_Id
) return Boolean is
6240 if Has_Pragma_Unmodified
(E
) then
6242 elsif Warnings_Off
(E
) then
6243 Set_Warnings_Off_Used_Unmodified
(E
);
6250 ---------------------
6251 -- Has_Unreferenced --
6252 ---------------------
6254 function Has_Unreferenced
(E
: Entity_Id
) return Boolean is
6256 if Has_Pragma_Unreferenced
(E
) then
6258 elsif Warnings_Off
(E
) then
6259 Set_Warnings_Off_Used_Unreferenced
(E
);
6264 end Has_Unreferenced
;
6266 ----------------------
6267 -- Has_Warnings_Off --
6268 ----------------------
6270 function Has_Warnings_Off
(E
: Entity_Id
) return Boolean is
6272 if Warnings_Off
(E
) then
6273 Set_Warnings_Off_Used
(E
);
6278 end Has_Warnings_Off
;
6280 ------------------------------
6281 -- Implementation_Base_Type --
6282 ------------------------------
6284 function Implementation_Base_Type
(Id
: E
) return E
is
6289 Bastyp
:= Base_Type
(Id
);
6291 if Is_Incomplete_Or_Private_Type
(Bastyp
) then
6292 Imptyp
:= Underlying_Type
(Bastyp
);
6294 -- If we have an implementation type, then just return it,
6295 -- otherwise we return the Base_Type anyway. This can only
6296 -- happen in error situations and should avoid some error bombs.
6298 if Present
(Imptyp
) then
6299 return Base_Type
(Imptyp
);
6307 end Implementation_Base_Type
;
6309 ---------------------
6310 -- Is_Boolean_Type --
6311 ---------------------
6313 function Is_Boolean_Type
(Id
: E
) return B
is
6315 return Root_Type
(Id
) = Standard_Boolean
;
6316 end Is_Boolean_Type
;
6318 ---------------------
6319 -- Is_By_Copy_Type --
6320 ---------------------
6322 function Is_By_Copy_Type
(Id
: E
) return B
is
6324 -- If Id is a private type whose full declaration has not been seen,
6325 -- we assume for now that it is not a By_Copy type. Clearly this
6326 -- attribute should not be used before the type is frozen, but it is
6327 -- needed to build the associated record of a protected type. Another
6328 -- place where some lookahead for a full view is needed ???
6331 Is_Elementary_Type
(Id
)
6332 or else (Is_Private_Type
(Id
)
6333 and then Present
(Underlying_Type
(Id
))
6334 and then Is_Elementary_Type
(Underlying_Type
(Id
)));
6335 end Is_By_Copy_Type
;
6337 --------------------------
6338 -- Is_By_Reference_Type --
6339 --------------------------
6341 -- This function knows too much semantics, it should be in sem_util ???
6343 function Is_By_Reference_Type
(Id
: E
) return B
is
6344 Btype
: constant Entity_Id
:= Base_Type
(Id
);
6347 if Error_Posted
(Id
)
6348 or else Error_Posted
(Btype
)
6352 elsif Is_Private_Type
(Btype
) then
6354 Utyp
: constant Entity_Id
:= Underlying_Type
(Btype
);
6359 return Is_By_Reference_Type
(Utyp
);
6363 elsif Is_Incomplete_Type
(Btype
) then
6365 Ftyp
: constant Entity_Id
:= Full_View
(Btype
);
6370 return Is_By_Reference_Type
(Ftyp
);
6374 elsif Is_Concurrent_Type
(Btype
) then
6377 elsif Is_Record_Type
(Btype
) then
6378 if Is_Limited_Record
(Btype
)
6379 or else Is_Tagged_Type
(Btype
)
6380 or else Is_Volatile
(Btype
)
6389 C
:= First_Component
(Btype
);
6390 while Present
(C
) loop
6391 if Is_By_Reference_Type
(Etype
(C
))
6392 or else Is_Volatile
(Etype
(C
))
6397 C
:= Next_Component
(C
);
6404 elsif Is_Array_Type
(Btype
) then
6407 or else Is_By_Reference_Type
(Component_Type
(Btype
))
6408 or else Is_Volatile
(Component_Type
(Btype
))
6409 or else Has_Volatile_Components
(Btype
);
6414 end Is_By_Reference_Type
;
6416 ------------------------
6417 -- Is_Constant_Object --
6418 ------------------------
6420 function Is_Constant_Object
(Id
: E
) return B
is
6421 K
: constant Entity_Kind
:= Ekind
(Id
);
6424 K
= E_Constant
or else K
= E_In_Parameter
or else K
= E_Loop_Parameter
;
6425 end Is_Constant_Object
;
6427 ---------------------
6428 -- Is_Derived_Type --
6429 ---------------------
6431 function Is_Derived_Type
(Id
: E
) return B
is
6436 and then Base_Type
(Id
) /= Root_Type
(Id
)
6437 and then not Is_Class_Wide_Type
(Id
)
6439 if not Is_Numeric_Type
(Root_Type
(Id
)) then
6443 Par
:= Parent
(First_Subtype
(Id
));
6445 return Present
(Par
)
6446 and then Nkind
(Par
) = N_Full_Type_Declaration
6447 and then Nkind
(Type_Definition
(Par
)) =
6448 N_Derived_Type_Definition
;
6454 end Is_Derived_Type
;
6456 --------------------
6457 -- Is_Discriminal --
6458 --------------------
6460 function Is_Discriminal
(Id
: E
) return B
is
6463 (Ekind
(Id
) = E_Constant
6464 or else Ekind
(Id
) = E_In_Parameter
)
6465 and then Present
(Discriminal_Link
(Id
));
6468 ----------------------
6469 -- Is_Dynamic_Scope --
6470 ----------------------
6472 function Is_Dynamic_Scope
(Id
: E
) return B
is
6475 Ekind
(Id
) = E_Block
6477 Ekind
(Id
) = E_Function
6479 Ekind
(Id
) = E_Procedure
6481 Ekind
(Id
) = E_Subprogram_Body
6483 Ekind
(Id
) = E_Task_Type
6485 Ekind
(Id
) = E_Entry
6487 Ekind
(Id
) = E_Entry_Family
6489 Ekind
(Id
) = E_Return_Statement
;
6490 end Is_Dynamic_Scope
;
6492 --------------------
6493 -- Is_Entity_Name --
6494 --------------------
6496 function Is_Entity_Name
(N
: Node_Id
) return Boolean is
6497 Kind
: constant Node_Kind
:= Nkind
(N
);
6500 -- Identifiers, operator symbols, expanded names are entity names
6502 return Kind
= N_Identifier
6503 or else Kind
= N_Operator_Symbol
6504 or else Kind
= N_Expanded_Name
6506 -- Attribute references are entity names if they refer to an entity.
6507 -- Note that we don't do this by testing for the presence of the
6508 -- Entity field in the N_Attribute_Reference node, since it may not
6509 -- have been set yet.
6511 or else (Kind
= N_Attribute_Reference
6512 and then Is_Entity_Attribute_Name
(Attribute_Name
(N
)));
6515 ---------------------------
6516 -- Is_Indefinite_Subtype --
6517 ---------------------------
6519 function Is_Indefinite_Subtype
(Id
: Entity_Id
) return B
is
6520 K
: constant Entity_Kind
:= Ekind
(Id
);
6523 if Is_Constrained
(Id
) then
6526 elsif K
in Array_Kind
6527 or else K
in Class_Wide_Kind
6528 or else Has_Unknown_Discriminants
(Id
)
6532 -- Known discriminants: indefinite if there are no default values
6534 elsif K
in Record_Kind
6535 or else Is_Incomplete_Or_Private_Type
(Id
)
6536 or else Is_Concurrent_Type
(Id
)
6538 return (Has_Discriminants
(Id
)
6539 and then No
(Discriminant_Default_Value
(First_Discriminant
(Id
))));
6544 end Is_Indefinite_Subtype
;
6546 --------------------------------
6547 -- Is_Inherently_Limited_Type --
6548 --------------------------------
6550 function Is_Inherently_Limited_Type
(Id
: E
) return B
is
6551 Btype
: constant Entity_Id
:= Base_Type
(Id
);
6554 if Is_Private_Type
(Btype
) then
6556 Utyp
: constant Entity_Id
:= Underlying_Type
(Btype
);
6561 return Is_Inherently_Limited_Type
(Utyp
);
6565 elsif Is_Concurrent_Type
(Btype
) then
6568 elsif Is_Record_Type
(Btype
) then
6569 if Is_Limited_Record
(Btype
) then
6570 return not Is_Interface
(Btype
)
6571 or else Is_Protected_Interface
(Btype
)
6572 or else Is_Synchronized_Interface
(Btype
)
6573 or else Is_Task_Interface
(Btype
);
6575 elsif Is_Class_Wide_Type
(Btype
) then
6576 return Is_Inherently_Limited_Type
(Root_Type
(Btype
));
6583 C
:= First_Component
(Btype
);
6584 while Present
(C
) loop
6585 if Is_Inherently_Limited_Type
(Etype
(C
)) then
6589 C
:= Next_Component
(C
);
6596 elsif Is_Array_Type
(Btype
) then
6597 return Is_Inherently_Limited_Type
(Component_Type
(Btype
));
6602 end Is_Inherently_Limited_Type
;
6604 ---------------------
6605 -- Is_Limited_Type --
6606 ---------------------
6608 function Is_Limited_Type
(Id
: E
) return B
is
6609 Btype
: constant E
:= Base_Type
(Id
);
6610 Rtype
: constant E
:= Root_Type
(Btype
);
6613 if not Is_Type
(Id
) then
6616 elsif Ekind
(Btype
) = E_Limited_Private_Type
6617 or else Is_Limited_Composite
(Btype
)
6621 elsif Is_Concurrent_Type
(Btype
) then
6624 -- The Is_Limited_Record flag normally indicates that the type is
6625 -- limited. The exception is that a type does not inherit limitedness
6626 -- from its interface ancestor. So the type may be derived from a
6627 -- limited interface, but is not limited.
6629 elsif Is_Limited_Record
(Id
)
6630 and then not Is_Interface
(Id
)
6634 -- Otherwise we will look around to see if there is some other reason
6635 -- for it to be limited, except that if an error was posted on the
6636 -- entity, then just assume it is non-limited, because it can cause
6637 -- trouble to recurse into a murky erroneous entity!
6639 elsif Error_Posted
(Id
) then
6642 elsif Is_Record_Type
(Btype
) then
6644 if Is_Limited_Interface
(Id
) then
6647 -- AI-419: limitedness is not inherited from a limited interface
6649 elsif Is_Limited_Record
(Rtype
) then
6650 return not Is_Interface
(Rtype
)
6651 or else Is_Protected_Interface
(Rtype
)
6652 or else Is_Synchronized_Interface
(Rtype
)
6653 or else Is_Task_Interface
(Rtype
);
6655 elsif Is_Class_Wide_Type
(Btype
) then
6656 return Is_Limited_Type
(Rtype
);
6663 C
:= First_Component
(Btype
);
6664 while Present
(C
) loop
6665 if Is_Limited_Type
(Etype
(C
)) then
6669 C
:= Next_Component
(C
);
6676 elsif Is_Array_Type
(Btype
) then
6677 return Is_Limited_Type
(Component_Type
(Btype
));
6682 end Is_Limited_Type
;
6684 -----------------------------------
6685 -- Is_Package_Or_Generic_Package --
6686 -----------------------------------
6688 function Is_Package_Or_Generic_Package
(Id
: E
) return B
is
6691 Ekind
(Id
) = E_Package
6693 Ekind
(Id
) = E_Generic_Package
;
6694 end Is_Package_Or_Generic_Package
;
6700 function Is_Prival
(Id
: E
) return B
is
6703 (Ekind
(Id
) = E_Constant
6704 or else Ekind
(Id
) = E_Variable
)
6705 and then Present
(Prival_Link
(Id
));
6708 ----------------------------
6709 -- Is_Protected_Component --
6710 ----------------------------
6712 function Is_Protected_Component
(Id
: E
) return B
is
6714 return Ekind
(Id
) = E_Component
6715 and then Is_Protected_Type
(Scope
(Id
));
6716 end Is_Protected_Component
;
6718 ------------------------------
6719 -- Is_Protected_Record_Type --
6720 ------------------------------
6722 function Is_Protected_Record_Type
(Id
: E
) return B
is
6725 Is_Concurrent_Record_Type
(Id
)
6726 and then Is_Protected_Type
(Corresponding_Concurrent_Type
(Id
));
6727 end Is_Protected_Record_Type
;
6729 --------------------------------
6730 -- Is_Standard_Character_Type --
6731 --------------------------------
6733 function Is_Standard_Character_Type
(Id
: E
) return B
is
6735 if Is_Type
(Id
) then
6737 R
: constant Entity_Id
:= Root_Type
(Id
);
6740 R
= Standard_Character
6742 R
= Standard_Wide_Character
6744 R
= Standard_Wide_Wide_Character
;
6750 end Is_Standard_Character_Type
;
6752 --------------------
6753 -- Is_String_Type --
6754 --------------------
6756 function Is_String_Type
(Id
: E
) return B
is
6758 return Ekind
(Id
) in String_Kind
6759 or else (Is_Array_Type
(Id
)
6760 and then Number_Dimensions
(Id
) = 1
6761 and then Is_Character_Type
(Component_Type
(Id
)));
6764 -------------------------
6765 -- Is_Task_Record_Type --
6766 -------------------------
6768 function Is_Task_Record_Type
(Id
: E
) return B
is
6771 Is_Concurrent_Record_Type
(Id
)
6772 and then Is_Task_Type
(Corresponding_Concurrent_Type
(Id
));
6773 end Is_Task_Record_Type
;
6775 ------------------------
6776 -- Is_Wrapper_Package --
6777 ------------------------
6779 function Is_Wrapper_Package
(Id
: E
) return B
is
6781 return (Ekind
(Id
) = E_Package
6782 and then Present
(Related_Instance
(Id
)));
6783 end Is_Wrapper_Package
;
6785 --------------------
6786 -- Next_Component --
6787 --------------------
6789 function Next_Component
(Id
: E
) return E
is
6793 Comp_Id
:= Next_Entity
(Id
);
6794 while Present
(Comp_Id
) loop
6795 exit when Ekind
(Comp_Id
) = E_Component
;
6796 Comp_Id
:= Next_Entity
(Comp_Id
);
6802 ------------------------------------
6803 -- Next_Component_Or_Discriminant --
6804 ------------------------------------
6806 function Next_Component_Or_Discriminant
(Id
: E
) return E
is
6810 Comp_Id
:= Next_Entity
(Id
);
6811 while Present
(Comp_Id
) loop
6812 exit when Ekind
(Comp_Id
) = E_Component
6814 Ekind
(Comp_Id
) = E_Discriminant
;
6815 Comp_Id
:= Next_Entity
(Comp_Id
);
6819 end Next_Component_Or_Discriminant
;
6821 -----------------------
6822 -- Next_Discriminant --
6823 -----------------------
6825 -- This function actually implements both Next_Discriminant and
6826 -- Next_Stored_Discriminant by making sure that the Discriminant
6827 -- returned is of the same variety as Id.
6829 function Next_Discriminant
(Id
: E
) return E
is
6831 -- Derived Tagged types with private extensions look like this...
6833 -- E_Discriminant d1
6834 -- E_Discriminant d2
6836 -- E_Discriminant d1
6837 -- E_Discriminant d2
6840 -- so it is critical not to go past the leading discriminants
6845 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
6848 D
:= Next_Entity
(D
);
6850 or else (Ekind
(D
) /= E_Discriminant
6851 and then not Is_Itype
(D
))
6856 exit when Ekind
(D
) = E_Discriminant
6857 and then (Is_Completely_Hidden
(D
) = Is_Completely_Hidden
(Id
));
6861 end Next_Discriminant
;
6867 function Next_Formal
(Id
: E
) return E
is
6871 -- Follow the chain of declared entities as long as the kind of the
6872 -- entity corresponds to a formal parameter. Skip internal entities
6873 -- that may have been created for implicit subtypes, in the process
6874 -- of analyzing default expressions.
6879 P
:= Next_Entity
(P
);
6881 if No
(P
) or else Is_Formal
(P
) then
6883 elsif not Is_Internal
(P
) then
6889 -----------------------------
6890 -- Next_Formal_With_Extras --
6891 -----------------------------
6893 function Next_Formal_With_Extras
(Id
: E
) return E
is
6895 if Present
(Extra_Formal
(Id
)) then
6896 return Extra_Formal
(Id
);
6898 return Next_Formal
(Id
);
6900 end Next_Formal_With_Extras
;
6906 function Next_Index
(Id
: Node_Id
) return Node_Id
is
6915 function Next_Literal
(Id
: E
) return E
is
6917 pragma Assert
(Nkind
(Id
) in N_Entity
);
6921 ------------------------------
6922 -- Next_Stored_Discriminant --
6923 ------------------------------
6925 function Next_Stored_Discriminant
(Id
: E
) return E
is
6927 -- See comment in Next_Discriminant
6929 return Next_Discriminant
(Id
);
6930 end Next_Stored_Discriminant
;
6932 -----------------------
6933 -- Number_Dimensions --
6934 -----------------------
6936 function Number_Dimensions
(Id
: E
) return Pos
is
6941 if Ekind
(Id
) in String_Kind
then
6946 T
:= First_Index
(Id
);
6947 while Present
(T
) loop
6954 end Number_Dimensions
;
6956 --------------------------
6957 -- Number_Discriminants --
6958 --------------------------
6960 function Number_Discriminants
(Id
: E
) return Pos
is
6966 Discr
:= First_Discriminant
(Id
);
6967 while Present
(Discr
) loop
6969 Discr
:= Next_Discriminant
(Discr
);
6973 end Number_Discriminants
;
6975 --------------------
6976 -- Number_Entries --
6977 --------------------
6979 function Number_Entries
(Id
: E
) return Nat
is
6984 pragma Assert
(Is_Concurrent_Type
(Id
));
6987 Ent
:= First_Entity
(Id
);
6988 while Present
(Ent
) loop
6989 if Is_Entry
(Ent
) then
6993 Ent
:= Next_Entity
(Ent
);
6999 --------------------
7000 -- Number_Formals --
7001 --------------------
7003 function Number_Formals
(Id
: E
) return Pos
is
7009 Formal
:= First_Formal
(Id
);
7010 while Present
(Formal
) loop
7012 Formal
:= Next_Formal
(Formal
);
7018 --------------------
7019 -- Parameter_Mode --
7020 --------------------
7022 function Parameter_Mode
(Id
: E
) return Formal_Kind
is
7027 ---------------------
7028 -- Record_Rep_Item --
7029 ---------------------
7031 procedure Record_Rep_Item
(E
: Entity_Id
; N
: Node_Id
) is
7033 Set_Next_Rep_Item
(N
, First_Rep_Item
(E
));
7034 Set_First_Rep_Item
(E
, N
);
7035 end Record_Rep_Item
;
7041 function Root_Type
(Id
: E
) return E
is
7045 pragma Assert
(Nkind
(Id
) in N_Entity
);
7047 T
:= Base_Type
(Id
);
7049 if Ekind
(T
) = E_Class_Wide_Type
then
7052 elsif Ekind
(T
) = E_Class_Wide_Subtype
then
7053 return Etype
(Base_Type
(T
));
7055 -- ??? T comes from Base_Type, how can it be a subtype?
7056 -- Also Base_Type is supposed to be idempotent, so either way
7057 -- this is equivalent to "return Etype (T)" and should be merged
7058 -- with the E_Class_Wide_Type case.
7069 -- Following test catches some error cases resulting from
7072 elsif No
(Etyp
) then
7075 elsif Is_Private_Type
(T
) and then Etyp
= Full_View
(T
) then
7078 elsif Is_Private_Type
(Etyp
) and then Full_View
(Etyp
) = T
then
7084 -- Return if there is a circularity in the inheritance chain. This
7085 -- happens in some error situations and we do not want to get
7086 -- stuck in this loop.
7088 if T
= Base_Type
(Id
) then
7099 function Scope_Depth
(Id
: E
) return Uint
is
7104 while Is_Record_Type
(Scop
) loop
7105 Scop
:= Scope
(Scop
);
7108 return Scope_Depth_Value
(Scop
);
7111 ---------------------
7112 -- Scope_Depth_Set --
7113 ---------------------
7115 function Scope_Depth_Set
(Id
: E
) return B
is
7117 return not Is_Record_Type
(Id
)
7118 and then Field22
(Id
) /= Union_Id
(Empty
);
7119 end Scope_Depth_Set
;
7121 -----------------------------
7122 -- Set_Component_Alignment --
7123 -----------------------------
7125 -- Component Alignment is encoded using two flags, Flag128/129 as
7126 -- follows. Note that both flags False = Align_Default, so that the
7127 -- default initialization of flags to False initializes component
7128 -- alignment to the default value as required.
7130 -- Flag128 Flag129 Value
7131 -- ------- ------- -----
7132 -- False False Calign_Default
7133 -- False True Calign_Component_Size
7134 -- True False Calign_Component_Size_4
7135 -- True True Calign_Storage_Unit
7137 procedure Set_Component_Alignment
(Id
: E
; V
: C
) is
7139 pragma Assert
((Is_Array_Type
(Id
) or else Is_Record_Type
(Id
))
7140 and then Id
= Base_Type
(Id
));
7143 when Calign_Default
=>
7144 Set_Flag128
(Id
, False);
7145 Set_Flag129
(Id
, False);
7147 when Calign_Component_Size
=>
7148 Set_Flag128
(Id
, False);
7149 Set_Flag129
(Id
, True);
7151 when Calign_Component_Size_4
=>
7152 Set_Flag128
(Id
, True);
7153 Set_Flag129
(Id
, False);
7155 when Calign_Storage_Unit
=>
7156 Set_Flag128
(Id
, True);
7157 Set_Flag129
(Id
, True);
7159 end Set_Component_Alignment
;
7165 function Size_Clause
(Id
: E
) return N
is
7167 return Rep_Clause
(Id
, Name_Size
);
7170 ------------------------
7171 -- Stream_Size_Clause --
7172 ------------------------
7174 function Stream_Size_Clause
(Id
: E
) return N
is
7176 return Rep_Clause
(Id
, Name_Stream_Size
);
7177 end Stream_Size_Clause
;
7183 function Subtype_Kind
(K
: Entity_Kind
) return Entity_Kind
is
7189 Kind
:= E_Access_Subtype
;
7193 Kind
:= E_Array_Subtype
;
7195 when E_Class_Wide_Type |
7196 E_Class_Wide_Subtype
=>
7197 Kind
:= E_Class_Wide_Subtype
;
7199 when E_Decimal_Fixed_Point_Type |
7200 E_Decimal_Fixed_Point_Subtype
=>
7201 Kind
:= E_Decimal_Fixed_Point_Subtype
;
7203 when E_Ordinary_Fixed_Point_Type |
7204 E_Ordinary_Fixed_Point_Subtype
=>
7205 Kind
:= E_Ordinary_Fixed_Point_Subtype
;
7207 when E_Private_Type |
7208 E_Private_Subtype
=>
7209 Kind
:= E_Private_Subtype
;
7211 when E_Limited_Private_Type |
7212 E_Limited_Private_Subtype
=>
7213 Kind
:= E_Limited_Private_Subtype
;
7215 when E_Record_Type_With_Private |
7216 E_Record_Subtype_With_Private
=>
7217 Kind
:= E_Record_Subtype_With_Private
;
7219 when E_Record_Type |
7221 Kind
:= E_Record_Subtype
;
7223 when E_String_Type |
7225 Kind
:= E_String_Subtype
;
7227 when Enumeration_Kind
=>
7228 Kind
:= E_Enumeration_Subtype
;
7231 Kind
:= E_Floating_Point_Subtype
;
7233 when Signed_Integer_Kind
=>
7234 Kind
:= E_Signed_Integer_Subtype
;
7236 when Modular_Integer_Kind
=>
7237 Kind
:= E_Modular_Integer_Subtype
;
7239 when Protected_Kind
=>
7240 Kind
:= E_Protected_Subtype
;
7243 Kind
:= E_Task_Subtype
;
7247 raise Program_Error
;
7253 -------------------------
7254 -- First_Tag_Component --
7255 -------------------------
7257 function First_Tag_Component
(Id
: E
) return E
is
7259 Typ
: Entity_Id
:= Id
;
7262 pragma Assert
(Is_Tagged_Type
(Typ
));
7264 if Is_Class_Wide_Type
(Typ
) then
7265 Typ
:= Root_Type
(Typ
);
7268 if Is_Private_Type
(Typ
) then
7269 Typ
:= Underlying_Type
(Typ
);
7271 -- If the underlying type is missing then the source program has
7272 -- errors and there is nothing else to do (the full-type declaration
7273 -- associated with the private type declaration is missing).
7280 Comp
:= First_Entity
(Typ
);
7281 while Present
(Comp
) loop
7282 if Is_Tag
(Comp
) then
7286 Comp
:= Next_Entity
(Comp
);
7289 -- No tag component found
7292 end First_Tag_Component
;
7294 ------------------------
7295 -- Next_Tag_Component --
7296 ------------------------
7298 function Next_Tag_Component
(Id
: E
) return E
is
7302 pragma Assert
(Is_Tag
(Id
));
7304 Comp
:= Next_Entity
(Id
);
7305 while Present
(Comp
) loop
7306 if Is_Tag
(Comp
) then
7307 pragma Assert
(Chars
(Comp
) /= Name_uTag
);
7311 Comp
:= Next_Entity
(Comp
);
7314 -- No tag component found
7317 end Next_Tag_Component
;
7319 ---------------------
7320 -- Type_High_Bound --
7321 ---------------------
7323 function Type_High_Bound
(Id
: E
) return Node_Id
is
7324 Rng
: constant Node_Id
:= Scalar_Range
(Id
);
7326 if Nkind
(Rng
) = N_Subtype_Indication
then
7327 return High_Bound
(Range_Expression
(Constraint
(Rng
)));
7329 return High_Bound
(Rng
);
7331 end Type_High_Bound
;
7333 --------------------
7334 -- Type_Low_Bound --
7335 --------------------
7337 function Type_Low_Bound
(Id
: E
) return Node_Id
is
7338 Rng
: constant Node_Id
:= Scalar_Range
(Id
);
7340 if Nkind
(Rng
) = N_Subtype_Indication
then
7341 return Low_Bound
(Range_Expression
(Constraint
(Rng
)));
7343 return Low_Bound
(Rng
);
7347 ---------------------
7348 -- Underlying_Type --
7349 ---------------------
7351 function Underlying_Type
(Id
: E
) return E
is
7353 -- For record_with_private the underlying type is always the direct
7354 -- full view. Never try to take the full view of the parent it
7355 -- doesn't make sense.
7357 if Ekind
(Id
) = E_Record_Type_With_Private
then
7358 return Full_View
(Id
);
7360 elsif Ekind
(Id
) in Incomplete_Or_Private_Kind
then
7362 -- If we have an incomplete or private type with a full view,
7363 -- then we return the Underlying_Type of this full view
7365 if Present
(Full_View
(Id
)) then
7366 if Id
= Full_View
(Id
) then
7368 -- Previous error in declaration
7373 return Underlying_Type
(Full_View
(Id
));
7376 -- If we have an incomplete entity that comes from the limited
7377 -- view then we return the Underlying_Type of its non-limited
7380 elsif From_With_Type
(Id
)
7381 and then Present
(Non_Limited_View
(Id
))
7383 return Underlying_Type
(Non_Limited_View
(Id
));
7385 -- Otherwise check for the case where we have a derived type or
7386 -- subtype, and if so get the Underlying_Type of the parent type.
7388 elsif Etype
(Id
) /= Id
then
7389 return Underlying_Type
(Etype
(Id
));
7391 -- Otherwise we have an incomplete or private type that has
7392 -- no full view, which means that we have not encountered the
7393 -- completion, so return Empty to indicate the underlying type
7394 -- is not yet known.
7400 -- For non-incomplete, non-private types, return the type itself
7401 -- Also for entities that are not types at all return the entity
7407 end Underlying_Type
;
7409 ------------------------
7410 -- Write_Entity_Flags --
7411 ------------------------
7413 procedure Write_Entity_Flags
(Id
: Entity_Id
; Prefix
: String) is
7415 procedure W
(Flag_Name
: String; Flag
: Boolean);
7416 -- Write out given flag if it is set
7422 procedure W
(Flag_Name
: String; Flag
: Boolean) is
7426 Write_Str
(Flag_Name
);
7427 Write_Str
(" = True");
7432 -- Start of processing for Write_Entity_Flags
7435 if (Is_Array_Type
(Id
) or else Is_Record_Type
(Id
))
7436 and then Id
= Base_Type
(Id
)
7439 Write_Str
("Component_Alignment = ");
7441 case Component_Alignment
(Id
) is
7442 when Calign_Default
=>
7443 Write_Str
("Calign_Default");
7445 when Calign_Component_Size
=>
7446 Write_Str
("Calign_Component_Size");
7448 when Calign_Component_Size_4
=>
7449 Write_Str
("Calign_Component_Size_4");
7451 when Calign_Storage_Unit
=>
7452 Write_Str
("Calign_Storage_Unit");
7458 W
("Address_Taken", Flag104
(Id
));
7459 W
("Body_Needed_For_SAL", Flag40
(Id
));
7460 W
("C_Pass_By_Copy", Flag125
(Id
));
7461 W
("Can_Never_Be_Null", Flag38
(Id
));
7462 W
("Checks_May_Be_Suppressed", Flag31
(Id
));
7463 W
("Debug_Info_Off", Flag166
(Id
));
7464 W
("Default_Expressions_Processed", Flag108
(Id
));
7465 W
("Delay_Cleanups", Flag114
(Id
));
7466 W
("Delay_Subprogram_Descriptors", Flag50
(Id
));
7467 W
("Depends_On_Private", Flag14
(Id
));
7468 W
("Discard_Names", Flag88
(Id
));
7469 W
("Elaboration_Entity_Required", Flag174
(Id
));
7470 W
("Elaborate_Body_Desirable", Flag210
(Id
));
7471 W
("Entry_Accepted", Flag152
(Id
));
7472 W
("Can_Use_Internal_Rep", Flag229
(Id
));
7473 W
("Finalize_Storage_Only", Flag158
(Id
));
7474 W
("From_With_Type", Flag159
(Id
));
7475 W
("Function_Returns_With_DSP", Flag169
(Id
));
7476 W
("Has_Aliased_Components", Flag135
(Id
));
7477 W
("Has_Alignment_Clause", Flag46
(Id
));
7478 W
("Has_All_Calls_Remote", Flag79
(Id
));
7479 W
("Has_Anon_Block_Suffix", Flag201
(Id
));
7480 W
("Has_Atomic_Components", Flag86
(Id
));
7481 W
("Has_Biased_Representation", Flag139
(Id
));
7482 W
("Has_Completion", Flag26
(Id
));
7483 W
("Has_Completion_In_Body", Flag71
(Id
));
7484 W
("Has_Complex_Representation", Flag140
(Id
));
7485 W
("Has_Component_Size_Clause", Flag68
(Id
));
7486 W
("Has_Contiguous_Rep", Flag181
(Id
));
7487 W
("Has_Controlled_Component", Flag43
(Id
));
7488 W
("Has_Controlling_Result", Flag98
(Id
));
7489 W
("Has_Convention_Pragma", Flag119
(Id
));
7490 W
("Has_Delayed_Freeze", Flag18
(Id
));
7491 W
("Has_Discriminants", Flag5
(Id
));
7492 W
("Has_Enumeration_Rep_Clause", Flag66
(Id
));
7493 W
("Has_Exit", Flag47
(Id
));
7494 W
("Has_External_Tag_Rep_Clause", Flag110
(Id
));
7495 W
("Has_Forward_Instantiation", Flag175
(Id
));
7496 W
("Has_Fully_Qualified_Name", Flag173
(Id
));
7497 W
("Has_Gigi_Rep_Item", Flag82
(Id
));
7498 W
("Has_Homonym", Flag56
(Id
));
7499 W
("Has_Initial_Value", Flag219
(Id
));
7500 W
("Has_Machine_Radix_Clause", Flag83
(Id
));
7501 W
("Has_Master_Entity", Flag21
(Id
));
7502 W
("Has_Missing_Return", Flag142
(Id
));
7503 W
("Has_Nested_Block_With_Handler", Flag101
(Id
));
7504 W
("Has_Non_Standard_Rep", Flag75
(Id
));
7505 W
("Has_Object_Size_Clause", Flag172
(Id
));
7506 W
("Has_Per_Object_Constraint", Flag154
(Id
));
7507 W
("Has_Persistent_BSS", Flag188
(Id
));
7508 W
("Has_Postconditions", Flag240
(Id
));
7509 W
("Has_Pragma_Controlled", Flag27
(Id
));
7510 W
("Has_Pragma_Elaborate_Body", Flag150
(Id
));
7511 W
("Has_Pragma_Inline", Flag157
(Id
));
7512 W
("Has_Pragma_Inline_Always", Flag230
(Id
));
7513 W
("Has_Pragma_Pack", Flag121
(Id
));
7514 W
("Has_Pragma_Preelab_Init", Flag221
(Id
));
7515 W
("Has_Pragma_Pure", Flag203
(Id
));
7516 W
("Has_Pragma_Pure_Function", Flag179
(Id
));
7517 W
("Has_Pragma_Unmodified", Flag233
(Id
));
7518 W
("Has_Pragma_Unreferenced", Flag180
(Id
));
7519 W
("Has_Pragma_Unreferenced_Objects", Flag212
(Id
));
7520 W
("Has_Primitive_Operations", Flag120
(Id
));
7521 W
("Has_Private_Declaration", Flag155
(Id
));
7522 W
("Has_Qualified_Name", Flag161
(Id
));
7523 W
("Has_RACW", Flag214
(Id
));
7524 W
("Has_Record_Rep_Clause", Flag65
(Id
));
7525 W
("Has_Recursive_Call", Flag143
(Id
));
7526 W
("Has_Size_Clause", Flag29
(Id
));
7527 W
("Has_Small_Clause", Flag67
(Id
));
7528 W
("Has_Specified_Layout", Flag100
(Id
));
7529 W
("Has_Specified_Stream_Input", Flag190
(Id
));
7530 W
("Has_Specified_Stream_Output", Flag191
(Id
));
7531 W
("Has_Specified_Stream_Read", Flag192
(Id
));
7532 W
("Has_Specified_Stream_Write", Flag193
(Id
));
7533 W
("Has_Static_Discriminants", Flag211
(Id
));
7534 W
("Has_Storage_Size_Clause", Flag23
(Id
));
7535 W
("Has_Stream_Size_Clause", Flag184
(Id
));
7536 W
("Has_Subprogram_Descriptor", Flag93
(Id
));
7537 W
("Has_Task", Flag30
(Id
));
7538 W
("Has_Thunks", Flag228
(Id
));
7539 W
("Has_Unchecked_Union", Flag123
(Id
));
7540 W
("Has_Unknown_Discriminants", Flag72
(Id
));
7541 W
("Has_Up_Level_Access", Flag215
(Id
));
7542 W
("Has_Volatile_Components", Flag87
(Id
));
7543 W
("Has_Xref_Entry", Flag182
(Id
));
7544 W
("Implemented_By_Entry", Flag232
(Id
));
7545 W
("In_Package_Body", Flag48
(Id
));
7546 W
("In_Private_Part", Flag45
(Id
));
7547 W
("In_Use", Flag8
(Id
));
7548 W
("Is_AST_Entry", Flag132
(Id
));
7549 W
("Is_Abstract_Subprogram", Flag19
(Id
));
7550 W
("Is_Abstract_Type", Flag146
(Id
));
7551 W
("Is_Local_Anonymous_Access", Flag194
(Id
));
7552 W
("Is_Access_Constant", Flag69
(Id
));
7553 W
("Is_Ada_2005_Only", Flag185
(Id
));
7554 W
("Is_Aliased", Flag15
(Id
));
7555 W
("Is_Asynchronous", Flag81
(Id
));
7556 W
("Is_Atomic", Flag85
(Id
));
7557 W
("Is_Bit_Packed_Array", Flag122
(Id
));
7558 W
("Is_CPP_Class", Flag74
(Id
));
7559 W
("Is_Called", Flag102
(Id
));
7560 W
("Is_Character_Type", Flag63
(Id
));
7561 W
("Is_Child_Unit", Flag73
(Id
));
7562 W
("Is_Class_Wide_Equivalent_Type", Flag35
(Id
));
7563 W
("Is_Compilation_Unit", Flag149
(Id
));
7564 W
("Is_Completely_Hidden", Flag103
(Id
));
7565 W
("Is_Concurrent_Record_Type", Flag20
(Id
));
7566 W
("Is_Constr_Subt_For_UN_Aliased", Flag141
(Id
));
7567 W
("Is_Constr_Subt_For_U_Nominal", Flag80
(Id
));
7568 W
("Is_Constrained", Flag12
(Id
));
7569 W
("Is_Constructor", Flag76
(Id
));
7570 W
("Is_Controlled", Flag42
(Id
));
7571 W
("Is_Controlling_Formal", Flag97
(Id
));
7572 W
("Is_Descendent_Of_Address", Flag223
(Id
));
7573 W
("Is_Discrim_SO_Function", Flag176
(Id
));
7574 W
("Is_Dispatch_Table_Entity", Flag234
(Id
));
7575 W
("Is_Dispatching_Operation", Flag6
(Id
));
7576 W
("Is_Eliminated", Flag124
(Id
));
7577 W
("Is_Entry_Formal", Flag52
(Id
));
7578 W
("Is_Exported", Flag99
(Id
));
7579 W
("Is_First_Subtype", Flag70
(Id
));
7580 W
("Is_For_Access_Subtype", Flag118
(Id
));
7581 W
("Is_Formal_Subprogram", Flag111
(Id
));
7582 W
("Is_Frozen", Flag4
(Id
));
7583 W
("Is_Generic_Actual_Type", Flag94
(Id
));
7584 W
("Is_Generic_Instance", Flag130
(Id
));
7585 W
("Is_Generic_Type", Flag13
(Id
));
7586 W
("Is_Hidden", Flag57
(Id
));
7587 W
("Is_Hidden_Open_Scope", Flag171
(Id
));
7588 W
("Is_Immediately_Visible", Flag7
(Id
));
7589 W
("Is_Imported", Flag24
(Id
));
7590 W
("Is_Inlined", Flag11
(Id
));
7591 W
("Is_Instantiated", Flag126
(Id
));
7592 W
("Is_Interface", Flag186
(Id
));
7593 W
("Is_Internal", Flag17
(Id
));
7594 W
("Is_Interrupt_Handler", Flag89
(Id
));
7595 W
("Is_Intrinsic_Subprogram", Flag64
(Id
));
7596 W
("Is_Itype", Flag91
(Id
));
7597 W
("Is_Known_Non_Null", Flag37
(Id
));
7598 W
("Is_Known_Null", Flag204
(Id
));
7599 W
("Is_Known_Valid", Flag170
(Id
));
7600 W
("Is_Limited_Composite", Flag106
(Id
));
7601 W
("Is_Limited_Interface", Flag197
(Id
));
7602 W
("Is_Limited_Record", Flag25
(Id
));
7603 W
("Is_Machine_Code_Subprogram", Flag137
(Id
));
7604 W
("Is_Non_Static_Subtype", Flag109
(Id
));
7605 W
("Is_Null_Init_Proc", Flag178
(Id
));
7606 W
("Is_Obsolescent", Flag153
(Id
));
7607 W
("Is_Only_Out_Parameter", Flag226
(Id
));
7608 W
("Is_Optional_Parameter", Flag134
(Id
));
7609 W
("Is_Overriding_Operation", Flag39
(Id
));
7610 W
("Is_Package_Body_Entity", Flag160
(Id
));
7611 W
("Is_Packed", Flag51
(Id
));
7612 W
("Is_Packed_Array_Type", Flag138
(Id
));
7613 W
("Is_Potentially_Use_Visible", Flag9
(Id
));
7614 W
("Is_Preelaborated", Flag59
(Id
));
7615 W
("Is_Primitive_Wrapper", Flag195
(Id
));
7616 W
("Is_Private_Composite", Flag107
(Id
));
7617 W
("Is_Private_Descendant", Flag53
(Id
));
7618 W
("Is_Protected_Interface", Flag198
(Id
));
7619 W
("Is_Public", Flag10
(Id
));
7620 W
("Is_Pure", Flag44
(Id
));
7621 W
("Is_Pure_Unit_Access_Type", Flag189
(Id
));
7622 W
("Is_RACW_Stub_Type", Flag244
(Id
));
7623 W
("Is_Raised", Flag224
(Id
));
7624 W
("Is_Remote_Call_Interface", Flag62
(Id
));
7625 W
("Is_Remote_Types", Flag61
(Id
));
7626 W
("Is_Renaming_Of_Object", Flag112
(Id
));
7627 W
("Is_Return_Object", Flag209
(Id
));
7628 W
("Is_Shared_Passive", Flag60
(Id
));
7629 W
("Is_Synchronized_Interface", Flag199
(Id
));
7630 W
("Is_Statically_Allocated", Flag28
(Id
));
7631 W
("Is_Tag", Flag78
(Id
));
7632 W
("Is_Tagged_Type", Flag55
(Id
));
7633 W
("Is_Task_Interface", Flag200
(Id
));
7634 W
("Is_Thunk", Flag225
(Id
));
7635 W
("Is_Trivial_Subprogram", Flag235
(Id
));
7636 W
("Is_True_Constant", Flag163
(Id
));
7637 W
("Is_Unchecked_Union", Flag117
(Id
));
7638 W
("Is_Unsigned_Type", Flag144
(Id
));
7639 W
("Is_VMS_Exception", Flag133
(Id
));
7640 W
("Is_Valued_Procedure", Flag127
(Id
));
7641 W
("Is_Visible_Child_Unit", Flag116
(Id
));
7642 W
("Is_Visible_Formal", Flag206
(Id
));
7643 W
("Is_Volatile", Flag16
(Id
));
7644 W
("Itype_Printed", Flag202
(Id
));
7645 W
("Kill_Elaboration_Checks", Flag32
(Id
));
7646 W
("Kill_Range_Checks", Flag33
(Id
));
7647 W
("Kill_Tag_Checks", Flag34
(Id
));
7648 W
("Known_To_Have_Preelab_Init", Flag207
(Id
));
7649 W
("Low_Bound_Known", Flag205
(Id
));
7650 W
("Machine_Radix_10", Flag84
(Id
));
7651 W
("Materialize_Entity", Flag168
(Id
));
7652 W
("Must_Be_On_Byte_Boundary", Flag183
(Id
));
7653 W
("Must_Have_Preelab_Init", Flag208
(Id
));
7654 W
("Needs_Debug_Info", Flag147
(Id
));
7655 W
("Needs_No_Actuals", Flag22
(Id
));
7656 W
("Never_Set_In_Source", Flag115
(Id
));
7657 W
("No_Pool_Assigned", Flag131
(Id
));
7658 W
("No_Return", Flag113
(Id
));
7659 W
("No_Strict_Aliasing", Flag136
(Id
));
7660 W
("Non_Binary_Modulus", Flag58
(Id
));
7661 W
("Nonzero_Is_True", Flag162
(Id
));
7662 W
("OK_To_Reorder_Components", Flag239
(Id
));
7663 W
("Optimize_Alignment_Space", Flag241
(Id
));
7664 W
("Optimize_Alignment_Time", Flag242
(Id
));
7665 W
("Overlays_Constant", Flag243
(Id
));
7666 W
("Reachable", Flag49
(Id
));
7667 W
("Referenced", Flag156
(Id
));
7668 W
("Referenced_As_LHS", Flag36
(Id
));
7669 W
("Referenced_As_Out_Parameter", Flag227
(Id
));
7670 W
("Renamed_In_Spec", Flag231
(Id
));
7671 W
("Requires_Overriding", Flag213
(Id
));
7672 W
("Return_Present", Flag54
(Id
));
7673 W
("Returns_By_Ref", Flag90
(Id
));
7674 W
("Reverse_Bit_Order", Flag164
(Id
));
7675 W
("Sec_Stack_Needed_For_Return", Flag167
(Id
));
7676 W
("Size_Depends_On_Discriminant", Flag177
(Id
));
7677 W
("Size_Known_At_Compile_Time", Flag92
(Id
));
7678 W
("Static_Elaboration_Desired", Flag77
(Id
));
7679 W
("Strict_Alignment", Flag145
(Id
));
7680 W
("Suppress_Elaboration_Warnings", Flag148
(Id
));
7681 W
("Suppress_Init_Proc", Flag105
(Id
));
7682 W
("Suppress_Style_Checks", Flag165
(Id
));
7683 W
("Suppress_Value_Tracking_On_Call", Flag217
(Id
));
7684 W
("Is_Primitive", Flag218
(Id
));
7685 W
("Treat_As_Volatile", Flag41
(Id
));
7686 W
("Universal_Aliasing", Flag216
(Id
));
7687 W
("Used_As_Generic_Actual", Flag222
(Id
));
7688 W
("Uses_Sec_Stack", Flag95
(Id
));
7689 W
("Vax_Float", Flag151
(Id
));
7690 W
("Warnings_Off", Flag96
(Id
));
7691 W
("Warnings_Off_Used", Flag236
(Id
));
7692 W
("Warnings_Off_Used_Unmodified", Flag237
(Id
));
7693 W
("Warnings_Off_Used_Unreferenced", Flag238
(Id
));
7694 W
("Was_Hidden", Flag196
(Id
));
7695 end Write_Entity_Flags
;
7697 -----------------------
7698 -- Write_Entity_Info --
7699 -----------------------
7701 procedure Write_Entity_Info
(Id
: Entity_Id
; Prefix
: String) is
7703 procedure Write_Attribute
(Which
: String; Nam
: E
);
7704 -- Write attribute value with given string name
7706 procedure Write_Kind
(Id
: Entity_Id
);
7707 -- Write Ekind field of entity
7709 ---------------------
7710 -- Write_Attribute --
7711 ---------------------
7713 procedure Write_Attribute
(Which
: String; Nam
: E
) is
7717 Write_Int
(Int
(Nam
));
7719 Write_Name
(Chars
(Nam
));
7721 end Write_Attribute
;
7727 procedure Write_Kind
(Id
: Entity_Id
) is
7728 K
: constant String := Entity_Kind
'Image (Ekind
(Id
));
7732 Write_Str
(" Kind ");
7734 if Is_Type
(Id
) and then Is_Tagged_Type
(Id
) then
7735 Write_Str
("TAGGED ");
7738 Write_Str
(K
(3 .. K
'Length));
7741 if Is_Type
(Id
) and then Depends_On_Private
(Id
) then
7742 Write_Str
("Depends_On_Private ");
7746 -- Start of processing for Write_Entity_Info
7750 Write_Attribute
("Name ", Id
);
7751 Write_Int
(Int
(Id
));
7755 Write_Attribute
(" Type ", Etype
(Id
));
7757 Write_Attribute
(" Scope ", Scope
(Id
));
7762 when Discrete_Kind
=>
7763 Write_Str
("Bounds: Id = ");
7765 if Present
(Scalar_Range
(Id
)) then
7766 Write_Int
(Int
(Type_Low_Bound
(Id
)));
7767 Write_Str
(" .. Id = ");
7768 Write_Int
(Int
(Type_High_Bound
(Id
)));
7770 Write_Str
("Empty");
7781 (" Component Type ", Component_Type
(Id
));
7784 Write_Str
(" Indices ");
7786 Index
:= First_Index
(Id
);
7787 while Present
(Index
) loop
7788 Write_Attribute
(" ", Etype
(Index
));
7789 Index
:= Next_Index
(Index
);
7797 (" Directly Designated Type ",
7798 Directly_Designated_Type
(Id
));
7801 when Overloadable_Kind
=>
7802 if Present
(Homonym
(Id
)) then
7803 Write_Str
(" Homonym ");
7804 Write_Name
(Chars
(Homonym
(Id
)));
7806 Write_Int
(Int
(Homonym
(Id
)));
7813 if Ekind
(Scope
(Id
)) in Record_Kind
then
7815 " Original_Record_Component ",
7816 Original_Record_Component
(Id
));
7817 Write_Int
(Int
(Original_Record_Component
(Id
)));
7821 when others => null;
7823 end Write_Entity_Info
;
7825 -----------------------
7826 -- Write_Field6_Name --
7827 -----------------------
7829 procedure Write_Field6_Name
(Id
: Entity_Id
) is
7830 pragma Warnings
(Off
, Id
);
7832 Write_Str
("First_Rep_Item");
7833 end Write_Field6_Name
;
7835 -----------------------
7836 -- Write_Field7_Name --
7837 -----------------------
7839 procedure Write_Field7_Name
(Id
: Entity_Id
) is
7840 pragma Warnings
(Off
, Id
);
7842 Write_Str
("Freeze_Node");
7843 end Write_Field7_Name
;
7845 -----------------------
7846 -- Write_Field8_Name --
7847 -----------------------
7849 procedure Write_Field8_Name
(Id
: Entity_Id
) is
7854 Write_Str
("Normalized_First_Bit");
7858 E_Subprogram_Body
=>
7859 Write_Str
("Mechanism");
7862 Write_Str
("Associated_Node_For_Itype");
7865 Write_Str
("Dependent_Instances");
7867 when E_Return_Statement
=>
7868 Write_Str
("Return_Applies_To");
7871 Write_Str
("Hiding_Loop_Variable");
7874 Write_Str
("Field8??");
7876 end Write_Field8_Name
;
7878 -----------------------
7879 -- Write_Field9_Name --
7880 -----------------------
7882 procedure Write_Field9_Name
(Id
: Entity_Id
) is
7886 Write_Str
("Class_Wide_Type");
7889 E_Generic_Function |
7891 E_Generic_Procedure |
7894 Write_Str
("Renaming_Map");
7897 Write_Str
("Current_Value");
7900 Write_Str
("Field9??");
7902 end Write_Field9_Name
;
7904 ------------------------
7905 -- Write_Field10_Name --
7906 ------------------------
7908 procedure Write_Field10_Name
(Id
: Entity_Id
) is
7912 Write_Str
("Referenced_Object");
7914 when E_In_Parameter |
7916 Write_Str
("Discriminal_Link");
7922 Write_Str
("Handler_Records");
7926 Write_Str
("Normalized_Position_Max");
7929 Write_Str
("Field10??");
7931 end Write_Field10_Name
;
7933 ------------------------
7934 -- Write_Field11_Name --
7935 ------------------------
7937 procedure Write_Field11_Name
(Id
: Entity_Id
) is
7941 Write_Str
("Entry_Component");
7945 Write_Str
("Component_Bit_Offset");
7948 Write_Str
("Full_View");
7950 when E_Enumeration_Literal
=>
7951 Write_Str
("Enumeration_Pos");
7954 Write_Str
("Block_Node");
7960 Write_Str
("Protected_Body_Subprogram");
7962 when E_Generic_Package
=>
7963 Write_Str
("Generic_Homonym");
7966 Write_Str
("Full_View");
7969 Write_Str
("Field11??");
7971 end Write_Field11_Name
;
7973 ------------------------
7974 -- Write_Field12_Name --
7975 ------------------------
7977 procedure Write_Field12_Name
(Id
: Entity_Id
) is
7981 Write_Str
("Barrier_Function");
7983 when E_Enumeration_Literal
=>
7984 Write_Str
("Enumeration_Rep");
7992 E_In_Out_Parameter |
7996 Write_Str
("Esize");
8000 Write_Str
("Next_Inlined_Subprogram");
8003 Write_Str
("Associated_Formal_Package");
8006 Write_Str
("Field12??");
8008 end Write_Field12_Name
;
8010 ------------------------
8011 -- Write_Field13_Name --
8012 ------------------------
8014 procedure Write_Field13_Name
(Id
: Entity_Id
) is
8018 Write_Str
("RM_Size");
8022 Write_Str
("Component_Clause");
8025 if not Comes_From_Source
(Id
)
8027 Chars
(Id
) = Name_Op_Ne
8029 Write_Str
("Corresponding_Equality");
8031 elsif Comes_From_Source
(Id
) then
8032 Write_Str
("Elaboration_Entity");
8035 Write_Str
("Field13??");
8040 Write_Str
("Extra_Accessibility");
8044 Generic_Unit_Kind
=>
8045 Write_Str
("Elaboration_Entity");
8048 Write_Str
("Field13??");
8050 end Write_Field13_Name
;
8052 -----------------------
8053 -- Write_Field14_Name --
8054 -----------------------
8056 procedure Write_Field14_Name
(Id
: Entity_Id
) is
8065 Write_Str
("Alignment");
8069 Write_Str
("Normalized_Position");
8073 Write_Str
("First_Optional_Parameter");
8076 E_Generic_Package
=>
8077 Write_Str
("Shadow_Entities");
8080 Write_Str
("Field14??");
8082 end Write_Field14_Name
;
8084 ------------------------
8085 -- Write_Field15_Name --
8086 ------------------------
8088 procedure Write_Field15_Name
(Id
: Entity_Id
) is
8093 Write_Str
("Storage_Size_Variable");
8095 when Class_Wide_Kind |
8099 Write_Str
("Primitive_Operations");
8102 Write_Str
("DT_Entry_Count");
8104 when Decimal_Fixed_Point_Kind
=>
8105 Write_Str
("Scale_Value");
8107 when E_Discriminant
=>
8108 Write_Str
("Discriminant_Number");
8111 Write_Str
("Extra_Formal");
8115 Write_Str
("DT_Position");
8118 Write_Str
("Entry_Parameters_Type");
8120 when Enumeration_Kind
=>
8121 Write_Str
("Lit_Indexes");
8125 Write_Str
("Related_Instance");
8127 when E_Protected_Type
=>
8128 Write_Str
("Entry_Bodies_Array");
8130 when E_String_Literal_Subtype
=>
8131 Write_Str
("String_Literal_Low_Bound");
8134 Write_Str
("Field15??");
8136 end Write_Field15_Name
;
8138 ------------------------
8139 -- Write_Field16_Name --
8140 ------------------------
8142 procedure Write_Field16_Name
(Id
: Entity_Id
) is
8146 Write_Str
("Entry_Formal");
8150 Write_Str
("DTC_Entity");
8155 Write_Str
("First_Private_Entity");
8157 when E_Record_Type |
8158 E_Record_Type_With_Private
=>
8159 Write_Str
("Access_Disp_Table");
8161 when E_String_Literal_Subtype
=>
8162 Write_Str
("String_Literal_Length");
8164 when Enumeration_Kind
=>
8165 Write_Str
("Lit_Strings");
8169 Write_Str
("Unset_Reference");
8171 when E_Record_Subtype |
8172 E_Class_Wide_Subtype
=>
8173 Write_Str
("Cloned_Subtype");
8176 Write_Str
("Field16??");
8178 end Write_Field16_Name
;
8180 ------------------------
8181 -- Write_Field17_Name --
8182 ------------------------
8184 procedure Write_Field17_Name
(Id
: Entity_Id
) is
8188 Write_Str
("Digits_Value");
8191 Write_Str
("Prival");
8193 when E_Discriminant
=>
8194 Write_Str
("Discriminal");
8203 E_Generic_Function |
8205 E_Generic_Procedure |
8213 E_Return_Statement |
8215 E_Subprogram_Type
=>
8216 Write_Str
("First_Entity");
8219 Write_Str
("First_Index");
8221 when Enumeration_Kind
=>
8222 Write_Str
("First_Literal");
8225 Write_Str
("Master_Id");
8227 when Modular_Integer_Kind
=>
8228 Write_Str
("Modulus");
8232 E_Generic_In_Out_Parameter |
8234 Write_Str
("Actual_Subtype");
8236 when E_Incomplete_Type
=>
8237 Write_Str
("Non_Limited_View");
8239 when E_Incomplete_Subtype
=>
8240 if From_With_Type
(Id
) then
8241 Write_Str
("Non_Limited_View");
8245 Write_Str
("Field17??");
8247 end Write_Field17_Name
;
8249 ------------------------
8250 -- Write_Field18_Name --
8251 ------------------------
8253 procedure Write_Field18_Name
(Id
: Entity_Id
) is
8256 when E_Enumeration_Literal |
8260 Write_Str
("Alias");
8262 when E_Record_Type
=>
8263 Write_Str
("Corresponding_Concurrent_Type");
8265 when E_Entry_Index_Parameter
=>
8266 Write_Str
("Entry_Index_Constant");
8268 when E_Class_Wide_Subtype |
8269 E_Access_Protected_Subprogram_Type |
8270 E_Anonymous_Access_Protected_Subprogram_Type |
8271 E_Access_Subprogram_Type |
8273 Write_Str
("Equivalent_Type");
8275 when Fixed_Point_Kind
=>
8276 Write_Str
("Delta_Value");
8279 Write_Str
("Renamed_Object");
8283 E_Generic_Function |
8284 E_Generic_Procedure |
8285 E_Generic_Package
=>
8286 Write_Str
("Renamed_Entity");
8288 when Incomplete_Or_Private_Kind
=>
8289 Write_Str
("Private_Dependents");
8291 when Concurrent_Kind
=>
8292 Write_Str
("Corresponding_Record_Type");
8297 Write_Str
("Enclosing_Scope");
8300 Write_Str
("Field18??");
8302 end Write_Field18_Name
;
8304 -----------------------
8305 -- Write_Field19_Name --
8306 -----------------------
8308 procedure Write_Field19_Name
(Id
: Entity_Id
) is
8313 Write_Str
("Related_Array_Object");
8319 E_Return_Statement |
8321 Write_Str
("Finalization_Chain_Entity");
8323 when E_Constant | E_Variable
=>
8324 Write_Str
("Size_Check_Code");
8326 when E_Discriminant
=>
8327 Write_Str
("Corresponding_Discriminant");
8330 E_Generic_Package
=>
8331 Write_Str
("Body_Entity");
8333 when E_Package_Body |
8335 Write_Str
("Spec_Entity");
8337 when Private_Kind
=>
8338 Write_Str
("Underlying_Full_View");
8340 when E_Record_Type
=>
8341 Write_Str
("Parent_Subtype");
8344 Write_Str
("Field19??");
8346 end Write_Field19_Name
;
8348 -----------------------
8349 -- Write_Field20_Name --
8350 -----------------------
8352 procedure Write_Field20_Name
(Id
: Entity_Id
) is
8356 Write_Str
("Component_Type");
8358 when E_In_Parameter |
8359 E_Generic_In_Parameter
=>
8360 Write_Str
("Default_Value");
8363 Write_Str
("Directly_Designated_Type");
8366 Write_Str
("Discriminant_Checking_Func");
8370 Write_Str
("Prival_Link");
8372 when E_Discriminant
=>
8373 Write_Str
("Discriminant_Default_Value");
8382 E_Generic_Function |
8384 E_Generic_Procedure |
8392 E_Return_Statement |
8394 E_Subprogram_Type
=>
8396 Write_Str
("Last_Entity");
8399 Write_Str
("Scalar_Range");
8402 Write_Str
("Register_Exception_Call");
8405 Write_Str
("Field20??");
8407 end Write_Field20_Name
;
8409 -----------------------
8410 -- Write_Field21_Name --
8411 -----------------------
8413 procedure Write_Field21_Name
(Id
: Entity_Id
) is
8419 E_Generic_Function |
8421 E_Generic_Procedure |
8423 Write_Str
("Interface_Name");
8425 when Concurrent_Kind |
8426 Incomplete_Or_Private_Kind |
8430 Write_Str
("Discriminant_Constraint");
8433 Write_Str
("Accept_Address");
8435 when Fixed_Point_Kind
=>
8436 Write_Str
("Small_Value");
8438 when E_In_Parameter
=>
8439 Write_Str
("Default_Expr_Function");
8442 Modular_Integer_Kind
=>
8443 Write_Str
("Original_Array_Type");
8446 Write_Str
("Field21??");
8448 end Write_Field21_Name
;
8450 -----------------------
8451 -- Write_Field22_Name --
8452 -----------------------
8454 procedure Write_Field22_Name
(Id
: Entity_Id
) is
8458 Write_Str
("Associated_Storage_Pool");
8461 Write_Str
("Component_Size");
8465 Write_Str
("Original_Record_Component");
8467 when E_Enumeration_Literal
=>
8468 Write_Str
("Enumeration_Rep_Expr");
8471 Write_Str
("Exception_Code");
8474 Write_Str
("Protected_Formal");
8476 when E_Record_Type
=>
8477 Write_Str
("Corresponding_Remote_Type");
8487 E_Generic_Function |
8488 E_Generic_Procedure |
8491 E_Return_Statement |
8494 Write_Str
("Scope_Depth_Value");
8496 when E_Record_Type_With_Private |
8497 E_Record_Subtype_With_Private |
8500 E_Limited_Private_Type |
8501 E_Limited_Private_Subtype
=>
8502 Write_Str
("Private_View");
8505 Write_Str
("Shared_Var_Procs_Instance");
8508 Write_Str
("Field22??");
8510 end Write_Field22_Name
;
8512 ------------------------
8513 -- Write_Field23_Name --
8514 ------------------------
8516 procedure Write_Field23_Name
(Id
: Entity_Id
) is
8520 Write_Str
("Associated_Final_Chain");
8523 Write_Str
("Packed_Array_Type");
8526 Write_Str
("Entry_Cancel_Parameter");
8528 when E_Discriminant
=>
8529 Write_Str
("CR_Discriminant");
8531 when E_Enumeration_Type
=>
8532 Write_Str
("Enum_Pos_To_Rep");
8536 Write_Str
("Extra_Constrained");
8538 when E_Generic_Function |
8540 E_Generic_Procedure
=>
8541 Write_Str
("Inner_Instances");
8543 when Concurrent_Kind |
8544 Incomplete_Or_Private_Kind |
8548 Write_Str
("Stored_Constraint");
8552 if Present
(Scope
(Id
))
8553 and then Is_Protected_Type
(Scope
(Id
))
8555 Write_Str
("Protection_Object");
8557 Write_Str
("Generic_Renamings");
8561 if Is_Generic_Instance
(Id
) then
8562 Write_Str
("Generic_Renamings");
8564 Write_Str
("Limited_View");
8568 Write_Str
("Protection_Object");
8571 Write_Str
("Field23??");
8573 end Write_Field23_Name
;
8575 ------------------------
8576 -- Write_Field24_Name --
8577 ------------------------
8579 procedure Write_Field24_Name
(Id
: Entity_Id
) is
8582 when Subprogram_Kind
=>
8583 Write_Str
("Spec_PPC_List");
8588 end Write_Field24_Name
;
8590 ------------------------
8591 -- Write_Field25_Name --
8592 ------------------------
8594 procedure Write_Field25_Name
(Id
: Entity_Id
) is
8598 Write_Str
("DT_Offset_To_Top_Func");
8602 Write_Str
("Interface_Alias");
8604 when E_Record_Type |
8606 E_Record_Type_With_Private |
8607 E_Record_Subtype_With_Private
=>
8608 Write_Str
("Interfaces");
8611 Write_Str
("Task_Body_Procedure");
8614 Write_Str
("Debug_Renaming_Link");
8617 Write_Str
("Field25??");
8619 end Write_Field25_Name
;
8621 ------------------------
8622 -- Write_Field26_Name --
8623 ------------------------
8625 procedure Write_Field26_Name
(Id
: Entity_Id
) is
8630 Write_Str
("Related_Type");
8632 when E_Generic_Package |
8634 Write_Str
("Package_Instantiation");
8639 if Is_Dispatching_Operation
(Id
) then
8640 Write_Str
("Overridden_Operation");
8642 Write_Str
("Static_Initialization");
8645 when E_Record_Type |
8646 E_Record_Type_With_Private
=>
8647 Write_Str
("Dispatch_Table_Wrapper");
8649 when E_In_Out_Parameter |
8652 Write_Str
("Last_Assignment");
8655 Write_Str
("Relative_Deadline_Variable");
8658 Write_Str
("Field26??");
8660 end Write_Field26_Name
;
8662 ------------------------
8663 -- Write_Field27_Name --
8664 ------------------------
8666 procedure Write_Field27_Name
(Id
: Entity_Id
) is
8670 Write_Str
("Wrapped_Entity");
8672 when E_Package | Type_Kind
=>
8673 Write_Str
("Current_Use_Clause");
8676 Write_Str
("Field27??");
8678 end Write_Field27_Name
;
8680 ------------------------
8681 -- Write_Field28_Name --
8682 ------------------------
8684 procedure Write_Field28_Name
(Id
: Entity_Id
) is
8687 when E_Procedure | E_Function | E_Entry
=>
8688 Write_Str
("Extra_Formals");
8691 Write_Str
("Field28??");
8693 end Write_Field28_Name
;
8695 -------------------------
8696 -- Iterator Procedures --
8697 -------------------------
8699 procedure Proc_Next_Component
(N
: in out Node_Id
) is
8701 N
:= Next_Component
(N
);
8702 end Proc_Next_Component
;
8704 procedure Proc_Next_Component_Or_Discriminant
(N
: in out Node_Id
) is
8706 N
:= Next_Entity
(N
);
8707 while Present
(N
) loop
8708 exit when Ekind
(N
) = E_Component
8710 Ekind
(N
) = E_Discriminant
;
8711 N
:= Next_Entity
(N
);
8713 end Proc_Next_Component_Or_Discriminant
;
8715 procedure Proc_Next_Discriminant
(N
: in out Node_Id
) is
8717 N
:= Next_Discriminant
(N
);
8718 end Proc_Next_Discriminant
;
8720 procedure Proc_Next_Formal
(N
: in out Node_Id
) is
8722 N
:= Next_Formal
(N
);
8723 end Proc_Next_Formal
;
8725 procedure Proc_Next_Formal_With_Extras
(N
: in out Node_Id
) is
8727 N
:= Next_Formal_With_Extras
(N
);
8728 end Proc_Next_Formal_With_Extras
;
8730 procedure Proc_Next_Index
(N
: in out Node_Id
) is
8732 N
:= Next_Index
(N
);
8733 end Proc_Next_Index
;
8735 procedure Proc_Next_Inlined_Subprogram
(N
: in out Node_Id
) is
8737 N
:= Next_Inlined_Subprogram
(N
);
8738 end Proc_Next_Inlined_Subprogram
;
8740 procedure Proc_Next_Literal
(N
: in out Node_Id
) is
8742 N
:= Next_Literal
(N
);
8743 end Proc_Next_Literal
;
8745 procedure Proc_Next_Stored_Discriminant
(N
: in out Node_Id
) is
8747 N
:= Next_Stored_Discriminant
(N
);
8748 end Proc_Next_Stored_Discriminant
;