1 ------------------------------------------------------------------------------
3 -- GNAT COMPILER COMPONENTS --
9 -- Copyright (C) 1992-2013, Free Software Foundation, Inc. --
11 -- GNAT is free software; you can redistribute it and/or modify it under --
12 -- terms of the GNU General Public License as published by the Free Soft- --
13 -- ware Foundation; either version 3, or (at your option) any later ver- --
14 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
15 -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
16 -- or FITNESS FOR A PARTICULAR PURPOSE. --
18 -- As a special exception under Section 7 of GPL version 3, you are granted --
19 -- additional permissions described in the GCC Runtime Library Exception, --
20 -- version 3.1, as published by the Free Software Foundation. --
22 -- You should have received a copy of the GNU General Public License and --
23 -- a copy of the GCC Runtime Library Exception along with this program; --
24 -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
25 -- <http://www.gnu.org/licenses/>. --
27 -- GNAT was originally developed by the GNAT team at New York University. --
28 -- Extensive contributions were provided by Ada Core Technologies Inc. --
30 ------------------------------------------------------------------------------
32 pragma Style_Checks
(All_Checks
);
33 -- Turn off subprogram ordering, not used for this unit
35 with Atree
; use Atree
;
36 with Elists
; use Elists
;
37 with Namet
; use Namet
;
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 base
55 -- part of the node. The access routines for these four fields and the
56 -- corresponding set procedures are defined in Sinfo. These fields are
57 -- present in all entities. Note that Homonym is also in the base part of
58 -- the node, but has access routines that are more properly part of Einfo,
59 -- 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 -- Postcondition_Proc Node8
83 -- Refinement_Constituents Elist8
84 -- Return_Applies_To Node8
85 -- First_Exit_Statement Node8
87 -- Class_Wide_Type Node9
88 -- Current_Value Node9
91 -- Direct_Primitive_Operations Elist10
92 -- Discriminal_Link Node10
93 -- Float_Rep Uint10 (but returns Float_Rep_Kind)
94 -- Handler_Records List10
95 -- Normalized_Position_Max Uint10
96 -- Refined_State Node10
98 -- Component_Bit_Offset Uint11
100 -- Entry_Component Node11
101 -- Enumeration_Pos Uint11
102 -- Generic_Homonym Node11
103 -- Protected_Body_Subprogram Node11
106 -- Barrier_Function Node12
107 -- Enumeration_Rep Uint12
109 -- Next_Inlined_Subprogram Node12
111 -- Component_Clause Node13
112 -- Elaboration_Entity Node13
113 -- Extra_Accessibility Node13
117 -- First_Optional_Parameter Node14
118 -- Normalized_Position Uint14
119 -- Shadow_Entities List14
121 -- Discriminant_Number Uint15
122 -- DT_Position Uint15
123 -- DT_Entry_Count Uint15
124 -- Entry_Bodies_Array Node15
125 -- Entry_Parameters_Type Node15
126 -- Extra_Formal Node15
127 -- Lit_Indexes Node15
128 -- Related_Instance Node15
129 -- Status_Flag_Or_Transient_Decl Node15
130 -- Scale_Value Uint15
131 -- Storage_Size_Variable Node15
132 -- String_Literal_Low_Bound Node15
134 -- Access_Disp_Table Elist16
135 -- Body_References Elist16
136 -- Cloned_Subtype Node16
138 -- Entry_Formal Node16
139 -- First_Private_Entity Node16
140 -- Lit_Strings Node16
141 -- String_Literal_Length Uint16
142 -- Unset_Reference Node16
144 -- Actual_Subtype Node17
145 -- Digits_Value Uint17
146 -- Discriminal Node17
147 -- First_Entity Node17
148 -- First_Index Node17
149 -- First_Literal Node17
152 -- Non_Limited_View Node17
156 -- Corresponding_Concurrent_Type Node18
157 -- Corresponding_Protected_Entry Node18
158 -- Corresponding_Record_Type Node18
159 -- Delta_Value Ureal18
160 -- Enclosing_Scope Node18
161 -- Equivalent_Type Node18
162 -- Private_Dependents Elist18
163 -- Renamed_Entity Node18
164 -- Renamed_Object Node18
166 -- Body_Entity Node19
167 -- Corresponding_Discriminant Node19
168 -- Default_Aspect_Component_Value Node19
169 -- Default_Aspect_Value Node19
170 -- Extra_Accessibility_Of_Result Node19
171 -- Parent_Subtype Node19
172 -- Size_Check_Code Node19
173 -- Spec_Entity Node19
174 -- Underlying_Full_View Node19
176 -- Component_Type Node20
177 -- Default_Value Node20
178 -- Directly_Designated_Type Node20
179 -- Discriminant_Checking_Func Node20
180 -- Discriminant_Default_Value Node20
181 -- Last_Entity Node20
182 -- Prival_Link Node20
183 -- Register_Exception_Call Node20
184 -- Scalar_Range Node20
186 -- Accept_Address Elist21
187 -- Default_Expr_Function Node21
188 -- Discriminant_Constraint Elist21
189 -- Interface_Name Node21
190 -- Original_Array_Type Node21
191 -- Small_Value Ureal21
193 -- Associated_Storage_Pool Node22
194 -- Component_Size Uint22
195 -- Corresponding_Remote_Type Node22
196 -- Enumeration_Rep_Expr Node22
197 -- Exception_Code Uint22
198 -- Original_Record_Component Node22
199 -- Private_View Node22
200 -- Protected_Formal Node22
201 -- Scope_Depth_Value Uint22
202 -- Shared_Var_Procs_Instance Node22
204 -- CR_Discriminant Node23
205 -- Entry_Cancel_Parameter Node23
206 -- Enum_Pos_To_Rep Node23
207 -- Extra_Constrained Node23
208 -- Finalization_Master Node23
209 -- Generic_Renamings Elist23
210 -- Inner_Instances Elist23
211 -- Limited_View Node23
212 -- Packed_Array_Type Node23
213 -- Protection_Object Node23
214 -- Stored_Constraint Elist23
216 -- Related_Expression Node24
219 -- Interface_Alias Node25
220 -- Interfaces Elist25
221 -- Debug_Renaming_Link Node25
222 -- DT_Offset_To_Top_Func Node25
223 -- PPC_Wrapper Node25
224 -- Related_Array_Object Node25
225 -- Static_Predicate List25
226 -- Task_Body_Procedure Node25
228 -- Dispatch_Table_Wrappers Elist26
229 -- Last_Assignment Node26
230 -- Original_Access_Type Node26
231 -- Overridden_Operation Node26
232 -- Package_Instantiation Node26
233 -- Relative_Deadline_Variable Node26
235 -- Current_Use_Clause Node27
236 -- Related_Type Node27
237 -- Wrapped_Entity Node27
239 -- Extra_Formals Node28
241 -- Initialization_Statements Node28
242 -- Underlying_Record_View Node28
244 -- Subprograms_For_Type Node29
246 -- Corresponding_Equality Node30
247 -- Static_Initialization Node30
249 -- Thunk_Entity Node31
251 -- SPARK_Mode_Pragmas Node32
259 ---------------------------------------------
260 -- Usage of Flags in Defining Entity Nodes --
261 ---------------------------------------------
263 -- All flags are unique, there is no overlaying, so each flag is physically
264 -- present in every entity. However, for many of the flags, it only makes
265 -- sense for them to be set true for certain subsets of entity kinds. See
266 -- the spec of Einfo for further details.
268 -- Note: Flag1-Flag3 are not used, for historical reasons
271 -- Has_Discriminants Flag5
272 -- Is_Dispatching_Operation Flag6
273 -- Is_Immediately_Visible Flag7
275 -- Is_Potentially_Use_Visible Flag9
279 -- Is_Constrained Flag12
280 -- Is_Generic_Type Flag13
281 -- Depends_On_Private Flag14
283 -- Is_Volatile Flag16
284 -- Is_Internal Flag17
285 -- Has_Delayed_Freeze Flag18
286 -- Is_Abstract_Subprogram Flag19
287 -- Is_Concurrent_Record_Type Flag20
289 -- Has_Master_Entity Flag21
290 -- Needs_No_Actuals Flag22
291 -- Has_Storage_Size_Clause Flag23
292 -- Is_Imported Flag24
293 -- Is_Limited_Record Flag25
294 -- Has_Completion Flag26
295 -- Has_Pragma_Controlled Flag27
296 -- Is_Statically_Allocated Flag28
297 -- Has_Size_Clause Flag29
300 -- Checks_May_Be_Suppressed Flag31
301 -- Kill_Elaboration_Checks Flag32
302 -- Kill_Range_Checks Flag33
303 -- Has_Independent_Components Flag34
304 -- Is_Class_Wide_Equivalent_Type Flag35
305 -- Referenced_As_LHS Flag36
306 -- Is_Known_Non_Null Flag37
307 -- Can_Never_Be_Null Flag38
308 -- Has_Default_Aspect Flag39
309 -- Body_Needed_For_SAL Flag40
311 -- Treat_As_Volatile Flag41
312 -- Is_Controlled Flag42
313 -- Has_Controlled_Component Flag43
315 -- In_Private_Part Flag45
316 -- Has_Alignment_Clause Flag46
318 -- In_Package_Body Flag48
320 -- Delay_Subprogram_Descriptors Flag50
323 -- Is_Entry_Formal Flag52
324 -- Is_Private_Descendant Flag53
325 -- Return_Present Flag54
326 -- Is_Tagged_Type Flag55
327 -- Has_Homonym Flag56
329 -- Non_Binary_Modulus Flag58
330 -- Is_Preelaborated Flag59
331 -- Is_Shared_Passive Flag60
333 -- Is_Remote_Types Flag61
334 -- Is_Remote_Call_Interface Flag62
335 -- Is_Character_Type Flag63
336 -- Is_Intrinsic_Subprogram Flag64
337 -- Has_Record_Rep_Clause Flag65
338 -- Has_Enumeration_Rep_Clause Flag66
339 -- Has_Small_Clause Flag67
340 -- Has_Component_Size_Clause Flag68
341 -- Is_Access_Constant Flag69
342 -- Is_First_Subtype Flag70
344 -- Has_Completion_In_Body Flag71
345 -- Has_Unknown_Discriminants Flag72
346 -- Is_Child_Unit Flag73
347 -- Is_CPP_Class Flag74
348 -- Has_Non_Standard_Rep Flag75
349 -- Is_Constructor Flag76
350 -- Static_Elaboration_Desired Flag77
352 -- Has_All_Calls_Remote Flag79
353 -- Is_Constr_Subt_For_U_Nominal Flag80
355 -- Is_Asynchronous Flag81
356 -- Has_Gigi_Rep_Item Flag82
357 -- Has_Machine_Radix_Clause Flag83
358 -- Machine_Radix_10 Flag84
360 -- Has_Atomic_Components Flag86
361 -- Has_Volatile_Components Flag87
362 -- Discard_Names Flag88
363 -- Is_Interrupt_Handler Flag89
364 -- Returns_By_Ref Flag90
367 -- Size_Known_At_Compile_Time Flag92
368 -- Reverse_Storage_Order Flag93
369 -- Is_Generic_Actual_Type Flag94
370 -- Uses_Sec_Stack Flag95
371 -- Warnings_Off Flag96
372 -- Is_Controlling_Formal Flag97
373 -- Has_Controlling_Result Flag98
374 -- Is_Exported Flag99
375 -- Has_Specified_Layout Flag100
377 -- Has_Nested_Block_With_Handler Flag101
379 -- Is_Completely_Hidden Flag103
380 -- Address_Taken Flag104
381 -- Suppress_Initialization Flag105
382 -- Is_Limited_Composite Flag106
383 -- Is_Private_Composite Flag107
384 -- Default_Expressions_Processed Flag108
385 -- Is_Non_Static_Subtype Flag109
386 -- Has_External_Tag_Rep_Clause Flag110
388 -- Is_Formal_Subprogram Flag111
389 -- Is_Renaming_Of_Object Flag112
391 -- Delay_Cleanups Flag114
392 -- Never_Set_In_Source Flag115
393 -- Is_Visible_Lib_Unit Flag116
394 -- Is_Unchecked_Union Flag117
395 -- Is_For_Access_Subtype Flag118
396 -- Has_Convention_Pragma Flag119
397 -- Has_Primitive_Operations Flag120
399 -- Has_Pragma_Pack Flag121
400 -- Is_Bit_Packed_Array Flag122
401 -- Has_Unchecked_Union Flag123
402 -- Is_Eliminated Flag124
403 -- C_Pass_By_Copy Flag125
404 -- Is_Instantiated Flag126
405 -- Is_Valued_Procedure Flag127
406 -- (used for Component_Alignment) Flag128
407 -- (used for Component_Alignment) Flag129
408 -- Is_Generic_Instance Flag130
410 -- No_Pool_Assigned Flag131
411 -- Is_AST_Entry Flag132
412 -- Is_VMS_Exception Flag133
413 -- Is_Optional_Parameter Flag134
414 -- Has_Aliased_Components Flag135
415 -- No_Strict_Aliasing Flag136
416 -- Is_Machine_Code_Subprogram Flag137
417 -- Is_Packed_Array_Type Flag138
418 -- Has_Biased_Representation Flag139
419 -- Has_Complex_Representation Flag140
421 -- Is_Constr_Subt_For_UN_Aliased Flag141
422 -- Has_Missing_Return Flag142
423 -- Has_Recursive_Call Flag143
424 -- Is_Unsigned_Type Flag144
425 -- Strict_Alignment Flag145
426 -- Is_Abstract_Type Flag146
427 -- Needs_Debug_Info Flag147
428 -- Suppress_Elaboration_Warnings Flag148
429 -- Is_Compilation_Unit Flag149
430 -- Has_Pragma_Elaborate_Body Flag150
432 -- Has_Private_Ancestor Flag151
433 -- Entry_Accepted Flag152
434 -- Is_Obsolescent Flag153
435 -- Has_Per_Object_Constraint Flag154
436 -- Has_Private_Declaration Flag155
437 -- Referenced Flag156
438 -- Has_Pragma_Inline Flag157
439 -- Finalize_Storage_Only Flag158
440 -- From_Limited_With Flag159
441 -- Is_Package_Body_Entity Flag160
443 -- Has_Qualified_Name Flag161
444 -- Nonzero_Is_True Flag162
445 -- Is_True_Constant Flag163
446 -- Reverse_Bit_Order Flag164
447 -- Suppress_Style_Checks Flag165
448 -- Debug_Info_Off Flag166
449 -- Sec_Stack_Needed_For_Return Flag167
450 -- Materialize_Entity Flag168
451 -- Has_Pragma_Thread_Local_Storage Flag169
452 -- Is_Known_Valid Flag170
454 -- Is_Hidden_Open_Scope Flag171
455 -- Has_Object_Size_Clause Flag172
456 -- Has_Fully_Qualified_Name Flag173
457 -- Elaboration_Entity_Required Flag174
458 -- Has_Forward_Instantiation Flag175
459 -- Is_Discrim_SO_Function Flag176
460 -- Size_Depends_On_Discriminant Flag177
461 -- Is_Null_Init_Proc Flag178
462 -- Has_Pragma_Pure_Function Flag179
463 -- Has_Pragma_Unreferenced Flag180
465 -- Has_Contiguous_Rep Flag181
466 -- Has_Xref_Entry Flag182
467 -- Must_Be_On_Byte_Boundary Flag183
468 -- Has_Stream_Size_Clause Flag184
469 -- Is_Ada_2005_Only Flag185
470 -- Is_Interface Flag186
471 -- Has_Constrained_Partial_View Flag187
472 -- Uses_Lock_Free Flag188
473 -- Is_Pure_Unit_Access_Type Flag189
474 -- Has_Specified_Stream_Input Flag190
476 -- Has_Specified_Stream_Output Flag191
477 -- Has_Specified_Stream_Read Flag192
478 -- Has_Specified_Stream_Write Flag193
479 -- Is_Local_Anonymous_Access Flag194
480 -- Is_Primitive_Wrapper Flag195
481 -- Was_Hidden Flag196
482 -- Is_Limited_Interface Flag197
483 -- Has_Pragma_Ordered Flag198
484 -- Is_Ada_2012_Only Flag199
486 -- Has_Delayed_Aspects Flag200
487 -- Has_Pragma_No_Inline Flag201
488 -- Itype_Printed Flag202
489 -- Has_Pragma_Pure Flag203
490 -- Is_Known_Null Flag204
491 -- Low_Bound_Tested Flag205
492 -- Is_Visible_Formal Flag206
493 -- Known_To_Have_Preelab_Init Flag207
494 -- Must_Have_Preelab_Init Flag208
495 -- Is_Return_Object Flag209
496 -- Elaborate_Body_Desirable Flag210
498 -- Has_Static_Discriminants Flag211
499 -- Has_Pragma_Unreferenced_Objects Flag212
500 -- Requires_Overriding Flag213
502 -- Has_Up_Level_Access Flag215
503 -- Universal_Aliasing Flag216
504 -- Suppress_Value_Tracking_On_Call Flag217
505 -- Is_Primitive Flag218
506 -- Has_Initial_Value Flag219
507 -- Has_Dispatch_Table Flag220
509 -- Has_Pragma_Preelab_Init Flag221
510 -- Used_As_Generic_Actual Flag222
511 -- Is_Descendent_Of_Address Flag223
514 -- Is_Only_Out_Parameter Flag226
515 -- Referenced_As_Out_Parameter Flag227
516 -- Has_Thunks Flag228
517 -- Can_Use_Internal_Rep Flag229
518 -- Has_Pragma_Inline_Always Flag230
520 -- Renamed_In_Spec Flag231
521 -- Has_Invariants Flag232
522 -- Has_Pragma_Unmodified Flag233
523 -- Is_Dispatch_Table_Entity Flag234
524 -- Is_Trivial_Subprogram Flag235
525 -- Warnings_Off_Used Flag236
526 -- Warnings_Off_Used_Unmodified Flag237
527 -- Warnings_Off_Used_Unreferenced Flag238
528 -- OK_To_Reorder_Components Flag239
529 -- Has_Postconditions Flag240
531 -- Optimize_Alignment_Space Flag241
532 -- Optimize_Alignment_Time Flag242
533 -- Overlays_Constant Flag243
534 -- Is_RACW_Stub_Type Flag244
535 -- Is_Private_Primitive Flag245
536 -- Is_Underlying_Record_View Flag246
537 -- OK_To_Rename Flag247
538 -- Has_Inheritable_Invariants Flag248
539 -- Is_Safe_To_Reevaluate Flag249
540 -- Has_Predicates Flag250
542 -- Has_Implicit_Dereference Flag251
543 -- Is_Processed_Transient Flag252
544 -- Has_Anonymous_Master Flag253
545 -- Is_Implementation_Defined Flag254
546 -- Is_Predicate_Function Flag255
547 -- Is_Predicate_Function_M Flag256
548 -- Is_Invariant_Procedure Flag257
549 -- Has_Dynamic_Predicate_Aspect Flag258
550 -- Has_Static_Predicate_Aspect Flag259
551 -- Has_Loop_Entry_Attributes Flag260
553 -- Has_Delayed_Rep_Aspects Flag261
554 -- May_Inherit_Delayed_Rep_Aspects Flag262
555 -- Has_Visible_Refinement Flag263
556 -- Has_Body_References Flag264
583 -- Note: Flag287-317 are defined in atree.ads/adb, but not yet in atree.h
585 -----------------------
586 -- Local subprograms --
587 -----------------------
591 Opt_Nam
: Name_Id
) return Boolean;
592 -- Determine whether abstract state State has a particular option denoted
593 -- by the name Opt_Nam.
599 function Float_Rep
(Id
: E
) return F
is
600 pragma Assert
(Is_Floating_Point_Type
(Id
));
602 return F
'Val (UI_To_Int
(Uint10
(Base_Type
(Id
))));
611 Opt_Nam
: Name_Id
) return Boolean
613 Par
: constant Node_Id
:= Parent
(State
);
617 pragma Assert
(Ekind
(State
) = E_Abstract_State
);
619 -- States with options appear as extension aggregates in the tree
621 if Nkind
(Par
) = N_Extension_Aggregate
then
622 if Opt_Nam
= Name_Part_Of
then
623 return Present
(Component_Associations
(Par
));
626 Opt
:= First
(Expressions
(Par
));
627 while Present
(Opt
) loop
628 if Chars
(Opt
) = Opt_Nam
then
640 --------------------------------
641 -- Attribute Access Functions --
642 --------------------------------
644 function Abstract_States
(Id
: E
) return L
is
646 pragma Assert
(Ekind_In
(Id
, E_Generic_Package
, E_Package
));
650 function Accept_Address
(Id
: E
) return L
is
655 function Access_Disp_Table
(Id
: E
) return L
is
657 pragma Assert
(Ekind_In
(Id
, E_Record_Type
,
659 return Elist16
(Implementation_Base_Type
(Id
));
660 end Access_Disp_Table
;
662 function Actual_Subtype
(Id
: E
) return E
is
665 (Ekind_In
(Id
, E_Constant
, E_Variable
, E_Generic_In_Out_Parameter
)
666 or else Is_Formal
(Id
));
670 function Address_Taken
(Id
: E
) return B
is
675 function Alias
(Id
: E
) return E
is
678 (Is_Overloadable
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
682 function Alignment
(Id
: E
) return U
is
684 pragma Assert
(Is_Type
(Id
)
685 or else Is_Formal
(Id
)
686 or else Ekind_In
(Id
, E_Loop_Parameter
,
693 function Associated_Formal_Package
(Id
: E
) return E
is
695 pragma Assert
(Ekind
(Id
) = E_Package
);
697 end Associated_Formal_Package
;
699 function Associated_Node_For_Itype
(Id
: E
) return N
is
702 end Associated_Node_For_Itype
;
704 function Associated_Storage_Pool
(Id
: E
) return E
is
706 pragma Assert
(Is_Access_Type
(Id
));
707 return Node22
(Root_Type
(Id
));
708 end Associated_Storage_Pool
;
710 function Barrier_Function
(Id
: E
) return N
is
712 pragma Assert
(Is_Entry
(Id
));
714 end Barrier_Function
;
716 function Block_Node
(Id
: E
) return N
is
718 pragma Assert
(Ekind
(Id
) = E_Block
);
722 function Body_Entity
(Id
: E
) return E
is
724 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
728 function Body_Needed_For_SAL
(Id
: E
) return B
is
731 (Ekind
(Id
) = E_Package
732 or else Is_Subprogram
(Id
)
733 or else Is_Generic_Unit
(Id
));
735 end Body_Needed_For_SAL
;
737 function Body_References
(Id
: E
) return L
is
739 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
743 function C_Pass_By_Copy
(Id
: E
) return B
is
745 pragma Assert
(Is_Record_Type
(Id
));
746 return Flag125
(Implementation_Base_Type
(Id
));
749 function Can_Never_Be_Null
(Id
: E
) return B
is
752 end Can_Never_Be_Null
;
754 function Checks_May_Be_Suppressed
(Id
: E
) return B
is
757 end Checks_May_Be_Suppressed
;
759 function Class_Wide_Type
(Id
: E
) return E
is
761 pragma Assert
(Is_Type
(Id
));
765 function Cloned_Subtype
(Id
: E
) return E
is
767 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
, E_Class_Wide_Subtype
));
771 function Component_Bit_Offset
(Id
: E
) return U
is
773 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
775 end Component_Bit_Offset
;
777 function Component_Clause
(Id
: E
) return N
is
779 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
781 end Component_Clause
;
783 function Component_Size
(Id
: E
) return U
is
785 pragma Assert
(Is_Array_Type
(Id
));
786 return Uint22
(Implementation_Base_Type
(Id
));
789 function Component_Type
(Id
: E
) return E
is
791 pragma Assert
(Is_Array_Type
(Id
) or else Is_String_Type
(Id
));
792 return Node20
(Implementation_Base_Type
(Id
));
795 function Corresponding_Concurrent_Type
(Id
: E
) return E
is
797 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
799 end Corresponding_Concurrent_Type
;
801 function Corresponding_Discriminant
(Id
: E
) return E
is
803 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
805 end Corresponding_Discriminant
;
807 function Corresponding_Equality
(Id
: E
) return E
is
810 (Ekind
(Id
) = E_Function
811 and then not Comes_From_Source
(Id
)
812 and then Chars
(Id
) = Name_Op_Ne
);
814 end Corresponding_Equality
;
816 function Corresponding_Protected_Entry
(Id
: E
) return E
is
818 pragma Assert
(Ekind
(Id
) = E_Subprogram_Body
);
820 end Corresponding_Protected_Entry
;
822 function Corresponding_Record_Type
(Id
: E
) return E
is
824 pragma Assert
(Is_Concurrent_Type
(Id
));
826 end Corresponding_Record_Type
;
828 function Corresponding_Remote_Type
(Id
: E
) return E
is
831 end Corresponding_Remote_Type
;
833 function Current_Use_Clause
(Id
: E
) return E
is
835 pragma Assert
(Ekind
(Id
) = E_Package
or else Is_Type
(Id
));
837 end Current_Use_Clause
;
839 function Current_Value
(Id
: E
) return N
is
841 pragma Assert
(Ekind
(Id
) in Object_Kind
);
845 function CR_Discriminant
(Id
: E
) return E
is
850 function Debug_Info_Off
(Id
: E
) return B
is
855 function Debug_Renaming_Link
(Id
: E
) return E
is
858 end Debug_Renaming_Link
;
860 function Default_Aspect_Component_Value
(Id
: E
) return N
is
862 pragma Assert
(Is_Array_Type
(Id
));
863 return Node19
(Base_Type
(Id
));
864 end Default_Aspect_Component_Value
;
866 function Default_Aspect_Value
(Id
: E
) return N
is
868 pragma Assert
(Is_Scalar_Type
(Id
));
869 return Node19
(Base_Type
(Id
));
870 end Default_Aspect_Value
;
872 function Default_Expr_Function
(Id
: E
) return E
is
874 pragma Assert
(Is_Formal
(Id
));
876 end Default_Expr_Function
;
878 function Default_Expressions_Processed
(Id
: E
) return B
is
881 end Default_Expressions_Processed
;
883 function Default_Value
(Id
: E
) return N
is
885 pragma Assert
(Is_Formal
(Id
));
889 function Delay_Cleanups
(Id
: E
) return B
is
894 function Delay_Subprogram_Descriptors
(Id
: E
) return B
is
897 end Delay_Subprogram_Descriptors
;
899 function Delta_Value
(Id
: E
) return R
is
901 pragma Assert
(Is_Fixed_Point_Type
(Id
));
905 function Dependent_Instances
(Id
: E
) return L
is
907 pragma Assert
(Is_Generic_Instance
(Id
));
909 end Dependent_Instances
;
911 function Depends_On_Private
(Id
: E
) return B
is
913 pragma Assert
(Nkind
(Id
) in N_Entity
);
915 end Depends_On_Private
;
917 function Digits_Value
(Id
: E
) return U
is
920 (Is_Floating_Point_Type
(Id
)
921 or else Is_Decimal_Fixed_Point_Type
(Id
));
925 function Direct_Primitive_Operations
(Id
: E
) return L
is
927 pragma Assert
(Is_Tagged_Type
(Id
));
929 end Direct_Primitive_Operations
;
931 function Directly_Designated_Type
(Id
: E
) return E
is
933 pragma Assert
(Is_Access_Type
(Id
));
935 end Directly_Designated_Type
;
937 function Discard_Names
(Id
: E
) return B
is
942 function Discriminal
(Id
: E
) return E
is
944 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
948 function Discriminal_Link
(Id
: E
) return N
is
951 end Discriminal_Link
;
953 function Discriminant_Checking_Func
(Id
: E
) return E
is
955 pragma Assert
(Ekind
(Id
) = E_Component
);
957 end Discriminant_Checking_Func
;
959 function Discriminant_Constraint
(Id
: E
) return L
is
961 pragma Assert
(Is_Composite_Type
(Id
) and then Has_Discriminants
(Id
));
963 end Discriminant_Constraint
;
965 function Discriminant_Default_Value
(Id
: E
) return N
is
967 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
969 end Discriminant_Default_Value
;
971 function Discriminant_Number
(Id
: E
) return U
is
973 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
975 end Discriminant_Number
;
977 function Dispatch_Table_Wrappers
(Id
: E
) return L
is
979 pragma Assert
(Ekind_In
(Id
, E_Record_Type
,
981 return Elist26
(Implementation_Base_Type
(Id
));
982 end Dispatch_Table_Wrappers
;
984 function DT_Entry_Count
(Id
: E
) return U
is
986 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
990 function DT_Offset_To_Top_Func
(Id
: E
) return E
is
992 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
994 end DT_Offset_To_Top_Func
;
996 function DT_Position
(Id
: E
) return U
is
998 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
999 and then Present
(DTC_Entity
(Id
)));
1003 function DTC_Entity
(Id
: E
) return E
is
1005 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
1009 function Elaborate_Body_Desirable
(Id
: E
) return B
is
1011 pragma Assert
(Ekind
(Id
) = E_Package
);
1012 return Flag210
(Id
);
1013 end Elaborate_Body_Desirable
;
1015 function Elaboration_Entity
(Id
: E
) return E
is
1020 Ekind
(Id
) = E_Package
1022 Is_Generic_Unit
(Id
));
1024 end Elaboration_Entity
;
1026 function Elaboration_Entity_Required
(Id
: E
) return B
is
1031 Ekind
(Id
) = E_Package
1033 Is_Generic_Unit
(Id
));
1034 return Flag174
(Id
);
1035 end Elaboration_Entity_Required
;
1037 function Enclosing_Scope
(Id
: E
) return E
is
1040 end Enclosing_Scope
;
1042 function Entry_Accepted
(Id
: E
) return B
is
1044 pragma Assert
(Is_Entry
(Id
));
1045 return Flag152
(Id
);
1048 function Entry_Bodies_Array
(Id
: E
) return E
is
1051 end Entry_Bodies_Array
;
1053 function Entry_Cancel_Parameter
(Id
: E
) return E
is
1056 end Entry_Cancel_Parameter
;
1058 function Entry_Component
(Id
: E
) return E
is
1061 end Entry_Component
;
1063 function Entry_Formal
(Id
: E
) return E
is
1068 function Entry_Index_Constant
(Id
: E
) return N
is
1070 pragma Assert
(Ekind
(Id
) = E_Entry_Index_Parameter
);
1072 end Entry_Index_Constant
;
1074 function Contract
(Id
: E
) return N
is
1077 (Ekind_In
(Id
, E_Entry
,
1083 or else Is_Generic_Subprogram
(Id
)
1084 or else Is_Subprogram
(Id
));
1088 function Entry_Parameters_Type
(Id
: E
) return E
is
1091 end Entry_Parameters_Type
;
1093 function Enum_Pos_To_Rep
(Id
: E
) return E
is
1095 pragma Assert
(Ekind
(Id
) = E_Enumeration_Type
);
1097 end Enum_Pos_To_Rep
;
1099 function Enumeration_Pos
(Id
: E
) return Uint
is
1101 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
1103 end Enumeration_Pos
;
1105 function Enumeration_Rep
(Id
: E
) return U
is
1107 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
1109 end Enumeration_Rep
;
1111 function Enumeration_Rep_Expr
(Id
: E
) return N
is
1113 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
1115 end Enumeration_Rep_Expr
;
1117 function Equivalent_Type
(Id
: E
) return E
is
1120 (Ekind_In
(Id
, E_Class_Wide_Type
,
1121 E_Class_Wide_Subtype
,
1122 E_Access_Subprogram_Type
,
1123 E_Access_Protected_Subprogram_Type
,
1124 E_Anonymous_Access_Protected_Subprogram_Type
,
1125 E_Access_Subprogram_Type
,
1128 end Equivalent_Type
;
1130 function Esize
(Id
: E
) return Uint
is
1135 function Exception_Code
(Id
: E
) return Uint
is
1137 pragma Assert
(Ekind
(Id
) = E_Exception
);
1141 function Extra_Accessibility
(Id
: E
) return E
is
1144 (Is_Formal
(Id
) or else Ekind_In
(Id
, E_Variable
, E_Constant
));
1146 end Extra_Accessibility
;
1148 function Extra_Accessibility_Of_Result
(Id
: E
) return E
is
1150 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Operator
, E_Subprogram_Type
));
1152 end Extra_Accessibility_Of_Result
;
1154 function Extra_Constrained
(Id
: E
) return E
is
1156 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
1158 end Extra_Constrained
;
1160 function Extra_Formal
(Id
: E
) return E
is
1165 function Extra_Formals
(Id
: E
) return E
is
1168 (Is_Overloadable
(Id
)
1169 or else Ekind_In
(Id
, E_Entry_Family
,
1171 E_Subprogram_Type
));
1175 function Can_Use_Internal_Rep
(Id
: E
) return B
is
1177 pragma Assert
(Is_Access_Subprogram_Type
(Base_Type
(Id
)));
1178 return Flag229
(Base_Type
(Id
));
1179 end Can_Use_Internal_Rep
;
1181 function Finalization_Master
(Id
: E
) return E
is
1183 pragma Assert
(Is_Access_Type
(Id
));
1184 return Node23
(Root_Type
(Id
));
1185 end Finalization_Master
;
1187 function Finalize_Storage_Only
(Id
: E
) return B
is
1189 pragma Assert
(Is_Type
(Id
));
1190 return Flag158
(Base_Type
(Id
));
1191 end Finalize_Storage_Only
;
1193 function Finalizer
(Id
: E
) return E
is
1195 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Package_Body
));
1199 function First_Entity
(Id
: E
) return E
is
1204 function First_Exit_Statement
(Id
: E
) return N
is
1206 pragma Assert
(Ekind
(Id
) = E_Loop
);
1208 end First_Exit_Statement
;
1210 function First_Index
(Id
: E
) return N
is
1212 pragma Assert
(Is_Array_Type
(Id
) or else Is_String_Type
(Id
));
1216 function First_Literal
(Id
: E
) return E
is
1218 pragma Assert
(Is_Enumeration_Type
(Id
));
1222 function First_Optional_Parameter
(Id
: E
) return E
is
1224 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
1226 end First_Optional_Parameter
;
1228 function First_Private_Entity
(Id
: E
) return E
is
1230 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
)
1231 or else Ekind
(Id
) in Concurrent_Kind
);
1233 end First_Private_Entity
;
1235 function First_Rep_Item
(Id
: E
) return E
is
1240 function Freeze_Node
(Id
: E
) return N
is
1245 function From_Limited_With
(Id
: E
) return B
is
1247 return Flag159
(Id
);
1248 end From_Limited_With
;
1250 function Full_View
(Id
: E
) return E
is
1252 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Constant
);
1256 function Generic_Homonym
(Id
: E
) return E
is
1258 pragma Assert
(Ekind
(Id
) = E_Generic_Package
);
1260 end Generic_Homonym
;
1262 function Generic_Renamings
(Id
: E
) return L
is
1264 return Elist23
(Id
);
1265 end Generic_Renamings
;
1267 function Handler_Records
(Id
: E
) return S
is
1270 end Handler_Records
;
1272 function Has_Aliased_Components
(Id
: E
) return B
is
1274 return Flag135
(Implementation_Base_Type
(Id
));
1275 end Has_Aliased_Components
;
1277 function Has_Alignment_Clause
(Id
: E
) return B
is
1280 end Has_Alignment_Clause
;
1282 function Has_All_Calls_Remote
(Id
: E
) return B
is
1285 end Has_All_Calls_Remote
;
1287 function Has_Anonymous_Master
(Id
: E
) return B
is
1290 (Ekind_In
(Id
, E_Function
, E_Package
, E_Package_Body
, E_Procedure
));
1291 return Flag253
(Id
);
1292 end Has_Anonymous_Master
;
1294 function Has_Atomic_Components
(Id
: E
) return B
is
1296 return Flag86
(Implementation_Base_Type
(Id
));
1297 end Has_Atomic_Components
;
1299 function Has_Biased_Representation
(Id
: E
) return B
is
1301 return Flag139
(Id
);
1302 end Has_Biased_Representation
;
1304 function Has_Body_References
(Id
: E
) return B
is
1306 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
1307 return Flag264
(Id
);
1308 end Has_Body_References
;
1310 function Has_Completion
(Id
: E
) return B
is
1315 function Has_Completion_In_Body
(Id
: E
) return B
is
1317 pragma Assert
(Is_Type
(Id
));
1319 end Has_Completion_In_Body
;
1321 function Has_Complex_Representation
(Id
: E
) return B
is
1323 pragma Assert
(Is_Type
(Id
));
1324 return Flag140
(Implementation_Base_Type
(Id
));
1325 end Has_Complex_Representation
;
1327 function Has_Component_Size_Clause
(Id
: E
) return B
is
1329 pragma Assert
(Is_Array_Type
(Id
));
1330 return Flag68
(Implementation_Base_Type
(Id
));
1331 end Has_Component_Size_Clause
;
1333 function Has_Constrained_Partial_View
(Id
: E
) return B
is
1335 pragma Assert
(Is_Type
(Id
));
1336 return Flag187
(Id
);
1337 end Has_Constrained_Partial_View
;
1339 function Has_Controlled_Component
(Id
: E
) return B
is
1341 return Flag43
(Base_Type
(Id
));
1342 end Has_Controlled_Component
;
1344 function Has_Contiguous_Rep
(Id
: E
) return B
is
1346 return Flag181
(Id
);
1347 end Has_Contiguous_Rep
;
1349 function Has_Controlling_Result
(Id
: E
) return B
is
1352 end Has_Controlling_Result
;
1354 function Has_Convention_Pragma
(Id
: E
) return B
is
1356 return Flag119
(Id
);
1357 end Has_Convention_Pragma
;
1359 function Has_Default_Aspect
(Id
: E
) return B
is
1361 return Flag39
(Base_Type
(Id
));
1362 end Has_Default_Aspect
;
1364 function Has_Delayed_Aspects
(Id
: E
) return B
is
1366 pragma Assert
(Nkind
(Id
) in N_Entity
);
1367 return Flag200
(Id
);
1368 end Has_Delayed_Aspects
;
1370 function Has_Delayed_Freeze
(Id
: E
) return B
is
1372 pragma Assert
(Nkind
(Id
) in N_Entity
);
1374 end Has_Delayed_Freeze
;
1376 function Has_Delayed_Rep_Aspects
(Id
: E
) return B
is
1378 pragma Assert
(Nkind
(Id
) in N_Entity
);
1379 return Flag261
(Id
);
1380 end Has_Delayed_Rep_Aspects
;
1382 function Has_Discriminants
(Id
: E
) return B
is
1384 pragma Assert
(Nkind
(Id
) in N_Entity
);
1386 end Has_Discriminants
;
1388 function Has_Dispatch_Table
(Id
: E
) return B
is
1390 pragma Assert
(Is_Tagged_Type
(Id
));
1391 return Flag220
(Id
);
1392 end Has_Dispatch_Table
;
1394 function Has_Dynamic_Predicate_Aspect
(Id
: E
) return B
is
1396 pragma Assert
(Is_Type
(Id
));
1397 return Flag258
(Id
);
1398 end Has_Dynamic_Predicate_Aspect
;
1400 function Has_Enumeration_Rep_Clause
(Id
: E
) return B
is
1402 pragma Assert
(Is_Enumeration_Type
(Id
));
1404 end Has_Enumeration_Rep_Clause
;
1406 function Has_Exit
(Id
: E
) return B
is
1411 function Has_External_Tag_Rep_Clause
(Id
: E
) return B
is
1413 pragma Assert
(Is_Tagged_Type
(Id
));
1414 return Flag110
(Id
);
1415 end Has_External_Tag_Rep_Clause
;
1417 function Has_Forward_Instantiation
(Id
: E
) return B
is
1419 return Flag175
(Id
);
1420 end Has_Forward_Instantiation
;
1422 function Has_Fully_Qualified_Name
(Id
: E
) return B
is
1424 return Flag173
(Id
);
1425 end Has_Fully_Qualified_Name
;
1427 function Has_Gigi_Rep_Item
(Id
: E
) return B
is
1430 end Has_Gigi_Rep_Item
;
1432 function Has_Homonym
(Id
: E
) return B
is
1437 function Has_Implicit_Dereference
(Id
: E
) return B
is
1439 return Flag251
(Id
);
1440 end Has_Implicit_Dereference
;
1442 function Has_Independent_Components
(Id
: E
) return B
is
1444 pragma Assert
(Is_Object
(Id
) or else Is_Type
(Id
));
1446 end Has_Independent_Components
;
1448 function Has_Inheritable_Invariants
(Id
: E
) return B
is
1450 pragma Assert
(Is_Type
(Id
));
1451 return Flag248
(Id
);
1452 end Has_Inheritable_Invariants
;
1454 function Has_Initial_Value
(Id
: E
) return B
is
1456 pragma Assert
(Ekind
(Id
) = E_Variable
or else Is_Formal
(Id
));
1457 return Flag219
(Id
);
1458 end Has_Initial_Value
;
1460 function Has_Invariants
(Id
: E
) return B
is
1462 pragma Assert
(Is_Type
(Id
));
1463 return Flag232
(Id
);
1466 function Has_Loop_Entry_Attributes
(Id
: E
) return B
is
1468 pragma Assert
(Ekind
(Id
) = E_Loop
);
1469 return Flag260
(Id
);
1470 end Has_Loop_Entry_Attributes
;
1472 function Has_Machine_Radix_Clause
(Id
: E
) return B
is
1474 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
1476 end Has_Machine_Radix_Clause
;
1478 function Has_Master_Entity
(Id
: E
) return B
is
1481 end Has_Master_Entity
;
1483 function Has_Missing_Return
(Id
: E
) return B
is
1485 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Generic_Function
));
1486 return Flag142
(Id
);
1487 end Has_Missing_Return
;
1489 function Has_Nested_Block_With_Handler
(Id
: E
) return B
is
1491 return Flag101
(Id
);
1492 end Has_Nested_Block_With_Handler
;
1494 function Has_Non_Standard_Rep
(Id
: E
) return B
is
1496 return Flag75
(Implementation_Base_Type
(Id
));
1497 end Has_Non_Standard_Rep
;
1499 function Has_Object_Size_Clause
(Id
: E
) return B
is
1501 pragma Assert
(Is_Type
(Id
));
1502 return Flag172
(Id
);
1503 end Has_Object_Size_Clause
;
1505 function Has_Per_Object_Constraint
(Id
: E
) return B
is
1507 return Flag154
(Id
);
1508 end Has_Per_Object_Constraint
;
1510 function Has_Postconditions
(Id
: E
) return B
is
1512 pragma Assert
(Is_Subprogram
(Id
));
1513 return Flag240
(Id
);
1514 end Has_Postconditions
;
1516 function Has_Pragma_Controlled
(Id
: E
) return B
is
1518 pragma Assert
(Is_Access_Type
(Id
));
1519 return Flag27
(Implementation_Base_Type
(Id
));
1520 end Has_Pragma_Controlled
;
1522 function Has_Pragma_Elaborate_Body
(Id
: E
) return B
is
1524 return Flag150
(Id
);
1525 end Has_Pragma_Elaborate_Body
;
1527 function Has_Pragma_Inline
(Id
: E
) return B
is
1529 return Flag157
(Id
);
1530 end Has_Pragma_Inline
;
1532 function Has_Pragma_Inline_Always
(Id
: E
) return B
is
1534 return Flag230
(Id
);
1535 end Has_Pragma_Inline_Always
;
1537 function Has_Pragma_No_Inline
(Id
: E
) return B
is
1539 return Flag201
(Id
);
1540 end Has_Pragma_No_Inline
;
1542 function Has_Pragma_Ordered
(Id
: E
) return B
is
1544 pragma Assert
(Is_Enumeration_Type
(Id
));
1545 return Flag198
(Implementation_Base_Type
(Id
));
1546 end Has_Pragma_Ordered
;
1548 function Has_Pragma_Pack
(Id
: E
) return B
is
1550 pragma Assert
(Is_Record_Type
(Id
) or else Is_Array_Type
(Id
));
1551 return Flag121
(Implementation_Base_Type
(Id
));
1552 end Has_Pragma_Pack
;
1554 function Has_Pragma_Preelab_Init
(Id
: E
) return B
is
1556 return Flag221
(Id
);
1557 end Has_Pragma_Preelab_Init
;
1559 function Has_Pragma_Pure
(Id
: E
) return B
is
1561 return Flag203
(Id
);
1562 end Has_Pragma_Pure
;
1564 function Has_Pragma_Pure_Function
(Id
: E
) return B
is
1566 return Flag179
(Id
);
1567 end Has_Pragma_Pure_Function
;
1569 function Has_Pragma_Thread_Local_Storage
(Id
: E
) return B
is
1571 return Flag169
(Id
);
1572 end Has_Pragma_Thread_Local_Storage
;
1574 function Has_Pragma_Unmodified
(Id
: E
) return B
is
1576 return Flag233
(Id
);
1577 end Has_Pragma_Unmodified
;
1579 function Has_Pragma_Unreferenced
(Id
: E
) return B
is
1581 return Flag180
(Id
);
1582 end Has_Pragma_Unreferenced
;
1584 function Has_Pragma_Unreferenced_Objects
(Id
: E
) return B
is
1586 pragma Assert
(Is_Type
(Id
));
1587 return Flag212
(Id
);
1588 end Has_Pragma_Unreferenced_Objects
;
1590 function Has_Predicates
(Id
: E
) return B
is
1592 pragma Assert
(Is_Type
(Id
));
1593 return Flag250
(Id
);
1596 function Has_Primitive_Operations
(Id
: E
) return B
is
1598 pragma Assert
(Is_Type
(Id
));
1599 return Flag120
(Base_Type
(Id
));
1600 end Has_Primitive_Operations
;
1602 function Has_Private_Ancestor
(Id
: E
) return B
is
1604 return Flag151
(Id
);
1605 end Has_Private_Ancestor
;
1607 function Has_Private_Declaration
(Id
: E
) return B
is
1609 return Flag155
(Id
);
1610 end Has_Private_Declaration
;
1612 function Has_Qualified_Name
(Id
: E
) return B
is
1614 return Flag161
(Id
);
1615 end Has_Qualified_Name
;
1617 function Has_RACW
(Id
: E
) return B
is
1619 pragma Assert
(Ekind
(Id
) = E_Package
);
1620 return Flag214
(Id
);
1623 function Has_Record_Rep_Clause
(Id
: E
) return B
is
1625 pragma Assert
(Is_Record_Type
(Id
));
1626 return Flag65
(Implementation_Base_Type
(Id
));
1627 end Has_Record_Rep_Clause
;
1629 function Has_Recursive_Call
(Id
: E
) return B
is
1631 pragma Assert
(Is_Subprogram
(Id
));
1632 return Flag143
(Id
);
1633 end Has_Recursive_Call
;
1635 function Has_Size_Clause
(Id
: E
) return B
is
1638 end Has_Size_Clause
;
1640 function Has_Small_Clause
(Id
: E
) return B
is
1643 end Has_Small_Clause
;
1645 function Has_Specified_Layout
(Id
: E
) return B
is
1647 pragma Assert
(Is_Type
(Id
));
1648 return Flag100
(Implementation_Base_Type
(Id
));
1649 end Has_Specified_Layout
;
1651 function Has_Specified_Stream_Input
(Id
: E
) return B
is
1653 pragma Assert
(Is_Type
(Id
));
1654 return Flag190
(Id
);
1655 end Has_Specified_Stream_Input
;
1657 function Has_Specified_Stream_Output
(Id
: E
) return B
is
1659 pragma Assert
(Is_Type
(Id
));
1660 return Flag191
(Id
);
1661 end Has_Specified_Stream_Output
;
1663 function Has_Specified_Stream_Read
(Id
: E
) return B
is
1665 pragma Assert
(Is_Type
(Id
));
1666 return Flag192
(Id
);
1667 end Has_Specified_Stream_Read
;
1669 function Has_Specified_Stream_Write
(Id
: E
) return B
is
1671 pragma Assert
(Is_Type
(Id
));
1672 return Flag193
(Id
);
1673 end Has_Specified_Stream_Write
;
1675 function Has_Static_Discriminants
(Id
: E
) return B
is
1677 pragma Assert
(Is_Type
(Id
));
1678 return Flag211
(Id
);
1679 end Has_Static_Discriminants
;
1681 function Has_Static_Predicate_Aspect
(Id
: E
) return B
is
1683 pragma Assert
(Is_Type
(Id
));
1684 return Flag259
(Id
);
1685 end Has_Static_Predicate_Aspect
;
1687 function Has_Storage_Size_Clause
(Id
: E
) return B
is
1689 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
1690 return Flag23
(Implementation_Base_Type
(Id
));
1691 end Has_Storage_Size_Clause
;
1693 function Has_Stream_Size_Clause
(Id
: E
) return B
is
1695 return Flag184
(Id
);
1696 end Has_Stream_Size_Clause
;
1698 function Has_Task
(Id
: E
) return B
is
1700 return Flag30
(Base_Type
(Id
));
1703 function Has_Thunks
(Id
: E
) return B
is
1705 return Flag228
(Id
);
1708 function Has_Unchecked_Union
(Id
: E
) return B
is
1710 return Flag123
(Base_Type
(Id
));
1711 end Has_Unchecked_Union
;
1713 function Has_Unknown_Discriminants
(Id
: E
) return B
is
1715 pragma Assert
(Is_Type
(Id
));
1717 end Has_Unknown_Discriminants
;
1719 function Has_Up_Level_Access
(Id
: E
) return B
is
1722 (Ekind_In
(Id
, E_Variable
, E_Constant
, E_Loop_Parameter
));
1723 return Flag215
(Id
);
1724 end Has_Up_Level_Access
;
1726 function Has_Visible_Refinement
(Id
: E
) return B
is
1728 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
1729 return Flag263
(Id
);
1730 end Has_Visible_Refinement
;
1732 function Has_Volatile_Components
(Id
: E
) return B
is
1734 return Flag87
(Implementation_Base_Type
(Id
));
1735 end Has_Volatile_Components
;
1737 function Has_Xref_Entry
(Id
: E
) return B
is
1739 return Flag182
(Id
);
1742 function Hiding_Loop_Variable
(Id
: E
) return E
is
1744 pragma Assert
(Ekind
(Id
) = E_Variable
);
1746 end Hiding_Loop_Variable
;
1748 function Homonym
(Id
: E
) return E
is
1753 function Interface_Alias
(Id
: E
) return E
is
1755 pragma Assert
(Is_Subprogram
(Id
));
1757 end Interface_Alias
;
1759 function Interfaces
(Id
: E
) return L
is
1761 pragma Assert
(Is_Record_Type
(Id
));
1762 return Elist25
(Id
);
1765 function In_Package_Body
(Id
: E
) return B
is
1768 end In_Package_Body
;
1770 function In_Private_Part
(Id
: E
) return B
is
1773 end In_Private_Part
;
1775 function In_Use
(Id
: E
) return B
is
1777 pragma Assert
(Nkind
(Id
) in N_Entity
);
1781 function Initialization_Statements
(Id
: E
) return N
is
1783 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
1785 end Initialization_Statements
;
1787 function Inner_Instances
(Id
: E
) return L
is
1789 return Elist23
(Id
);
1790 end Inner_Instances
;
1792 function Interface_Name
(Id
: E
) return N
is
1797 function Is_Abstract_Subprogram
(Id
: E
) return B
is
1799 pragma Assert
(Is_Overloadable
(Id
));
1801 end Is_Abstract_Subprogram
;
1803 function Is_Abstract_Type
(Id
: E
) return B
is
1805 pragma Assert
(Is_Type
(Id
));
1806 return Flag146
(Id
);
1807 end Is_Abstract_Type
;
1809 function Is_Local_Anonymous_Access
(Id
: E
) return B
is
1811 pragma Assert
(Is_Access_Type
(Id
));
1812 return Flag194
(Id
);
1813 end Is_Local_Anonymous_Access
;
1815 function Is_Access_Constant
(Id
: E
) return B
is
1817 pragma Assert
(Is_Access_Type
(Id
));
1819 end Is_Access_Constant
;
1821 function Is_Ada_2005_Only
(Id
: E
) return B
is
1823 return Flag185
(Id
);
1824 end Is_Ada_2005_Only
;
1826 function Is_Ada_2012_Only
(Id
: E
) return B
is
1828 return Flag199
(Id
);
1829 end Is_Ada_2012_Only
;
1831 function Is_Aliased
(Id
: E
) return B
is
1833 pragma Assert
(Nkind
(Id
) in N_Entity
);
1837 function Is_AST_Entry
(Id
: E
) return B
is
1839 pragma Assert
(Is_Entry
(Id
));
1840 return Flag132
(Id
);
1843 function Is_Asynchronous
(Id
: E
) return B
is
1845 pragma Assert
(Ekind
(Id
) = E_Procedure
or else Is_Type
(Id
));
1847 end Is_Asynchronous
;
1849 function Is_Atomic
(Id
: E
) return B
is
1854 function Is_Bit_Packed_Array
(Id
: E
) return B
is
1856 return Flag122
(Implementation_Base_Type
(Id
));
1857 end Is_Bit_Packed_Array
;
1859 function Is_Called
(Id
: E
) return B
is
1861 pragma Assert
(Ekind_In
(Id
, E_Procedure
, E_Function
));
1862 return Flag102
(Id
);
1865 function Is_Character_Type
(Id
: E
) return B
is
1868 end Is_Character_Type
;
1870 function Is_Child_Unit
(Id
: E
) return B
is
1875 function Is_Class_Wide_Equivalent_Type
(Id
: E
) return B
is
1878 end Is_Class_Wide_Equivalent_Type
;
1880 function Is_Compilation_Unit
(Id
: E
) return B
is
1882 return Flag149
(Id
);
1883 end Is_Compilation_Unit
;
1885 function Is_Completely_Hidden
(Id
: E
) return B
is
1887 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
1888 return Flag103
(Id
);
1889 end Is_Completely_Hidden
;
1891 function Is_Constr_Subt_For_U_Nominal
(Id
: E
) return B
is
1894 end Is_Constr_Subt_For_U_Nominal
;
1896 function Is_Constr_Subt_For_UN_Aliased
(Id
: E
) return B
is
1898 return Flag141
(Id
);
1899 end Is_Constr_Subt_For_UN_Aliased
;
1901 function Is_Constrained
(Id
: E
) return B
is
1903 pragma Assert
(Nkind
(Id
) in N_Entity
);
1907 function Is_Constructor
(Id
: E
) return B
is
1912 function Is_Controlled
(Id
: E
) return B
is
1914 return Flag42
(Base_Type
(Id
));
1917 function Is_Controlling_Formal
(Id
: E
) return B
is
1919 pragma Assert
(Is_Formal
(Id
));
1921 end Is_Controlling_Formal
;
1923 function Is_CPP_Class
(Id
: E
) return B
is
1928 function Is_Descendent_Of_Address
(Id
: E
) return B
is
1930 pragma Assert
(Is_Type
(Id
));
1931 return Flag223
(Id
);
1932 end Is_Descendent_Of_Address
;
1934 function Is_Discrim_SO_Function
(Id
: E
) return B
is
1936 return Flag176
(Id
);
1937 end Is_Discrim_SO_Function
;
1939 function Is_Dispatch_Table_Entity
(Id
: E
) return B
is
1941 return Flag234
(Id
);
1942 end Is_Dispatch_Table_Entity
;
1944 function Is_Dispatching_Operation
(Id
: E
) return B
is
1946 pragma Assert
(Nkind
(Id
) in N_Entity
);
1948 end Is_Dispatching_Operation
;
1950 function Is_Eliminated
(Id
: E
) return B
is
1952 return Flag124
(Id
);
1955 function Is_Entry_Formal
(Id
: E
) return B
is
1958 end Is_Entry_Formal
;
1960 function Is_Exported
(Id
: E
) return B
is
1965 function Is_First_Subtype
(Id
: E
) return B
is
1968 end Is_First_Subtype
;
1970 function Is_For_Access_Subtype
(Id
: E
) return B
is
1972 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
, E_Private_Subtype
));
1973 return Flag118
(Id
);
1974 end Is_For_Access_Subtype
;
1976 function Is_Formal_Subprogram
(Id
: E
) return B
is
1978 return Flag111
(Id
);
1979 end Is_Formal_Subprogram
;
1981 function Is_Frozen
(Id
: E
) return B
is
1986 function Is_Generic_Actual_Type
(Id
: E
) return B
is
1988 pragma Assert
(Is_Type
(Id
));
1990 end Is_Generic_Actual_Type
;
1992 function Is_Generic_Instance
(Id
: E
) return B
is
1994 return Flag130
(Id
);
1995 end Is_Generic_Instance
;
1997 function Is_Generic_Type
(Id
: E
) return B
is
1999 pragma Assert
(Nkind
(Id
) in N_Entity
);
2001 end Is_Generic_Type
;
2003 function Is_Hidden
(Id
: E
) return B
is
2008 function Is_Hidden_Open_Scope
(Id
: E
) return B
is
2010 return Flag171
(Id
);
2011 end Is_Hidden_Open_Scope
;
2013 function Is_Immediately_Visible
(Id
: E
) return B
is
2015 pragma Assert
(Nkind
(Id
) in N_Entity
);
2017 end Is_Immediately_Visible
;
2019 function Is_Implementation_Defined
(Id
: E
) return B
is
2021 return Flag254
(Id
);
2022 end Is_Implementation_Defined
;
2024 function Is_Imported
(Id
: E
) return B
is
2029 function Is_Inlined
(Id
: E
) return B
is
2034 function Is_Interface
(Id
: E
) return B
is
2036 return Flag186
(Id
);
2039 function Is_Instantiated
(Id
: E
) return B
is
2041 return Flag126
(Id
);
2042 end Is_Instantiated
;
2044 function Is_Internal
(Id
: E
) return B
is
2046 pragma Assert
(Nkind
(Id
) in N_Entity
);
2050 function Is_Interrupt_Handler
(Id
: E
) return B
is
2052 pragma Assert
(Nkind
(Id
) in N_Entity
);
2054 end Is_Interrupt_Handler
;
2056 function Is_Intrinsic_Subprogram
(Id
: E
) return B
is
2059 end Is_Intrinsic_Subprogram
;
2061 function Is_Invariant_Procedure
(Id
: E
) return B
is
2063 pragma Assert
(Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
2064 return Flag257
(Id
);
2065 end Is_Invariant_Procedure
;
2067 function Is_Itype
(Id
: E
) return B
is
2072 function Is_Known_Non_Null
(Id
: E
) return B
is
2075 end Is_Known_Non_Null
;
2077 function Is_Known_Null
(Id
: E
) return B
is
2079 return Flag204
(Id
);
2082 function Is_Known_Valid
(Id
: E
) return B
is
2084 return Flag170
(Id
);
2087 function Is_Limited_Composite
(Id
: E
) return B
is
2089 return Flag106
(Id
);
2090 end Is_Limited_Composite
;
2092 function Is_Limited_Interface
(Id
: E
) return B
is
2094 return Flag197
(Id
);
2095 end Is_Limited_Interface
;
2097 function Is_Limited_Record
(Id
: E
) return B
is
2100 end Is_Limited_Record
;
2102 function Is_Machine_Code_Subprogram
(Id
: E
) return B
is
2104 pragma Assert
(Is_Subprogram
(Id
));
2105 return Flag137
(Id
);
2106 end Is_Machine_Code_Subprogram
;
2108 function Is_Non_Static_Subtype
(Id
: E
) return B
is
2110 pragma Assert
(Is_Type
(Id
));
2111 return Flag109
(Id
);
2112 end Is_Non_Static_Subtype
;
2114 function Is_Null_Init_Proc
(Id
: E
) return B
is
2116 pragma Assert
(Ekind
(Id
) = E_Procedure
);
2117 return Flag178
(Id
);
2118 end Is_Null_Init_Proc
;
2120 function Is_Obsolescent
(Id
: E
) return B
is
2122 return Flag153
(Id
);
2125 function Is_Only_Out_Parameter
(Id
: E
) return B
is
2127 pragma Assert
(Is_Formal
(Id
));
2128 return Flag226
(Id
);
2129 end Is_Only_Out_Parameter
;
2131 function Is_Optional_Parameter
(Id
: E
) return B
is
2133 pragma Assert
(Is_Formal
(Id
));
2134 return Flag134
(Id
);
2135 end Is_Optional_Parameter
;
2137 function Is_Package_Body_Entity
(Id
: E
) return B
is
2139 return Flag160
(Id
);
2140 end Is_Package_Body_Entity
;
2142 function Is_Packed
(Id
: E
) return B
is
2144 return Flag51
(Implementation_Base_Type
(Id
));
2147 function Is_Packed_Array_Type
(Id
: E
) return B
is
2149 return Flag138
(Id
);
2150 end Is_Packed_Array_Type
;
2152 function Is_Potentially_Use_Visible
(Id
: E
) return B
is
2154 pragma Assert
(Nkind
(Id
) in N_Entity
);
2156 end Is_Potentially_Use_Visible
;
2158 function Is_Predicate_Function
(Id
: E
) return B
is
2160 pragma Assert
(Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
2161 return Flag255
(Id
);
2162 end Is_Predicate_Function
;
2164 function Is_Predicate_Function_M
(Id
: E
) return B
is
2166 pragma Assert
(Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
2167 return Flag256
(Id
);
2168 end Is_Predicate_Function_M
;
2170 function Is_Preelaborated
(Id
: E
) return B
is
2173 end Is_Preelaborated
;
2175 function Is_Primitive
(Id
: E
) return B
is
2178 (Is_Overloadable
(Id
)
2179 or else Ekind_In
(Id
, E_Generic_Function
, E_Generic_Procedure
));
2180 return Flag218
(Id
);
2183 function Is_Primitive_Wrapper
(Id
: E
) return B
is
2185 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2186 return Flag195
(Id
);
2187 end Is_Primitive_Wrapper
;
2189 function Is_Private_Composite
(Id
: E
) return B
is
2191 pragma Assert
(Is_Type
(Id
));
2192 return Flag107
(Id
);
2193 end Is_Private_Composite
;
2195 function Is_Private_Descendant
(Id
: E
) return B
is
2198 end Is_Private_Descendant
;
2200 function Is_Private_Primitive
(Id
: E
) return B
is
2202 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2203 return Flag245
(Id
);
2204 end Is_Private_Primitive
;
2206 function Is_Processed_Transient
(Id
: E
) return B
is
2208 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
2209 return Flag252
(Id
);
2210 end Is_Processed_Transient
;
2212 function Is_Public
(Id
: E
) return B
is
2214 pragma Assert
(Nkind
(Id
) in N_Entity
);
2218 function Is_Pure
(Id
: E
) return B
is
2223 function Is_Pure_Unit_Access_Type
(Id
: E
) return B
is
2225 pragma Assert
(Is_Access_Type
(Id
));
2226 return Flag189
(Id
);
2227 end Is_Pure_Unit_Access_Type
;
2229 function Is_RACW_Stub_Type
(Id
: E
) return B
is
2231 pragma Assert
(Is_Type
(Id
));
2232 return Flag244
(Id
);
2233 end Is_RACW_Stub_Type
;
2235 function Is_Raised
(Id
: E
) return B
is
2237 pragma Assert
(Ekind
(Id
) = E_Exception
);
2238 return Flag224
(Id
);
2241 function Is_Remote_Call_Interface
(Id
: E
) return B
is
2244 end Is_Remote_Call_Interface
;
2246 function Is_Remote_Types
(Id
: E
) return B
is
2249 end Is_Remote_Types
;
2251 function Is_Renaming_Of_Object
(Id
: E
) return B
is
2253 return Flag112
(Id
);
2254 end Is_Renaming_Of_Object
;
2256 function Is_Return_Object
(Id
: E
) return B
is
2258 return Flag209
(Id
);
2259 end Is_Return_Object
;
2261 function Is_Safe_To_Reevaluate
(Id
: E
) return B
is
2263 return Flag249
(Id
);
2264 end Is_Safe_To_Reevaluate
;
2266 function Is_Shared_Passive
(Id
: E
) return B
is
2269 end Is_Shared_Passive
;
2271 function Is_Statically_Allocated
(Id
: E
) return B
is
2274 end Is_Statically_Allocated
;
2276 function Is_Tag
(Id
: E
) return B
is
2278 pragma Assert
(Nkind
(Id
) in N_Entity
);
2282 function Is_Tagged_Type
(Id
: E
) return B
is
2287 function Is_Thunk
(Id
: E
) return B
is
2289 return Flag225
(Id
);
2292 function Is_Trivial_Subprogram
(Id
: E
) return B
is
2294 return Flag235
(Id
);
2295 end Is_Trivial_Subprogram
;
2297 function Is_True_Constant
(Id
: E
) return B
is
2299 return Flag163
(Id
);
2300 end Is_True_Constant
;
2302 function Is_Unchecked_Union
(Id
: E
) return B
is
2304 return Flag117
(Implementation_Base_Type
(Id
));
2305 end Is_Unchecked_Union
;
2307 function Is_Underlying_Record_View
(Id
: E
) return B
is
2309 return Flag246
(Id
);
2310 end Is_Underlying_Record_View
;
2312 function Is_Unsigned_Type
(Id
: E
) return B
is
2314 pragma Assert
(Is_Type
(Id
));
2315 return Flag144
(Id
);
2316 end Is_Unsigned_Type
;
2318 function Is_Valued_Procedure
(Id
: E
) return B
is
2320 pragma Assert
(Ekind
(Id
) = E_Procedure
);
2321 return Flag127
(Id
);
2322 end Is_Valued_Procedure
;
2324 function Is_Visible_Formal
(Id
: E
) return B
is
2326 return Flag206
(Id
);
2327 end Is_Visible_Formal
;
2329 function Is_Visible_Lib_Unit
(Id
: E
) return B
is
2331 return Flag116
(Id
);
2332 end Is_Visible_Lib_Unit
;
2334 function Is_VMS_Exception
(Id
: E
) return B
is
2336 return Flag133
(Id
);
2337 end Is_VMS_Exception
;
2339 function Is_Volatile
(Id
: E
) return B
is
2341 pragma Assert
(Nkind
(Id
) in N_Entity
);
2343 if Is_Type
(Id
) then
2344 return Flag16
(Base_Type
(Id
));
2350 function Itype_Printed
(Id
: E
) return B
is
2352 pragma Assert
(Is_Itype
(Id
));
2353 return Flag202
(Id
);
2356 function Kill_Elaboration_Checks
(Id
: E
) return B
is
2359 end Kill_Elaboration_Checks
;
2361 function Kill_Range_Checks
(Id
: E
) return B
is
2364 end Kill_Range_Checks
;
2366 function Known_To_Have_Preelab_Init
(Id
: E
) return B
is
2368 pragma Assert
(Is_Type
(Id
));
2369 return Flag207
(Id
);
2370 end Known_To_Have_Preelab_Init
;
2372 function Last_Assignment
(Id
: E
) return N
is
2374 pragma Assert
(Is_Assignable
(Id
));
2376 end Last_Assignment
;
2378 function Last_Entity
(Id
: E
) return E
is
2383 function Limited_View
(Id
: E
) return E
is
2385 pragma Assert
(Ekind
(Id
) = E_Package
);
2389 function Lit_Indexes
(Id
: E
) return E
is
2391 pragma Assert
(Is_Enumeration_Type
(Id
));
2395 function Lit_Strings
(Id
: E
) return E
is
2397 pragma Assert
(Is_Enumeration_Type
(Id
));
2401 function Low_Bound_Tested
(Id
: E
) return B
is
2403 return Flag205
(Id
);
2404 end Low_Bound_Tested
;
2406 function Machine_Radix_10
(Id
: E
) return B
is
2408 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
2410 end Machine_Radix_10
;
2412 function Master_Id
(Id
: E
) return E
is
2414 pragma Assert
(Is_Access_Type
(Id
));
2418 function Materialize_Entity
(Id
: E
) return B
is
2420 return Flag168
(Id
);
2421 end Materialize_Entity
;
2423 function May_Inherit_Delayed_Rep_Aspects
(Id
: E
) return B
is
2425 return Flag262
(Id
);
2426 end May_Inherit_Delayed_Rep_Aspects
;
2428 function Mechanism
(Id
: E
) return M
is
2430 pragma Assert
(Ekind
(Id
) = E_Function
or else Is_Formal
(Id
));
2431 return UI_To_Int
(Uint8
(Id
));
2434 function Modulus
(Id
: E
) return Uint
is
2436 pragma Assert
(Is_Modular_Integer_Type
(Id
));
2437 return Uint17
(Base_Type
(Id
));
2440 function Must_Be_On_Byte_Boundary
(Id
: E
) return B
is
2442 pragma Assert
(Is_Type
(Id
));
2443 return Flag183
(Id
);
2444 end Must_Be_On_Byte_Boundary
;
2446 function Must_Have_Preelab_Init
(Id
: E
) return B
is
2448 pragma Assert
(Is_Type
(Id
));
2449 return Flag208
(Id
);
2450 end Must_Have_Preelab_Init
;
2452 function Needs_Debug_Info
(Id
: E
) return B
is
2454 return Flag147
(Id
);
2455 end Needs_Debug_Info
;
2457 function Needs_No_Actuals
(Id
: E
) return B
is
2460 (Is_Overloadable
(Id
)
2461 or else Ekind_In
(Id
, E_Subprogram_Type
, E_Entry_Family
));
2463 end Needs_No_Actuals
;
2465 function Never_Set_In_Source
(Id
: E
) return B
is
2467 return Flag115
(Id
);
2468 end Never_Set_In_Source
;
2470 function Next_Inlined_Subprogram
(Id
: E
) return E
is
2473 end Next_Inlined_Subprogram
;
2475 function No_Pool_Assigned
(Id
: E
) return B
is
2477 pragma Assert
(Is_Access_Type
(Id
));
2478 return Flag131
(Root_Type
(Id
));
2479 end No_Pool_Assigned
;
2481 function No_Return
(Id
: E
) return B
is
2483 return Flag113
(Id
);
2486 function No_Strict_Aliasing
(Id
: E
) return B
is
2488 pragma Assert
(Is_Access_Type
(Id
));
2489 return Flag136
(Base_Type
(Id
));
2490 end No_Strict_Aliasing
;
2492 function Non_Binary_Modulus
(Id
: E
) return B
is
2494 pragma Assert
(Is_Type
(Id
));
2495 return Flag58
(Base_Type
(Id
));
2496 end Non_Binary_Modulus
;
2498 function Non_Limited_View
(Id
: E
) return E
is
2500 pragma Assert
(Ekind
(Id
) in Incomplete_Kind
);
2502 end Non_Limited_View
;
2504 function Nonzero_Is_True
(Id
: E
) return B
is
2506 pragma Assert
(Root_Type
(Id
) = Standard_Boolean
);
2507 return Flag162
(Base_Type
(Id
));
2508 end Nonzero_Is_True
;
2510 function Normalized_First_Bit
(Id
: E
) return U
is
2512 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
2514 end Normalized_First_Bit
;
2516 function Normalized_Position
(Id
: E
) return U
is
2518 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
2520 end Normalized_Position
;
2522 function Normalized_Position_Max
(Id
: E
) return U
is
2524 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
2526 end Normalized_Position_Max
;
2528 function OK_To_Rename
(Id
: E
) return B
is
2530 pragma Assert
(Ekind
(Id
) = E_Variable
);
2531 return Flag247
(Id
);
2534 function OK_To_Reorder_Components
(Id
: E
) return B
is
2536 pragma Assert
(Is_Record_Type
(Id
));
2537 return Flag239
(Base_Type
(Id
));
2538 end OK_To_Reorder_Components
;
2540 function Optimize_Alignment_Space
(Id
: E
) return B
is
2543 (Is_Type
(Id
) or else Ekind_In
(Id
, E_Constant
, E_Variable
));
2544 return Flag241
(Id
);
2545 end Optimize_Alignment_Space
;
2547 function Optimize_Alignment_Time
(Id
: E
) return B
is
2550 (Is_Type
(Id
) or else Ekind_In
(Id
, E_Constant
, E_Variable
));
2551 return Flag242
(Id
);
2552 end Optimize_Alignment_Time
;
2554 function Original_Access_Type
(Id
: E
) return E
is
2556 pragma Assert
(Ekind
(Id
) = E_Access_Subprogram_Type
);
2558 end Original_Access_Type
;
2560 function Original_Array_Type
(Id
: E
) return E
is
2562 pragma Assert
(Is_Array_Type
(Id
) or else Is_Modular_Integer_Type
(Id
));
2564 end Original_Array_Type
;
2566 function Original_Record_Component
(Id
: E
) return E
is
2568 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Component
, E_Discriminant
));
2570 end Original_Record_Component
;
2572 function Overlays_Constant
(Id
: E
) return B
is
2574 return Flag243
(Id
);
2575 end Overlays_Constant
;
2577 function Overridden_Operation
(Id
: E
) return E
is
2580 end Overridden_Operation
;
2582 function Package_Instantiation
(Id
: E
) return N
is
2584 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
2586 end Package_Instantiation
;
2588 function Packed_Array_Type
(Id
: E
) return E
is
2590 pragma Assert
(Is_Array_Type
(Id
));
2592 end Packed_Array_Type
;
2594 function Parent_Subtype
(Id
: E
) return E
is
2596 pragma Assert
(Is_Record_Type
(Id
));
2597 return Node19
(Base_Type
(Id
));
2600 function Postcondition_Proc
(Id
: E
) return E
is
2602 pragma Assert
(Ekind
(Id
) = E_Procedure
);
2604 end Postcondition_Proc
;
2606 function PPC_Wrapper
(Id
: E
) return E
is
2608 pragma Assert
(Ekind_In
(Id
, E_Entry
, E_Entry_Family
));
2612 function Prival
(Id
: E
) return E
is
2614 pragma Assert
(Is_Protected_Component
(Id
));
2618 function Prival_Link
(Id
: E
) return E
is
2620 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
2624 function Private_Dependents
(Id
: E
) return L
is
2626 pragma Assert
(Is_Incomplete_Or_Private_Type
(Id
));
2627 return Elist18
(Id
);
2628 end Private_Dependents
;
2630 function Private_View
(Id
: E
) return N
is
2632 pragma Assert
(Is_Private_Type
(Id
));
2636 function Protected_Body_Subprogram
(Id
: E
) return E
is
2638 pragma Assert
(Is_Subprogram
(Id
) or else Is_Entry
(Id
));
2640 end Protected_Body_Subprogram
;
2642 function Protected_Formal
(Id
: E
) return E
is
2644 pragma Assert
(Is_Formal
(Id
));
2646 end Protected_Formal
;
2648 function Protection_Object
(Id
: E
) return E
is
2651 (Ekind_In
(Id
, E_Entry
, E_Entry_Family
, E_Function
, E_Procedure
));
2653 end Protection_Object
;
2655 function Reachable
(Id
: E
) return B
is
2660 function Referenced
(Id
: E
) return B
is
2662 return Flag156
(Id
);
2665 function Referenced_As_LHS
(Id
: E
) return B
is
2668 end Referenced_As_LHS
;
2670 function Referenced_As_Out_Parameter
(Id
: E
) return B
is
2672 return Flag227
(Id
);
2673 end Referenced_As_Out_Parameter
;
2675 function Refined_State
(Id
: E
) return N
is
2677 pragma Assert
(Ekind_In
(Id
, E_Abstract_State
, E_Variable
));
2681 function Refinement_Constituents
(Id
: E
) return L
is
2683 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
2685 end Refinement_Constituents
;
2687 function Register_Exception_Call
(Id
: E
) return N
is
2689 pragma Assert
(Ekind
(Id
) = E_Exception
);
2691 end Register_Exception_Call
;
2693 function Related_Array_Object
(Id
: E
) return E
is
2695 pragma Assert
(Is_Array_Type
(Id
));
2697 end Related_Array_Object
;
2699 function Related_Expression
(Id
: E
) return N
is
2701 pragma Assert
(Ekind
(Id
) in Type_Kind
2702 or else Ekind_In
(Id
, E_Constant
, E_Variable
));
2704 end Related_Expression
;
2706 function Related_Instance
(Id
: E
) return E
is
2708 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Package_Body
));
2710 end Related_Instance
;
2712 function Related_Type
(Id
: E
) return E
is
2714 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Constant
, E_Variable
));
2718 function Relative_Deadline_Variable
(Id
: E
) return E
is
2720 pragma Assert
(Is_Task_Type
(Id
));
2721 return Node26
(Implementation_Base_Type
(Id
));
2722 end Relative_Deadline_Variable
;
2724 function Renamed_Entity
(Id
: E
) return N
is
2729 function Renamed_In_Spec
(Id
: E
) return B
is
2731 pragma Assert
(Ekind
(Id
) = E_Package
);
2732 return Flag231
(Id
);
2733 end Renamed_In_Spec
;
2735 function Renamed_Object
(Id
: E
) return N
is
2740 function Renaming_Map
(Id
: E
) return U
is
2745 function Requires_Overriding
(Id
: E
) return B
is
2747 pragma Assert
(Is_Overloadable
(Id
));
2748 return Flag213
(Id
);
2749 end Requires_Overriding
;
2751 function Return_Present
(Id
: E
) return B
is
2756 function Return_Applies_To
(Id
: E
) return N
is
2759 end Return_Applies_To
;
2761 function Returns_By_Ref
(Id
: E
) return B
is
2766 function Reverse_Bit_Order
(Id
: E
) return B
is
2768 pragma Assert
(Is_Record_Type
(Id
));
2769 return Flag164
(Base_Type
(Id
));
2770 end Reverse_Bit_Order
;
2772 function Reverse_Storage_Order
(Id
: E
) return B
is
2774 pragma Assert
(Is_Record_Type
(Id
) or else Is_Array_Type
(Id
));
2775 return Flag93
(Base_Type
(Id
));
2776 end Reverse_Storage_Order
;
2778 function RM_Size
(Id
: E
) return U
is
2780 pragma Assert
(Is_Type
(Id
));
2784 function Scalar_Range
(Id
: E
) return N
is
2789 function Scale_Value
(Id
: E
) return U
is
2794 function Scope_Depth_Value
(Id
: E
) return U
is
2797 end Scope_Depth_Value
;
2799 function Sec_Stack_Needed_For_Return
(Id
: E
) return B
is
2801 return Flag167
(Id
);
2802 end Sec_Stack_Needed_For_Return
;
2804 function Shadow_Entities
(Id
: E
) return S
is
2806 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
2808 end Shadow_Entities
;
2810 function Shared_Var_Procs_Instance
(Id
: E
) return E
is
2812 pragma Assert
(Ekind
(Id
) = E_Variable
);
2814 end Shared_Var_Procs_Instance
;
2816 function Size_Check_Code
(Id
: E
) return N
is
2818 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
2820 end Size_Check_Code
;
2822 function Size_Depends_On_Discriminant
(Id
: E
) return B
is
2824 return Flag177
(Id
);
2825 end Size_Depends_On_Discriminant
;
2827 function Size_Known_At_Compile_Time
(Id
: E
) return B
is
2830 end Size_Known_At_Compile_Time
;
2832 function Small_Value
(Id
: E
) return R
is
2834 pragma Assert
(Is_Fixed_Point_Type
(Id
));
2835 return Ureal21
(Id
);
2838 function SPARK_Mode_Pragmas
(Id
: E
) return N
is
2841 (Ekind_In
(Id
, E_Function
, -- subprogram variants
2843 E_Generic_Procedure
,
2847 Ekind_In
(Id
, E_Generic_Package
, -- package variants
2851 end SPARK_Mode_Pragmas
;
2853 function Spec_Entity
(Id
: E
) return E
is
2855 pragma Assert
(Ekind
(Id
) = E_Package_Body
or else Is_Formal
(Id
));
2859 function Static_Predicate
(Id
: E
) return S
is
2861 pragma Assert
(Is_Discrete_Type
(Id
));
2863 end Static_Predicate
;
2865 function Status_Flag_Or_Transient_Decl
(Id
: E
) return N
is
2867 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
2869 end Status_Flag_Or_Transient_Decl
;
2871 function Storage_Size_Variable
(Id
: E
) return E
is
2873 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
2874 return Node15
(Implementation_Base_Type
(Id
));
2875 end Storage_Size_Variable
;
2877 function Static_Elaboration_Desired
(Id
: E
) return B
is
2879 pragma Assert
(Ekind
(Id
) = E_Package
);
2881 end Static_Elaboration_Desired
;
2883 function Static_Initialization
(Id
: E
) return N
is
2886 (Ekind
(Id
) = E_Procedure
and then not Is_Dispatching_Operation
(Id
));
2888 end Static_Initialization
;
2890 function Stored_Constraint
(Id
: E
) return L
is
2893 (Is_Composite_Type
(Id
) and then not Is_Array_Type
(Id
));
2894 return Elist23
(Id
);
2895 end Stored_Constraint
;
2897 function Strict_Alignment
(Id
: E
) return B
is
2899 return Flag145
(Implementation_Base_Type
(Id
));
2900 end Strict_Alignment
;
2902 function String_Literal_Length
(Id
: E
) return U
is
2905 end String_Literal_Length
;
2907 function String_Literal_Low_Bound
(Id
: E
) return N
is
2910 end String_Literal_Low_Bound
;
2912 function Subprograms_For_Type
(Id
: E
) return E
is
2914 pragma Assert
(Is_Type
(Id
) or else Is_Subprogram
(Id
));
2916 end Subprograms_For_Type
;
2918 function Suppress_Elaboration_Warnings
(Id
: E
) return B
is
2920 return Flag148
(Id
);
2921 end Suppress_Elaboration_Warnings
;
2923 function Suppress_Initialization
(Id
: E
) return B
is
2925 pragma Assert
(Is_Type
(Id
));
2926 return Flag105
(Id
);
2927 end Suppress_Initialization
;
2929 function Suppress_Style_Checks
(Id
: E
) return B
is
2931 return Flag165
(Id
);
2932 end Suppress_Style_Checks
;
2934 function Suppress_Value_Tracking_On_Call
(Id
: E
) return B
is
2936 return Flag217
(Id
);
2937 end Suppress_Value_Tracking_On_Call
;
2939 function Task_Body_Procedure
(Id
: E
) return N
is
2941 pragma Assert
(Ekind
(Id
) in Task_Kind
);
2943 end Task_Body_Procedure
;
2945 function Thunk_Entity
(Id
: E
) return E
is
2947 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
2948 and then Is_Thunk
(Id
));
2952 function Treat_As_Volatile
(Id
: E
) return B
is
2955 end Treat_As_Volatile
;
2957 function Underlying_Full_View
(Id
: E
) return E
is
2959 pragma Assert
(Ekind
(Id
) in Private_Kind
);
2961 end Underlying_Full_View
;
2963 function Underlying_Record_View
(Id
: E
) return E
is
2966 end Underlying_Record_View
;
2968 function Universal_Aliasing
(Id
: E
) return B
is
2970 pragma Assert
(Is_Type
(Id
));
2971 return Flag216
(Implementation_Base_Type
(Id
));
2972 end Universal_Aliasing
;
2974 function Unset_Reference
(Id
: E
) return N
is
2977 end Unset_Reference
;
2979 function Used_As_Generic_Actual
(Id
: E
) return B
is
2981 return Flag222
(Id
);
2982 end Used_As_Generic_Actual
;
2984 function Uses_Lock_Free
(Id
: E
) return B
is
2986 pragma Assert
(Is_Protected_Type
(Id
));
2987 return Flag188
(Id
);
2990 function Uses_Sec_Stack
(Id
: E
) return B
is
2995 function Warnings_Off
(Id
: E
) return B
is
3000 function Warnings_Off_Used
(Id
: E
) return B
is
3002 return Flag236
(Id
);
3003 end Warnings_Off_Used
;
3005 function Warnings_Off_Used_Unmodified
(Id
: E
) return B
is
3007 return Flag237
(Id
);
3008 end Warnings_Off_Used_Unmodified
;
3010 function Warnings_Off_Used_Unreferenced
(Id
: E
) return B
is
3012 return Flag238
(Id
);
3013 end Warnings_Off_Used_Unreferenced
;
3015 function Wrapped_Entity
(Id
: E
) return E
is
3017 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
3018 and then Is_Primitive_Wrapper
(Id
));
3022 function Was_Hidden
(Id
: E
) return B
is
3024 return Flag196
(Id
);
3027 ------------------------------
3028 -- Classification Functions --
3029 ------------------------------
3031 function Is_Access_Type
(Id
: E
) return B
is
3033 return Ekind
(Id
) in Access_Kind
;
3036 function Is_Access_Protected_Subprogram_Type
(Id
: E
) return B
is
3038 return Ekind
(Id
) in Access_Protected_Kind
;
3039 end Is_Access_Protected_Subprogram_Type
;
3041 function Is_Access_Subprogram_Type
(Id
: E
) return B
is
3043 return Ekind
(Id
) in Access_Subprogram_Kind
;
3044 end Is_Access_Subprogram_Type
;
3046 function Is_Aggregate_Type
(Id
: E
) return B
is
3048 return Ekind
(Id
) in Aggregate_Kind
;
3049 end Is_Aggregate_Type
;
3051 function Is_Array_Type
(Id
: E
) return B
is
3053 return Ekind
(Id
) in Array_Kind
;
3056 function Is_Assignable
(Id
: E
) return B
is
3058 return Ekind
(Id
) in Assignable_Kind
;
3061 function Is_Class_Wide_Type
(Id
: E
) return B
is
3063 return Ekind
(Id
) in Class_Wide_Kind
;
3064 end Is_Class_Wide_Type
;
3066 function Is_Composite_Type
(Id
: E
) return B
is
3068 return Ekind
(Id
) in Composite_Kind
;
3069 end Is_Composite_Type
;
3071 function Is_Concurrent_Body
(Id
: E
) return B
is
3073 return Ekind
(Id
) in
3074 Concurrent_Body_Kind
;
3075 end Is_Concurrent_Body
;
3077 function Is_Concurrent_Record_Type
(Id
: E
) return B
is
3080 end Is_Concurrent_Record_Type
;
3082 function Is_Concurrent_Type
(Id
: E
) return B
is
3084 return Ekind
(Id
) in Concurrent_Kind
;
3085 end Is_Concurrent_Type
;
3087 function Is_Decimal_Fixed_Point_Type
(Id
: E
) return B
is
3089 return Ekind
(Id
) in
3090 Decimal_Fixed_Point_Kind
;
3091 end Is_Decimal_Fixed_Point_Type
;
3093 function Is_Digits_Type
(Id
: E
) return B
is
3095 return Ekind
(Id
) in Digits_Kind
;
3098 function Is_Discrete_Or_Fixed_Point_Type
(Id
: E
) return B
is
3100 return Ekind
(Id
) in Discrete_Or_Fixed_Point_Kind
;
3101 end Is_Discrete_Or_Fixed_Point_Type
;
3103 function Is_Discrete_Type
(Id
: E
) return B
is
3105 return Ekind
(Id
) in Discrete_Kind
;
3106 end Is_Discrete_Type
;
3108 function Is_Elementary_Type
(Id
: E
) return B
is
3110 return Ekind
(Id
) in Elementary_Kind
;
3111 end Is_Elementary_Type
;
3113 function Is_Entry
(Id
: E
) return B
is
3115 return Ekind
(Id
) in Entry_Kind
;
3118 function Is_Enumeration_Type
(Id
: E
) return B
is
3120 return Ekind
(Id
) in
3122 end Is_Enumeration_Type
;
3124 function Is_Fixed_Point_Type
(Id
: E
) return B
is
3126 return Ekind
(Id
) in
3128 end Is_Fixed_Point_Type
;
3130 function Is_Floating_Point_Type
(Id
: E
) return B
is
3132 return Ekind
(Id
) in Float_Kind
;
3133 end Is_Floating_Point_Type
;
3135 function Is_Formal
(Id
: E
) return B
is
3137 return Ekind
(Id
) in Formal_Kind
;
3140 function Is_Formal_Object
(Id
: E
) return B
is
3142 return Ekind
(Id
) in Formal_Object_Kind
;
3143 end Is_Formal_Object
;
3145 function Is_Generic_Subprogram
(Id
: E
) return B
is
3147 return Ekind
(Id
) in Generic_Subprogram_Kind
;
3148 end Is_Generic_Subprogram
;
3150 function Is_Generic_Unit
(Id
: E
) return B
is
3152 return Ekind
(Id
) in Generic_Unit_Kind
;
3153 end Is_Generic_Unit
;
3155 function Is_Incomplete_Or_Private_Type
(Id
: E
) return B
is
3157 return Ekind
(Id
) in
3158 Incomplete_Or_Private_Kind
;
3159 end Is_Incomplete_Or_Private_Type
;
3161 function Is_Incomplete_Type
(Id
: E
) return B
is
3163 return Ekind
(Id
) in
3165 end Is_Incomplete_Type
;
3167 function Is_Integer_Type
(Id
: E
) return B
is
3169 return Ekind
(Id
) in Integer_Kind
;
3170 end Is_Integer_Type
;
3172 function Is_Modular_Integer_Type
(Id
: E
) return B
is
3174 return Ekind
(Id
) in
3175 Modular_Integer_Kind
;
3176 end Is_Modular_Integer_Type
;
3178 function Is_Named_Number
(Id
: E
) return B
is
3180 return Ekind
(Id
) in Named_Kind
;
3181 end Is_Named_Number
;
3183 function Is_Numeric_Type
(Id
: E
) return B
is
3185 return Ekind
(Id
) in Numeric_Kind
;
3186 end Is_Numeric_Type
;
3188 function Is_Object
(Id
: E
) return B
is
3190 return Ekind
(Id
) in Object_Kind
;
3193 function Is_Ordinary_Fixed_Point_Type
(Id
: E
) return B
is
3195 return Ekind
(Id
) in
3196 Ordinary_Fixed_Point_Kind
;
3197 end Is_Ordinary_Fixed_Point_Type
;
3199 function Is_Overloadable
(Id
: E
) return B
is
3201 return Ekind
(Id
) in Overloadable_Kind
;
3202 end Is_Overloadable
;
3204 function Is_Private_Type
(Id
: E
) return B
is
3206 return Ekind
(Id
) in Private_Kind
;
3207 end Is_Private_Type
;
3209 function Is_Protected_Type
(Id
: E
) return B
is
3211 return Ekind
(Id
) in Protected_Kind
;
3212 end Is_Protected_Type
;
3214 function Is_Real_Type
(Id
: E
) return B
is
3216 return Ekind
(Id
) in Real_Kind
;
3219 function Is_Record_Type
(Id
: E
) return B
is
3221 return Ekind
(Id
) in Record_Kind
;
3224 function Is_Scalar_Type
(Id
: E
) return B
is
3226 return Ekind
(Id
) in Scalar_Kind
;
3229 function Is_Signed_Integer_Type
(Id
: E
) return B
is
3231 return Ekind
(Id
) in Signed_Integer_Kind
;
3232 end Is_Signed_Integer_Type
;
3234 function Is_Subprogram
(Id
: E
) return B
is
3236 return Ekind
(Id
) in Subprogram_Kind
;
3239 function Is_Task_Type
(Id
: E
) return B
is
3241 return Ekind
(Id
) in Task_Kind
;
3244 function Is_Type
(Id
: E
) return B
is
3246 return Ekind
(Id
) in Type_Kind
;
3249 ------------------------------
3250 -- Attribute Set Procedures --
3251 ------------------------------
3253 -- Note: in many of these set procedures an "obvious" assertion is missing.
3254 -- The reason for this is that in many cases, a field is set before the
3255 -- Ekind field is set, so that the field is set when Ekind = E_Void. It
3256 -- it is possible to add assertions that specifically include the E_Void
3257 -- possibility, but in some cases, we just omit the assertions.
3259 procedure Set_Abstract_States
(Id
: E
; V
: L
) is
3261 pragma Assert
(Ekind_In
(Id
, E_Generic_Package
, E_Package
));
3262 Set_Elist25
(Id
, V
);
3263 end Set_Abstract_States
;
3265 procedure Set_Accept_Address
(Id
: E
; V
: L
) is
3267 Set_Elist21
(Id
, V
);
3268 end Set_Accept_Address
;
3270 procedure Set_Access_Disp_Table
(Id
: E
; V
: L
) is
3272 pragma Assert
(Ekind
(Id
) = E_Record_Type
3273 and then Id
= Implementation_Base_Type
(Id
));
3274 pragma Assert
(V
= No_Elist
or else Is_Tagged_Type
(Id
));
3275 Set_Elist16
(Id
, V
);
3276 end Set_Access_Disp_Table
;
3278 procedure Set_Associated_Formal_Package
(Id
: E
; V
: E
) is
3281 end Set_Associated_Formal_Package
;
3283 procedure Set_Associated_Node_For_Itype
(Id
: E
; V
: E
) is
3286 end Set_Associated_Node_For_Itype
;
3288 procedure Set_Associated_Storage_Pool
(Id
: E
; V
: E
) is
3290 pragma Assert
(Is_Access_Type
(Id
) and then Is_Base_Type
(Id
));
3292 end Set_Associated_Storage_Pool
;
3294 procedure Set_Actual_Subtype
(Id
: E
; V
: E
) is
3297 (Ekind_In
(Id
, E_Constant
, E_Variable
, E_Generic_In_Out_Parameter
)
3298 or else Is_Formal
(Id
));
3300 end Set_Actual_Subtype
;
3302 procedure Set_Address_Taken
(Id
: E
; V
: B
:= True) is
3304 Set_Flag104
(Id
, V
);
3305 end Set_Address_Taken
;
3307 procedure Set_Alias
(Id
: E
; V
: E
) is
3310 (Is_Overloadable
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
3314 procedure Set_Alignment
(Id
: E
; V
: U
) is
3316 pragma Assert
(Is_Type
(Id
)
3317 or else Is_Formal
(Id
)
3318 or else Ekind_In
(Id
, E_Loop_Parameter
,
3325 procedure Set_Barrier_Function
(Id
: E
; V
: N
) is
3327 pragma Assert
(Is_Entry
(Id
));
3329 end Set_Barrier_Function
;
3331 procedure Set_Block_Node
(Id
: E
; V
: N
) is
3333 pragma Assert
(Ekind
(Id
) = E_Block
);
3337 procedure Set_Body_Entity
(Id
: E
; V
: E
) is
3339 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
3341 end Set_Body_Entity
;
3343 procedure Set_Body_Needed_For_SAL
(Id
: E
; V
: B
:= True) is
3346 (Ekind
(Id
) = E_Package
3347 or else Is_Subprogram
(Id
)
3348 or else Is_Generic_Unit
(Id
));
3350 end Set_Body_Needed_For_SAL
;
3352 procedure Set_Body_References
(Id
: E
; V
: L
) is
3354 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
3355 Set_Elist16
(Id
, V
);
3356 end Set_Body_References
;
3358 procedure Set_C_Pass_By_Copy
(Id
: E
; V
: B
:= True) is
3360 pragma Assert
(Is_Record_Type
(Id
) and then Is_Base_Type
(Id
));
3361 Set_Flag125
(Id
, V
);
3362 end Set_C_Pass_By_Copy
;
3364 procedure Set_Can_Never_Be_Null
(Id
: E
; V
: B
:= True) is
3367 end Set_Can_Never_Be_Null
;
3369 procedure Set_Checks_May_Be_Suppressed
(Id
: E
; V
: B
:= True) is
3372 end Set_Checks_May_Be_Suppressed
;
3374 procedure Set_Class_Wide_Type
(Id
: E
; V
: E
) is
3376 pragma Assert
(Is_Type
(Id
));
3378 end Set_Class_Wide_Type
;
3380 procedure Set_Cloned_Subtype
(Id
: E
; V
: E
) is
3382 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
, E_Class_Wide_Subtype
));
3384 end Set_Cloned_Subtype
;
3386 procedure Set_Component_Bit_Offset
(Id
: E
; V
: U
) is
3388 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
3390 end Set_Component_Bit_Offset
;
3392 procedure Set_Component_Clause
(Id
: E
; V
: N
) is
3394 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
3396 end Set_Component_Clause
;
3398 procedure Set_Component_Size
(Id
: E
; V
: U
) is
3400 pragma Assert
(Is_Array_Type
(Id
) and then Is_Base_Type
(Id
));
3402 end Set_Component_Size
;
3404 procedure Set_Component_Type
(Id
: E
; V
: E
) is
3406 pragma Assert
(Is_Array_Type
(Id
) and then Is_Base_Type
(Id
));
3408 end Set_Component_Type
;
3410 procedure Set_Corresponding_Concurrent_Type
(Id
: E
; V
: E
) is
3413 (Ekind
(Id
) = E_Record_Type
and then Is_Concurrent_Type
(V
));
3415 end Set_Corresponding_Concurrent_Type
;
3417 procedure Set_Corresponding_Discriminant
(Id
: E
; V
: E
) is
3419 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
3421 end Set_Corresponding_Discriminant
;
3423 procedure Set_Corresponding_Equality
(Id
: E
; V
: E
) is
3426 (Ekind
(Id
) = E_Function
3427 and then not Comes_From_Source
(Id
)
3428 and then Chars
(Id
) = Name_Op_Ne
);
3430 end Set_Corresponding_Equality
;
3432 procedure Set_Corresponding_Protected_Entry
(Id
: E
; V
: E
) is
3434 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Subprogram_Body
));
3436 end Set_Corresponding_Protected_Entry
;
3438 procedure Set_Corresponding_Record_Type
(Id
: E
; V
: E
) is
3440 pragma Assert
(Is_Concurrent_Type
(Id
));
3442 end Set_Corresponding_Record_Type
;
3444 procedure Set_Corresponding_Remote_Type
(Id
: E
; V
: E
) is
3447 end Set_Corresponding_Remote_Type
;
3449 procedure Set_Current_Use_Clause
(Id
: E
; V
: E
) is
3451 pragma Assert
(Ekind
(Id
) = E_Package
or else Is_Type
(Id
));
3453 end Set_Current_Use_Clause
;
3455 procedure Set_Current_Value
(Id
: E
; V
: N
) is
3457 pragma Assert
(Ekind
(Id
) in Object_Kind
or else Ekind
(Id
) = E_Void
);
3459 end Set_Current_Value
;
3461 procedure Set_CR_Discriminant
(Id
: E
; V
: E
) is
3464 end Set_CR_Discriminant
;
3466 procedure Set_Debug_Info_Off
(Id
: E
; V
: B
:= True) is
3468 Set_Flag166
(Id
, V
);
3469 end Set_Debug_Info_Off
;
3471 procedure Set_Debug_Renaming_Link
(Id
: E
; V
: E
) is
3474 end Set_Debug_Renaming_Link
;
3476 procedure Set_Default_Aspect_Component_Value
(Id
: E
; V
: E
) is
3478 pragma Assert
(Is_Array_Type
(Id
) and then Is_Base_Type
(Id
));
3480 end Set_Default_Aspect_Component_Value
;
3482 procedure Set_Default_Aspect_Value
(Id
: E
; V
: E
) is
3484 pragma Assert
(Is_Scalar_Type
(Id
) and then Is_Base_Type
(Id
));
3486 end Set_Default_Aspect_Value
;
3488 procedure Set_Default_Expr_Function
(Id
: E
; V
: E
) is
3490 pragma Assert
(Is_Formal
(Id
));
3492 end Set_Default_Expr_Function
;
3494 procedure Set_Default_Expressions_Processed
(Id
: E
; V
: B
:= True) is
3496 Set_Flag108
(Id
, V
);
3497 end Set_Default_Expressions_Processed
;
3499 procedure Set_Default_Value
(Id
: E
; V
: N
) is
3501 pragma Assert
(Is_Formal
(Id
));
3503 end Set_Default_Value
;
3505 procedure Set_Delay_Cleanups
(Id
: E
; V
: B
:= True) is
3509 or else Is_Task_Type
(Id
)
3510 or else Ekind
(Id
) = E_Block
);
3511 Set_Flag114
(Id
, V
);
3512 end Set_Delay_Cleanups
;
3514 procedure Set_Delay_Subprogram_Descriptors
(Id
: E
; V
: B
:= True) is
3517 (Is_Subprogram
(Id
) or else Ekind_In
(Id
, E_Package
, E_Package_Body
));
3520 end Set_Delay_Subprogram_Descriptors
;
3522 procedure Set_Delta_Value
(Id
: E
; V
: R
) is
3524 pragma Assert
(Is_Fixed_Point_Type
(Id
));
3525 Set_Ureal18
(Id
, V
);
3526 end Set_Delta_Value
;
3528 procedure Set_Dependent_Instances
(Id
: E
; V
: L
) is
3530 pragma Assert
(Is_Generic_Instance
(Id
));
3532 end Set_Dependent_Instances
;
3534 procedure Set_Depends_On_Private
(Id
: E
; V
: B
:= True) is
3536 pragma Assert
(Nkind
(Id
) in N_Entity
);
3538 end Set_Depends_On_Private
;
3540 procedure Set_Digits_Value
(Id
: E
; V
: U
) is
3543 (Is_Floating_Point_Type
(Id
)
3544 or else Is_Decimal_Fixed_Point_Type
(Id
));
3546 end Set_Digits_Value
;
3548 procedure Set_Directly_Designated_Type
(Id
: E
; V
: E
) is
3551 end Set_Directly_Designated_Type
;
3553 procedure Set_Discard_Names
(Id
: E
; V
: B
:= True) is
3556 end Set_Discard_Names
;
3558 procedure Set_Discriminal
(Id
: E
; V
: E
) is
3560 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
3562 end Set_Discriminal
;
3564 procedure Set_Discriminal_Link
(Id
: E
; V
: E
) is
3567 end Set_Discriminal_Link
;
3569 procedure Set_Discriminant_Checking_Func
(Id
: E
; V
: E
) is
3571 pragma Assert
(Ekind
(Id
) = E_Component
);
3573 end Set_Discriminant_Checking_Func
;
3575 procedure Set_Discriminant_Constraint
(Id
: E
; V
: L
) is
3577 pragma Assert
(Nkind
(Id
) in N_Entity
);
3578 Set_Elist21
(Id
, V
);
3579 end Set_Discriminant_Constraint
;
3581 procedure Set_Discriminant_Default_Value
(Id
: E
; V
: N
) is
3584 end Set_Discriminant_Default_Value
;
3586 procedure Set_Discriminant_Number
(Id
: E
; V
: U
) is
3589 end Set_Discriminant_Number
;
3591 procedure Set_Dispatch_Table_Wrappers
(Id
: E
; V
: L
) is
3593 pragma Assert
(Ekind
(Id
) = E_Record_Type
3594 and then Id
= Implementation_Base_Type
(Id
));
3595 pragma Assert
(V
= No_Elist
or else Is_Tagged_Type
(Id
));
3596 Set_Elist26
(Id
, V
);
3597 end Set_Dispatch_Table_Wrappers
;
3599 procedure Set_DT_Entry_Count
(Id
: E
; V
: U
) is
3601 pragma Assert
(Ekind
(Id
) = E_Component
);
3603 end Set_DT_Entry_Count
;
3605 procedure Set_DT_Offset_To_Top_Func
(Id
: E
; V
: E
) is
3607 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
3609 end Set_DT_Offset_To_Top_Func
;
3611 procedure Set_DT_Position
(Id
: E
; V
: U
) is
3613 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
3615 end Set_DT_Position
;
3617 procedure Set_DTC_Entity
(Id
: E
; V
: E
) is
3619 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
3623 procedure Set_Elaborate_Body_Desirable
(Id
: E
; V
: B
:= True) is
3625 pragma Assert
(Ekind
(Id
) = E_Package
);
3626 Set_Flag210
(Id
, V
);
3627 end Set_Elaborate_Body_Desirable
;
3629 procedure Set_Elaboration_Entity
(Id
: E
; V
: E
) is
3634 Ekind
(Id
) = E_Package
3636 Is_Generic_Unit
(Id
));
3638 end Set_Elaboration_Entity
;
3640 procedure Set_Elaboration_Entity_Required
(Id
: E
; V
: B
:= True) is
3645 Ekind
(Id
) = E_Package
3647 Is_Generic_Unit
(Id
));
3648 Set_Flag174
(Id
, V
);
3649 end Set_Elaboration_Entity_Required
;
3651 procedure Set_Enclosing_Scope
(Id
: E
; V
: E
) is
3654 end Set_Enclosing_Scope
;
3656 procedure Set_Entry_Accepted
(Id
: E
; V
: B
:= True) is
3658 pragma Assert
(Is_Entry
(Id
));
3659 Set_Flag152
(Id
, V
);
3660 end Set_Entry_Accepted
;
3662 procedure Set_Entry_Bodies_Array
(Id
: E
; V
: E
) is
3665 end Set_Entry_Bodies_Array
;
3667 procedure Set_Entry_Cancel_Parameter
(Id
: E
; V
: E
) is
3670 end Set_Entry_Cancel_Parameter
;
3672 procedure Set_Entry_Component
(Id
: E
; V
: E
) is
3675 end Set_Entry_Component
;
3677 procedure Set_Entry_Formal
(Id
: E
; V
: E
) is
3680 end Set_Entry_Formal
;
3682 procedure Set_Entry_Index_Constant
(Id
: E
; V
: E
) is
3684 pragma Assert
(Ekind
(Id
) = E_Entry_Index_Parameter
);
3686 end Set_Entry_Index_Constant
;
3688 procedure Set_Contract
(Id
: E
; V
: N
) is
3691 (Ekind_In
(Id
, E_Entry
,
3698 or else Is_Generic_Subprogram
(Id
)
3699 or else Is_Subprogram
(Id
));
3703 procedure Set_Entry_Parameters_Type
(Id
: E
; V
: E
) is
3706 end Set_Entry_Parameters_Type
;
3708 procedure Set_Enum_Pos_To_Rep
(Id
: E
; V
: E
) is
3710 pragma Assert
(Ekind
(Id
) = E_Enumeration_Type
);
3712 end Set_Enum_Pos_To_Rep
;
3714 procedure Set_Enumeration_Pos
(Id
: E
; V
: U
) is
3716 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
3718 end Set_Enumeration_Pos
;
3720 procedure Set_Enumeration_Rep
(Id
: E
; V
: U
) is
3722 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
3724 end Set_Enumeration_Rep
;
3726 procedure Set_Enumeration_Rep_Expr
(Id
: E
; V
: N
) is
3728 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
3730 end Set_Enumeration_Rep_Expr
;
3732 procedure Set_Equivalent_Type
(Id
: E
; V
: E
) is
3735 (Ekind_In
(Id
, E_Class_Wide_Type
,
3736 E_Class_Wide_Subtype
,
3737 E_Access_Protected_Subprogram_Type
,
3738 E_Anonymous_Access_Protected_Subprogram_Type
,
3739 E_Access_Subprogram_Type
,
3742 end Set_Equivalent_Type
;
3744 procedure Set_Esize
(Id
: E
; V
: U
) is
3749 procedure Set_Exception_Code
(Id
: E
; V
: U
) is
3751 pragma Assert
(Ekind
(Id
) = E_Exception
);
3753 end Set_Exception_Code
;
3755 procedure Set_Extra_Accessibility
(Id
: E
; V
: E
) is
3758 (Is_Formal
(Id
) or else Ekind_In
(Id
, E_Variable
, E_Constant
));
3760 end Set_Extra_Accessibility
;
3762 procedure Set_Extra_Accessibility_Of_Result
(Id
: E
; V
: E
) is
3764 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Operator
, E_Subprogram_Type
));
3766 end Set_Extra_Accessibility_Of_Result
;
3768 procedure Set_Extra_Constrained
(Id
: E
; V
: E
) is
3770 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
3772 end Set_Extra_Constrained
;
3774 procedure Set_Extra_Formal
(Id
: E
; V
: E
) is
3777 end Set_Extra_Formal
;
3779 procedure Set_Extra_Formals
(Id
: E
; V
: E
) is
3782 (Is_Overloadable
(Id
)
3783 or else Ekind_In
(Id
, E_Entry_Family
,
3785 E_Subprogram_Type
));
3787 end Set_Extra_Formals
;
3789 procedure Set_Can_Use_Internal_Rep
(Id
: E
; V
: B
:= True) is
3792 (Is_Access_Subprogram_Type
(Id
) and then Is_Base_Type
(Id
));
3793 Set_Flag229
(Id
, V
);
3794 end Set_Can_Use_Internal_Rep
;
3796 procedure Set_Finalization_Master
(Id
: E
; V
: E
) is
3798 pragma Assert
(Is_Access_Type
(Id
) and then Is_Base_Type
(Id
));
3800 end Set_Finalization_Master
;
3802 procedure Set_Finalize_Storage_Only
(Id
: E
; V
: B
:= True) is
3804 pragma Assert
(Is_Type
(Id
) and then Is_Base_Type
(Id
));
3805 Set_Flag158
(Id
, V
);
3806 end Set_Finalize_Storage_Only
;
3808 procedure Set_Finalizer
(Id
: E
; V
: E
) is
3810 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Package_Body
));
3814 procedure Set_First_Entity
(Id
: E
; V
: E
) is
3817 end Set_First_Entity
;
3819 procedure Set_First_Exit_Statement
(Id
: E
; V
: N
) is
3821 pragma Assert
(Ekind
(Id
) = E_Loop
);
3823 end Set_First_Exit_Statement
;
3825 procedure Set_First_Index
(Id
: E
; V
: N
) is
3827 pragma Assert
(Is_Array_Type
(Id
) or else Is_String_Type
(Id
));
3829 end Set_First_Index
;
3831 procedure Set_First_Literal
(Id
: E
; V
: E
) is
3833 pragma Assert
(Is_Enumeration_Type
(Id
));
3835 end Set_First_Literal
;
3837 procedure Set_First_Optional_Parameter
(Id
: E
; V
: E
) is
3839 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
3841 end Set_First_Optional_Parameter
;
3843 procedure Set_First_Private_Entity
(Id
: E
; V
: E
) is
3845 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
)
3846 or else Ekind
(Id
) in Concurrent_Kind
);
3848 end Set_First_Private_Entity
;
3850 procedure Set_First_Rep_Item
(Id
: E
; V
: N
) is
3853 end Set_First_Rep_Item
;
3855 procedure Set_Float_Rep
(Id
: E
; V
: F
) is
3856 pragma Assert
(Ekind
(Id
) = E_Floating_Point_Type
);
3858 Set_Uint10
(Id
, UI_From_Int
(F
'Pos (V
)));
3861 procedure Set_Freeze_Node
(Id
: E
; V
: N
) is
3864 end Set_Freeze_Node
;
3866 procedure Set_From_Limited_With
(Id
: E
; V
: B
:= True) is
3868 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Package
);
3869 Set_Flag159
(Id
, V
);
3870 end Set_From_Limited_With
;
3872 procedure Set_Full_View
(Id
: E
; V
: E
) is
3874 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Constant
);
3878 procedure Set_Generic_Homonym
(Id
: E
; V
: E
) is
3881 end Set_Generic_Homonym
;
3883 procedure Set_Generic_Renamings
(Id
: E
; V
: L
) is
3885 Set_Elist23
(Id
, V
);
3886 end Set_Generic_Renamings
;
3888 procedure Set_Handler_Records
(Id
: E
; V
: S
) is
3891 end Set_Handler_Records
;
3893 procedure Set_Has_Aliased_Components
(Id
: E
; V
: B
:= True) is
3895 pragma Assert
(Id
= Base_Type
(Id
));
3896 Set_Flag135
(Id
, V
);
3897 end Set_Has_Aliased_Components
;
3899 procedure Set_Has_Alignment_Clause
(Id
: E
; V
: B
:= True) is
3902 end Set_Has_Alignment_Clause
;
3904 procedure Set_Has_All_Calls_Remote
(Id
: E
; V
: B
:= True) is
3907 end Set_Has_All_Calls_Remote
;
3909 procedure Set_Has_Anonymous_Master
(Id
: E
; V
: B
:= True) is
3912 (Ekind_In
(Id
, E_Function
, E_Package
, E_Package_Body
, E_Procedure
));
3913 Set_Flag253
(Id
, V
);
3914 end Set_Has_Anonymous_Master
;
3916 procedure Set_Has_Atomic_Components
(Id
: E
; V
: B
:= True) is
3918 pragma Assert
(not Is_Type
(Id
) or else Is_Base_Type
(Id
));
3920 end Set_Has_Atomic_Components
;
3922 procedure Set_Has_Biased_Representation
(Id
: E
; V
: B
:= True) is
3925 ((V
= False) or else (Is_Discrete_Type
(Id
) or else Is_Object
(Id
)));
3926 Set_Flag139
(Id
, V
);
3927 end Set_Has_Biased_Representation
;
3929 procedure Set_Has_Body_References
(Id
: E
; V
: B
:= True) is
3931 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
3932 Set_Flag264
(Id
, V
);
3933 end Set_Has_Body_References
;
3935 procedure Set_Has_Completion
(Id
: E
; V
: B
:= True) is
3938 end Set_Has_Completion
;
3940 procedure Set_Has_Completion_In_Body
(Id
: E
; V
: B
:= True) is
3942 pragma Assert
(Is_Type
(Id
));
3944 end Set_Has_Completion_In_Body
;
3946 procedure Set_Has_Complex_Representation
(Id
: E
; V
: B
:= True) is
3948 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
3949 Set_Flag140
(Id
, V
);
3950 end Set_Has_Complex_Representation
;
3952 procedure Set_Has_Component_Size_Clause
(Id
: E
; V
: B
:= True) is
3954 pragma Assert
(Ekind
(Id
) = E_Array_Type
);
3956 end Set_Has_Component_Size_Clause
;
3958 procedure Set_Has_Constrained_Partial_View
(Id
: E
; V
: B
:= True) is
3960 pragma Assert
(Is_Type
(Id
));
3961 Set_Flag187
(Id
, V
);
3962 end Set_Has_Constrained_Partial_View
;
3964 procedure Set_Has_Contiguous_Rep
(Id
: E
; V
: B
:= True) is
3966 Set_Flag181
(Id
, V
);
3967 end Set_Has_Contiguous_Rep
;
3969 procedure Set_Has_Controlled_Component
(Id
: E
; V
: B
:= True) is
3971 pragma Assert
(Id
= Base_Type
(Id
));
3973 end Set_Has_Controlled_Component
;
3975 procedure Set_Has_Controlling_Result
(Id
: E
; V
: B
:= True) is
3978 end Set_Has_Controlling_Result
;
3980 procedure Set_Has_Convention_Pragma
(Id
: E
; V
: B
:= True) is
3982 Set_Flag119
(Id
, V
);
3983 end Set_Has_Convention_Pragma
;
3985 procedure Set_Has_Default_Aspect
(Id
: E
; V
: B
:= True) is
3988 ((Is_Scalar_Type
(Id
) or else Is_Array_Type
(Id
))
3989 and then Is_Base_Type
(Id
));
3991 end Set_Has_Default_Aspect
;
3993 procedure Set_Has_Delayed_Aspects
(Id
: E
; V
: B
:= True) is
3995 pragma Assert
(Nkind
(Id
) in N_Entity
);
3996 Set_Flag200
(Id
, V
);
3997 end Set_Has_Delayed_Aspects
;
3999 procedure Set_Has_Delayed_Freeze
(Id
: E
; V
: B
:= True) is
4001 pragma Assert
(Nkind
(Id
) in N_Entity
);
4003 end Set_Has_Delayed_Freeze
;
4005 procedure Set_Has_Delayed_Rep_Aspects
(Id
: E
; V
: B
:= True) is
4007 pragma Assert
(Nkind
(Id
) in N_Entity
);
4008 Set_Flag261
(Id
, V
);
4009 end Set_Has_Delayed_Rep_Aspects
;
4011 procedure Set_Has_Discriminants
(Id
: E
; V
: B
:= True) is
4013 pragma Assert
(Nkind
(Id
) in N_Entity
);
4015 end Set_Has_Discriminants
;
4017 procedure Set_Has_Dispatch_Table
(Id
: E
; V
: B
:= True) is
4019 pragma Assert
(Ekind
(Id
) = E_Record_Type
4020 and then Is_Tagged_Type
(Id
));
4021 Set_Flag220
(Id
, V
);
4022 end Set_Has_Dispatch_Table
;
4024 procedure Set_Has_Dynamic_Predicate_Aspect
(Id
: E
; V
: B
:= True) is
4026 pragma Assert
(Is_Type
(Id
));
4027 Set_Flag258
(Id
, V
);
4028 end Set_Has_Dynamic_Predicate_Aspect
;
4030 procedure Set_Has_Enumeration_Rep_Clause
(Id
: E
; V
: B
:= True) is
4032 pragma Assert
(Is_Enumeration_Type
(Id
));
4034 end Set_Has_Enumeration_Rep_Clause
;
4036 procedure Set_Has_Exit
(Id
: E
; V
: B
:= True) is
4041 procedure Set_Has_External_Tag_Rep_Clause
(Id
: E
; V
: B
:= True) is
4043 pragma Assert
(Is_Tagged_Type
(Id
));
4044 Set_Flag110
(Id
, V
);
4045 end Set_Has_External_Tag_Rep_Clause
;
4047 procedure Set_Has_Forward_Instantiation
(Id
: E
; V
: B
:= True) is
4049 Set_Flag175
(Id
, V
);
4050 end Set_Has_Forward_Instantiation
;
4052 procedure Set_Has_Fully_Qualified_Name
(Id
: E
; V
: B
:= True) is
4054 Set_Flag173
(Id
, V
);
4055 end Set_Has_Fully_Qualified_Name
;
4057 procedure Set_Has_Gigi_Rep_Item
(Id
: E
; V
: B
:= True) is
4060 end Set_Has_Gigi_Rep_Item
;
4062 procedure Set_Has_Homonym
(Id
: E
; V
: B
:= True) is
4065 end Set_Has_Homonym
;
4067 procedure Set_Has_Implicit_Dereference
(Id
: E
; V
: B
:= True) is
4069 Set_Flag251
(Id
, V
);
4070 end Set_Has_Implicit_Dereference
;
4072 procedure Set_Has_Independent_Components
(Id
: E
; V
: B
:= True) is
4074 pragma Assert
(Is_Object
(Id
) or else Is_Type
(Id
));
4076 end Set_Has_Independent_Components
;
4078 procedure Set_Has_Inheritable_Invariants
(Id
: E
; V
: B
:= True) is
4080 pragma Assert
(Is_Type
(Id
));
4081 Set_Flag248
(Id
, V
);
4082 end Set_Has_Inheritable_Invariants
;
4084 procedure Set_Has_Initial_Value
(Id
: E
; V
: B
:= True) is
4086 pragma Assert
(Ekind_In
(Id
, E_Variable
, E_Out_Parameter
));
4087 Set_Flag219
(Id
, V
);
4088 end Set_Has_Initial_Value
;
4090 procedure Set_Has_Invariants
(Id
: E
; V
: B
:= True) is
4092 pragma Assert
(Is_Type
(Id
));
4093 Set_Flag232
(Id
, V
);
4094 end Set_Has_Invariants
;
4096 procedure Set_Has_Loop_Entry_Attributes
(Id
: E
; V
: B
:= True) is
4098 pragma Assert
(Ekind
(Id
) = E_Loop
);
4099 Set_Flag260
(Id
, V
);
4100 end Set_Has_Loop_Entry_Attributes
;
4102 procedure Set_Has_Machine_Radix_Clause
(Id
: E
; V
: B
:= True) is
4104 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
4106 end Set_Has_Machine_Radix_Clause
;
4108 procedure Set_Has_Master_Entity
(Id
: E
; V
: B
:= True) is
4111 end Set_Has_Master_Entity
;
4113 procedure Set_Has_Missing_Return
(Id
: E
; V
: B
:= True) is
4115 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Generic_Function
));
4116 Set_Flag142
(Id
, V
);
4117 end Set_Has_Missing_Return
;
4119 procedure Set_Has_Nested_Block_With_Handler
(Id
: E
; V
: B
:= True) is
4121 Set_Flag101
(Id
, V
);
4122 end Set_Has_Nested_Block_With_Handler
;
4124 procedure Set_Has_Up_Level_Access
(Id
: E
; V
: B
:= True) is
4126 pragma Assert
(Ekind_In
(Id
, E_Variable
, E_Constant
, E_Loop_Parameter
));
4127 Set_Flag215
(Id
, V
);
4128 end Set_Has_Up_Level_Access
;
4130 procedure Set_Has_Non_Standard_Rep
(Id
: E
; V
: B
:= True) is
4132 pragma Assert
(Id
= Base_Type
(Id
));
4134 end Set_Has_Non_Standard_Rep
;
4136 procedure Set_Has_Object_Size_Clause
(Id
: E
; V
: B
:= True) is
4138 pragma Assert
(Is_Type
(Id
));
4139 Set_Flag172
(Id
, V
);
4140 end Set_Has_Object_Size_Clause
;
4142 procedure Set_Has_Per_Object_Constraint
(Id
: E
; V
: B
:= True) is
4144 Set_Flag154
(Id
, V
);
4145 end Set_Has_Per_Object_Constraint
;
4147 procedure Set_Has_Postconditions
(Id
: E
; V
: B
:= True) is
4149 pragma Assert
(Is_Subprogram
(Id
));
4150 Set_Flag240
(Id
, V
);
4151 end Set_Has_Postconditions
;
4153 procedure Set_Has_Pragma_Controlled
(Id
: E
; V
: B
:= True) is
4155 pragma Assert
(Is_Access_Type
(Id
));
4156 Set_Flag27
(Base_Type
(Id
), V
);
4157 end Set_Has_Pragma_Controlled
;
4159 procedure Set_Has_Pragma_Elaborate_Body
(Id
: E
; V
: B
:= True) is
4161 Set_Flag150
(Id
, V
);
4162 end Set_Has_Pragma_Elaborate_Body
;
4164 procedure Set_Has_Pragma_Inline
(Id
: E
; V
: B
:= True) is
4166 Set_Flag157
(Id
, V
);
4167 end Set_Has_Pragma_Inline
;
4169 procedure Set_Has_Pragma_Inline_Always
(Id
: E
; V
: B
:= True) is
4171 Set_Flag230
(Id
, V
);
4172 end Set_Has_Pragma_Inline_Always
;
4174 procedure Set_Has_Pragma_No_Inline
(Id
: E
; V
: B
:= True) is
4176 Set_Flag201
(Id
, V
);
4177 end Set_Has_Pragma_No_Inline
;
4179 procedure Set_Has_Pragma_Ordered
(Id
: E
; V
: B
:= True) is
4181 pragma Assert
(Is_Enumeration_Type
(Id
));
4182 pragma Assert
(Id
= Base_Type
(Id
));
4183 Set_Flag198
(Id
, V
);
4184 end Set_Has_Pragma_Ordered
;
4186 procedure Set_Has_Pragma_Pack
(Id
: E
; V
: B
:= True) is
4188 pragma Assert
(Is_Array_Type
(Id
) or else Is_Record_Type
(Id
));
4189 pragma Assert
(Id
= Base_Type
(Id
));
4190 Set_Flag121
(Id
, V
);
4191 end Set_Has_Pragma_Pack
;
4193 procedure Set_Has_Pragma_Preelab_Init
(Id
: E
; V
: B
:= True) is
4195 Set_Flag221
(Id
, V
);
4196 end Set_Has_Pragma_Preelab_Init
;
4198 procedure Set_Has_Pragma_Pure
(Id
: E
; V
: B
:= True) is
4200 Set_Flag203
(Id
, V
);
4201 end Set_Has_Pragma_Pure
;
4203 procedure Set_Has_Pragma_Pure_Function
(Id
: E
; V
: B
:= True) is
4205 Set_Flag179
(Id
, V
);
4206 end Set_Has_Pragma_Pure_Function
;
4208 procedure Set_Has_Pragma_Thread_Local_Storage
(Id
: E
; V
: B
:= True) is
4210 Set_Flag169
(Id
, V
);
4211 end Set_Has_Pragma_Thread_Local_Storage
;
4213 procedure Set_Has_Pragma_Unmodified
(Id
: E
; V
: B
:= True) is
4215 Set_Flag233
(Id
, V
);
4216 end Set_Has_Pragma_Unmodified
;
4218 procedure Set_Has_Pragma_Unreferenced
(Id
: E
; V
: B
:= True) is
4220 Set_Flag180
(Id
, V
);
4221 end Set_Has_Pragma_Unreferenced
;
4223 procedure Set_Has_Pragma_Unreferenced_Objects
(Id
: E
; V
: B
:= True) is
4225 pragma Assert
(Is_Type
(Id
));
4226 Set_Flag212
(Id
, V
);
4227 end Set_Has_Pragma_Unreferenced_Objects
;
4229 procedure Set_Has_Predicates
(Id
: E
; V
: B
:= True) is
4231 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Void
);
4232 Set_Flag250
(Id
, V
);
4233 end Set_Has_Predicates
;
4235 procedure Set_Has_Primitive_Operations
(Id
: E
; V
: B
:= True) is
4237 pragma Assert
(Id
= Base_Type
(Id
));
4238 Set_Flag120
(Id
, V
);
4239 end Set_Has_Primitive_Operations
;
4241 procedure Set_Has_Private_Ancestor
(Id
: E
; V
: B
:= True) is
4243 pragma Assert
(Is_Type
(Id
));
4244 Set_Flag151
(Id
, V
);
4245 end Set_Has_Private_Ancestor
;
4247 procedure Set_Has_Private_Declaration
(Id
: E
; V
: B
:= True) is
4249 Set_Flag155
(Id
, V
);
4250 end Set_Has_Private_Declaration
;
4252 procedure Set_Has_Qualified_Name
(Id
: E
; V
: B
:= True) is
4254 Set_Flag161
(Id
, V
);
4255 end Set_Has_Qualified_Name
;
4257 procedure Set_Has_RACW
(Id
: E
; V
: B
:= True) is
4259 pragma Assert
(Ekind
(Id
) = E_Package
);
4260 Set_Flag214
(Id
, V
);
4263 procedure Set_Has_Record_Rep_Clause
(Id
: E
; V
: B
:= True) is
4265 pragma Assert
(Id
= Base_Type
(Id
));
4267 end Set_Has_Record_Rep_Clause
;
4269 procedure Set_Has_Recursive_Call
(Id
: E
; V
: B
:= True) is
4271 pragma Assert
(Is_Subprogram
(Id
));
4272 Set_Flag143
(Id
, V
);
4273 end Set_Has_Recursive_Call
;
4275 procedure Set_Has_Size_Clause
(Id
: E
; V
: B
:= True) is
4278 end Set_Has_Size_Clause
;
4280 procedure Set_Has_Small_Clause
(Id
: E
; V
: B
:= True) is
4283 end Set_Has_Small_Clause
;
4285 procedure Set_Has_Specified_Layout
(Id
: E
; V
: B
:= True) is
4287 pragma Assert
(Id
= Base_Type
(Id
));
4288 Set_Flag100
(Id
, V
);
4289 end Set_Has_Specified_Layout
;
4291 procedure Set_Has_Specified_Stream_Input
(Id
: E
; V
: B
:= True) is
4293 pragma Assert
(Is_Type
(Id
));
4294 Set_Flag190
(Id
, V
);
4295 end Set_Has_Specified_Stream_Input
;
4297 procedure Set_Has_Specified_Stream_Output
(Id
: E
; V
: B
:= True) is
4299 pragma Assert
(Is_Type
(Id
));
4300 Set_Flag191
(Id
, V
);
4301 end Set_Has_Specified_Stream_Output
;
4303 procedure Set_Has_Specified_Stream_Read
(Id
: E
; V
: B
:= True) is
4305 pragma Assert
(Is_Type
(Id
));
4306 Set_Flag192
(Id
, V
);
4307 end Set_Has_Specified_Stream_Read
;
4309 procedure Set_Has_Specified_Stream_Write
(Id
: E
; V
: B
:= True) is
4311 pragma Assert
(Is_Type
(Id
));
4312 Set_Flag193
(Id
, V
);
4313 end Set_Has_Specified_Stream_Write
;
4315 procedure Set_Has_Static_Discriminants
(Id
: E
; V
: B
:= True) is
4317 Set_Flag211
(Id
, V
);
4318 end Set_Has_Static_Discriminants
;
4320 procedure Set_Has_Static_Predicate_Aspect
(Id
: E
; V
: B
:= True) is
4322 pragma Assert
(Is_Type
(Id
));
4323 Set_Flag259
(Id
, V
);
4324 end Set_Has_Static_Predicate_Aspect
;
4326 procedure Set_Has_Storage_Size_Clause
(Id
: E
; V
: B
:= True) is
4328 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
4329 pragma Assert
(Id
= Base_Type
(Id
));
4331 end Set_Has_Storage_Size_Clause
;
4333 procedure Set_Has_Stream_Size_Clause
(Id
: E
; V
: B
:= True) is
4335 pragma Assert
(Is_Elementary_Type
(Id
));
4336 Set_Flag184
(Id
, V
);
4337 end Set_Has_Stream_Size_Clause
;
4339 procedure Set_Has_Task
(Id
: E
; V
: B
:= True) is
4341 pragma Assert
(Id
= Base_Type
(Id
));
4345 procedure Set_Has_Thunks
(Id
: E
; V
: B
:= True) is
4347 pragma Assert
(Is_Tag
(Id
));
4348 Set_Flag228
(Id
, V
);
4351 procedure Set_Has_Unchecked_Union
(Id
: E
; V
: B
:= True) is
4353 pragma Assert
(Id
= Base_Type
(Id
));
4354 Set_Flag123
(Id
, V
);
4355 end Set_Has_Unchecked_Union
;
4357 procedure Set_Has_Unknown_Discriminants
(Id
: E
; V
: B
:= True) is
4359 pragma Assert
(Is_Type
(Id
));
4361 end Set_Has_Unknown_Discriminants
;
4363 procedure Set_Has_Visible_Refinement
(Id
: E
; V
: B
:= True) is
4365 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
4366 Set_Flag263
(Id
, V
);
4367 end Set_Has_Visible_Refinement
;
4369 procedure Set_Has_Volatile_Components
(Id
: E
; V
: B
:= True) is
4371 pragma Assert
(not Is_Type
(Id
) or else Is_Base_Type
(Id
));
4373 end Set_Has_Volatile_Components
;
4375 procedure Set_Has_Xref_Entry
(Id
: E
; V
: B
:= True) is
4377 Set_Flag182
(Id
, V
);
4378 end Set_Has_Xref_Entry
;
4380 procedure Set_Hiding_Loop_Variable
(Id
: E
; V
: E
) is
4382 pragma Assert
(Ekind
(Id
) = E_Variable
);
4384 end Set_Hiding_Loop_Variable
;
4386 procedure Set_Homonym
(Id
: E
; V
: E
) is
4388 pragma Assert
(Id
/= V
);
4392 procedure Set_Interface_Alias
(Id
: E
; V
: E
) is
4396 and then Is_Hidden
(Id
)
4397 and then (Ekind_In
(Id
, E_Procedure
, E_Function
)));
4399 end Set_Interface_Alias
;
4401 procedure Set_Interfaces
(Id
: E
; V
: L
) is
4403 pragma Assert
(Is_Record_Type
(Id
));
4404 Set_Elist25
(Id
, V
);
4407 procedure Set_In_Package_Body
(Id
: E
; V
: B
:= True) is
4410 end Set_In_Package_Body
;
4412 procedure Set_In_Private_Part
(Id
: E
; V
: B
:= True) is
4415 end Set_In_Private_Part
;
4417 procedure Set_In_Use
(Id
: E
; V
: B
:= True) is
4419 pragma Assert
(Nkind
(Id
) in N_Entity
);
4423 procedure Set_Initialization_Statements
(Id
: E
; V
: N
) is
4425 -- Tolerate an E_Void entity since this can be called while resolving
4426 -- an aggregate used as the initialization expression for an object
4427 -- declaration, and this occurs before the Ekind for the object is set.
4429 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Constant
, E_Variable
));
4431 end Set_Initialization_Statements
;
4433 procedure Set_Inner_Instances
(Id
: E
; V
: L
) is
4435 Set_Elist23
(Id
, V
);
4436 end Set_Inner_Instances
;
4438 procedure Set_Interface_Name
(Id
: E
; V
: N
) is
4441 end Set_Interface_Name
;
4443 procedure Set_Is_Abstract_Subprogram
(Id
: E
; V
: B
:= True) is
4445 pragma Assert
(Is_Overloadable
(Id
));
4447 end Set_Is_Abstract_Subprogram
;
4449 procedure Set_Is_Abstract_Type
(Id
: E
; V
: B
:= True) is
4451 pragma Assert
(Is_Type
(Id
));
4452 Set_Flag146
(Id
, V
);
4453 end Set_Is_Abstract_Type
;
4455 procedure Set_Is_Local_Anonymous_Access
(Id
: E
; V
: B
:= True) is
4457 pragma Assert
(Is_Access_Type
(Id
));
4458 Set_Flag194
(Id
, V
);
4459 end Set_Is_Local_Anonymous_Access
;
4461 procedure Set_Is_Access_Constant
(Id
: E
; V
: B
:= True) is
4463 pragma Assert
(Is_Access_Type
(Id
));
4465 end Set_Is_Access_Constant
;
4467 procedure Set_Is_Ada_2005_Only
(Id
: E
; V
: B
:= True) is
4469 Set_Flag185
(Id
, V
);
4470 end Set_Is_Ada_2005_Only
;
4472 procedure Set_Is_Ada_2012_Only
(Id
: E
; V
: B
:= True) is
4474 Set_Flag199
(Id
, V
);
4475 end Set_Is_Ada_2012_Only
;
4477 procedure Set_Is_Aliased
(Id
: E
; V
: B
:= True) is
4479 pragma Assert
(Nkind
(Id
) in N_Entity
);
4483 procedure Set_Is_AST_Entry
(Id
: E
; V
: B
:= True) is
4485 pragma Assert
(Is_Entry
(Id
));
4486 Set_Flag132
(Id
, V
);
4487 end Set_Is_AST_Entry
;
4489 procedure Set_Is_Asynchronous
(Id
: E
; V
: B
:= True) is
4492 (Ekind
(Id
) = E_Procedure
or else Is_Type
(Id
));
4494 end Set_Is_Asynchronous
;
4496 procedure Set_Is_Atomic
(Id
: E
; V
: B
:= True) is
4501 procedure Set_Is_Bit_Packed_Array
(Id
: E
; V
: B
:= True) is
4503 pragma Assert
((not V
)
4504 or else (Is_Array_Type
(Id
) and then Is_Base_Type
(Id
)));
4505 Set_Flag122
(Id
, V
);
4506 end Set_Is_Bit_Packed_Array
;
4508 procedure Set_Is_Called
(Id
: E
; V
: B
:= True) is
4510 pragma Assert
(Ekind_In
(Id
, E_Procedure
, E_Function
));
4511 Set_Flag102
(Id
, V
);
4514 procedure Set_Is_Character_Type
(Id
: E
; V
: B
:= True) is
4517 end Set_Is_Character_Type
;
4519 procedure Set_Is_Child_Unit
(Id
: E
; V
: B
:= True) is
4522 end Set_Is_Child_Unit
;
4524 procedure Set_Is_Class_Wide_Equivalent_Type
(Id
: E
; V
: B
:= True) is
4527 end Set_Is_Class_Wide_Equivalent_Type
;
4529 procedure Set_Is_Compilation_Unit
(Id
: E
; V
: B
:= True) is
4531 Set_Flag149
(Id
, V
);
4532 end Set_Is_Compilation_Unit
;
4534 procedure Set_Is_Completely_Hidden
(Id
: E
; V
: B
:= True) is
4536 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
4537 Set_Flag103
(Id
, V
);
4538 end Set_Is_Completely_Hidden
;
4540 procedure Set_Is_Concurrent_Record_Type
(Id
: E
; V
: B
:= True) is
4543 end Set_Is_Concurrent_Record_Type
;
4545 procedure Set_Is_Constr_Subt_For_U_Nominal
(Id
: E
; V
: B
:= True) is
4548 end Set_Is_Constr_Subt_For_U_Nominal
;
4550 procedure Set_Is_Constr_Subt_For_UN_Aliased
(Id
: E
; V
: B
:= True) is
4552 Set_Flag141
(Id
, V
);
4553 end Set_Is_Constr_Subt_For_UN_Aliased
;
4555 procedure Set_Is_Constrained
(Id
: E
; V
: B
:= True) is
4557 pragma Assert
(Nkind
(Id
) in N_Entity
);
4559 end Set_Is_Constrained
;
4561 procedure Set_Is_Constructor
(Id
: E
; V
: B
:= True) is
4564 end Set_Is_Constructor
;
4566 procedure Set_Is_Controlled
(Id
: E
; V
: B
:= True) is
4568 pragma Assert
(Id
= Base_Type
(Id
));
4570 end Set_Is_Controlled
;
4572 procedure Set_Is_Controlling_Formal
(Id
: E
; V
: B
:= True) is
4574 pragma Assert
(Is_Formal
(Id
));
4576 end Set_Is_Controlling_Formal
;
4578 procedure Set_Is_CPP_Class
(Id
: E
; V
: B
:= True) is
4581 end Set_Is_CPP_Class
;
4583 procedure Set_Is_Descendent_Of_Address
(Id
: E
; V
: B
:= True) is
4585 pragma Assert
(Is_Type
(Id
));
4586 Set_Flag223
(Id
, V
);
4587 end Set_Is_Descendent_Of_Address
;
4589 procedure Set_Is_Discrim_SO_Function
(Id
: E
; V
: B
:= True) is
4591 Set_Flag176
(Id
, V
);
4592 end Set_Is_Discrim_SO_Function
;
4594 procedure Set_Is_Dispatch_Table_Entity
(Id
: E
; V
: B
:= True) is
4596 Set_Flag234
(Id
, V
);
4597 end Set_Is_Dispatch_Table_Entity
;
4599 procedure Set_Is_Dispatching_Operation
(Id
: E
; V
: B
:= True) is
4604 Is_Overloadable
(Id
)
4606 Ekind
(Id
) = E_Subprogram_Type
);
4609 end Set_Is_Dispatching_Operation
;
4611 procedure Set_Is_Eliminated
(Id
: E
; V
: B
:= True) is
4613 Set_Flag124
(Id
, V
);
4614 end Set_Is_Eliminated
;
4616 procedure Set_Is_Entry_Formal
(Id
: E
; V
: B
:= True) is
4619 end Set_Is_Entry_Formal
;
4621 procedure Set_Is_Exported
(Id
: E
; V
: B
:= True) is
4624 end Set_Is_Exported
;
4626 procedure Set_Is_First_Subtype
(Id
: E
; V
: B
:= True) is
4629 end Set_Is_First_Subtype
;
4631 procedure Set_Is_For_Access_Subtype
(Id
: E
; V
: B
:= True) is
4633 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
, E_Private_Subtype
));
4634 Set_Flag118
(Id
, V
);
4635 end Set_Is_For_Access_Subtype
;
4637 procedure Set_Is_Formal_Subprogram
(Id
: E
; V
: B
:= True) is
4639 Set_Flag111
(Id
, V
);
4640 end Set_Is_Formal_Subprogram
;
4642 procedure Set_Is_Frozen
(Id
: E
; V
: B
:= True) is
4644 pragma Assert
(Nkind
(Id
) in N_Entity
);
4648 procedure Set_Is_Generic_Actual_Type
(Id
: E
; V
: B
:= True) is
4650 pragma Assert
(Is_Type
(Id
));
4652 end Set_Is_Generic_Actual_Type
;
4654 procedure Set_Is_Generic_Instance
(Id
: E
; V
: B
:= True) is
4656 Set_Flag130
(Id
, V
);
4657 end Set_Is_Generic_Instance
;
4659 procedure Set_Is_Generic_Type
(Id
: E
; V
: B
:= True) is
4661 pragma Assert
(Nkind
(Id
) in N_Entity
);
4663 end Set_Is_Generic_Type
;
4665 procedure Set_Is_Hidden
(Id
: E
; V
: B
:= True) is
4670 procedure Set_Is_Hidden_Open_Scope
(Id
: E
; V
: B
:= True) is
4672 Set_Flag171
(Id
, V
);
4673 end Set_Is_Hidden_Open_Scope
;
4675 procedure Set_Is_Immediately_Visible
(Id
: E
; V
: B
:= True) is
4677 pragma Assert
(Nkind
(Id
) in N_Entity
);
4679 end Set_Is_Immediately_Visible
;
4681 procedure Set_Is_Implementation_Defined
(Id
: E
; V
: B
:= True) is
4683 Set_Flag254
(Id
, V
);
4684 end Set_Is_Implementation_Defined
;
4686 procedure Set_Is_Imported
(Id
: E
; V
: B
:= True) is
4689 end Set_Is_Imported
;
4691 procedure Set_Is_Inlined
(Id
: E
; V
: B
:= True) is
4696 procedure Set_Is_Interface
(Id
: E
; V
: B
:= True) is
4698 pragma Assert
(Is_Record_Type
(Id
));
4699 Set_Flag186
(Id
, V
);
4700 end Set_Is_Interface
;
4702 procedure Set_Is_Instantiated
(Id
: E
; V
: B
:= True) is
4704 Set_Flag126
(Id
, V
);
4705 end Set_Is_Instantiated
;
4707 procedure Set_Is_Internal
(Id
: E
; V
: B
:= True) is
4709 pragma Assert
(Nkind
(Id
) in N_Entity
);
4711 end Set_Is_Internal
;
4713 procedure Set_Is_Interrupt_Handler
(Id
: E
; V
: B
:= True) is
4715 pragma Assert
(Nkind
(Id
) in N_Entity
);
4717 end Set_Is_Interrupt_Handler
;
4719 procedure Set_Is_Intrinsic_Subprogram
(Id
: E
; V
: B
:= True) is
4722 end Set_Is_Intrinsic_Subprogram
;
4724 procedure Set_Is_Invariant_Procedure
(Id
: E
; V
: B
:= True) is
4726 pragma Assert
(Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
4727 Set_Flag257
(Id
, V
);
4728 end Set_Is_Invariant_Procedure
;
4730 procedure Set_Is_Itype
(Id
: E
; V
: B
:= True) is
4735 procedure Set_Is_Known_Non_Null
(Id
: E
; V
: B
:= True) is
4738 end Set_Is_Known_Non_Null
;
4740 procedure Set_Is_Known_Null
(Id
: E
; V
: B
:= True) is
4742 Set_Flag204
(Id
, V
);
4743 end Set_Is_Known_Null
;
4745 procedure Set_Is_Known_Valid
(Id
: E
; V
: B
:= True) is
4747 Set_Flag170
(Id
, V
);
4748 end Set_Is_Known_Valid
;
4750 procedure Set_Is_Limited_Composite
(Id
: E
; V
: B
:= True) is
4752 pragma Assert
(Is_Type
(Id
));
4753 Set_Flag106
(Id
, V
);
4754 end Set_Is_Limited_Composite
;
4756 procedure Set_Is_Limited_Interface
(Id
: E
; V
: B
:= True) is
4758 pragma Assert
(Is_Interface
(Id
));
4759 Set_Flag197
(Id
, V
);
4760 end Set_Is_Limited_Interface
;
4762 procedure Set_Is_Limited_Record
(Id
: E
; V
: B
:= True) is
4765 end Set_Is_Limited_Record
;
4767 procedure Set_Is_Machine_Code_Subprogram
(Id
: E
; V
: B
:= True) is
4769 pragma Assert
(Is_Subprogram
(Id
));
4770 Set_Flag137
(Id
, V
);
4771 end Set_Is_Machine_Code_Subprogram
;
4773 procedure Set_Is_Non_Static_Subtype
(Id
: E
; V
: B
:= True) is
4775 pragma Assert
(Is_Type
(Id
));
4776 Set_Flag109
(Id
, V
);
4777 end Set_Is_Non_Static_Subtype
;
4779 procedure Set_Is_Null_Init_Proc
(Id
: E
; V
: B
:= True) is
4781 pragma Assert
(Ekind
(Id
) = E_Procedure
);
4782 Set_Flag178
(Id
, V
);
4783 end Set_Is_Null_Init_Proc
;
4785 procedure Set_Is_Obsolescent
(Id
: E
; V
: B
:= True) is
4787 Set_Flag153
(Id
, V
);
4788 end Set_Is_Obsolescent
;
4790 procedure Set_Is_Only_Out_Parameter
(Id
: E
; V
: B
:= True) is
4792 pragma Assert
(Ekind
(Id
) = E_Out_Parameter
);
4793 Set_Flag226
(Id
, V
);
4794 end Set_Is_Only_Out_Parameter
;
4796 procedure Set_Is_Optional_Parameter
(Id
: E
; V
: B
:= True) is
4798 pragma Assert
(Is_Formal
(Id
));
4799 Set_Flag134
(Id
, V
);
4800 end Set_Is_Optional_Parameter
;
4802 procedure Set_Is_Package_Body_Entity
(Id
: E
; V
: B
:= True) is
4804 Set_Flag160
(Id
, V
);
4805 end Set_Is_Package_Body_Entity
;
4807 procedure Set_Is_Packed
(Id
: E
; V
: B
:= True) is
4809 pragma Assert
(Id
= Base_Type
(Id
));
4813 procedure Set_Is_Packed_Array_Type
(Id
: E
; V
: B
:= True) is
4815 Set_Flag138
(Id
, V
);
4816 end Set_Is_Packed_Array_Type
;
4818 procedure Set_Is_Potentially_Use_Visible
(Id
: E
; V
: B
:= True) is
4820 pragma Assert
(Nkind
(Id
) in N_Entity
);
4822 end Set_Is_Potentially_Use_Visible
;
4824 procedure Set_Is_Predicate_Function
(Id
: E
; V
: B
:= True) is
4826 pragma Assert
(Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
4827 Set_Flag255
(Id
, V
);
4828 end Set_Is_Predicate_Function
;
4830 procedure Set_Is_Predicate_Function_M
(Id
: E
; V
: B
:= True) is
4832 pragma Assert
(Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
4833 Set_Flag256
(Id
, V
);
4834 end Set_Is_Predicate_Function_M
;
4836 procedure Set_Is_Preelaborated
(Id
: E
; V
: B
:= True) is
4839 end Set_Is_Preelaborated
;
4841 procedure Set_Is_Primitive
(Id
: E
; V
: B
:= True) is
4844 (Is_Overloadable
(Id
)
4845 or else Ekind_In
(Id
, E_Generic_Function
, E_Generic_Procedure
));
4846 Set_Flag218
(Id
, V
);
4847 end Set_Is_Primitive
;
4849 procedure Set_Is_Primitive_Wrapper
(Id
: E
; V
: B
:= True) is
4851 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
4852 Set_Flag195
(Id
, V
);
4853 end Set_Is_Primitive_Wrapper
;
4855 procedure Set_Is_Private_Composite
(Id
: E
; V
: B
:= True) is
4857 pragma Assert
(Is_Type
(Id
));
4858 Set_Flag107
(Id
, V
);
4859 end Set_Is_Private_Composite
;
4861 procedure Set_Is_Private_Descendant
(Id
: E
; V
: B
:= True) is
4864 end Set_Is_Private_Descendant
;
4866 procedure Set_Is_Private_Primitive
(Id
: E
; V
: B
:= True) is
4868 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
4869 Set_Flag245
(Id
, V
);
4870 end Set_Is_Private_Primitive
;
4872 procedure Set_Is_Processed_Transient
(Id
: E
; V
: B
:= True) is
4874 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
4875 Set_Flag252
(Id
, V
);
4876 end Set_Is_Processed_Transient
;
4878 procedure Set_Is_Public
(Id
: E
; V
: B
:= True) is
4880 pragma Assert
(Nkind
(Id
) in N_Entity
);
4884 procedure Set_Is_Pure
(Id
: E
; V
: B
:= True) is
4889 procedure Set_Is_Pure_Unit_Access_Type
(Id
: E
; V
: B
:= True) is
4891 pragma Assert
(Is_Access_Type
(Id
));
4892 Set_Flag189
(Id
, V
);
4893 end Set_Is_Pure_Unit_Access_Type
;
4895 procedure Set_Is_RACW_Stub_Type
(Id
: E
; V
: B
:= True) is
4897 pragma Assert
(Is_Type
(Id
));
4898 Set_Flag244
(Id
, V
);
4899 end Set_Is_RACW_Stub_Type
;
4901 procedure Set_Is_Raised
(Id
: E
; V
: B
:= True) is
4903 pragma Assert
(Ekind
(Id
) = E_Exception
);
4904 Set_Flag224
(Id
, V
);
4907 procedure Set_Is_Remote_Call_Interface
(Id
: E
; V
: B
:= True) is
4910 end Set_Is_Remote_Call_Interface
;
4912 procedure Set_Is_Remote_Types
(Id
: E
; V
: B
:= True) is
4915 end Set_Is_Remote_Types
;
4917 procedure Set_Is_Renaming_Of_Object
(Id
: E
; V
: B
:= True) is
4919 Set_Flag112
(Id
, V
);
4920 end Set_Is_Renaming_Of_Object
;
4922 procedure Set_Is_Return_Object
(Id
: E
; V
: B
:= True) is
4924 Set_Flag209
(Id
, V
);
4925 end Set_Is_Return_Object
;
4927 procedure Set_Is_Safe_To_Reevaluate
(Id
: E
; V
: B
:= True) is
4929 pragma Assert
(Ekind
(Id
) = E_Variable
);
4930 Set_Flag249
(Id
, V
);
4931 end Set_Is_Safe_To_Reevaluate
;
4933 procedure Set_Is_Shared_Passive
(Id
: E
; V
: B
:= True) is
4936 end Set_Is_Shared_Passive
;
4938 procedure Set_Is_Statically_Allocated
(Id
: E
; V
: B
:= True) is
4942 or else Ekind_In
(Id
, E_Exception
,
4947 end Set_Is_Statically_Allocated
;
4949 procedure Set_Is_Tag
(Id
: E
; V
: B
:= True) is
4951 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Constant
, E_Variable
));
4955 procedure Set_Is_Tagged_Type
(Id
: E
; V
: B
:= True) is
4958 end Set_Is_Tagged_Type
;
4960 procedure Set_Is_Thunk
(Id
: E
; V
: B
:= True) is
4962 pragma Assert
(Is_Subprogram
(Id
));
4963 Set_Flag225
(Id
, V
);
4966 procedure Set_Is_Trivial_Subprogram
(Id
: E
; V
: B
:= True) is
4968 Set_Flag235
(Id
, V
);
4969 end Set_Is_Trivial_Subprogram
;
4971 procedure Set_Is_True_Constant
(Id
: E
; V
: B
:= True) is
4973 Set_Flag163
(Id
, V
);
4974 end Set_Is_True_Constant
;
4976 procedure Set_Is_Unchecked_Union
(Id
: E
; V
: B
:= True) is
4978 pragma Assert
(Id
= Base_Type
(Id
));
4979 Set_Flag117
(Id
, V
);
4980 end Set_Is_Unchecked_Union
;
4982 procedure Set_Is_Underlying_Record_View
(Id
: E
; V
: B
:= True) is
4984 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
4985 Set_Flag246
(Id
, V
);
4986 end Set_Is_Underlying_Record_View
;
4988 procedure Set_Is_Unsigned_Type
(Id
: E
; V
: B
:= True) is
4990 pragma Assert
(Is_Discrete_Or_Fixed_Point_Type
(Id
));
4991 Set_Flag144
(Id
, V
);
4992 end Set_Is_Unsigned_Type
;
4994 procedure Set_Is_Valued_Procedure
(Id
: E
; V
: B
:= True) is
4996 pragma Assert
(Ekind
(Id
) = E_Procedure
);
4997 Set_Flag127
(Id
, V
);
4998 end Set_Is_Valued_Procedure
;
5000 procedure Set_Is_Visible_Formal
(Id
: E
; V
: B
:= True) is
5002 Set_Flag206
(Id
, V
);
5003 end Set_Is_Visible_Formal
;
5005 procedure Set_Is_Visible_Lib_Unit
(Id
: E
; V
: B
:= True) is
5007 Set_Flag116
(Id
, V
);
5008 end Set_Is_Visible_Lib_Unit
;
5010 procedure Set_Is_VMS_Exception
(Id
: E
; V
: B
:= True) is
5012 pragma Assert
(Ekind
(Id
) = E_Exception
);
5013 Set_Flag133
(Id
, V
);
5014 end Set_Is_VMS_Exception
;
5016 procedure Set_Is_Volatile
(Id
: E
; V
: B
:= True) is
5018 pragma Assert
(Nkind
(Id
) in N_Entity
);
5020 end Set_Is_Volatile
;
5022 procedure Set_Itype_Printed
(Id
: E
; V
: B
:= True) is
5024 pragma Assert
(Is_Itype
(Id
));
5025 Set_Flag202
(Id
, V
);
5026 end Set_Itype_Printed
;
5028 procedure Set_Kill_Elaboration_Checks
(Id
: E
; V
: B
:= True) is
5031 end Set_Kill_Elaboration_Checks
;
5033 procedure Set_Kill_Range_Checks
(Id
: E
; V
: B
:= True) is
5036 end Set_Kill_Range_Checks
;
5038 procedure Set_Known_To_Have_Preelab_Init
(Id
: E
; V
: B
:= True) is
5040 pragma Assert
(Is_Type
(Id
));
5041 Set_Flag207
(Id
, V
);
5042 end Set_Known_To_Have_Preelab_Init
;
5044 procedure Set_Last_Assignment
(Id
: E
; V
: N
) is
5046 pragma Assert
(Is_Assignable
(Id
));
5048 end Set_Last_Assignment
;
5050 procedure Set_Last_Entity
(Id
: E
; V
: E
) is
5053 end Set_Last_Entity
;
5055 procedure Set_Limited_View
(Id
: E
; V
: E
) is
5057 pragma Assert
(Ekind
(Id
) = E_Package
);
5059 end Set_Limited_View
;
5061 procedure Set_Lit_Indexes
(Id
: E
; V
: E
) is
5063 pragma Assert
(Is_Enumeration_Type
(Id
) and then Root_Type
(Id
) = Id
);
5065 end Set_Lit_Indexes
;
5067 procedure Set_Lit_Strings
(Id
: E
; V
: E
) is
5069 pragma Assert
(Is_Enumeration_Type
(Id
) and then Root_Type
(Id
) = Id
);
5071 end Set_Lit_Strings
;
5073 procedure Set_Low_Bound_Tested
(Id
: E
; V
: B
:= True) is
5075 pragma Assert
(Is_Formal
(Id
));
5076 Set_Flag205
(Id
, V
);
5077 end Set_Low_Bound_Tested
;
5079 procedure Set_Machine_Radix_10
(Id
: E
; V
: B
:= True) is
5081 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
5083 end Set_Machine_Radix_10
;
5085 procedure Set_Master_Id
(Id
: E
; V
: E
) is
5087 pragma Assert
(Is_Access_Type
(Id
));
5091 procedure Set_Materialize_Entity
(Id
: E
; V
: B
:= True) is
5093 Set_Flag168
(Id
, V
);
5094 end Set_Materialize_Entity
;
5096 procedure Set_May_Inherit_Delayed_Rep_Aspects
(Id
: E
; V
: B
:= True) is
5098 Set_Flag262
(Id
, V
);
5099 end Set_May_Inherit_Delayed_Rep_Aspects
;
5101 procedure Set_Mechanism
(Id
: E
; V
: M
) is
5103 pragma Assert
(Ekind
(Id
) = E_Function
or else Is_Formal
(Id
));
5104 Set_Uint8
(Id
, UI_From_Int
(V
));
5107 procedure Set_Modulus
(Id
: E
; V
: U
) is
5109 pragma Assert
(Ekind
(Id
) = E_Modular_Integer_Type
);
5113 procedure Set_Must_Be_On_Byte_Boundary
(Id
: E
; V
: B
:= True) is
5115 pragma Assert
(Is_Type
(Id
));
5116 Set_Flag183
(Id
, V
);
5117 end Set_Must_Be_On_Byte_Boundary
;
5119 procedure Set_Must_Have_Preelab_Init
(Id
: E
; V
: B
:= True) is
5121 pragma Assert
(Is_Type
(Id
));
5122 Set_Flag208
(Id
, V
);
5123 end Set_Must_Have_Preelab_Init
;
5125 procedure Set_Needs_Debug_Info
(Id
: E
; V
: B
:= True) is
5127 Set_Flag147
(Id
, V
);
5128 end Set_Needs_Debug_Info
;
5130 procedure Set_Needs_No_Actuals
(Id
: E
; V
: B
:= True) is
5133 (Is_Overloadable
(Id
)
5134 or else Ekind_In
(Id
, E_Subprogram_Type
, E_Entry_Family
));
5136 end Set_Needs_No_Actuals
;
5138 procedure Set_Never_Set_In_Source
(Id
: E
; V
: B
:= True) is
5140 Set_Flag115
(Id
, V
);
5141 end Set_Never_Set_In_Source
;
5143 procedure Set_Next_Inlined_Subprogram
(Id
: E
; V
: E
) is
5146 end Set_Next_Inlined_Subprogram
;
5148 procedure Set_No_Pool_Assigned
(Id
: E
; V
: B
:= True) is
5150 pragma Assert
(Is_Access_Type
(Id
) and then Is_Base_Type
(Id
));
5151 Set_Flag131
(Id
, V
);
5152 end Set_No_Pool_Assigned
;
5154 procedure Set_No_Return
(Id
: E
; V
: B
:= True) is
5157 (V
= False or else Ekind_In
(Id
, E_Procedure
, E_Generic_Procedure
));
5158 Set_Flag113
(Id
, V
);
5161 procedure Set_No_Strict_Aliasing
(Id
: E
; V
: B
:= True) is
5163 pragma Assert
(Is_Access_Type
(Id
) and then Is_Base_Type
(Id
));
5164 Set_Flag136
(Id
, V
);
5165 end Set_No_Strict_Aliasing
;
5167 procedure Set_Non_Binary_Modulus
(Id
: E
; V
: B
:= True) is
5169 pragma Assert
(Is_Type
(Id
) and then Is_Base_Type
(Id
));
5171 end Set_Non_Binary_Modulus
;
5173 procedure Set_Non_Limited_View
(Id
: E
; V
: E
) is
5175 pragma Assert
(Ekind
(Id
) in Incomplete_Kind
);
5177 end Set_Non_Limited_View
;
5179 procedure Set_Nonzero_Is_True
(Id
: E
; V
: B
:= True) is
5182 (Root_Type
(Id
) = Standard_Boolean
5183 and then Ekind
(Id
) = E_Enumeration_Type
);
5184 Set_Flag162
(Id
, V
);
5185 end Set_Nonzero_Is_True
;
5187 procedure Set_Normalized_First_Bit
(Id
: E
; V
: U
) is
5189 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
5191 end Set_Normalized_First_Bit
;
5193 procedure Set_Normalized_Position
(Id
: E
; V
: U
) is
5195 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
5197 end Set_Normalized_Position
;
5199 procedure Set_Normalized_Position_Max
(Id
: E
; V
: U
) is
5201 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
5203 end Set_Normalized_Position_Max
;
5205 procedure Set_OK_To_Rename
(Id
: E
; V
: B
:= True) is
5207 pragma Assert
(Ekind
(Id
) = E_Variable
);
5208 Set_Flag247
(Id
, V
);
5209 end Set_OK_To_Rename
;
5211 procedure Set_OK_To_Reorder_Components
(Id
: E
; V
: B
:= True) is
5214 (Is_Record_Type
(Id
) and then Is_Base_Type
(Id
));
5215 Set_Flag239
(Id
, V
);
5216 end Set_OK_To_Reorder_Components
;
5218 procedure Set_Optimize_Alignment_Space
(Id
: E
; V
: B
:= True) is
5221 (Is_Type
(Id
) or else Ekind_In
(Id
, E_Constant
, E_Variable
));
5222 Set_Flag241
(Id
, V
);
5223 end Set_Optimize_Alignment_Space
;
5225 procedure Set_Optimize_Alignment_Time
(Id
: E
; V
: B
:= True) is
5228 (Is_Type
(Id
) or else Ekind_In
(Id
, E_Constant
, E_Variable
));
5229 Set_Flag242
(Id
, V
);
5230 end Set_Optimize_Alignment_Time
;
5232 procedure Set_Original_Access_Type
(Id
: E
; V
: E
) is
5234 pragma Assert
(Ekind
(Id
) = E_Access_Subprogram_Type
);
5236 end Set_Original_Access_Type
;
5238 procedure Set_Original_Array_Type
(Id
: E
; V
: E
) is
5240 pragma Assert
(Is_Array_Type
(Id
) or else Is_Modular_Integer_Type
(Id
));
5242 end Set_Original_Array_Type
;
5244 procedure Set_Original_Record_Component
(Id
: E
; V
: E
) is
5246 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Component
, E_Discriminant
));
5248 end Set_Original_Record_Component
;
5250 procedure Set_Overlays_Constant
(Id
: E
; V
: B
:= True) is
5252 Set_Flag243
(Id
, V
);
5253 end Set_Overlays_Constant
;
5255 procedure Set_Overridden_Operation
(Id
: E
; V
: E
) is
5258 end Set_Overridden_Operation
;
5260 procedure Set_Package_Instantiation
(Id
: E
; V
: N
) is
5262 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Generic_Package
, E_Package
));
5264 end Set_Package_Instantiation
;
5266 procedure Set_Packed_Array_Type
(Id
: E
; V
: E
) is
5268 pragma Assert
(Is_Array_Type
(Id
));
5270 end Set_Packed_Array_Type
;
5272 procedure Set_Parent_Subtype
(Id
: E
; V
: E
) is
5274 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
5276 end Set_Parent_Subtype
;
5278 procedure Set_Postcondition_Proc
(Id
: E
; V
: E
) is
5280 pragma Assert
(Ekind
(Id
) = E_Procedure
);
5282 end Set_Postcondition_Proc
;
5284 procedure Set_PPC_Wrapper
(Id
: E
; V
: E
) is
5286 pragma Assert
(Ekind_In
(Id
, E_Entry
, E_Entry_Family
));
5288 end Set_PPC_Wrapper
;
5290 procedure Set_Direct_Primitive_Operations
(Id
: E
; V
: L
) is
5292 pragma Assert
(Is_Tagged_Type
(Id
));
5293 Set_Elist10
(Id
, V
);
5294 end Set_Direct_Primitive_Operations
;
5296 procedure Set_Prival
(Id
: E
; V
: E
) is
5298 pragma Assert
(Is_Protected_Component
(Id
));
5302 procedure Set_Prival_Link
(Id
: E
; V
: E
) is
5304 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
5306 end Set_Prival_Link
;
5308 procedure Set_Private_Dependents
(Id
: E
; V
: L
) is
5310 pragma Assert
(Is_Incomplete_Or_Private_Type
(Id
));
5311 Set_Elist18
(Id
, V
);
5312 end Set_Private_Dependents
;
5314 procedure Set_Private_View
(Id
: E
; V
: N
) is
5316 pragma Assert
(Is_Private_Type
(Id
));
5318 end Set_Private_View
;
5320 procedure Set_Protected_Body_Subprogram
(Id
: E
; V
: E
) is
5322 pragma Assert
(Is_Subprogram
(Id
) or else Is_Entry
(Id
));
5324 end Set_Protected_Body_Subprogram
;
5326 procedure Set_Protected_Formal
(Id
: E
; V
: E
) is
5328 pragma Assert
(Is_Formal
(Id
));
5330 end Set_Protected_Formal
;
5332 procedure Set_Protection_Object
(Id
: E
; V
: E
) is
5334 pragma Assert
(Ekind_In
(Id
, E_Entry
,
5339 end Set_Protection_Object
;
5341 procedure Set_Reachable
(Id
: E
; V
: B
:= True) is
5346 procedure Set_Referenced
(Id
: E
; V
: B
:= True) is
5348 Set_Flag156
(Id
, V
);
5351 procedure Set_Referenced_As_LHS
(Id
: E
; V
: B
:= True) is
5354 end Set_Referenced_As_LHS
;
5356 procedure Set_Referenced_As_Out_Parameter
(Id
: E
; V
: B
:= True) is
5358 Set_Flag227
(Id
, V
);
5359 end Set_Referenced_As_Out_Parameter
;
5361 procedure Set_Refined_State
(Id
: E
; V
: E
) is
5363 pragma Assert
(Ekind_In
(Id
, E_Abstract_State
, E_Variable
));
5365 end Set_Refined_State
;
5367 procedure Set_Refinement_Constituents
(Id
: E
; V
: L
) is
5369 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
5371 end Set_Refinement_Constituents
;
5373 procedure Set_Register_Exception_Call
(Id
: E
; V
: N
) is
5375 pragma Assert
(Ekind
(Id
) = E_Exception
);
5377 end Set_Register_Exception_Call
;
5379 procedure Set_Related_Array_Object
(Id
: E
; V
: E
) is
5381 pragma Assert
(Is_Array_Type
(Id
));
5383 end Set_Related_Array_Object
;
5385 procedure Set_Related_Expression
(Id
: E
; V
: N
) is
5387 pragma Assert
(Ekind
(Id
) in Type_Kind
5388 or else Ekind_In
(Id
, E_Constant
, E_Variable
, E_Void
));
5390 end Set_Related_Expression
;
5392 procedure Set_Related_Instance
(Id
: E
; V
: E
) is
5394 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Package_Body
));
5396 end Set_Related_Instance
;
5398 procedure Set_Related_Type
(Id
: E
; V
: E
) is
5400 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Constant
, E_Variable
));
5402 end Set_Related_Type
;
5404 procedure Set_Relative_Deadline_Variable
(Id
: E
; V
: E
) is
5406 pragma Assert
(Is_Task_Type
(Id
) and then Is_Base_Type
(Id
));
5408 end Set_Relative_Deadline_Variable
;
5410 procedure Set_Renamed_Entity
(Id
: E
; V
: N
) is
5413 end Set_Renamed_Entity
;
5415 procedure Set_Renamed_In_Spec
(Id
: E
; V
: B
:= True) is
5417 pragma Assert
(Ekind
(Id
) = E_Package
);
5418 Set_Flag231
(Id
, V
);
5419 end Set_Renamed_In_Spec
;
5421 procedure Set_Renamed_Object
(Id
: E
; V
: N
) is
5424 end Set_Renamed_Object
;
5426 procedure Set_Renaming_Map
(Id
: E
; V
: U
) is
5429 end Set_Renaming_Map
;
5431 procedure Set_Requires_Overriding
(Id
: E
; V
: B
:= True) is
5433 pragma Assert
(Is_Overloadable
(Id
));
5434 Set_Flag213
(Id
, V
);
5435 end Set_Requires_Overriding
;
5437 procedure Set_Return_Present
(Id
: E
; V
: B
:= True) is
5440 end Set_Return_Present
;
5442 procedure Set_Return_Applies_To
(Id
: E
; V
: N
) is
5445 end Set_Return_Applies_To
;
5447 procedure Set_Returns_By_Ref
(Id
: E
; V
: B
:= True) is
5450 end Set_Returns_By_Ref
;
5452 procedure Set_Reverse_Bit_Order
(Id
: E
; V
: B
:= True) is
5455 (Is_Record_Type
(Id
) and then Is_Base_Type
(Id
));
5456 Set_Flag164
(Id
, V
);
5457 end Set_Reverse_Bit_Order
;
5459 procedure Set_Reverse_Storage_Order
(Id
: E
; V
: B
:= True) is
5463 and then (Is_Record_Type
(Id
) or else Is_Array_Type
(Id
)));
5465 end Set_Reverse_Storage_Order
;
5467 procedure Set_RM_Size
(Id
: E
; V
: U
) is
5469 pragma Assert
(Is_Type
(Id
));
5473 procedure Set_Scalar_Range
(Id
: E
; V
: N
) is
5476 end Set_Scalar_Range
;
5478 procedure Set_Scale_Value
(Id
: E
; V
: U
) is
5481 end Set_Scale_Value
;
5483 procedure Set_Scope_Depth_Value
(Id
: E
; V
: U
) is
5485 pragma Assert
(not Is_Record_Type
(Id
));
5487 end Set_Scope_Depth_Value
;
5489 procedure Set_Sec_Stack_Needed_For_Return
(Id
: E
; V
: B
:= True) is
5491 Set_Flag167
(Id
, V
);
5492 end Set_Sec_Stack_Needed_For_Return
;
5494 procedure Set_Shadow_Entities
(Id
: E
; V
: S
) is
5496 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
5498 end Set_Shadow_Entities
;
5500 procedure Set_Shared_Var_Procs_Instance
(Id
: E
; V
: E
) is
5502 pragma Assert
(Ekind
(Id
) = E_Variable
);
5504 end Set_Shared_Var_Procs_Instance
;
5506 procedure Set_Size_Check_Code
(Id
: E
; V
: N
) is
5508 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
5510 end Set_Size_Check_Code
;
5512 procedure Set_Size_Depends_On_Discriminant
(Id
: E
; V
: B
:= True) is
5514 Set_Flag177
(Id
, V
);
5515 end Set_Size_Depends_On_Discriminant
;
5517 procedure Set_Size_Known_At_Compile_Time
(Id
: E
; V
: B
:= True) is
5520 end Set_Size_Known_At_Compile_Time
;
5522 procedure Set_Small_Value
(Id
: E
; V
: R
) is
5524 pragma Assert
(Is_Fixed_Point_Type
(Id
));
5525 Set_Ureal21
(Id
, V
);
5526 end Set_Small_Value
;
5528 procedure Set_SPARK_Mode_Pragmas
(Id
: E
; V
: N
) is
5531 (Ekind_In
(Id
, E_Function
, -- subprogram variants
5533 E_Generic_Procedure
,
5537 Ekind_In
(Id
, E_Generic_Package
, -- package variants
5542 end Set_SPARK_Mode_Pragmas
;
5544 procedure Set_Spec_Entity
(Id
: E
; V
: E
) is
5546 pragma Assert
(Ekind
(Id
) = E_Package_Body
or else Is_Formal
(Id
));
5548 end Set_Spec_Entity
;
5550 procedure Set_Static_Predicate
(Id
: E
; V
: S
) is
5553 (Ekind_In
(Id
, E_Enumeration_Subtype
,
5554 E_Modular_Integer_Subtype
,
5555 E_Signed_Integer_Subtype
)
5556 and then Has_Predicates
(Id
));
5558 end Set_Static_Predicate
;
5560 procedure Set_Status_Flag_Or_Transient_Decl
(Id
: E
; V
: E
) is
5562 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
5564 end Set_Status_Flag_Or_Transient_Decl
;
5566 procedure Set_Storage_Size_Variable
(Id
: E
; V
: E
) is
5568 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
5569 pragma Assert
(Id
= Base_Type
(Id
));
5571 end Set_Storage_Size_Variable
;
5573 procedure Set_Static_Elaboration_Desired
(Id
: E
; V
: B
) is
5575 pragma Assert
(Ekind
(Id
) = E_Package
);
5577 end Set_Static_Elaboration_Desired
;
5579 procedure Set_Static_Initialization
(Id
: E
; V
: N
) is
5582 (Ekind
(Id
) = E_Procedure
and then not Is_Dispatching_Operation
(Id
));
5584 end Set_Static_Initialization
;
5586 procedure Set_Stored_Constraint
(Id
: E
; V
: L
) is
5588 pragma Assert
(Nkind
(Id
) in N_Entity
);
5589 Set_Elist23
(Id
, V
);
5590 end Set_Stored_Constraint
;
5592 procedure Set_Strict_Alignment
(Id
: E
; V
: B
:= True) is
5594 pragma Assert
(Id
= Base_Type
(Id
));
5595 Set_Flag145
(Id
, V
);
5596 end Set_Strict_Alignment
;
5598 procedure Set_String_Literal_Length
(Id
: E
; V
: U
) is
5600 pragma Assert
(Ekind
(Id
) = E_String_Literal_Subtype
);
5602 end Set_String_Literal_Length
;
5604 procedure Set_String_Literal_Low_Bound
(Id
: E
; V
: N
) is
5606 pragma Assert
(Ekind
(Id
) = E_String_Literal_Subtype
);
5608 end Set_String_Literal_Low_Bound
;
5610 procedure Set_Subprograms_For_Type
(Id
: E
; V
: E
) is
5612 pragma Assert
(Is_Type
(Id
) or else Is_Subprogram
(Id
));
5614 end Set_Subprograms_For_Type
;
5616 procedure Set_Suppress_Elaboration_Warnings
(Id
: E
; V
: B
:= True) is
5618 Set_Flag148
(Id
, V
);
5619 end Set_Suppress_Elaboration_Warnings
;
5621 procedure Set_Suppress_Initialization
(Id
: E
; V
: B
:= True) is
5623 pragma Assert
(Is_Type
(Id
));
5624 Set_Flag105
(Id
, V
);
5625 end Set_Suppress_Initialization
;
5627 procedure Set_Suppress_Style_Checks
(Id
: E
; V
: B
:= True) is
5629 Set_Flag165
(Id
, V
);
5630 end Set_Suppress_Style_Checks
;
5632 procedure Set_Suppress_Value_Tracking_On_Call
(Id
: E
; V
: B
:= True) is
5634 Set_Flag217
(Id
, V
);
5635 end Set_Suppress_Value_Tracking_On_Call
;
5637 procedure Set_Task_Body_Procedure
(Id
: E
; V
: N
) is
5639 pragma Assert
(Ekind
(Id
) in Task_Kind
);
5641 end Set_Task_Body_Procedure
;
5643 procedure Set_Thunk_Entity
(Id
: E
; V
: E
) is
5645 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
5646 and then Is_Thunk
(Id
));
5648 end Set_Thunk_Entity
;
5650 procedure Set_Treat_As_Volatile
(Id
: E
; V
: B
:= True) is
5653 end Set_Treat_As_Volatile
;
5655 procedure Set_Underlying_Full_View
(Id
: E
; V
: E
) is
5657 pragma Assert
(Ekind
(Id
) in Private_Kind
);
5659 end Set_Underlying_Full_View
;
5661 procedure Set_Underlying_Record_View
(Id
: E
; V
: E
) is
5663 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
5665 end Set_Underlying_Record_View
;
5667 procedure Set_Universal_Aliasing
(Id
: E
; V
: B
:= True) is
5669 pragma Assert
(Is_Type
(Id
) and then Is_Base_Type
(Id
));
5670 Set_Flag216
(Id
, V
);
5671 end Set_Universal_Aliasing
;
5673 procedure Set_Unset_Reference
(Id
: E
; V
: N
) is
5676 end Set_Unset_Reference
;
5678 procedure Set_Used_As_Generic_Actual
(Id
: E
; V
: B
:= True) is
5680 Set_Flag222
(Id
, V
);
5681 end Set_Used_As_Generic_Actual
;
5683 procedure Set_Uses_Lock_Free
(Id
: E
; V
: B
:= True) is
5685 pragma Assert
(Ekind
(Id
) = E_Protected_Type
);
5686 Set_Flag188
(Id
, V
);
5687 end Set_Uses_Lock_Free
;
5689 procedure Set_Uses_Sec_Stack
(Id
: E
; V
: B
:= True) is
5692 end Set_Uses_Sec_Stack
;
5694 procedure Set_Warnings_Off
(Id
: E
; V
: B
:= True) is
5697 end Set_Warnings_Off
;
5699 procedure Set_Warnings_Off_Used
(Id
: E
; V
: B
:= True) is
5701 Set_Flag236
(Id
, V
);
5702 end Set_Warnings_Off_Used
;
5704 procedure Set_Warnings_Off_Used_Unmodified
(Id
: E
; V
: B
:= True) is
5706 Set_Flag237
(Id
, V
);
5707 end Set_Warnings_Off_Used_Unmodified
;
5709 procedure Set_Warnings_Off_Used_Unreferenced
(Id
: E
; V
: B
:= True) is
5711 Set_Flag238
(Id
, V
);
5712 end Set_Warnings_Off_Used_Unreferenced
;
5714 procedure Set_Was_Hidden
(Id
: E
; V
: B
:= True) is
5716 Set_Flag196
(Id
, V
);
5719 procedure Set_Wrapped_Entity
(Id
: E
; V
: E
) is
5721 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
5722 and then Is_Primitive_Wrapper
(Id
));
5724 end Set_Wrapped_Entity
;
5726 -----------------------------------
5727 -- Field Initialization Routines --
5728 -----------------------------------
5730 procedure Init_Alignment
(Id
: E
) is
5732 Set_Uint14
(Id
, Uint_0
);
5735 procedure Init_Alignment
(Id
: E
; V
: Int
) is
5737 Set_Uint14
(Id
, UI_From_Int
(V
));
5740 procedure Init_Component_Bit_Offset
(Id
: E
) is
5742 Set_Uint11
(Id
, No_Uint
);
5743 end Init_Component_Bit_Offset
;
5745 procedure Init_Component_Bit_Offset
(Id
: E
; V
: Int
) is
5747 Set_Uint11
(Id
, UI_From_Int
(V
));
5748 end Init_Component_Bit_Offset
;
5750 procedure Init_Component_Size
(Id
: E
) is
5752 Set_Uint22
(Id
, Uint_0
);
5753 end Init_Component_Size
;
5755 procedure Init_Component_Size
(Id
: E
; V
: Int
) is
5757 Set_Uint22
(Id
, UI_From_Int
(V
));
5758 end Init_Component_Size
;
5760 procedure Init_Digits_Value
(Id
: E
) is
5762 Set_Uint17
(Id
, Uint_0
);
5763 end Init_Digits_Value
;
5765 procedure Init_Digits_Value
(Id
: E
; V
: Int
) is
5767 Set_Uint17
(Id
, UI_From_Int
(V
));
5768 end Init_Digits_Value
;
5770 procedure Init_Esize
(Id
: E
) is
5772 Set_Uint12
(Id
, Uint_0
);
5775 procedure Init_Esize
(Id
: E
; V
: Int
) is
5777 Set_Uint12
(Id
, UI_From_Int
(V
));
5780 procedure Init_Normalized_First_Bit
(Id
: E
) is
5782 Set_Uint8
(Id
, No_Uint
);
5783 end Init_Normalized_First_Bit
;
5785 procedure Init_Normalized_First_Bit
(Id
: E
; V
: Int
) is
5787 Set_Uint8
(Id
, UI_From_Int
(V
));
5788 end Init_Normalized_First_Bit
;
5790 procedure Init_Normalized_Position
(Id
: E
) is
5792 Set_Uint14
(Id
, No_Uint
);
5793 end Init_Normalized_Position
;
5795 procedure Init_Normalized_Position
(Id
: E
; V
: Int
) is
5797 Set_Uint14
(Id
, UI_From_Int
(V
));
5798 end Init_Normalized_Position
;
5800 procedure Init_Normalized_Position_Max
(Id
: E
) is
5802 Set_Uint10
(Id
, No_Uint
);
5803 end Init_Normalized_Position_Max
;
5805 procedure Init_Normalized_Position_Max
(Id
: E
; V
: Int
) is
5807 Set_Uint10
(Id
, UI_From_Int
(V
));
5808 end Init_Normalized_Position_Max
;
5810 procedure Init_RM_Size
(Id
: E
) is
5812 Set_Uint13
(Id
, Uint_0
);
5815 procedure Init_RM_Size
(Id
: E
; V
: Int
) is
5817 Set_Uint13
(Id
, UI_From_Int
(V
));
5820 -----------------------------
5821 -- Init_Component_Location --
5822 -----------------------------
5824 procedure Init_Component_Location
(Id
: E
) is
5826 Set_Uint8
(Id
, No_Uint
); -- Normalized_First_Bit
5827 Set_Uint10
(Id
, No_Uint
); -- Normalized_Position_Max
5828 Set_Uint11
(Id
, No_Uint
); -- Component_Bit_Offset
5829 Set_Uint12
(Id
, Uint_0
); -- Esize
5830 Set_Uint14
(Id
, No_Uint
); -- Normalized_Position
5831 end Init_Component_Location
;
5833 ----------------------------
5834 -- Init_Object_Size_Align --
5835 ----------------------------
5837 procedure Init_Object_Size_Align
(Id
: E
) is
5839 Set_Uint12
(Id
, Uint_0
); -- Esize
5840 Set_Uint14
(Id
, Uint_0
); -- Alignment
5841 end Init_Object_Size_Align
;
5847 procedure Init_Size
(Id
: E
; V
: Int
) is
5849 pragma Assert
(not Is_Object
(Id
));
5850 Set_Uint12
(Id
, UI_From_Int
(V
)); -- Esize
5851 Set_Uint13
(Id
, UI_From_Int
(V
)); -- RM_Size
5854 ---------------------
5855 -- Init_Size_Align --
5856 ---------------------
5858 procedure Init_Size_Align
(Id
: E
) is
5860 pragma Assert
(not Is_Object
(Id
));
5861 Set_Uint12
(Id
, Uint_0
); -- Esize
5862 Set_Uint13
(Id
, Uint_0
); -- RM_Size
5863 Set_Uint14
(Id
, Uint_0
); -- Alignment
5864 end Init_Size_Align
;
5866 ----------------------------------------------
5867 -- Type Representation Attribute Predicates --
5868 ----------------------------------------------
5870 function Known_Alignment
(E
: Entity_Id
) return B
is
5872 return Uint14
(E
) /= Uint_0
5873 and then Uint14
(E
) /= No_Uint
;
5874 end Known_Alignment
;
5876 function Known_Component_Bit_Offset
(E
: Entity_Id
) return B
is
5878 return Uint11
(E
) /= No_Uint
;
5879 end Known_Component_Bit_Offset
;
5881 function Known_Component_Size
(E
: Entity_Id
) return B
is
5883 return Uint22
(Base_Type
(E
)) /= Uint_0
5884 and then Uint22
(Base_Type
(E
)) /= No_Uint
;
5885 end Known_Component_Size
;
5887 function Known_Esize
(E
: Entity_Id
) return B
is
5889 return Uint12
(E
) /= Uint_0
5890 and then Uint12
(E
) /= No_Uint
;
5893 function Known_Normalized_First_Bit
(E
: Entity_Id
) return B
is
5895 return Uint8
(E
) /= No_Uint
;
5896 end Known_Normalized_First_Bit
;
5898 function Known_Normalized_Position
(E
: Entity_Id
) return B
is
5900 return Uint14
(E
) /= No_Uint
;
5901 end Known_Normalized_Position
;
5903 function Known_Normalized_Position_Max
(E
: Entity_Id
) return B
is
5905 return Uint10
(E
) /= No_Uint
;
5906 end Known_Normalized_Position_Max
;
5908 function Known_RM_Size
(E
: Entity_Id
) return B
is
5910 return Uint13
(E
) /= No_Uint
5911 and then (Uint13
(E
) /= Uint_0
5912 or else Is_Discrete_Type
(E
)
5913 or else Is_Fixed_Point_Type
(E
));
5916 function Known_Static_Component_Bit_Offset
(E
: Entity_Id
) return B
is
5918 return Uint11
(E
) /= No_Uint
5919 and then Uint11
(E
) >= Uint_0
;
5920 end Known_Static_Component_Bit_Offset
;
5922 function Known_Static_Component_Size
(E
: Entity_Id
) return B
is
5924 return Uint22
(Base_Type
(E
)) > Uint_0
;
5925 end Known_Static_Component_Size
;
5927 function Known_Static_Esize
(E
: Entity_Id
) return B
is
5929 return Uint12
(E
) > Uint_0
5930 and then not Is_Generic_Type
(E
);
5931 end Known_Static_Esize
;
5933 function Known_Static_Normalized_First_Bit
(E
: Entity_Id
) return B
is
5935 return Uint8
(E
) /= No_Uint
5936 and then Uint8
(E
) >= Uint_0
;
5937 end Known_Static_Normalized_First_Bit
;
5939 function Known_Static_Normalized_Position
(E
: Entity_Id
) return B
is
5941 return Uint14
(E
) /= No_Uint
5942 and then Uint14
(E
) >= Uint_0
;
5943 end Known_Static_Normalized_Position
;
5945 function Known_Static_Normalized_Position_Max
(E
: Entity_Id
) return B
is
5947 return Uint10
(E
) /= No_Uint
5948 and then Uint10
(E
) >= Uint_0
;
5949 end Known_Static_Normalized_Position_Max
;
5951 function Known_Static_RM_Size
(E
: Entity_Id
) return B
is
5953 return (Uint13
(E
) > Uint_0
5954 or else Is_Discrete_Type
(E
)
5955 or else Is_Fixed_Point_Type
(E
))
5956 and then not Is_Generic_Type
(E
);
5957 end Known_Static_RM_Size
;
5959 function Unknown_Alignment
(E
: Entity_Id
) return B
is
5961 return Uint14
(E
) = Uint_0
5962 or else Uint14
(E
) = No_Uint
;
5963 end Unknown_Alignment
;
5965 function Unknown_Component_Bit_Offset
(E
: Entity_Id
) return B
is
5967 return Uint11
(E
) = No_Uint
;
5968 end Unknown_Component_Bit_Offset
;
5970 function Unknown_Component_Size
(E
: Entity_Id
) return B
is
5972 return Uint22
(Base_Type
(E
)) = Uint_0
5974 Uint22
(Base_Type
(E
)) = No_Uint
;
5975 end Unknown_Component_Size
;
5977 function Unknown_Esize
(E
: Entity_Id
) return B
is
5979 return Uint12
(E
) = No_Uint
5981 Uint12
(E
) = Uint_0
;
5984 function Unknown_Normalized_First_Bit
(E
: Entity_Id
) return B
is
5986 return Uint8
(E
) = No_Uint
;
5987 end Unknown_Normalized_First_Bit
;
5989 function Unknown_Normalized_Position
(E
: Entity_Id
) return B
is
5991 return Uint14
(E
) = No_Uint
;
5992 end Unknown_Normalized_Position
;
5994 function Unknown_Normalized_Position_Max
(E
: Entity_Id
) return B
is
5996 return Uint10
(E
) = No_Uint
;
5997 end Unknown_Normalized_Position_Max
;
5999 function Unknown_RM_Size
(E
: Entity_Id
) return B
is
6001 return (Uint13
(E
) = Uint_0
6002 and then not Is_Discrete_Type
(E
)
6003 and then not Is_Fixed_Point_Type
(E
))
6004 or else Uint13
(E
) = No_Uint
;
6005 end Unknown_RM_Size
;
6007 --------------------
6008 -- Address_Clause --
6009 --------------------
6011 function Address_Clause
(Id
: E
) return N
is
6013 return Get_Attribute_Definition_Clause
(Id
, Attribute_Address
);
6020 function Aft_Value
(Id
: E
) return U
is
6022 Delta_Val
: Ureal
:= Delta_Value
(Id
);
6024 while Delta_Val
< Ureal_Tenth
loop
6025 Delta_Val
:= Delta_Val
* Ureal_10
;
6026 Result
:= Result
+ 1;
6029 return UI_From_Int
(Result
);
6032 ----------------------
6033 -- Alignment_Clause --
6034 ----------------------
6036 function Alignment_Clause
(Id
: E
) return N
is
6038 return Get_Attribute_Definition_Clause
(Id
, Attribute_Alignment
);
6039 end Alignment_Clause
;
6045 procedure Append_Entity
(Id
: Entity_Id
; V
: Entity_Id
) is
6047 if Last_Entity
(V
) = Empty
then
6048 Set_First_Entity
(Id
=> V
, V
=> Id
);
6050 Set_Next_Entity
(Last_Entity
(V
), Id
);
6053 Set_Next_Entity
(Id
, Empty
);
6055 Set_Last_Entity
(Id
=> V
, V
=> Id
);
6062 function Base_Type
(Id
: E
) return E
is
6064 if Is_Base_Type
(Id
) then
6067 pragma Assert
(Is_Type
(Id
));
6072 -------------------------
6073 -- Component_Alignment --
6074 -------------------------
6076 -- Component Alignment is encoded using two flags, Flag128/129 as
6077 -- follows. Note that both flags False = Align_Default, so that the
6078 -- default initialization of flags to False initializes component
6079 -- alignment to the default value as required.
6081 -- Flag128 Flag129 Value
6082 -- ------- ------- -----
6083 -- False False Calign_Default
6084 -- False True Calign_Component_Size
6085 -- True False Calign_Component_Size_4
6086 -- True True Calign_Storage_Unit
6088 function Component_Alignment
(Id
: E
) return C
is
6089 BT
: constant Node_Id
:= Base_Type
(Id
);
6092 pragma Assert
(Is_Array_Type
(Id
) or else Is_Record_Type
(Id
));
6094 if Flag128
(BT
) then
6095 if Flag129
(BT
) then
6096 return Calign_Storage_Unit
;
6098 return Calign_Component_Size_4
;
6102 if Flag129
(BT
) then
6103 return Calign_Component_Size
;
6105 return Calign_Default
;
6108 end Component_Alignment
;
6110 ----------------------
6111 -- Declaration_Node --
6112 ----------------------
6114 function Declaration_Node
(Id
: E
) return N
is
6118 if Ekind
(Id
) = E_Incomplete_Type
6119 and then Present
(Full_View
(Id
))
6121 P
:= Parent
(Full_View
(Id
));
6127 if Nkind
(P
) /= N_Selected_Component
6128 and then Nkind
(P
) /= N_Expanded_Name
6130 not (Nkind
(P
) = N_Defining_Program_Unit_Name
6131 and then Is_Child_Unit
(Id
))
6138 end Declaration_Node
;
6140 ---------------------
6141 -- Designated_Type --
6142 ---------------------
6144 function Designated_Type
(Id
: E
) return E
is
6148 Desig_Type
:= Directly_Designated_Type
(Id
);
6150 if Ekind
(Desig_Type
) = E_Incomplete_Type
6151 and then Present
(Full_View
(Desig_Type
))
6153 return Full_View
(Desig_Type
);
6155 elsif Is_Class_Wide_Type
(Desig_Type
)
6156 and then Ekind
(Etype
(Desig_Type
)) = E_Incomplete_Type
6157 and then Present
(Full_View
(Etype
(Desig_Type
)))
6158 and then Present
(Class_Wide_Type
(Full_View
(Etype
(Desig_Type
))))
6160 return Class_Wide_Type
(Full_View
(Etype
(Desig_Type
)));
6165 end Designated_Type
;
6167 ----------------------
6168 -- Entry_Index_Type --
6169 ----------------------
6171 function Entry_Index_Type
(Id
: E
) return N
is
6173 pragma Assert
(Ekind
(Id
) = E_Entry_Family
);
6174 return Etype
(Discrete_Subtype_Definition
(Parent
(Id
)));
6175 end Entry_Index_Type
;
6177 ---------------------
6178 -- First_Component --
6179 ---------------------
6181 function First_Component
(Id
: E
) return E
is
6186 (Is_Record_Type
(Id
) or else Is_Incomplete_Or_Private_Type
(Id
));
6188 Comp_Id
:= First_Entity
(Id
);
6189 while Present
(Comp_Id
) loop
6190 exit when Ekind
(Comp_Id
) = E_Component
;
6191 Comp_Id
:= Next_Entity
(Comp_Id
);
6195 end First_Component
;
6197 -------------------------------------
6198 -- First_Component_Or_Discriminant --
6199 -------------------------------------
6201 function First_Component_Or_Discriminant
(Id
: E
) return E
is
6206 (Is_Record_Type
(Id
)
6207 or else Is_Incomplete_Or_Private_Type
(Id
)
6208 or else Has_Discriminants
(Id
));
6210 Comp_Id
:= First_Entity
(Id
);
6211 while Present
(Comp_Id
) loop
6212 exit when Ekind_In
(Comp_Id
, E_Component
, E_Discriminant
);
6213 Comp_Id
:= Next_Entity
(Comp_Id
);
6217 end First_Component_Or_Discriminant
;
6223 function First_Formal
(Id
: E
) return E
is
6228 (Is_Overloadable
(Id
)
6229 or else Ekind_In
(Id
, E_Entry_Family
,
6231 E_Subprogram_Type
));
6233 if Ekind
(Id
) = E_Enumeration_Literal
then
6237 Formal
:= First_Entity
(Id
);
6239 if Present
(Formal
) and then Is_Formal
(Formal
) then
6247 ------------------------------
6248 -- First_Formal_With_Extras --
6249 ------------------------------
6251 function First_Formal_With_Extras
(Id
: E
) return E
is
6256 (Is_Overloadable
(Id
)
6257 or else Ekind_In
(Id
, E_Entry_Family
,
6259 E_Subprogram_Type
));
6261 if Ekind
(Id
) = E_Enumeration_Literal
then
6265 Formal
:= First_Entity
(Id
);
6267 if Present
(Formal
) and then Is_Formal
(Formal
) then
6270 return Extra_Formals
(Id
); -- Empty if no extra formals
6273 end First_Formal_With_Extras
;
6275 -------------------------------------
6276 -- Get_Attribute_Definition_Clause --
6277 -------------------------------------
6279 function Get_Attribute_Definition_Clause
6281 Id
: Attribute_Id
) return Node_Id
6286 N
:= First_Rep_Item
(E
);
6287 while Present
(N
) loop
6288 if Nkind
(N
) = N_Attribute_Definition_Clause
6289 and then Get_Attribute_Id
(Chars
(N
)) = Id
6298 end Get_Attribute_Definition_Clause
;
6304 function Get_Full_View
(T
: Entity_Id
) return Entity_Id
is
6306 if Ekind
(T
) = E_Incomplete_Type
and then Present
(Full_View
(T
)) then
6307 return Full_View
(T
);
6309 elsif Is_Class_Wide_Type
(T
)
6310 and then Ekind
(Root_Type
(T
)) = E_Incomplete_Type
6311 and then Present
(Full_View
(Root_Type
(T
)))
6313 return Class_Wide_Type
(Full_View
(Root_Type
(T
)));
6324 function Get_Pragma
(E
: Entity_Id
; Id
: Pragma_Id
) return Node_Id
is
6325 Is_CDG
: constant Boolean :=
6326 Id
= Pragma_Abstract_State
or else
6327 Id
= Pragma_Depends
or else
6328 Id
= Pragma_Global
or else
6329 Id
= Pragma_Initial_Condition
or else
6330 Id
= Pragma_Initializes
or else
6331 Id
= Pragma_Refined_Depends
or else
6332 Id
= Pragma_Refined_Global
or else
6333 Id
= Pragma_Refined_State
;
6334 Is_CTC
: constant Boolean :=
6335 Id
= Pragma_Contract_Cases
or else
6336 Id
= Pragma_Test_Case
;
6337 Is_PPC
: constant Boolean :=
6338 Id
= Pragma_Precondition
or else
6339 Id
= Pragma_Postcondition
;
6341 In_Contract
: constant Boolean := Is_CDG
or Is_CTC
or Is_PPC
;
6347 -- Handle pragmas that appear in N_Contract nodes. Those have to be
6348 -- extracted from their specialized list.
6351 Items
:= Contract
(E
);
6357 Item
:= Classifications
(Items
);
6360 Item
:= Contract_Test_Cases
(Items
);
6363 Item
:= Pre_Post_Conditions
(Items
);
6369 Item
:= First_Rep_Item
(E
);
6372 while Present
(Item
) loop
6373 if Nkind
(Item
) = N_Pragma
6374 and then Get_Pragma_Id
(Pragma_Name
(Item
)) = Id
6378 -- All nodes in N_Contract are chained using Next_Pragma
6380 elsif In_Contract
then
6381 Item
:= Next_Pragma
(Item
);
6386 Next_Rep_Item
(Item
);
6393 --------------------------------------
6394 -- Get_Record_Representation_Clause --
6395 --------------------------------------
6397 function Get_Record_Representation_Clause
(E
: Entity_Id
) return Node_Id
is
6401 N
:= First_Rep_Item
(E
);
6402 while Present
(N
) loop
6403 if Nkind
(N
) = N_Record_Representation_Clause
then
6411 end Get_Record_Representation_Clause
;
6413 ------------------------
6414 -- Has_Attach_Handler --
6415 ------------------------
6417 function Has_Attach_Handler
(Id
: E
) return B
is
6421 pragma Assert
(Is_Protected_Type
(Id
));
6423 Ritem
:= First_Rep_Item
(Id
);
6424 while Present
(Ritem
) loop
6425 if Nkind
(Ritem
) = N_Pragma
6426 and then Pragma_Name
(Ritem
) = Name_Attach_Handler
6430 Next_Rep_Item
(Ritem
);
6435 end Has_Attach_Handler
;
6441 function Has_Entries
(Id
: E
) return B
is
6445 pragma Assert
(Is_Concurrent_Type
(Id
));
6447 Ent
:= First_Entity
(Id
);
6448 while Present
(Ent
) loop
6449 if Is_Entry
(Ent
) then
6453 Ent
:= Next_Entity
(Ent
);
6459 ----------------------------
6460 -- Has_Foreign_Convention --
6461 ----------------------------
6463 function Has_Foreign_Convention
(Id
: E
) return B
is
6465 -- While regular Intrinsics such as the Standard operators fit in the
6466 -- "Ada" convention, those with an Interface_Name materialize GCC
6467 -- builtin imports for which Ada special treatments shouldn't apply.
6469 return Convention
(Id
) in Foreign_Convention
6470 or else (Convention
(Id
) = Convention_Intrinsic
6471 and then Present
(Interface_Name
(Id
)));
6472 end Has_Foreign_Convention
;
6474 ---------------------------
6475 -- Has_Interrupt_Handler --
6476 ---------------------------
6478 function Has_Interrupt_Handler
(Id
: E
) return B
is
6482 pragma Assert
(Is_Protected_Type
(Id
));
6484 Ritem
:= First_Rep_Item
(Id
);
6485 while Present
(Ritem
) loop
6486 if Nkind
(Ritem
) = N_Pragma
6487 and then Pragma_Name
(Ritem
) = Name_Interrupt_Handler
6491 Next_Rep_Item
(Ritem
);
6496 end Has_Interrupt_Handler
;
6498 -----------------------------
6499 -- Has_Non_Null_Refinement --
6500 -----------------------------
6502 function Has_Non_Null_Refinement
(Id
: E
) return B
is
6504 -- "Refinement" is a concept applicable only to abstract states
6506 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
6508 if Has_Visible_Refinement
(Id
) then
6509 pragma Assert
(Present
(Refinement_Constituents
(Id
)));
6511 -- For a refinement to be non-null, the first constituent must be
6512 -- anything other than null.
6515 Nkind
(Node
(First_Elmt
(Refinement_Constituents
(Id
)))) /= N_Null
;
6519 end Has_Non_Null_Refinement
;
6521 -----------------------------
6522 -- Has_Null_Abstract_State --
6523 -----------------------------
6525 function Has_Null_Abstract_State
(Id
: E
) return B
is
6527 pragma Assert
(Ekind_In
(Id
, E_Generic_Package
, E_Package
));
6530 Present
(Abstract_States
(Id
))
6531 and then Is_Null_State
(Node
(First_Elmt
(Abstract_States
(Id
))));
6532 end Has_Null_Abstract_State
;
6534 -------------------------
6535 -- Has_Null_Refinement --
6536 -------------------------
6538 function Has_Null_Refinement
(Id
: E
) return B
is
6540 -- "Refinement" is a concept applicable only to abstract states
6542 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
6544 if Has_Visible_Refinement
(Id
) then
6545 pragma Assert
(Present
(Refinement_Constituents
(Id
)));
6547 -- For a refinement to be null, the state's sole constituent must be
6551 Nkind
(Node
(First_Elmt
(Refinement_Constituents
(Id
)))) = N_Null
;
6555 end Has_Null_Refinement
;
6557 --------------------
6558 -- Has_Unmodified --
6559 --------------------
6561 function Has_Unmodified
(E
: Entity_Id
) return Boolean is
6563 if Has_Pragma_Unmodified
(E
) then
6565 elsif Warnings_Off
(E
) then
6566 Set_Warnings_Off_Used_Unmodified
(E
);
6573 ---------------------
6574 -- Has_Unreferenced --
6575 ---------------------
6577 function Has_Unreferenced
(E
: Entity_Id
) return Boolean is
6579 if Has_Pragma_Unreferenced
(E
) then
6581 elsif Warnings_Off
(E
) then
6582 Set_Warnings_Off_Used_Unreferenced
(E
);
6587 end Has_Unreferenced
;
6589 ----------------------
6590 -- Has_Warnings_Off --
6591 ----------------------
6593 function Has_Warnings_Off
(E
: Entity_Id
) return Boolean is
6595 if Warnings_Off
(E
) then
6596 Set_Warnings_Off_Used
(E
);
6601 end Has_Warnings_Off
;
6603 ------------------------------
6604 -- Implementation_Base_Type --
6605 ------------------------------
6607 function Implementation_Base_Type
(Id
: E
) return E
is
6612 Bastyp
:= Base_Type
(Id
);
6614 if Is_Incomplete_Or_Private_Type
(Bastyp
) then
6615 Imptyp
:= Underlying_Type
(Bastyp
);
6617 -- If we have an implementation type, then just return it,
6618 -- otherwise we return the Base_Type anyway. This can only
6619 -- happen in error situations and should avoid some error bombs.
6621 if Present
(Imptyp
) then
6622 return Base_Type
(Imptyp
);
6630 end Implementation_Base_Type
;
6632 -------------------------
6633 -- Invariant_Procedure --
6634 -------------------------
6636 function Invariant_Procedure
(Id
: E
) return E
is
6640 pragma Assert
(Is_Type
(Id
) and then Has_Invariants
(Id
));
6642 if No
(Subprograms_For_Type
(Id
)) then
6646 S
:= Subprograms_For_Type
(Id
);
6647 while Present
(S
) loop
6648 if Is_Invariant_Procedure
(S
) then
6651 S
:= Subprograms_For_Type
(S
);
6657 end Invariant_Procedure
;
6663 -- Global flag table allowing rapid computation of this function
6665 Entity_Is_Base_Type
: constant array (Entity_Kind
) of Boolean :=
6666 (E_Enumeration_Subtype |
6668 E_Signed_Integer_Subtype |
6669 E_Modular_Integer_Subtype |
6670 E_Floating_Point_Subtype |
6671 E_Ordinary_Fixed_Point_Subtype |
6672 E_Decimal_Fixed_Point_Subtype |
6677 E_Record_Subtype_With_Private |
6678 E_Limited_Private_Subtype |
6680 E_Protected_Subtype |
6682 E_String_Literal_Subtype |
6683 E_Class_Wide_Subtype
=> False,
6686 function Is_Base_Type
(Id
: E
) return Boolean is
6688 return Entity_Is_Base_Type
(Ekind
(Id
));
6691 ---------------------
6692 -- Is_Boolean_Type --
6693 ---------------------
6695 function Is_Boolean_Type
(Id
: E
) return B
is
6697 return Root_Type
(Id
) = Standard_Boolean
;
6698 end Is_Boolean_Type
;
6700 ------------------------
6701 -- Is_Constant_Object --
6702 ------------------------
6704 function Is_Constant_Object
(Id
: E
) return B
is
6705 K
: constant Entity_Kind
:= Ekind
(Id
);
6708 K
= E_Constant
or else K
= E_In_Parameter
or else K
= E_Loop_Parameter
;
6709 end Is_Constant_Object
;
6711 --------------------
6712 -- Is_Discriminal --
6713 --------------------
6715 function Is_Discriminal
(Id
: E
) return B
is
6717 return (Ekind_In
(Id
, E_Constant
, E_In_Parameter
)
6718 and then Present
(Discriminal_Link
(Id
)));
6721 ----------------------
6722 -- Is_Dynamic_Scope --
6723 ----------------------
6725 function Is_Dynamic_Scope
(Id
: E
) return B
is
6728 Ekind
(Id
) = E_Block
6730 Ekind
(Id
) = E_Function
6732 Ekind
(Id
) = E_Procedure
6734 Ekind
(Id
) = E_Subprogram_Body
6736 Ekind
(Id
) = E_Task_Type
6738 (Ekind
(Id
) = E_Limited_Private_Type
6739 and then Present
(Full_View
(Id
))
6740 and then Ekind
(Full_View
(Id
)) = E_Task_Type
)
6742 Ekind
(Id
) = E_Entry
6744 Ekind
(Id
) = E_Entry_Family
6746 Ekind
(Id
) = E_Return_Statement
;
6747 end Is_Dynamic_Scope
;
6749 --------------------
6750 -- Is_Entity_Name --
6751 --------------------
6753 function Is_Entity_Name
(N
: Node_Id
) return Boolean is
6754 Kind
: constant Node_Kind
:= Nkind
(N
);
6757 -- Identifiers, operator symbols, expanded names are entity names
6759 return Kind
= N_Identifier
6760 or else Kind
= N_Operator_Symbol
6761 or else Kind
= N_Expanded_Name
6763 -- Attribute references are entity names if they refer to an entity.
6764 -- Note that we don't do this by testing for the presence of the
6765 -- Entity field in the N_Attribute_Reference node, since it may not
6766 -- have been set yet.
6768 or else (Kind
= N_Attribute_Reference
6769 and then Is_Entity_Attribute_Name
(Attribute_Name
(N
)));
6772 -----------------------
6773 -- Is_External_State --
6774 -----------------------
6776 function Is_External_State
(Id
: E
) return B
is
6779 Ekind
(Id
) = E_Abstract_State
and then Has_Option
(Id
, Name_External
);
6780 end Is_External_State
;
6786 function Is_Finalizer
(Id
: E
) return B
is
6788 return Ekind
(Id
) = E_Procedure
and then Chars
(Id
) = Name_uFinalizer
;
6791 ---------------------
6792 -- Is_Ghost_Entity --
6793 ---------------------
6795 function Is_Ghost_Entity
(Id
: E
) return B
is
6797 if Present
(Id
) and then Ekind
(Id
) = E_Variable
then
6798 return Convention
(Id
) = Convention_Ghost
;
6800 return Is_Ghost_Subprogram
(Id
);
6802 end Is_Ghost_Entity
;
6804 -------------------------
6805 -- Is_Ghost_Subprogram --
6806 -------------------------
6808 function Is_Ghost_Subprogram
(Id
: E
) return B
is
6810 if Present
(Id
) and then Ekind_In
(Id
, E_Function
, E_Procedure
) then
6811 return Convention
(Id
) = Convention_Ghost
;
6815 end Is_Ghost_Subprogram
;
6817 -------------------------
6818 -- Is_Input_Only_State --
6819 -------------------------
6821 function Is_Input_Only_State
(Id
: E
) return B
is
6824 Ekind
(Id
) = E_Abstract_State
6825 and then Has_Option
(Id
, Name_Input_Only
);
6826 end Is_Input_Only_State
;
6828 ---------------------------
6829 -- Is_Non_Volatile_State --
6830 ---------------------------
6832 function Is_Non_Volatile_State
(Id
: E
) return B
is
6835 Ekind
(Id
) = E_Abstract_State
6836 and then Has_Option
(Id
, Name_Non_Volatile
);
6837 end Is_Non_Volatile_State
;
6843 function Is_Null_State
(Id
: E
) return B
is
6846 Ekind
(Id
) = E_Abstract_State
and then Nkind
(Parent
(Id
)) = N_Null
;
6849 ---------------------
6850 -- Is_Output_State --
6851 ---------------------
6853 function Is_Output_Only_State
(Id
: E
) return B
is
6856 Ekind
(Id
) = E_Abstract_State
6857 and then Has_Option
(Id
, Name_Output_Only
);
6858 end Is_Output_Only_State
;
6860 -----------------------------------
6861 -- Is_Package_Or_Generic_Package --
6862 -----------------------------------
6864 function Is_Package_Or_Generic_Package
(Id
: E
) return B
is
6866 return Ekind_In
(Id
, E_Generic_Package
, E_Package
);
6867 end Is_Package_Or_Generic_Package
;
6873 function Is_Prival
(Id
: E
) return B
is
6875 return (Ekind_In
(Id
, E_Constant
, E_Variable
)
6876 and then Present
(Prival_Link
(Id
)));
6879 ----------------------------
6880 -- Is_Protected_Component --
6881 ----------------------------
6883 function Is_Protected_Component
(Id
: E
) return B
is
6885 return Ekind
(Id
) = E_Component
and then Is_Protected_Type
(Scope
(Id
));
6886 end Is_Protected_Component
;
6888 ----------------------------
6889 -- Is_Protected_Interface --
6890 ----------------------------
6892 function Is_Protected_Interface
(Id
: E
) return B
is
6893 Typ
: constant Entity_Id
:= Base_Type
(Id
);
6895 if not Is_Interface
(Typ
) then
6897 elsif Is_Class_Wide_Type
(Typ
) then
6898 return Is_Protected_Interface
(Etype
(Typ
));
6900 return Protected_Present
(Type_Definition
(Parent
(Typ
)));
6902 end Is_Protected_Interface
;
6904 ------------------------------
6905 -- Is_Protected_Record_Type --
6906 ------------------------------
6908 function Is_Protected_Record_Type
(Id
: E
) return B
is
6911 Is_Concurrent_Record_Type
(Id
)
6912 and then Is_Protected_Type
(Corresponding_Concurrent_Type
(Id
));
6913 end Is_Protected_Record_Type
;
6915 --------------------------------
6916 -- Is_Standard_Character_Type --
6917 --------------------------------
6919 function Is_Standard_Character_Type
(Id
: E
) return B
is
6921 if Is_Type
(Id
) then
6923 R
: constant Entity_Id
:= Root_Type
(Id
);
6926 R
= Standard_Character
6928 R
= Standard_Wide_Character
6930 R
= Standard_Wide_Wide_Character
;
6936 end Is_Standard_Character_Type
;
6938 --------------------
6939 -- Is_String_Type --
6940 --------------------
6942 function Is_String_Type
(Id
: E
) return B
is
6944 return Ekind
(Id
) in String_Kind
6945 or else (Is_Array_Type
(Id
)
6946 and then Id
/= Any_Composite
6947 and then Number_Dimensions
(Id
) = 1
6948 and then Is_Character_Type
(Component_Type
(Id
)));
6951 -------------------------------
6952 -- Is_Synchronized_Interface --
6953 -------------------------------
6955 function Is_Synchronized_Interface
(Id
: E
) return B
is
6956 Typ
: constant Entity_Id
:= Base_Type
(Id
);
6959 if not Is_Interface
(Typ
) then
6962 elsif Is_Class_Wide_Type
(Typ
) then
6963 return Is_Synchronized_Interface
(Etype
(Typ
));
6966 return Protected_Present
(Type_Definition
(Parent
(Typ
)))
6967 or else Synchronized_Present
(Type_Definition
(Parent
(Typ
)))
6968 or else Task_Present
(Type_Definition
(Parent
(Typ
)));
6970 end Is_Synchronized_Interface
;
6972 -----------------------
6973 -- Is_Task_Interface --
6974 -----------------------
6976 function Is_Task_Interface
(Id
: E
) return B
is
6977 Typ
: constant Entity_Id
:= Base_Type
(Id
);
6979 if not Is_Interface
(Typ
) then
6981 elsif Is_Class_Wide_Type
(Typ
) then
6982 return Is_Task_Interface
(Etype
(Typ
));
6984 return Task_Present
(Type_Definition
(Parent
(Typ
)));
6986 end Is_Task_Interface
;
6988 -------------------------
6989 -- Is_Task_Record_Type --
6990 -------------------------
6992 function Is_Task_Record_Type
(Id
: E
) return B
is
6995 Is_Concurrent_Record_Type
(Id
)
6996 and then Is_Task_Type
(Corresponding_Concurrent_Type
(Id
));
6997 end Is_Task_Record_Type
;
6999 ------------------------
7000 -- Is_Wrapper_Package --
7001 ------------------------
7003 function Is_Wrapper_Package
(Id
: E
) return B
is
7005 return (Ekind
(Id
) = E_Package
and then Present
(Related_Instance
(Id
)));
7006 end Is_Wrapper_Package
;
7012 function Last_Formal
(Id
: E
) return E
is
7017 (Is_Overloadable
(Id
)
7018 or else Ekind_In
(Id
, E_Entry_Family
,
7020 E_Subprogram_Type
));
7022 if Ekind
(Id
) = E_Enumeration_Literal
then
7026 Formal
:= First_Formal
(Id
);
7028 if Present
(Formal
) then
7029 while Present
(Next_Formal
(Formal
)) loop
7030 Formal
:= Next_Formal
(Formal
);
7038 function Model_Emin_Value
(Id
: E
) return Uint
is
7040 return Machine_Emin_Value
(Id
);
7041 end Model_Emin_Value
;
7043 -------------------------
7044 -- Model_Epsilon_Value --
7045 -------------------------
7047 function Model_Epsilon_Value
(Id
: E
) return Ureal
is
7048 Radix
: constant Ureal
:= UR_From_Uint
(Machine_Radix_Value
(Id
));
7050 return Radix
** (1 - Model_Mantissa_Value
(Id
));
7051 end Model_Epsilon_Value
;
7053 --------------------------
7054 -- Model_Mantissa_Value --
7055 --------------------------
7057 function Model_Mantissa_Value
(Id
: E
) return Uint
is
7059 return Machine_Mantissa_Value
(Id
);
7060 end Model_Mantissa_Value
;
7062 -----------------------
7063 -- Model_Small_Value --
7064 -----------------------
7066 function Model_Small_Value
(Id
: E
) return Ureal
is
7067 Radix
: constant Ureal
:= UR_From_Uint
(Machine_Radix_Value
(Id
));
7069 return Radix
** (Model_Emin_Value
(Id
) - 1);
7070 end Model_Small_Value
;
7072 ------------------------
7073 -- Machine_Emax_Value --
7074 ------------------------
7076 function Machine_Emax_Value
(Id
: E
) return Uint
is
7077 Digs
: constant Pos
:= UI_To_Int
(Digits_Value
(Base_Type
(Id
)));
7080 case Float_Rep
(Id
) is
7083 when 1 .. 6 => return Uint_128
;
7084 when 7 .. 15 => return 2**10;
7085 when 16 .. 33 => return 2**14;
7086 when others => return No_Uint
;
7091 when 1 .. 9 => return 2**7 - 1;
7092 when 10 .. 15 => return 2**10 - 1;
7093 when others => return No_Uint
;
7097 return Uint_2
** Uint_7
- Uint_1
;
7099 end Machine_Emax_Value
;
7101 ------------------------
7102 -- Machine_Emin_Value --
7103 ------------------------
7105 function Machine_Emin_Value
(Id
: E
) return Uint
is
7107 case Float_Rep
(Id
) is
7108 when IEEE_Binary
=> return Uint_3
- Machine_Emax_Value
(Id
);
7109 when VAX_Native
=> return -Machine_Emax_Value
(Id
);
7110 when AAMP
=> return -Machine_Emax_Value
(Id
);
7112 end Machine_Emin_Value
;
7114 ----------------------------
7115 -- Machine_Mantissa_Value --
7116 ----------------------------
7118 function Machine_Mantissa_Value
(Id
: E
) return Uint
is
7119 Digs
: constant Pos
:= UI_To_Int
(Digits_Value
(Base_Type
(Id
)));
7122 case Float_Rep
(Id
) is
7125 when 1 .. 6 => return Uint_24
;
7126 when 7 .. 15 => return UI_From_Int
(53);
7127 when 16 .. 18 => return Uint_64
;
7128 when 19 .. 33 => return UI_From_Int
(113);
7129 when others => return No_Uint
;
7134 when 1 .. 6 => return Uint_24
;
7135 when 7 .. 9 => return UI_From_Int
(56);
7136 when 10 .. 15 => return UI_From_Int
(53);
7137 when others => return No_Uint
;
7142 when 1 .. 6 => return Uint_24
;
7143 when 7 .. 9 => return UI_From_Int
(40);
7144 when others => return No_Uint
;
7147 end Machine_Mantissa_Value
;
7149 -------------------------
7150 -- Machine_Radix_Value --
7151 -------------------------
7153 function Machine_Radix_Value
(Id
: E
) return U
is
7155 case Float_Rep
(Id
) is
7156 when IEEE_Binary | VAX_Native | AAMP
=>
7159 end Machine_Radix_Value
;
7161 --------------------
7162 -- Next_Component --
7163 --------------------
7165 function Next_Component
(Id
: E
) return E
is
7169 Comp_Id
:= Next_Entity
(Id
);
7170 while Present
(Comp_Id
) loop
7171 exit when Ekind
(Comp_Id
) = E_Component
;
7172 Comp_Id
:= Next_Entity
(Comp_Id
);
7178 ------------------------------------
7179 -- Next_Component_Or_Discriminant --
7180 ------------------------------------
7182 function Next_Component_Or_Discriminant
(Id
: E
) return E
is
7186 Comp_Id
:= Next_Entity
(Id
);
7187 while Present
(Comp_Id
) loop
7188 exit when Ekind_In
(Comp_Id
, E_Component
, E_Discriminant
);
7189 Comp_Id
:= Next_Entity
(Comp_Id
);
7193 end Next_Component_Or_Discriminant
;
7195 -----------------------
7196 -- Next_Discriminant --
7197 -----------------------
7199 -- This function actually implements both Next_Discriminant and
7200 -- Next_Stored_Discriminant by making sure that the Discriminant
7201 -- returned is of the same variety as Id.
7203 function Next_Discriminant
(Id
: E
) return E
is
7205 -- Derived Tagged types with private extensions look like this...
7207 -- E_Discriminant d1
7208 -- E_Discriminant d2
7210 -- E_Discriminant d1
7211 -- E_Discriminant d2
7214 -- so it is critical not to go past the leading discriminants
7219 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
7222 D
:= Next_Entity
(D
);
7224 or else (Ekind
(D
) /= E_Discriminant
7225 and then not Is_Itype
(D
))
7230 exit when Ekind
(D
) = E_Discriminant
7231 and then (Is_Completely_Hidden
(D
) = Is_Completely_Hidden
(Id
));
7235 end Next_Discriminant
;
7241 function Next_Formal
(Id
: E
) return E
is
7245 -- Follow the chain of declared entities as long as the kind of the
7246 -- entity corresponds to a formal parameter. Skip internal entities
7247 -- that may have been created for implicit subtypes, in the process
7248 -- of analyzing default expressions.
7252 P
:= Next_Entity
(P
);
7254 if No
(P
) or else Is_Formal
(P
) then
7256 elsif not Is_Internal
(P
) then
7262 -----------------------------
7263 -- Next_Formal_With_Extras --
7264 -----------------------------
7266 function Next_Formal_With_Extras
(Id
: E
) return E
is
7268 if Present
(Extra_Formal
(Id
)) then
7269 return Extra_Formal
(Id
);
7271 return Next_Formal
(Id
);
7273 end Next_Formal_With_Extras
;
7279 function Next_Index
(Id
: Node_Id
) return Node_Id
is
7288 function Next_Literal
(Id
: E
) return E
is
7290 pragma Assert
(Nkind
(Id
) in N_Entity
);
7294 ------------------------------
7295 -- Next_Stored_Discriminant --
7296 ------------------------------
7298 function Next_Stored_Discriminant
(Id
: E
) return E
is
7300 -- See comment in Next_Discriminant
7302 return Next_Discriminant
(Id
);
7303 end Next_Stored_Discriminant
;
7305 -----------------------
7306 -- Number_Dimensions --
7307 -----------------------
7309 function Number_Dimensions
(Id
: E
) return Pos
is
7314 if Ekind
(Id
) in String_Kind
then
7319 T
:= First_Index
(Id
);
7320 while Present
(T
) loop
7327 end Number_Dimensions
;
7329 --------------------
7330 -- Number_Entries --
7331 --------------------
7333 function Number_Entries
(Id
: E
) return Nat
is
7338 pragma Assert
(Is_Concurrent_Type
(Id
));
7341 Ent
:= First_Entity
(Id
);
7342 while Present
(Ent
) loop
7343 if Is_Entry
(Ent
) then
7347 Ent
:= Next_Entity
(Ent
);
7353 --------------------
7354 -- Number_Formals --
7355 --------------------
7357 function Number_Formals
(Id
: E
) return Pos
is
7363 Formal
:= First_Formal
(Id
);
7364 while Present
(Formal
) loop
7366 Formal
:= Next_Formal
(Formal
);
7372 --------------------
7373 -- Parameter_Mode --
7374 --------------------
7376 function Parameter_Mode
(Id
: E
) return Formal_Kind
is
7381 ------------------------
7382 -- Predicate_Function --
7383 ------------------------
7385 function Predicate_Function
(Id
: E
) return E
is
7390 pragma Assert
(Is_Type
(Id
));
7392 -- If type is private and has a completion, predicate may be defined
7393 -- on the full view.
7395 if Is_Private_Type
(Id
) and then Present
(Full_View
(Id
)) then
7396 T
:= Full_View
(Id
);
7401 if No
(Subprograms_For_Type
(T
)) then
7405 S
:= Subprograms_For_Type
(T
);
7406 while Present
(S
) loop
7407 if Is_Predicate_Function
(S
) then
7410 S
:= Subprograms_For_Type
(S
);
7416 end Predicate_Function
;
7418 --------------------------
7419 -- Predicate_Function_M --
7420 --------------------------
7422 function Predicate_Function_M
(Id
: E
) return E
is
7427 pragma Assert
(Is_Type
(Id
));
7429 -- If type is private and has a completion, predicate may be defined
7430 -- on the full view.
7432 if Is_Private_Type
(Id
) and then Present
(Full_View
(Id
)) then
7433 T
:= Full_View
(Id
);
7438 if No
(Subprograms_For_Type
(T
)) then
7442 S
:= Subprograms_For_Type
(T
);
7443 while Present
(S
) loop
7444 if Is_Predicate_Function_M
(S
) then
7447 S
:= Subprograms_For_Type
(S
);
7453 end Predicate_Function_M
;
7455 -------------------------
7456 -- Present_In_Rep_Item --
7457 -------------------------
7459 function Present_In_Rep_Item
(E
: Entity_Id
; N
: Node_Id
) return Boolean is
7463 Ritem
:= First_Rep_Item
(E
);
7465 while Present
(Ritem
) loop
7470 Next_Rep_Item
(Ritem
);
7474 end Present_In_Rep_Item
;
7476 --------------------------
7477 -- Primitive_Operations --
7478 --------------------------
7480 function Primitive_Operations
(Id
: E
) return L
is
7482 if Is_Concurrent_Type
(Id
) then
7483 if Present
(Corresponding_Record_Type
(Id
)) then
7484 return Direct_Primitive_Operations
7485 (Corresponding_Record_Type
(Id
));
7487 -- If expansion is disabled the corresponding record type is absent,
7488 -- but if the type has ancestors it may have primitive operations.
7490 elsif Is_Tagged_Type
(Id
) then
7491 return Direct_Primitive_Operations
(Id
);
7497 return Direct_Primitive_Operations
(Id
);
7499 end Primitive_Operations
;
7501 ---------------------
7502 -- Record_Rep_Item --
7503 ---------------------
7505 procedure Record_Rep_Item
(E
: Entity_Id
; N
: Node_Id
) is
7507 Set_Next_Rep_Item
(N
, First_Rep_Item
(E
));
7508 Set_First_Rep_Item
(E
, N
);
7509 end Record_Rep_Item
;
7515 function Root_Type
(Id
: E
) return E
is
7519 pragma Assert
(Nkind
(Id
) in N_Entity
);
7521 T
:= Base_Type
(Id
);
7523 if Ekind
(T
) = E_Class_Wide_Type
then
7535 -- Following test catches some error cases resulting from
7538 elsif No
(Etyp
) then
7539 Check_Error_Detected
;
7542 elsif Is_Private_Type
(T
) and then Etyp
= Full_View
(T
) then
7545 elsif Is_Private_Type
(Etyp
) and then Full_View
(Etyp
) = T
then
7551 -- Return if there is a circularity in the inheritance chain. This
7552 -- happens in some error situations and we do not want to get
7553 -- stuck in this loop.
7555 if T
= Base_Type
(Id
) then
7562 ---------------------
7563 -- Safe_Emax_Value --
7564 ---------------------
7566 function Safe_Emax_Value
(Id
: E
) return Uint
is
7568 return Machine_Emax_Value
(Id
);
7569 end Safe_Emax_Value
;
7571 ----------------------
7572 -- Safe_First_Value --
7573 ----------------------
7575 function Safe_First_Value
(Id
: E
) return Ureal
is
7577 return -Safe_Last_Value
(Id
);
7578 end Safe_First_Value
;
7580 ---------------------
7581 -- Safe_Last_Value --
7582 ---------------------
7584 function Safe_Last_Value
(Id
: E
) return Ureal
is
7585 Radix
: constant Uint
:= Machine_Radix_Value
(Id
);
7586 Mantissa
: constant Uint
:= Machine_Mantissa_Value
(Id
);
7587 Emax
: constant Uint
:= Safe_Emax_Value
(Id
);
7588 Significand
: constant Uint
:= Radix
** Mantissa
- 1;
7589 Exponent
: constant Uint
:= Emax
- Mantissa
;
7595 (Num
=> Significand
* 2 ** (Exponent
mod 4),
7596 Den
=> -Exponent
/ 4,
7602 (Num
=> Significand
,
7606 end Safe_Last_Value
;
7612 function Scope_Depth
(Id
: E
) return Uint
is
7617 while Is_Record_Type
(Scop
) loop
7618 Scop
:= Scope
(Scop
);
7621 return Scope_Depth_Value
(Scop
);
7624 ---------------------
7625 -- Scope_Depth_Set --
7626 ---------------------
7628 function Scope_Depth_Set
(Id
: E
) return B
is
7630 return not Is_Record_Type
(Id
)
7631 and then Field22
(Id
) /= Union_Id
(Empty
);
7632 end Scope_Depth_Set
;
7634 -----------------------------
7635 -- Set_Component_Alignment --
7636 -----------------------------
7638 -- Component Alignment is encoded using two flags, Flag128/129 as
7639 -- follows. Note that both flags False = Align_Default, so that the
7640 -- default initialization of flags to False initializes component
7641 -- alignment to the default value as required.
7643 -- Flag128 Flag129 Value
7644 -- ------- ------- -----
7645 -- False False Calign_Default
7646 -- False True Calign_Component_Size
7647 -- True False Calign_Component_Size_4
7648 -- True True Calign_Storage_Unit
7650 procedure Set_Component_Alignment
(Id
: E
; V
: C
) is
7652 pragma Assert
((Is_Array_Type
(Id
) or else Is_Record_Type
(Id
))
7653 and then Is_Base_Type
(Id
));
7656 when Calign_Default
=>
7657 Set_Flag128
(Id
, False);
7658 Set_Flag129
(Id
, False);
7660 when Calign_Component_Size
=>
7661 Set_Flag128
(Id
, False);
7662 Set_Flag129
(Id
, True);
7664 when Calign_Component_Size_4
=>
7665 Set_Flag128
(Id
, True);
7666 Set_Flag129
(Id
, False);
7668 when Calign_Storage_Unit
=>
7669 Set_Flag128
(Id
, True);
7670 Set_Flag129
(Id
, True);
7672 end Set_Component_Alignment
;
7674 -----------------------------
7675 -- Set_Invariant_Procedure --
7676 -----------------------------
7678 procedure Set_Invariant_Procedure
(Id
: E
; V
: E
) is
7682 pragma Assert
(Is_Type
(Id
) and then Has_Invariants
(Id
));
7684 S
:= Subprograms_For_Type
(Id
);
7685 Set_Subprograms_For_Type
(Id
, V
);
7686 Set_Subprograms_For_Type
(V
, S
);
7688 -- Check for duplicate entry
7690 while Present
(S
) loop
7691 if Is_Invariant_Procedure
(S
) then
7692 raise Program_Error
;
7694 S
:= Subprograms_For_Type
(S
);
7697 end Set_Invariant_Procedure
;
7699 ----------------------------
7700 -- Set_Predicate_Function --
7701 ----------------------------
7703 procedure Set_Predicate_Function
(Id
: E
; V
: E
) is
7707 pragma Assert
(Is_Type
(Id
) and then Has_Predicates
(Id
));
7709 S
:= Subprograms_For_Type
(Id
);
7710 Set_Subprograms_For_Type
(Id
, V
);
7711 Set_Subprograms_For_Type
(V
, S
);
7713 while Present
(S
) loop
7714 if Is_Predicate_Function
(S
) then
7715 raise Program_Error
;
7717 S
:= Subprograms_For_Type
(S
);
7720 end Set_Predicate_Function
;
7722 ------------------------------
7723 -- Set_Predicate_Function_M --
7724 ------------------------------
7726 procedure Set_Predicate_Function_M
(Id
: E
; V
: E
) is
7730 pragma Assert
(Is_Type
(Id
) and then Has_Predicates
(Id
));
7732 S
:= Subprograms_For_Type
(Id
);
7733 Set_Subprograms_For_Type
(Id
, V
);
7734 Set_Subprograms_For_Type
(V
, S
);
7736 -- Check for duplicates
7738 while Present
(S
) loop
7739 if Is_Predicate_Function_M
(S
) then
7740 raise Program_Error
;
7742 S
:= Subprograms_For_Type
(S
);
7745 end Set_Predicate_Function_M
;
7751 function Size_Clause
(Id
: E
) return N
is
7753 return Get_Attribute_Definition_Clause
(Id
, Attribute_Size
);
7756 ------------------------
7757 -- Stream_Size_Clause --
7758 ------------------------
7760 function Stream_Size_Clause
(Id
: E
) return N
is
7762 return Get_Attribute_Definition_Clause
(Id
, Attribute_Stream_Size
);
7763 end Stream_Size_Clause
;
7769 function Subtype_Kind
(K
: Entity_Kind
) return Entity_Kind
is
7775 Kind
:= E_Access_Subtype
;
7779 Kind
:= E_Array_Subtype
;
7781 when E_Class_Wide_Type |
7782 E_Class_Wide_Subtype
=>
7783 Kind
:= E_Class_Wide_Subtype
;
7785 when E_Decimal_Fixed_Point_Type |
7786 E_Decimal_Fixed_Point_Subtype
=>
7787 Kind
:= E_Decimal_Fixed_Point_Subtype
;
7789 when E_Ordinary_Fixed_Point_Type |
7790 E_Ordinary_Fixed_Point_Subtype
=>
7791 Kind
:= E_Ordinary_Fixed_Point_Subtype
;
7793 when E_Private_Type |
7794 E_Private_Subtype
=>
7795 Kind
:= E_Private_Subtype
;
7797 when E_Limited_Private_Type |
7798 E_Limited_Private_Subtype
=>
7799 Kind
:= E_Limited_Private_Subtype
;
7801 when E_Record_Type_With_Private |
7802 E_Record_Subtype_With_Private
=>
7803 Kind
:= E_Record_Subtype_With_Private
;
7805 when E_Record_Type |
7807 Kind
:= E_Record_Subtype
;
7809 when E_String_Type |
7811 Kind
:= E_String_Subtype
;
7813 when Enumeration_Kind
=>
7814 Kind
:= E_Enumeration_Subtype
;
7817 Kind
:= E_Floating_Point_Subtype
;
7819 when Signed_Integer_Kind
=>
7820 Kind
:= E_Signed_Integer_Subtype
;
7822 when Modular_Integer_Kind
=>
7823 Kind
:= E_Modular_Integer_Subtype
;
7825 when Protected_Kind
=>
7826 Kind
:= E_Protected_Subtype
;
7829 Kind
:= E_Task_Subtype
;
7833 raise Program_Error
;
7839 ---------------------
7840 -- Type_High_Bound --
7841 ---------------------
7843 function Type_High_Bound
(Id
: E
) return Node_Id
is
7844 Rng
: constant Node_Id
:= Scalar_Range
(Id
);
7846 if Nkind
(Rng
) = N_Subtype_Indication
then
7847 return High_Bound
(Range_Expression
(Constraint
(Rng
)));
7849 return High_Bound
(Rng
);
7851 end Type_High_Bound
;
7853 --------------------
7854 -- Type_Low_Bound --
7855 --------------------
7857 function Type_Low_Bound
(Id
: E
) return Node_Id
is
7858 Rng
: constant Node_Id
:= Scalar_Range
(Id
);
7860 if Nkind
(Rng
) = N_Subtype_Indication
then
7861 return Low_Bound
(Range_Expression
(Constraint
(Rng
)));
7863 return Low_Bound
(Rng
);
7867 ---------------------
7868 -- Underlying_Type --
7869 ---------------------
7871 function Underlying_Type
(Id
: E
) return E
is
7873 -- For record_with_private the underlying type is always the direct
7874 -- full view. Never try to take the full view of the parent it
7875 -- doesn't make sense.
7877 if Ekind
(Id
) = E_Record_Type_With_Private
then
7878 return Full_View
(Id
);
7880 elsif Ekind
(Id
) in Incomplete_Or_Private_Kind
then
7882 -- If we have an incomplete or private type with a full view,
7883 -- then we return the Underlying_Type of this full view
7885 if Present
(Full_View
(Id
)) then
7886 if Id
= Full_View
(Id
) then
7888 -- Previous error in declaration
7893 return Underlying_Type
(Full_View
(Id
));
7896 -- If we have an incomplete entity that comes from the limited
7897 -- view then we return the Underlying_Type of its non-limited
7900 elsif From_Limited_With
(Id
)
7901 and then Present
(Non_Limited_View
(Id
))
7903 return Underlying_Type
(Non_Limited_View
(Id
));
7905 -- Otherwise check for the case where we have a derived type or
7906 -- subtype, and if so get the Underlying_Type of the parent type.
7908 elsif Etype
(Id
) /= Id
then
7909 return Underlying_Type
(Etype
(Id
));
7911 -- Otherwise we have an incomplete or private type that has
7912 -- no full view, which means that we have not encountered the
7913 -- completion, so return Empty to indicate the underlying type
7914 -- is not yet known.
7920 -- For non-incomplete, non-private types, return the type itself
7921 -- Also for entities that are not types at all return the entity
7927 end Underlying_Type
;
7933 function Vax_Float
(Id
: E
) return B
is
7935 return Is_Floating_Point_Type
(Id
) and then Float_Rep
(Id
) = VAX_Native
;
7938 ------------------------
7939 -- Write_Entity_Flags --
7940 ------------------------
7942 procedure Write_Entity_Flags
(Id
: Entity_Id
; Prefix
: String) is
7944 procedure W
(Flag_Name
: String; Flag
: Boolean);
7945 -- Write out given flag if it is set
7951 procedure W
(Flag_Name
: String; Flag
: Boolean) is
7955 Write_Str
(Flag_Name
);
7956 Write_Str
(" = True");
7961 -- Start of processing for Write_Entity_Flags
7964 if (Is_Array_Type
(Id
) or else Is_Record_Type
(Id
))
7965 and then Is_Base_Type
(Id
)
7968 Write_Str
("Component_Alignment = ");
7970 case Component_Alignment
(Id
) is
7971 when Calign_Default
=>
7972 Write_Str
("Calign_Default");
7974 when Calign_Component_Size
=>
7975 Write_Str
("Calign_Component_Size");
7977 when Calign_Component_Size_4
=>
7978 Write_Str
("Calign_Component_Size_4");
7980 when Calign_Storage_Unit
=>
7981 Write_Str
("Calign_Storage_Unit");
7987 W
("Address_Taken", Flag104
(Id
));
7988 W
("Body_Needed_For_SAL", Flag40
(Id
));
7989 W
("C_Pass_By_Copy", Flag125
(Id
));
7990 W
("Can_Never_Be_Null", Flag38
(Id
));
7991 W
("Checks_May_Be_Suppressed", Flag31
(Id
));
7992 W
("Debug_Info_Off", Flag166
(Id
));
7993 W
("Default_Expressions_Processed", Flag108
(Id
));
7994 W
("Delay_Cleanups", Flag114
(Id
));
7995 W
("Delay_Subprogram_Descriptors", Flag50
(Id
));
7996 W
("Depends_On_Private", Flag14
(Id
));
7997 W
("Discard_Names", Flag88
(Id
));
7998 W
("Elaboration_Entity_Required", Flag174
(Id
));
7999 W
("Elaborate_Body_Desirable", Flag210
(Id
));
8000 W
("Entry_Accepted", Flag152
(Id
));
8001 W
("Can_Use_Internal_Rep", Flag229
(Id
));
8002 W
("Finalize_Storage_Only", Flag158
(Id
));
8003 W
("From_Limited_With", Flag159
(Id
));
8004 W
("Has_Aliased_Components", Flag135
(Id
));
8005 W
("Has_Alignment_Clause", Flag46
(Id
));
8006 W
("Has_All_Calls_Remote", Flag79
(Id
));
8007 W
("Has_Anonymous_Master", Flag253
(Id
));
8008 W
("Has_Atomic_Components", Flag86
(Id
));
8009 W
("Has_Biased_Representation", Flag139
(Id
));
8010 W
("Has_Body_References", Flag264
(Id
));
8011 W
("Has_Completion", Flag26
(Id
));
8012 W
("Has_Completion_In_Body", Flag71
(Id
));
8013 W
("Has_Complex_Representation", Flag140
(Id
));
8014 W
("Has_Component_Size_Clause", Flag68
(Id
));
8015 W
("Has_Contiguous_Rep", Flag181
(Id
));
8016 W
("Has_Controlled_Component", Flag43
(Id
));
8017 W
("Has_Controlling_Result", Flag98
(Id
));
8018 W
("Has_Convention_Pragma", Flag119
(Id
));
8019 W
("Has_Default_Aspect", Flag39
(Id
));
8020 W
("Has_Delayed_Aspects", Flag200
(Id
));
8021 W
("Has_Delayed_Freeze", Flag18
(Id
));
8022 W
("Has_Delayed_Rep_Aspects", Flag261
(Id
));
8023 W
("Has_Discriminants", Flag5
(Id
));
8024 W
("Has_Dispatch_Table", Flag220
(Id
));
8025 W
("Has_Dynamic_Predicate_Aspect", Flag258
(Id
));
8026 W
("Has_Enumeration_Rep_Clause", Flag66
(Id
));
8027 W
("Has_Exit", Flag47
(Id
));
8028 W
("Has_External_Tag_Rep_Clause", Flag110
(Id
));
8029 W
("Has_Forward_Instantiation", Flag175
(Id
));
8030 W
("Has_Fully_Qualified_Name", Flag173
(Id
));
8031 W
("Has_Gigi_Rep_Item", Flag82
(Id
));
8032 W
("Has_Homonym", Flag56
(Id
));
8033 W
("Has_Implicit_Dereference", Flag251
(Id
));
8034 W
("Has_Inheritable_Invariants", Flag248
(Id
));
8035 W
("Has_Initial_Value", Flag219
(Id
));
8036 W
("Has_Invariants", Flag232
(Id
));
8037 W
("Has_Loop_Entry_Attributes", Flag260
(Id
));
8038 W
("Has_Machine_Radix_Clause", Flag83
(Id
));
8039 W
("Has_Master_Entity", Flag21
(Id
));
8040 W
("Has_Missing_Return", Flag142
(Id
));
8041 W
("Has_Nested_Block_With_Handler", Flag101
(Id
));
8042 W
("Has_Non_Standard_Rep", Flag75
(Id
));
8043 W
("Has_Object_Size_Clause", Flag172
(Id
));
8044 W
("Has_Per_Object_Constraint", Flag154
(Id
));
8045 W
("Has_Postconditions", Flag240
(Id
));
8046 W
("Has_Pragma_Controlled", Flag27
(Id
));
8047 W
("Has_Pragma_Elaborate_Body", Flag150
(Id
));
8048 W
("Has_Pragma_Inline", Flag157
(Id
));
8049 W
("Has_Pragma_Inline_Always", Flag230
(Id
));
8050 W
("Has_Pragma_No_Inline", Flag201
(Id
));
8051 W
("Has_Pragma_Ordered", Flag198
(Id
));
8052 W
("Has_Pragma_Pack", Flag121
(Id
));
8053 W
("Has_Pragma_Preelab_Init", Flag221
(Id
));
8054 W
("Has_Pragma_Pure", Flag203
(Id
));
8055 W
("Has_Pragma_Pure_Function", Flag179
(Id
));
8056 W
("Has_Pragma_Thread_Local_Storage", Flag169
(Id
));
8057 W
("Has_Pragma_Unmodified", Flag233
(Id
));
8058 W
("Has_Pragma_Unreferenced", Flag180
(Id
));
8059 W
("Has_Pragma_Unreferenced_Objects", Flag212
(Id
));
8060 W
("Has_Predicates", Flag250
(Id
));
8061 W
("Has_Primitive_Operations", Flag120
(Id
));
8062 W
("Has_Private_Ancestor", Flag151
(Id
));
8063 W
("Has_Private_Declaration", Flag155
(Id
));
8064 W
("Has_Qualified_Name", Flag161
(Id
));
8065 W
("Has_RACW", Flag214
(Id
));
8066 W
("Has_Record_Rep_Clause", Flag65
(Id
));
8067 W
("Has_Recursive_Call", Flag143
(Id
));
8068 W
("Has_Size_Clause", Flag29
(Id
));
8069 W
("Has_Small_Clause", Flag67
(Id
));
8070 W
("Has_Specified_Layout", Flag100
(Id
));
8071 W
("Has_Specified_Stream_Input", Flag190
(Id
));
8072 W
("Has_Specified_Stream_Output", Flag191
(Id
));
8073 W
("Has_Specified_Stream_Read", Flag192
(Id
));
8074 W
("Has_Specified_Stream_Write", Flag193
(Id
));
8075 W
("Has_Static_Discriminants", Flag211
(Id
));
8076 W
("Has_Static_Predicate_Aspect", Flag259
(Id
));
8077 W
("Has_Storage_Size_Clause", Flag23
(Id
));
8078 W
("Has_Stream_Size_Clause", Flag184
(Id
));
8079 W
("Has_Task", Flag30
(Id
));
8080 W
("Has_Thunks", Flag228
(Id
));
8081 W
("Has_Unchecked_Union", Flag123
(Id
));
8082 W
("Has_Unknown_Discriminants", Flag72
(Id
));
8083 W
("Has_Up_Level_Access", Flag215
(Id
));
8084 W
("Has_Visible_Refinement", Flag263
(Id
));
8085 W
("Has_Volatile_Components", Flag87
(Id
));
8086 W
("Has_Xref_Entry", Flag182
(Id
));
8087 W
("In_Package_Body", Flag48
(Id
));
8088 W
("In_Private_Part", Flag45
(Id
));
8089 W
("In_Use", Flag8
(Id
));
8090 W
("Is_AST_Entry", Flag132
(Id
));
8091 W
("Is_Abstract_Subprogram", Flag19
(Id
));
8092 W
("Is_Abstract_Type", Flag146
(Id
));
8093 W
("Is_Local_Anonymous_Access", Flag194
(Id
));
8094 W
("Is_Access_Constant", Flag69
(Id
));
8095 W
("Is_Ada_2005_Only", Flag185
(Id
));
8096 W
("Is_Ada_2012_Only", Flag199
(Id
));
8097 W
("Is_Aliased", Flag15
(Id
));
8098 W
("Is_Asynchronous", Flag81
(Id
));
8099 W
("Is_Atomic", Flag85
(Id
));
8100 W
("Is_Bit_Packed_Array", Flag122
(Id
));
8101 W
("Is_CPP_Class", Flag74
(Id
));
8102 W
("Is_Called", Flag102
(Id
));
8103 W
("Is_Character_Type", Flag63
(Id
));
8104 W
("Is_Child_Unit", Flag73
(Id
));
8105 W
("Is_Class_Wide_Equivalent_Type", Flag35
(Id
));
8106 W
("Is_Compilation_Unit", Flag149
(Id
));
8107 W
("Is_Completely_Hidden", Flag103
(Id
));
8108 W
("Is_Concurrent_Record_Type", Flag20
(Id
));
8109 W
("Is_Constr_Subt_For_UN_Aliased", Flag141
(Id
));
8110 W
("Is_Constr_Subt_For_U_Nominal", Flag80
(Id
));
8111 W
("Is_Constrained", Flag12
(Id
));
8112 W
("Is_Constructor", Flag76
(Id
));
8113 W
("Is_Controlled", Flag42
(Id
));
8114 W
("Is_Controlling_Formal", Flag97
(Id
));
8115 W
("Is_Descendent_Of_Address", Flag223
(Id
));
8116 W
("Is_Discrim_SO_Function", Flag176
(Id
));
8117 W
("Is_Dispatch_Table_Entity", Flag234
(Id
));
8118 W
("Is_Dispatching_Operation", Flag6
(Id
));
8119 W
("Is_Eliminated", Flag124
(Id
));
8120 W
("Is_Entry_Formal", Flag52
(Id
));
8121 W
("Is_Exported", Flag99
(Id
));
8122 W
("Is_First_Subtype", Flag70
(Id
));
8123 W
("Is_For_Access_Subtype", Flag118
(Id
));
8124 W
("Is_Formal_Subprogram", Flag111
(Id
));
8125 W
("Is_Frozen", Flag4
(Id
));
8126 W
("Is_Generic_Actual_Type", Flag94
(Id
));
8127 W
("Is_Generic_Instance", Flag130
(Id
));
8128 W
("Is_Generic_Type", Flag13
(Id
));
8129 W
("Is_Hidden", Flag57
(Id
));
8130 W
("Is_Hidden_Open_Scope", Flag171
(Id
));
8131 W
("Is_Immediately_Visible", Flag7
(Id
));
8132 W
("Is_Implementation_Defined", Flag254
(Id
));
8133 W
("Is_Imported", Flag24
(Id
));
8134 W
("Is_Inlined", Flag11
(Id
));
8135 W
("Is_Instantiated", Flag126
(Id
));
8136 W
("Is_Interface", Flag186
(Id
));
8137 W
("Is_Internal", Flag17
(Id
));
8138 W
("Is_Interrupt_Handler", Flag89
(Id
));
8139 W
("Is_Intrinsic_Subprogram", Flag64
(Id
));
8140 W
("Is_Invariant_Procedure", Flag257
(Id
));
8141 W
("Is_Itype", Flag91
(Id
));
8142 W
("Is_Known_Non_Null", Flag37
(Id
));
8143 W
("Is_Known_Null", Flag204
(Id
));
8144 W
("Is_Known_Valid", Flag170
(Id
));
8145 W
("Is_Limited_Composite", Flag106
(Id
));
8146 W
("Is_Limited_Interface", Flag197
(Id
));
8147 W
("Is_Limited_Record", Flag25
(Id
));
8148 W
("Is_Machine_Code_Subprogram", Flag137
(Id
));
8149 W
("Is_Non_Static_Subtype", Flag109
(Id
));
8150 W
("Is_Null_Init_Proc", Flag178
(Id
));
8151 W
("Is_Obsolescent", Flag153
(Id
));
8152 W
("Is_Only_Out_Parameter", Flag226
(Id
));
8153 W
("Is_Optional_Parameter", Flag134
(Id
));
8154 W
("Is_Package_Body_Entity", Flag160
(Id
));
8155 W
("Is_Packed", Flag51
(Id
));
8156 W
("Is_Packed_Array_Type", Flag138
(Id
));
8157 W
("Is_Potentially_Use_Visible", Flag9
(Id
));
8158 W
("Is_Predicate_Function", Flag255
(Id
));
8159 W
("Is_Predicate_Function_M", Flag256
(Id
));
8160 W
("Is_Preelaborated", Flag59
(Id
));
8161 W
("Is_Primitive", Flag218
(Id
));
8162 W
("Is_Primitive_Wrapper", Flag195
(Id
));
8163 W
("Is_Private_Composite", Flag107
(Id
));
8164 W
("Is_Private_Descendant", Flag53
(Id
));
8165 W
("Is_Private_Primitive", Flag245
(Id
));
8166 W
("Is_Processed_Transient", Flag252
(Id
));
8167 W
("Is_Public", Flag10
(Id
));
8168 W
("Is_Pure", Flag44
(Id
));
8169 W
("Is_Pure_Unit_Access_Type", Flag189
(Id
));
8170 W
("Is_RACW_Stub_Type", Flag244
(Id
));
8171 W
("Is_Raised", Flag224
(Id
));
8172 W
("Is_Remote_Call_Interface", Flag62
(Id
));
8173 W
("Is_Remote_Types", Flag61
(Id
));
8174 W
("Is_Renaming_Of_Object", Flag112
(Id
));
8175 W
("Is_Return_Object", Flag209
(Id
));
8176 W
("Is_Safe_To_Reevaluate", Flag249
(Id
));
8177 W
("Is_Shared_Passive", Flag60
(Id
));
8178 W
("Is_Statically_Allocated", Flag28
(Id
));
8179 W
("Is_Tag", Flag78
(Id
));
8180 W
("Is_Tagged_Type", Flag55
(Id
));
8181 W
("Is_Thunk", Flag225
(Id
));
8182 W
("Is_Trivial_Subprogram", Flag235
(Id
));
8183 W
("Is_True_Constant", Flag163
(Id
));
8184 W
("Is_Unchecked_Union", Flag117
(Id
));
8185 W
("Is_Underlying_Record_View", Flag246
(Id
));
8186 W
("Is_Unsigned_Type", Flag144
(Id
));
8187 W
("Is_VMS_Exception", Flag133
(Id
));
8188 W
("Is_Valued_Procedure", Flag127
(Id
));
8189 W
("Is_Visible_Formal", Flag206
(Id
));
8190 W
("Is_Visible_Lib_Unit", Flag116
(Id
));
8191 W
("Is_Volatile", Flag16
(Id
));
8192 W
("Itype_Printed", Flag202
(Id
));
8193 W
("Kill_Elaboration_Checks", Flag32
(Id
));
8194 W
("Kill_Range_Checks", Flag33
(Id
));
8195 W
("Known_To_Have_Preelab_Init", Flag207
(Id
));
8196 W
("Low_Bound_Tested", Flag205
(Id
));
8197 W
("Machine_Radix_10", Flag84
(Id
));
8198 W
("Materialize_Entity", Flag168
(Id
));
8199 W
("May_Inherit_Delayed_Rep_Aspects", Flag262
(Id
));
8200 W
("Must_Be_On_Byte_Boundary", Flag183
(Id
));
8201 W
("Must_Have_Preelab_Init", Flag208
(Id
));
8202 W
("Needs_Debug_Info", Flag147
(Id
));
8203 W
("Needs_No_Actuals", Flag22
(Id
));
8204 W
("Never_Set_In_Source", Flag115
(Id
));
8205 W
("No_Pool_Assigned", Flag131
(Id
));
8206 W
("No_Return", Flag113
(Id
));
8207 W
("No_Strict_Aliasing", Flag136
(Id
));
8208 W
("Non_Binary_Modulus", Flag58
(Id
));
8209 W
("Nonzero_Is_True", Flag162
(Id
));
8210 W
("OK_To_Rename", Flag247
(Id
));
8211 W
("OK_To_Reorder_Components", Flag239
(Id
));
8212 W
("Optimize_Alignment_Space", Flag241
(Id
));
8213 W
("Optimize_Alignment_Time", Flag242
(Id
));
8214 W
("Overlays_Constant", Flag243
(Id
));
8215 W
("Reachable", Flag49
(Id
));
8216 W
("Referenced", Flag156
(Id
));
8217 W
("Referenced_As_LHS", Flag36
(Id
));
8218 W
("Referenced_As_Out_Parameter", Flag227
(Id
));
8219 W
("Renamed_In_Spec", Flag231
(Id
));
8220 W
("Requires_Overriding", Flag213
(Id
));
8221 W
("Return_Present", Flag54
(Id
));
8222 W
("Returns_By_Ref", Flag90
(Id
));
8223 W
("Reverse_Bit_Order", Flag164
(Id
));
8224 W
("Reverse_Storage_Order", Flag93
(Id
));
8225 W
("Sec_Stack_Needed_For_Return", Flag167
(Id
));
8226 W
("Size_Depends_On_Discriminant", Flag177
(Id
));
8227 W
("Size_Known_At_Compile_Time", Flag92
(Id
));
8228 W
("Static_Elaboration_Desired", Flag77
(Id
));
8229 W
("Strict_Alignment", Flag145
(Id
));
8230 W
("Suppress_Elaboration_Warnings", Flag148
(Id
));
8231 W
("Suppress_Initialization", Flag105
(Id
));
8232 W
("Suppress_Style_Checks", Flag165
(Id
));
8233 W
("Suppress_Value_Tracking_On_Call", Flag217
(Id
));
8234 W
("Treat_As_Volatile", Flag41
(Id
));
8235 W
("Universal_Aliasing", Flag216
(Id
));
8236 W
("Used_As_Generic_Actual", Flag222
(Id
));
8237 W
("Uses_Sec_Stack", Flag95
(Id
));
8238 W
("Warnings_Off", Flag96
(Id
));
8239 W
("Warnings_Off_Used", Flag236
(Id
));
8240 W
("Warnings_Off_Used_Unmodified", Flag237
(Id
));
8241 W
("Warnings_Off_Used_Unreferenced", Flag238
(Id
));
8242 W
("Was_Hidden", Flag196
(Id
));
8243 end Write_Entity_Flags
;
8245 -----------------------
8246 -- Write_Entity_Info --
8247 -----------------------
8249 procedure Write_Entity_Info
(Id
: Entity_Id
; Prefix
: String) is
8251 procedure Write_Attribute
(Which
: String; Nam
: E
);
8252 -- Write attribute value with given string name
8254 procedure Write_Kind
(Id
: Entity_Id
);
8255 -- Write Ekind field of entity
8257 ---------------------
8258 -- Write_Attribute --
8259 ---------------------
8261 procedure Write_Attribute
(Which
: String; Nam
: E
) is
8265 Write_Int
(Int
(Nam
));
8267 Write_Name
(Chars
(Nam
));
8269 end Write_Attribute
;
8275 procedure Write_Kind
(Id
: Entity_Id
) is
8276 K
: constant String := Entity_Kind
'Image (Ekind
(Id
));
8280 Write_Str
(" Kind ");
8282 if Is_Type
(Id
) and then Is_Tagged_Type
(Id
) then
8283 Write_Str
("TAGGED ");
8286 Write_Str
(K
(3 .. K
'Length));
8289 if Is_Type
(Id
) and then Depends_On_Private
(Id
) then
8290 Write_Str
("Depends_On_Private ");
8294 -- Start of processing for Write_Entity_Info
8298 Write_Attribute
("Name ", Id
);
8299 Write_Int
(Int
(Id
));
8303 Write_Attribute
(" Type ", Etype
(Id
));
8305 Write_Attribute
(" Scope ", Scope
(Id
));
8310 when Discrete_Kind
=>
8311 Write_Str
("Bounds: Id = ");
8313 if Present
(Scalar_Range
(Id
)) then
8314 Write_Int
(Int
(Type_Low_Bound
(Id
)));
8315 Write_Str
(" .. Id = ");
8316 Write_Int
(Int
(Type_High_Bound
(Id
)));
8318 Write_Str
("Empty");
8329 (" Component Type ", Component_Type
(Id
));
8332 Write_Str
(" Indexes ");
8334 Index
:= First_Index
(Id
);
8335 while Present
(Index
) loop
8336 Write_Attribute
(" ", Etype
(Index
));
8337 Index
:= Next_Index
(Index
);
8345 (" Directly Designated Type ",
8346 Directly_Designated_Type
(Id
));
8349 when Overloadable_Kind
=>
8350 if Present
(Homonym
(Id
)) then
8351 Write_Str
(" Homonym ");
8352 Write_Name
(Chars
(Homonym
(Id
)));
8354 Write_Int
(Int
(Homonym
(Id
)));
8361 if Ekind
(Scope
(Id
)) in Record_Kind
then
8363 " Original_Record_Component ",
8364 Original_Record_Component
(Id
));
8365 Write_Int
(Int
(Original_Record_Component
(Id
)));
8369 when others => null;
8371 end Write_Entity_Info
;
8373 -----------------------
8374 -- Write_Field6_Name --
8375 -----------------------
8377 procedure Write_Field6_Name
(Id
: Entity_Id
) is
8378 pragma Warnings
(Off
, Id
);
8380 Write_Str
("First_Rep_Item");
8381 end Write_Field6_Name
;
8383 -----------------------
8384 -- Write_Field7_Name --
8385 -----------------------
8387 procedure Write_Field7_Name
(Id
: Entity_Id
) is
8388 pragma Warnings
(Off
, Id
);
8390 Write_Str
("Freeze_Node");
8391 end Write_Field7_Name
;
8393 -----------------------
8394 -- Write_Field8_Name --
8395 -----------------------
8397 procedure Write_Field8_Name
(Id
: Entity_Id
) is
8401 Write_Str
("Associated_Node_For_Itype");
8404 Write_Str
("Dependent_Instances");
8407 Write_Str
("First_Exit_Statement");
8410 Write_Str
("Hiding_Loop_Variable");
8414 E_Subprogram_Body
=>
8415 Write_Str
("Mechanism");
8419 Write_Str
("Normalized_First_Bit");
8422 Write_Str
("Postcondition_Proc");
8424 when E_Abstract_State
=>
8425 Write_Str
("Refinement_Constituents");
8427 when E_Return_Statement
=>
8428 Write_Str
("Return_Applies_To");
8431 Write_Str
("Field8??");
8433 end Write_Field8_Name
;
8435 -----------------------
8436 -- Write_Field9_Name --
8437 -----------------------
8439 procedure Write_Field9_Name
(Id
: Entity_Id
) is
8443 Write_Str
("Class_Wide_Type");
8446 Write_Str
("Current_Value");
8449 E_Generic_Function |
8451 E_Generic_Procedure |
8454 Write_Str
("Renaming_Map");
8457 Write_Str
("Field9??");
8459 end Write_Field9_Name
;
8461 ------------------------
8462 -- Write_Field10_Name --
8463 ------------------------
8465 procedure Write_Field10_Name
(Id
: Entity_Id
) is
8468 when Class_Wide_Kind |
8474 Write_Str
("Direct_Primitive_Operations");
8477 Write_Str
("Float_Rep");
8479 when E_In_Parameter |
8481 Write_Str
("Discriminal_Link");
8487 Write_Str
("Handler_Records");
8491 Write_Str
("Normalized_Position_Max");
8493 when E_Abstract_State |
8495 Write_Str
("Refined_State");
8498 Write_Str
("Field10??");
8500 end Write_Field10_Name
;
8502 ------------------------
8503 -- Write_Field11_Name --
8504 ------------------------
8506 procedure Write_Field11_Name
(Id
: Entity_Id
) is
8510 Write_Str
("Block_Node");
8514 Write_Str
("Component_Bit_Offset");
8517 Write_Str
("Entry_Component");
8519 when E_Enumeration_Literal
=>
8520 Write_Str
("Enumeration_Pos");
8524 Write_Str
("Full_View");
8526 when E_Generic_Package
=>
8527 Write_Str
("Generic_Homonym");
8533 Write_Str
("Protected_Body_Subprogram");
8536 Write_Str
("Field11??");
8538 end Write_Field11_Name
;
8540 ------------------------
8541 -- Write_Field12_Name --
8542 ------------------------
8544 procedure Write_Field12_Name
(Id
: Entity_Id
) is
8548 Write_Str
("Associated_Formal_Package");
8551 Write_Str
("Barrier_Function");
8553 when E_Enumeration_Literal
=>
8554 Write_Str
("Enumeration_Rep");
8562 E_In_Out_Parameter |
8566 Write_Str
("Esize");
8570 Write_Str
("Next_Inlined_Subprogram");
8573 Write_Str
("Field12??");
8575 end Write_Field12_Name
;
8577 ------------------------
8578 -- Write_Field13_Name --
8579 ------------------------
8581 procedure Write_Field13_Name
(Id
: Entity_Id
) is
8586 Write_Str
("Component_Clause");
8589 Write_Str
("Elaboration_Entity");
8593 Generic_Unit_Kind
=>
8594 Write_Str
("Elaboration_Entity");
8598 Write_Str
("Extra_Accessibility");
8601 Write_Str
("RM_Size");
8604 Write_Str
("Field13??");
8606 end Write_Field13_Name
;
8608 -----------------------
8609 -- Write_Field14_Name --
8610 -----------------------
8612 procedure Write_Field14_Name
(Id
: Entity_Id
) is
8621 Write_Str
("Alignment");
8625 Write_Str
("First_Optional_Parameter");
8629 Write_Str
("Normalized_Position");
8632 E_Generic_Package
=>
8633 Write_Str
("Shadow_Entities");
8636 Write_Str
("Field14??");
8638 end Write_Field14_Name
;
8640 ------------------------
8641 -- Write_Field15_Name --
8642 ------------------------
8644 procedure Write_Field15_Name
(Id
: Entity_Id
) is
8647 when E_Discriminant
=>
8648 Write_Str
("Discriminant_Number");
8651 Write_Str
("DT_Entry_Count");
8655 Write_Str
("DT_Position");
8657 when E_Protected_Type
=>
8658 Write_Str
("Entry_Bodies_Array");
8661 Write_Str
("Entry_Parameters_Type");
8664 Write_Str
("Extra_Formal");
8666 when Enumeration_Kind
=>
8667 Write_Str
("Lit_Indexes");
8671 Write_Str
("Related_Instance");
8673 when Decimal_Fixed_Point_Kind
=>
8674 Write_Str
("Scale_Value");
8678 Write_Str
("Status_Flag_Or_Transient_Decl");
8682 Write_Str
("Storage_Size_Variable");
8684 when E_String_Literal_Subtype
=>
8685 Write_Str
("String_Literal_Low_Bound");
8688 Write_Str
("Field15??");
8690 end Write_Field15_Name
;
8692 ------------------------
8693 -- Write_Field16_Name --
8694 ------------------------
8696 procedure Write_Field16_Name
(Id
: Entity_Id
) is
8699 when E_Record_Type |
8700 E_Record_Type_With_Private
=>
8701 Write_Str
("Access_Disp_Table");
8703 when E_Abstract_State
=>
8704 Write_Str
("Body_References");
8706 when E_Record_Subtype |
8707 E_Class_Wide_Subtype
=>
8708 Write_Str
("Cloned_Subtype");
8712 Write_Str
("DTC_Entity");
8715 Write_Str
("Entry_Formal");
8720 Write_Str
("First_Private_Entity");
8722 when Enumeration_Kind
=>
8723 Write_Str
("Lit_Strings");
8725 when E_String_Literal_Subtype
=>
8726 Write_Str
("String_Literal_Length");
8730 Write_Str
("Unset_Reference");
8733 Write_Str
("Field16??");
8735 end Write_Field16_Name
;
8737 ------------------------
8738 -- Write_Field17_Name --
8739 ------------------------
8741 procedure Write_Field17_Name
(Id
: Entity_Id
) is
8746 E_Generic_In_Out_Parameter |
8748 Write_Str
("Actual_Subtype");
8751 Write_Str
("Digits_Value");
8753 when E_Discriminant
=>
8754 Write_Str
("Discriminal");
8763 E_Generic_Function |
8765 E_Generic_Procedure |
8773 E_Return_Statement |
8775 E_Subprogram_Type
=>
8776 Write_Str
("First_Entity");
8779 Write_Str
("First_Index");
8781 when Enumeration_Kind
=>
8782 Write_Str
("First_Literal");
8785 Write_Str
("Master_Id");
8787 when Modular_Integer_Kind
=>
8788 Write_Str
("Modulus");
8790 when E_Incomplete_Type
=>
8791 Write_Str
("Non_Limited_View");
8793 when E_Incomplete_Subtype
=>
8794 if From_Limited_With
(Id
) then
8795 Write_Str
("Non_Limited_View");
8799 Write_Str
("Prival");
8802 Write_Str
("Field17??");
8804 end Write_Field17_Name
;
8806 ------------------------
8807 -- Write_Field18_Name --
8808 ------------------------
8810 procedure Write_Field18_Name
(Id
: Entity_Id
) is
8813 when E_Enumeration_Literal |
8817 Write_Str
("Alias");
8819 when E_Record_Type
=>
8820 Write_Str
("Corresponding_Concurrent_Type");
8822 when E_Subprogram_Body
=>
8823 Write_Str
("Corresponding_Protected_Entry");
8825 when Concurrent_Kind
=>
8826 Write_Str
("Corresponding_Record_Type");
8831 Write_Str
("Enclosing_Scope");
8833 when E_Entry_Index_Parameter
=>
8834 Write_Str
("Entry_Index_Constant");
8836 when E_Class_Wide_Subtype |
8837 E_Access_Protected_Subprogram_Type |
8838 E_Anonymous_Access_Protected_Subprogram_Type |
8839 E_Access_Subprogram_Type |
8841 Write_Str
("Equivalent_Type");
8843 when Fixed_Point_Kind
=>
8844 Write_Str
("Delta_Value");
8846 when Incomplete_Or_Private_Kind |
8848 Write_Str
("Private_Dependents");
8851 Write_Str
("Renamed_Object");
8855 E_Generic_Function |
8856 E_Generic_Procedure |
8857 E_Generic_Package
=>
8858 Write_Str
("Renamed_Entity");
8861 Write_Str
("Field18??");
8863 end Write_Field18_Name
;
8865 -----------------------
8866 -- Write_Field19_Name --
8867 -----------------------
8869 procedure Write_Field19_Name
(Id
: Entity_Id
) is
8873 E_Generic_Package
=>
8874 Write_Str
("Body_Entity");
8876 when E_Discriminant
=>
8877 Write_Str
("Corresponding_Discriminant");
8880 Write_Str
("Default_Aspect_Value");
8882 when E_Array_Type
=>
8883 Write_Str
("Default_Component_Value");
8885 when E_Record_Type
=>
8886 Write_Str
("Parent_Subtype");
8890 Write_Str
("Size_Check_Code");
8892 when E_Package_Body |
8894 Write_Str
("Spec_Entity");
8896 when Private_Kind
=>
8897 Write_Str
("Underlying_Full_View");
8899 when E_Function | E_Operator | E_Subprogram_Type
=>
8900 Write_Str
("Extra_Accessibility_Of_Result");
8903 Write_Str
("Field19??");
8905 end Write_Field19_Name
;
8907 -----------------------
8908 -- Write_Field20_Name --
8909 -----------------------
8911 procedure Write_Field20_Name
(Id
: Entity_Id
) is
8915 Write_Str
("Component_Type");
8917 when E_In_Parameter |
8918 E_Generic_In_Parameter
=>
8919 Write_Str
("Default_Value");
8922 Write_Str
("Directly_Designated_Type");
8925 Write_Str
("Discriminant_Checking_Func");
8927 when E_Discriminant
=>
8928 Write_Str
("Discriminant_Default_Value");
8937 E_Generic_Function |
8939 E_Generic_Procedure |
8947 E_Return_Statement |
8949 E_Subprogram_Type
=>
8950 Write_Str
("Last_Entity");
8954 Write_Str
("Prival_Link");
8957 Write_Str
("Scalar_Range");
8960 Write_Str
("Register_Exception_Call");
8963 Write_Str
("Field20??");
8965 end Write_Field20_Name
;
8967 -----------------------
8968 -- Write_Field21_Name --
8969 -----------------------
8971 procedure Write_Field21_Name
(Id
: Entity_Id
) is
8975 Write_Str
("Accept_Address");
8977 when E_In_Parameter
=>
8978 Write_Str
("Default_Expr_Function");
8980 when Concurrent_Kind |
8981 Incomplete_Or_Private_Kind |
8985 Write_Str
("Discriminant_Constraint");
8990 E_Generic_Function |
8992 E_Generic_Procedure |
8994 Write_Str
("Interface_Name");
8997 Modular_Integer_Kind
=>
8998 Write_Str
("Original_Array_Type");
9000 when Fixed_Point_Kind
=>
9001 Write_Str
("Small_Value");
9004 Write_Str
("Field21??");
9006 end Write_Field21_Name
;
9008 -----------------------
9009 -- Write_Field22_Name --
9010 -----------------------
9012 procedure Write_Field22_Name
(Id
: Entity_Id
) is
9016 Write_Str
("Associated_Storage_Pool");
9019 Write_Str
("Component_Size");
9021 when E_Record_Type
=>
9022 Write_Str
("Corresponding_Remote_Type");
9026 Write_Str
("Original_Record_Component");
9028 when E_Enumeration_Literal
=>
9029 Write_Str
("Enumeration_Rep_Expr");
9032 Write_Str
("Exception_Code");
9034 when E_Record_Type_With_Private |
9035 E_Record_Subtype_With_Private |
9038 E_Limited_Private_Type |
9039 E_Limited_Private_Subtype
=>
9040 Write_Str
("Private_View");
9043 Write_Str
("Protected_Formal");
9053 E_Generic_Function |
9054 E_Generic_Procedure |
9057 E_Return_Statement |
9060 Write_Str
("Scope_Depth_Value");
9063 Write_Str
("Shared_Var_Procs_Instance");
9066 Write_Str
("Field22??");
9068 end Write_Field22_Name
;
9070 ------------------------
9071 -- Write_Field23_Name --
9072 ------------------------
9074 procedure Write_Field23_Name
(Id
: Entity_Id
) is
9077 when E_Discriminant
=>
9078 Write_Str
("CR_Discriminant");
9081 Write_Str
("Entry_Cancel_Parameter");
9083 when E_Enumeration_Type
=>
9084 Write_Str
("Enum_Pos_To_Rep");
9088 Write_Str
("Extra_Constrained");
9091 Write_Str
("Finalization_Master");
9093 when E_Generic_Function |
9095 E_Generic_Procedure
=>
9096 Write_Str
("Inner_Instances");
9099 Write_Str
("Packed_Array_Type");
9102 Write_Str
("Protection_Object");
9104 when Concurrent_Kind |
9105 Incomplete_Or_Private_Kind |
9109 Write_Str
("Stored_Constraint");
9113 if Present
(Scope
(Id
))
9114 and then Is_Protected_Type
(Scope
(Id
))
9116 Write_Str
("Protection_Object");
9118 Write_Str
("Generic_Renamings");
9122 if Is_Generic_Instance
(Id
) then
9123 Write_Str
("Generic_Renamings");
9125 Write_Str
("Limited_View");
9129 Write_Str
("Field23??");
9131 end Write_Field23_Name
;
9133 ------------------------
9134 -- Write_Field24_Name --
9135 ------------------------
9137 procedure Write_Field24_Name
(Id
: Entity_Id
) is
9143 Write_Str
("Related_Expression");
9151 Generic_Subprogram_Kind |
9153 Write_Str
("Contract");
9156 Write_Str
("Field24???");
9158 end Write_Field24_Name
;
9160 ------------------------
9161 -- Write_Field25_Name --
9162 ------------------------
9164 procedure Write_Field25_Name
(Id
: Entity_Id
) is
9168 Write_Str
("Abstract_States");
9171 Write_Str
("Debug_Renaming_Link");
9174 Write_Str
("DT_Offset_To_Top_Func");
9178 Write_Str
("Interface_Alias");
9180 when E_Record_Type |
9182 E_Record_Type_With_Private |
9183 E_Record_Subtype_With_Private
=>
9184 Write_Str
("Interfaces");
9188 Write_Str
("Related_Array_Object");
9191 Write_Str
("Task_Body_Procedure");
9195 Write_Str
("PPC_Wrapper");
9197 when E_Enumeration_Subtype |
9198 E_Modular_Integer_Subtype |
9199 E_Signed_Integer_Subtype
=>
9200 Write_Str
("Static_Predicate");
9203 Write_Str
("Field25??");
9205 end Write_Field25_Name
;
9207 ------------------------
9208 -- Write_Field26_Name --
9209 ------------------------
9211 procedure Write_Field26_Name
(Id
: Entity_Id
) is
9214 when E_Record_Type |
9215 E_Record_Type_With_Private
=>
9216 Write_Str
("Dispatch_Table_Wrappers");
9218 when E_In_Out_Parameter |
9221 Write_Str
("Last_Assignment");
9223 when E_Access_Subprogram_Type
=>
9224 Write_Str
("Original_Access_Type");
9226 when E_Generic_Package |
9228 Write_Str
("Package_Instantiation");
9232 Write_Str
("Related_Type");
9235 Write_Str
("Relative_Deadline_Variable");
9239 Write_Str
("Overridden_Operation");
9242 Write_Str
("Field26??");
9244 end Write_Field26_Name
;
9246 ------------------------
9247 -- Write_Field27_Name --
9248 ------------------------
9250 procedure Write_Field27_Name
(Id
: Entity_Id
) is
9255 Write_Str
("Current_Use_Clause");
9260 Write_Str
("Related_Type");
9264 Write_Str
("Wrapped_Entity");
9267 Write_Str
("Field27??");
9269 end Write_Field27_Name
;
9271 ------------------------
9272 -- Write_Field28_Name --
9273 ------------------------
9275 procedure Write_Field28_Name
(Id
: Entity_Id
) is
9283 E_Subprogram_Type
=>
9284 Write_Str
("Extra_Formals");
9288 Write_Str
("Finalizer");
9292 Write_Str
("Initialization_Statements");
9294 when E_Record_Type
=>
9295 Write_Str
("Underlying_Record_View");
9298 Write_Str
("Field28??");
9300 end Write_Field28_Name
;
9302 ------------------------
9303 -- Write_Field29_Name --
9304 ------------------------
9306 procedure Write_Field29_Name
(Id
: Entity_Id
) is
9310 Write_Str
("Subprograms_For_Type");
9313 Write_Str
("Field29??");
9315 end Write_Field29_Name
;
9317 ------------------------
9318 -- Write_Field30_Name --
9319 ------------------------
9321 procedure Write_Field30_Name
(Id
: Entity_Id
) is
9325 Write_Str
("Corresponding_Equality");
9328 Write_Str
("Static_Initialization");
9331 Write_Str
("Field30??");
9333 end Write_Field30_Name
;
9335 ------------------------
9336 -- Write_Field31_Name --
9337 ------------------------
9339 procedure Write_Field31_Name
(Id
: Entity_Id
) is
9344 Write_Str
("Thunk_Entity");
9347 Write_Str
("Field31??");
9349 end Write_Field31_Name
;
9351 ------------------------
9352 -- Write_Field32_Name --
9353 ------------------------
9355 procedure Write_Field32_Name
(Id
: Entity_Id
) is
9359 E_Generic_Function |
9361 E_Generic_Procedure |
9365 E_Subprogram_Body
=>
9366 Write_Str
("SPARK_Mode_Pragmas");
9369 Write_Str
("Field32??");
9371 end Write_Field32_Name
;
9373 ------------------------
9374 -- Write_Field33_Name --
9375 ------------------------
9377 procedure Write_Field33_Name
(Id
: Entity_Id
) is
9381 Write_Str
("Field33??");
9383 end Write_Field33_Name
;
9385 ------------------------
9386 -- Write_Field34_Name --
9387 ------------------------
9389 procedure Write_Field34_Name
(Id
: Entity_Id
) is
9393 Write_Str
("Field34??");
9395 end Write_Field34_Name
;
9397 ------------------------
9398 -- Write_Field35_Name --
9399 ------------------------
9401 procedure Write_Field35_Name
(Id
: Entity_Id
) is
9405 Write_Str
("Field35??");
9407 end Write_Field35_Name
;
9409 -------------------------
9410 -- Iterator Procedures --
9411 -------------------------
9413 procedure Proc_Next_Component
(N
: in out Node_Id
) is
9415 N
:= Next_Component
(N
);
9416 end Proc_Next_Component
;
9418 procedure Proc_Next_Component_Or_Discriminant
(N
: in out Node_Id
) is
9420 N
:= Next_Entity
(N
);
9421 while Present
(N
) loop
9422 exit when Ekind_In
(N
, E_Component
, E_Discriminant
);
9423 N
:= Next_Entity
(N
);
9425 end Proc_Next_Component_Or_Discriminant
;
9427 procedure Proc_Next_Discriminant
(N
: in out Node_Id
) is
9429 N
:= Next_Discriminant
(N
);
9430 end Proc_Next_Discriminant
;
9432 procedure Proc_Next_Formal
(N
: in out Node_Id
) is
9434 N
:= Next_Formal
(N
);
9435 end Proc_Next_Formal
;
9437 procedure Proc_Next_Formal_With_Extras
(N
: in out Node_Id
) is
9439 N
:= Next_Formal_With_Extras
(N
);
9440 end Proc_Next_Formal_With_Extras
;
9442 procedure Proc_Next_Index
(N
: in out Node_Id
) is
9444 N
:= Next_Index
(N
);
9445 end Proc_Next_Index
;
9447 procedure Proc_Next_Inlined_Subprogram
(N
: in out Node_Id
) is
9449 N
:= Next_Inlined_Subprogram
(N
);
9450 end Proc_Next_Inlined_Subprogram
;
9452 procedure Proc_Next_Literal
(N
: in out Node_Id
) is
9454 N
:= Next_Literal
(N
);
9455 end Proc_Next_Literal
;
9457 procedure Proc_Next_Stored_Discriminant
(N
: in out Node_Id
) is
9459 N
:= Next_Stored_Discriminant
(N
);
9460 end Proc_Next_Stored_Discriminant
;