1 ------------------------------------------------------------------------------
3 -- GNAT COMPILER COMPONENTS --
9 -- Copyright (C) 1992-2017, 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
73 -- Associated_Entity Node37
75 -- The usage of other fields (and the entity kinds to which it applies)
76 -- depends on the particular field (see Einfo spec for details).
78 -- Associated_Node_For_Itype Node8
79 -- Dependent_Instances Elist8
80 -- Hiding_Loop_Variable Node8
81 -- Mechanism Uint8 (but returns Mechanism_Type)
82 -- Normalized_First_Bit Uint8
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 -- Part_Of_Constituents Elist10
99 -- Component_Bit_Offset Uint11
101 -- Entry_Component Node11
102 -- Enumeration_Pos Uint11
103 -- Generic_Homonym Node11
104 -- Part_Of_References Elist11
105 -- Protected_Body_Subprogram Node11
107 -- Barrier_Function Node12
108 -- Enumeration_Rep Uint12
110 -- Next_Inlined_Subprogram Node12
112 -- Component_Clause Node13
113 -- Elaboration_Entity Node13
114 -- Extra_Accessibility Node13
118 -- Normalized_Position Uint14
119 -- Postconditions_Proc Node14
120 -- Shadow_Entities List14
122 -- Discriminant_Number Uint15
123 -- DT_Position Uint15
124 -- DT_Entry_Count Uint15
125 -- Entry_Parameters_Type Node15
126 -- Extra_Formal Node15
127 -- Pending_Access_Types Elist15
128 -- Related_Instance Node15
129 -- Status_Flag_Or_Transient_Decl Node15
131 -- Access_Disp_Table Elist16
132 -- Body_References Elist16
133 -- Cloned_Subtype Node16
135 -- Entry_Formal Node16
136 -- First_Private_Entity Node16
137 -- Lit_Strings Node16
138 -- Scale_Value Uint16
139 -- String_Literal_Length Uint16
140 -- Unset_Reference Node16
142 -- Actual_Subtype Node17
143 -- Digits_Value Uint17
144 -- Discriminal Node17
145 -- First_Entity Node17
146 -- First_Index Node17
147 -- First_Literal Node17
153 -- Corresponding_Concurrent_Type Node18
154 -- Corresponding_Protected_Entry Node18
155 -- Corresponding_Record_Type Node18
156 -- Delta_Value Ureal18
157 -- Enclosing_Scope Node18
158 -- Equivalent_Type Node18
159 -- Lit_Indexes Node18
160 -- Private_Dependents Elist18
161 -- Renamed_Entity Node18
162 -- Renamed_Object Node18
163 -- String_Literal_Low_Bound Node18
165 -- Body_Entity Node19
166 -- Corresponding_Discriminant Node19
167 -- Default_Aspect_Component_Value Node19
168 -- Default_Aspect_Value Node19
169 -- Entry_Bodies_Array Node19
170 -- Extra_Accessibility_Of_Result Node19
171 -- Non_Limited_View Node19
172 -- Parent_Subtype Node19
173 -- Receiving_Entry Node19
174 -- Size_Check_Code Node19
175 -- Spec_Entity Node19
176 -- Underlying_Full_View Node19
178 -- Component_Type Node20
179 -- Default_Value Node20
180 -- Directly_Designated_Type Node20
181 -- Discriminant_Checking_Func Node20
182 -- Discriminant_Default_Value Node20
183 -- Last_Entity Node20
184 -- Prival_Link Node20
185 -- Register_Exception_Call Node20
186 -- Scalar_Range Node20
188 -- Accept_Address Elist21
189 -- Corresponding_Record_Component Node21
190 -- Default_Expr_Function Node21
191 -- Discriminant_Constraint Elist21
192 -- Interface_Name Node21
193 -- Original_Array_Type Node21
194 -- Small_Value Ureal21
196 -- Associated_Storage_Pool Node22
197 -- Component_Size Uint22
198 -- Corresponding_Remote_Type Node22
199 -- Enumeration_Rep_Expr Node22
200 -- Original_Record_Component Node22
201 -- Private_View Node22
202 -- Protected_Formal Node22
203 -- Scope_Depth_Value Uint22
204 -- Shared_Var_Procs_Instance Node22
206 -- CR_Discriminant Node23
207 -- Entry_Cancel_Parameter Node23
208 -- Enum_Pos_To_Rep Node23
209 -- Extra_Constrained Node23
210 -- Finalization_Master Node23
211 -- Generic_Renamings Elist23
212 -- Inner_Instances Elist23
213 -- Limited_View Node23
214 -- Packed_Array_Impl_Type Node23
215 -- Protection_Object Node23
216 -- Stored_Constraint Elist23
218 -- Incomplete_Actuals Elist24
219 -- Related_Expression Node24
220 -- Subps_Index Uint24
222 -- Contract_Wrapper Node25
223 -- Debug_Renaming_Link Node25
224 -- DT_Offset_To_Top_Func Node25
225 -- Interface_Alias Node25
226 -- Interfaces Elist25
227 -- Related_Array_Object Node25
228 -- Static_Discrete_Predicate List25
229 -- Static_Real_Or_String_Predicate Node25
230 -- Task_Body_Procedure Node25
232 -- Dispatch_Table_Wrappers Elist26
233 -- Last_Assignment Node26
234 -- Overridden_Operation Node26
235 -- Package_Instantiation Node26
236 -- Storage_Size_Variable Node26
238 -- Current_Use_Clause Node27
239 -- Related_Type Node27
240 -- Wrapped_Entity Node27
242 -- Extra_Formals Node28
244 -- Initialization_Statements Node28
245 -- Original_Access_Type Node28
246 -- Relative_Deadline_Variable Node28
247 -- Underlying_Record_View Node28
249 -- Anonymous_Masters Elist29
250 -- BIP_Initialization_Call Node29
251 -- Subprograms_For_Type Elist29
253 -- Access_Disp_Table_Elab_Flag Node30
254 -- Anonymous_Object Node30
255 -- Corresponding_Equality Node30
256 -- Last_Aggregate_Assignment Node30
257 -- Static_Initialization Node30
259 -- Derived_Type_Link Node31
260 -- Thunk_Entity Node31
261 -- Activation_Record_Component Node31
263 -- Corresponding_Function Node32
264 -- Corresponding_Procedure Node32
265 -- Encapsulating_State Node32
266 -- No_Tagged_Streams_Pragma Node32
268 -- Linker_Section_Pragma Node33
272 -- Anonymous_Designated_Type Node35
273 -- Entry_Max_Queue_Lengths_Array Node35
274 -- Import_Pragma Node35
276 -- Nested_Scenarios Elist36
277 -- Validated_Object Node36
279 -- Class_Wide_Clone Node38
281 -- Protected_Subprogram Node39
283 -- SPARK_Pragma Node40
285 -- Original_Protected_Subprogram Node41
286 -- SPARK_Aux_Pragma Node41
288 ---------------------------------------------
289 -- Usage of Flags in Defining Entity Nodes --
290 ---------------------------------------------
292 -- All flags are unique, there is no overlaying, so each flag is physically
293 -- present in every entity. However, for many of the flags, it only makes
294 -- sense for them to be set true for certain subsets of entity kinds. See
295 -- the spec of Einfo for further details.
297 -- Is_Inlined_Always Flag1
298 -- Is_Hidden_Non_Overridden_Subpgm Flag2
301 -- Has_Discriminants Flag5
302 -- Is_Dispatching_Operation Flag6
303 -- Is_Immediately_Visible Flag7
305 -- Is_Potentially_Use_Visible Flag9
309 -- Is_Constrained Flag12
310 -- Is_Generic_Type Flag13
311 -- Depends_On_Private Flag14
313 -- Is_Volatile Flag16
314 -- Is_Internal Flag17
315 -- Has_Delayed_Freeze Flag18
316 -- Is_Abstract_Subprogram Flag19
317 -- Is_Concurrent_Record_Type Flag20
319 -- Has_Master_Entity Flag21
320 -- Needs_No_Actuals Flag22
321 -- Has_Storage_Size_Clause Flag23
322 -- Is_Imported Flag24
323 -- Is_Limited_Record Flag25
324 -- Has_Completion Flag26
325 -- Has_Pragma_Controlled Flag27
326 -- Is_Statically_Allocated Flag28
327 -- Has_Size_Clause Flag29
330 -- Checks_May_Be_Suppressed Flag31
331 -- Kill_Elaboration_Checks Flag32
332 -- Kill_Range_Checks Flag33
333 -- Has_Independent_Components Flag34
334 -- Is_Class_Wide_Equivalent_Type Flag35
335 -- Referenced_As_LHS Flag36
336 -- Is_Known_Non_Null Flag37
337 -- Can_Never_Be_Null Flag38
338 -- Has_Default_Aspect Flag39
339 -- Body_Needed_For_SAL Flag40
341 -- Treat_As_Volatile Flag41
342 -- Is_Controlled_Active Flag42
343 -- Has_Controlled_Component Flag43
345 -- In_Private_Part Flag45
346 -- Has_Alignment_Clause Flag46
348 -- In_Package_Body Flag48
350 -- Delay_Subprogram_Descriptors Flag50
353 -- Is_Entry_Formal Flag52
354 -- Is_Private_Descendant Flag53
355 -- Return_Present Flag54
356 -- Is_Tagged_Type Flag55
357 -- Has_Homonym Flag56
359 -- Non_Binary_Modulus Flag58
360 -- Is_Preelaborated Flag59
361 -- Is_Shared_Passive Flag60
363 -- Is_Remote_Types Flag61
364 -- Is_Remote_Call_Interface Flag62
365 -- Is_Character_Type Flag63
366 -- Is_Intrinsic_Subprogram Flag64
367 -- Has_Record_Rep_Clause Flag65
368 -- Has_Enumeration_Rep_Clause Flag66
369 -- Has_Small_Clause Flag67
370 -- Has_Component_Size_Clause Flag68
371 -- Is_Access_Constant Flag69
372 -- Is_First_Subtype Flag70
374 -- Has_Completion_In_Body Flag71
375 -- Has_Unknown_Discriminants Flag72
376 -- Is_Child_Unit Flag73
377 -- Is_CPP_Class Flag74
378 -- Has_Non_Standard_Rep Flag75
379 -- Is_Constructor Flag76
380 -- Static_Elaboration_Desired Flag77
382 -- Has_All_Calls_Remote Flag79
383 -- Is_Constr_Subt_For_U_Nominal Flag80
385 -- Is_Asynchronous Flag81
386 -- Has_Gigi_Rep_Item Flag82
387 -- Has_Machine_Radix_Clause Flag83
388 -- Machine_Radix_10 Flag84
390 -- Has_Atomic_Components Flag86
391 -- Has_Volatile_Components Flag87
392 -- Discard_Names Flag88
393 -- Is_Interrupt_Handler Flag89
394 -- Returns_By_Ref Flag90
397 -- Size_Known_At_Compile_Time Flag92
398 -- Reverse_Storage_Order Flag93
399 -- Is_Generic_Actual_Type Flag94
400 -- Uses_Sec_Stack Flag95
401 -- Warnings_Off Flag96
402 -- Is_Controlling_Formal Flag97
403 -- Has_Controlling_Result Flag98
404 -- Is_Exported Flag99
405 -- Has_Specified_Layout Flag100
407 -- Has_Nested_Block_With_Handler Flag101
409 -- Is_Completely_Hidden Flag103
410 -- Address_Taken Flag104
411 -- Suppress_Initialization Flag105
412 -- Is_Limited_Composite Flag106
413 -- Is_Private_Composite Flag107
414 -- Default_Expressions_Processed Flag108
415 -- Is_Non_Static_Subtype Flag109
416 -- Has_Out_Or_In_Out_Parameter Flag110
418 -- Is_Formal_Subprogram Flag111
419 -- Is_Renaming_Of_Object Flag112
421 -- Delay_Cleanups Flag114
422 -- Never_Set_In_Source Flag115
423 -- Is_Visible_Lib_Unit Flag116
424 -- Is_Unchecked_Union Flag117
425 -- Is_For_Access_Subtype Flag118
426 -- Has_Convention_Pragma Flag119
427 -- Has_Primitive_Operations Flag120
429 -- Has_Pragma_Pack Flag121
430 -- Is_Bit_Packed_Array Flag122
431 -- Has_Unchecked_Union Flag123
432 -- Is_Eliminated Flag124
433 -- C_Pass_By_Copy Flag125
434 -- Is_Instantiated Flag126
435 -- Is_Valued_Procedure Flag127
436 -- (used for Component_Alignment) Flag128
437 -- (used for Component_Alignment) Flag129
438 -- Is_Generic_Instance Flag130
440 -- No_Pool_Assigned Flag131
441 -- Is_DIC_Procedure Flag132
442 -- Has_Inherited_DIC Flag133
443 -- Has_Aliased_Components Flag135
444 -- No_Strict_Aliasing Flag136
445 -- Is_Machine_Code_Subprogram Flag137
446 -- Is_Packed_Array_Impl_Type Flag138
447 -- Has_Biased_Representation Flag139
448 -- Has_Complex_Representation Flag140
450 -- Is_Constr_Subt_For_UN_Aliased Flag141
451 -- Has_Missing_Return Flag142
452 -- Has_Recursive_Call Flag143
453 -- Is_Unsigned_Type Flag144
454 -- Strict_Alignment Flag145
455 -- Is_Abstract_Type Flag146
456 -- Needs_Debug_Info Flag147
457 -- Is_Elaboration_Checks_OK_Id Flag148
458 -- Is_Compilation_Unit Flag149
459 -- Has_Pragma_Elaborate_Body Flag150
461 -- Has_Private_Ancestor Flag151
462 -- Entry_Accepted Flag152
463 -- Is_Obsolescent Flag153
464 -- Has_Per_Object_Constraint Flag154
465 -- Has_Private_Declaration Flag155
466 -- Referenced Flag156
467 -- Has_Pragma_Inline Flag157
468 -- Finalize_Storage_Only Flag158
469 -- From_Limited_With Flag159
470 -- Is_Package_Body_Entity Flag160
472 -- Has_Qualified_Name Flag161
473 -- Nonzero_Is_True Flag162
474 -- Is_True_Constant Flag163
475 -- Reverse_Bit_Order Flag164
476 -- Suppress_Style_Checks Flag165
477 -- Debug_Info_Off Flag166
478 -- Sec_Stack_Needed_For_Return Flag167
479 -- Materialize_Entity Flag168
480 -- Has_Pragma_Thread_Local_Storage Flag169
481 -- Is_Known_Valid Flag170
483 -- Is_Hidden_Open_Scope Flag171
484 -- Has_Object_Size_Clause Flag172
485 -- Has_Fully_Qualified_Name Flag173
486 -- Elaboration_Entity_Required Flag174
487 -- Has_Forward_Instantiation Flag175
488 -- Is_Discrim_SO_Function Flag176
489 -- Size_Depends_On_Discriminant Flag177
490 -- Is_Null_Init_Proc Flag178
491 -- Has_Pragma_Pure_Function Flag179
492 -- Has_Pragma_Unreferenced Flag180
494 -- Has_Contiguous_Rep Flag181
495 -- Has_Xref_Entry Flag182
496 -- Must_Be_On_Byte_Boundary Flag183
497 -- Has_Stream_Size_Clause Flag184
498 -- Is_Ada_2005_Only Flag185
499 -- Is_Interface Flag186
500 -- Has_Constrained_Partial_View Flag187
501 -- Uses_Lock_Free Flag188
502 -- Is_Pure_Unit_Access_Type Flag189
503 -- Has_Specified_Stream_Input Flag190
505 -- Has_Specified_Stream_Output Flag191
506 -- Has_Specified_Stream_Read Flag192
507 -- Has_Specified_Stream_Write Flag193
508 -- Is_Local_Anonymous_Access Flag194
509 -- Is_Primitive_Wrapper Flag195
510 -- Was_Hidden Flag196
511 -- Is_Limited_Interface Flag197
512 -- Has_Pragma_Ordered Flag198
513 -- Is_Ada_2012_Only Flag199
515 -- Has_Delayed_Aspects Flag200
516 -- Has_Pragma_No_Inline Flag201
517 -- Itype_Printed Flag202
518 -- Has_Pragma_Pure Flag203
519 -- Is_Known_Null Flag204
520 -- Low_Bound_Tested Flag205
521 -- Is_Visible_Formal Flag206
522 -- Known_To_Have_Preelab_Init Flag207
523 -- Must_Have_Preelab_Init Flag208
524 -- Is_Return_Object Flag209
525 -- Elaborate_Body_Desirable Flag210
527 -- Has_Static_Discriminants Flag211
528 -- Has_Pragma_Unreferenced_Objects Flag212
529 -- Requires_Overriding Flag213
531 -- Is_Param_Block_Component_Type Flag215
532 -- Universal_Aliasing Flag216
533 -- Suppress_Value_Tracking_On_Call Flag217
534 -- Is_Primitive Flag218
535 -- Has_Initial_Value Flag219
536 -- Has_Dispatch_Table Flag220
538 -- Has_Pragma_Preelab_Init Flag221
539 -- Used_As_Generic_Actual Flag222
540 -- Is_Descendant_Of_Address Flag223
543 -- Is_Only_Out_Parameter Flag226
544 -- Referenced_As_Out_Parameter Flag227
545 -- Has_Thunks Flag228
546 -- Can_Use_Internal_Rep Flag229
547 -- Has_Pragma_Inline_Always Flag230
549 -- Renamed_In_Spec Flag231
550 -- Has_Own_Invariants Flag232
551 -- Has_Pragma_Unmodified Flag233
552 -- Is_Dispatch_Table_Entity Flag234
553 -- Is_Trivial_Subprogram Flag235
554 -- Warnings_Off_Used Flag236
555 -- Warnings_Off_Used_Unmodified Flag237
556 -- Warnings_Off_Used_Unreferenced Flag238
557 -- No_Reordering Flag239
558 -- Has_Expanded_Contract Flag240
560 -- Optimize_Alignment_Space Flag241
561 -- Optimize_Alignment_Time Flag242
562 -- Overlays_Constant Flag243
563 -- Is_RACW_Stub_Type Flag244
564 -- Is_Private_Primitive Flag245
565 -- Is_Underlying_Record_View Flag246
566 -- OK_To_Rename Flag247
567 -- Has_Inheritable_Invariants Flag248
568 -- Is_Safe_To_Reevaluate Flag249
569 -- Has_Predicates Flag250
571 -- Has_Implicit_Dereference Flag251
572 -- Is_Finalized_Transient Flag252
573 -- Disable_Controlled Flag253
574 -- Is_Implementation_Defined Flag254
575 -- Is_Predicate_Function Flag255
576 -- Is_Predicate_Function_M Flag256
577 -- Is_Invariant_Procedure Flag257
578 -- Has_Dynamic_Predicate_Aspect Flag258
579 -- Has_Static_Predicate_Aspect Flag259
580 -- Has_Loop_Entry_Attributes Flag260
582 -- Has_Delayed_Rep_Aspects Flag261
583 -- May_Inherit_Delayed_Rep_Aspects Flag262
584 -- Has_Visible_Refinement Flag263
585 -- Is_Discriminant_Check_Function Flag264
586 -- SPARK_Pragma_Inherited Flag265
587 -- SPARK_Aux_Pragma_Inherited Flag266
588 -- Has_Shift_Operator Flag267
589 -- Is_Independent Flag268
590 -- Has_Static_Predicate Flag269
591 -- Stores_Attribute_Old_Prefix Flag270
593 -- Has_Protected Flag271
594 -- SSO_Set_Low_By_Default Flag272
595 -- SSO_Set_High_By_Default Flag273
596 -- Is_Generic_Actual_Subprogram Flag274
597 -- No_Predicate_On_Actual Flag275
598 -- No_Dynamic_Predicate_On_Actual Flag276
599 -- Is_Checked_Ghost_Entity Flag277
600 -- Is_Ignored_Ghost_Entity Flag278
601 -- Contains_Ignored_Ghost_Code Flag279
602 -- Partial_View_Has_Unknown_Discr Flag280
604 -- Is_Static_Type Flag281
605 -- Has_Nested_Subprogram Flag282
606 -- Is_Uplevel_Referenced_Entity Flag283
607 -- Is_Unimplemented Flag284
608 -- Is_Volatile_Full_Access Flag285
609 -- Is_Exception_Handler Flag286
610 -- Rewritten_For_C Flag287
611 -- Predicates_Ignored Flag288
612 -- Has_Timing_Event Flag289
613 -- Is_Class_Wide_Clone Flag290
615 -- Has_Inherited_Invariants Flag291
616 -- Is_Partial_Invariant_Procedure Flag292
617 -- Is_Actual_Subtype Flag293
618 -- Has_Pragma_Unused Flag294
619 -- Is_Ignored_Transient Flag295
620 -- Has_Partial_Visible_Refinement Flag296
621 -- Is_Entry_Wrapper Flag297
622 -- Is_Underlying_Full_View Flag298
623 -- Body_Needed_For_Inlining Flag299
624 -- Has_Private_Extension Flag300
626 -- Ignore_SPARK_Mode_Pragmas Flag301
627 -- Is_Initial_Condition_Procedure Flag302
628 -- Suppress_Elaboration_Warnings Flag303
637 -- Note: Flag310-317 are defined in atree.ads/adb, but not yet in atree.h
639 -----------------------
640 -- Local subprograms --
641 -----------------------
644 (State_Id
: Entity_Id
;
645 Option_Nam
: Name_Id
) return Boolean;
646 -- Determine whether abstract state State_Id has particular option denoted
647 -- by the name Option_Nam.
653 function Float_Rep
(Id
: E
) return F
is
654 pragma Assert
(Is_Floating_Point_Type
(Id
));
656 return F
'Val (UI_To_Int
(Uint10
(Base_Type
(Id
))));
664 (State_Id
: Entity_Id
;
665 Option_Nam
: Name_Id
) return Boolean
667 Decl
: constant Node_Id
:= Parent
(State_Id
);
672 pragma Assert
(Ekind
(State_Id
) = E_Abstract_State
);
674 -- The declaration of abstract states with options appear as an
675 -- extension aggregate. If this is not the case, the option is not
678 if Nkind
(Decl
) /= N_Extension_Aggregate
then
684 Opt
:= First
(Expressions
(Decl
));
685 while Present
(Opt
) loop
686 if Nkind
(Opt
) = N_Identifier
and then Chars
(Opt
) = Option_Nam
then
693 -- Complex options with various specifiers
695 Opt
:= First
(Component_Associations
(Decl
));
696 while Present
(Opt
) loop
697 Opt_Nam
:= First
(Choices
(Opt
));
699 if Nkind
(Opt_Nam
) = N_Identifier
700 and then Chars
(Opt_Nam
) = Option_Nam
711 --------------------------------
712 -- Attribute Access Functions --
713 --------------------------------
715 function Abstract_States
(Id
: E
) return L
is
717 pragma Assert
(Ekind_In
(Id
, E_Generic_Package
, E_Package
));
721 function Accept_Address
(Id
: E
) return L
is
726 function Access_Disp_Table
(Id
: E
) return L
is
728 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
,
730 E_Record_Type_With_Private
));
731 return Elist16
(Implementation_Base_Type
(Id
));
732 end Access_Disp_Table
;
734 function Access_Disp_Table_Elab_Flag
(Id
: E
) return E
is
736 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
,
738 E_Record_Type_With_Private
));
739 return Node30
(Implementation_Base_Type
(Id
));
740 end Access_Disp_Table_Elab_Flag
;
742 function Activation_Record_Component
(Id
: E
) return E
is
744 pragma Assert
(Ekind_In
(Id
, E_Constant
,
751 end Activation_Record_Component
;
753 function Actual_Subtype
(Id
: E
) return E
is
756 (Ekind_In
(Id
, E_Constant
, E_Variable
, E_Generic_In_Out_Parameter
)
757 or else Is_Formal
(Id
));
761 function Address_Taken
(Id
: E
) return B
is
766 function Alias
(Id
: E
) return E
is
769 (Is_Overloadable
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
773 function Alignment
(Id
: E
) return U
is
775 pragma Assert
(Is_Type
(Id
)
776 or else Is_Formal
(Id
)
777 or else Ekind_In
(Id
, E_Loop_Parameter
,
784 function Anonymous_Designated_Type
(Id
: E
) return E
is
786 pragma Assert
(Ekind
(Id
) = E_Variable
);
788 end Anonymous_Designated_Type
;
790 function Anonymous_Masters
(Id
: E
) return L
is
792 pragma Assert
(Ekind_In
(Id
, E_Function
,
797 end Anonymous_Masters
;
799 function Anonymous_Object
(Id
: E
) return E
is
801 pragma Assert
(Ekind_In
(Id
, E_Protected_Type
, E_Task_Type
));
803 end Anonymous_Object
;
805 function Associated_Entity
(Id
: E
) return E
is
808 end Associated_Entity
;
810 function Associated_Formal_Package
(Id
: E
) return E
is
812 pragma Assert
(Ekind
(Id
) = E_Package
);
814 end Associated_Formal_Package
;
816 function Associated_Node_For_Itype
(Id
: E
) return N
is
819 end Associated_Node_For_Itype
;
821 function Associated_Storage_Pool
(Id
: E
) return E
is
823 pragma Assert
(Is_Access_Type
(Id
));
824 return Node22
(Root_Type
(Id
));
825 end Associated_Storage_Pool
;
827 function Barrier_Function
(Id
: E
) return N
is
829 pragma Assert
(Is_Entry
(Id
));
831 end Barrier_Function
;
833 function Block_Node
(Id
: E
) return N
is
835 pragma Assert
(Ekind
(Id
) = E_Block
);
839 function Body_Entity
(Id
: E
) return E
is
841 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
845 function Body_Needed_For_Inlining
(Id
: E
) return B
is
847 pragma Assert
(Ekind
(Id
) = E_Package
);
849 end Body_Needed_For_Inlining
;
851 function Body_Needed_For_SAL
(Id
: E
) return B
is
854 (Ekind
(Id
) = E_Package
855 or else Is_Subprogram
(Id
)
856 or else Is_Generic_Unit
(Id
));
858 end Body_Needed_For_SAL
;
860 function Body_References
(Id
: E
) return L
is
862 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
866 function BIP_Initialization_Call
(Id
: E
) return N
is
868 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
870 end BIP_Initialization_Call
;
872 function C_Pass_By_Copy
(Id
: E
) return B
is
874 pragma Assert
(Is_Record_Type
(Id
));
875 return Flag125
(Implementation_Base_Type
(Id
));
878 function Can_Never_Be_Null
(Id
: E
) return B
is
881 end Can_Never_Be_Null
;
883 function Checks_May_Be_Suppressed
(Id
: E
) return B
is
886 end Checks_May_Be_Suppressed
;
888 function Class_Wide_Clone
(Id
: E
) return E
is
890 pragma Assert
(Is_Subprogram
(Id
));
892 end Class_Wide_Clone
;
894 function Class_Wide_Type
(Id
: E
) return E
is
896 pragma Assert
(Is_Type
(Id
));
900 function Cloned_Subtype
(Id
: E
) return E
is
902 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
, E_Class_Wide_Subtype
));
906 function Component_Bit_Offset
(Id
: E
) return U
is
908 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
910 end Component_Bit_Offset
;
912 function Component_Clause
(Id
: E
) return N
is
914 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
916 end Component_Clause
;
918 function Component_Size
(Id
: E
) return U
is
920 pragma Assert
(Is_Array_Type
(Id
));
921 return Uint22
(Implementation_Base_Type
(Id
));
924 function Component_Type
(Id
: E
) return E
is
926 pragma Assert
(Is_Array_Type
(Id
));
927 return Node20
(Implementation_Base_Type
(Id
));
930 function Corresponding_Concurrent_Type
(Id
: E
) return E
is
932 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
934 end Corresponding_Concurrent_Type
;
936 function Corresponding_Discriminant
(Id
: E
) return E
is
938 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
940 end Corresponding_Discriminant
;
942 function Corresponding_Equality
(Id
: E
) return E
is
945 (Ekind
(Id
) = E_Function
946 and then not Comes_From_Source
(Id
)
947 and then Chars
(Id
) = Name_Op_Ne
);
949 end Corresponding_Equality
;
951 function Corresponding_Function
(Id
: E
) return E
is
953 pragma Assert
(Ekind
(Id
) = E_Procedure
);
955 end Corresponding_Function
;
957 function Corresponding_Procedure
(Id
: E
) return E
is
959 pragma Assert
(Ekind
(Id
) = E_Function
);
961 end Corresponding_Procedure
;
963 function Corresponding_Protected_Entry
(Id
: E
) return E
is
965 pragma Assert
(Ekind
(Id
) = E_Subprogram_Body
);
967 end Corresponding_Protected_Entry
;
969 function Corresponding_Record_Component
(Id
: E
) return E
is
971 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
973 end Corresponding_Record_Component
;
975 function Corresponding_Record_Type
(Id
: E
) return E
is
977 pragma Assert
(Is_Concurrent_Type
(Id
));
979 end Corresponding_Record_Type
;
981 function Corresponding_Remote_Type
(Id
: E
) return E
is
984 end Corresponding_Remote_Type
;
986 function Current_Use_Clause
(Id
: E
) return E
is
988 pragma Assert
(Ekind
(Id
) = E_Package
or else Is_Type
(Id
));
990 end Current_Use_Clause
;
992 function Current_Value
(Id
: E
) return N
is
994 pragma Assert
(Ekind
(Id
) in Object_Kind
);
998 function CR_Discriminant
(Id
: E
) return E
is
1001 end CR_Discriminant
;
1003 function Debug_Info_Off
(Id
: E
) return B
is
1005 return Flag166
(Id
);
1008 function Debug_Renaming_Link
(Id
: E
) return E
is
1011 end Debug_Renaming_Link
;
1013 function Default_Aspect_Component_Value
(Id
: E
) return N
is
1015 pragma Assert
(Is_Array_Type
(Id
));
1016 return Node19
(Base_Type
(Id
));
1017 end Default_Aspect_Component_Value
;
1019 function Default_Aspect_Value
(Id
: E
) return N
is
1021 pragma Assert
(Is_Scalar_Type
(Id
));
1022 return Node19
(Base_Type
(Id
));
1023 end Default_Aspect_Value
;
1025 function Default_Expr_Function
(Id
: E
) return E
is
1027 pragma Assert
(Is_Formal
(Id
));
1029 end Default_Expr_Function
;
1031 function Default_Expressions_Processed
(Id
: E
) return B
is
1033 return Flag108
(Id
);
1034 end Default_Expressions_Processed
;
1036 function Default_Value
(Id
: E
) return N
is
1038 pragma Assert
(Is_Formal
(Id
));
1042 function Delay_Cleanups
(Id
: E
) return B
is
1044 return Flag114
(Id
);
1047 function Delay_Subprogram_Descriptors
(Id
: E
) return B
is
1050 end Delay_Subprogram_Descriptors
;
1052 function Delta_Value
(Id
: E
) return R
is
1054 pragma Assert
(Is_Fixed_Point_Type
(Id
));
1055 return Ureal18
(Id
);
1058 function Dependent_Instances
(Id
: E
) return L
is
1060 pragma Assert
(Is_Generic_Instance
(Id
));
1062 end Dependent_Instances
;
1064 function Depends_On_Private
(Id
: E
) return B
is
1066 pragma Assert
(Nkind
(Id
) in N_Entity
);
1068 end Depends_On_Private
;
1070 function Derived_Type_Link
(Id
: E
) return E
is
1072 pragma Assert
(Is_Type
(Id
));
1073 return Node31
(Base_Type
(Id
));
1074 end Derived_Type_Link
;
1076 function Digits_Value
(Id
: E
) return U
is
1079 (Is_Floating_Point_Type
(Id
)
1080 or else Is_Decimal_Fixed_Point_Type
(Id
));
1084 function Direct_Primitive_Operations
(Id
: E
) return L
is
1086 pragma Assert
(Is_Tagged_Type
(Id
));
1087 return Elist10
(Id
);
1088 end Direct_Primitive_Operations
;
1090 function Directly_Designated_Type
(Id
: E
) return E
is
1092 pragma Assert
(Is_Access_Type
(Id
));
1094 end Directly_Designated_Type
;
1096 function Disable_Controlled
(Id
: E
) return B
is
1098 return Flag253
(Base_Type
(Id
));
1099 end Disable_Controlled
;
1101 function Discard_Names
(Id
: E
) return B
is
1106 function Discriminal
(Id
: E
) return E
is
1108 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
1112 function Discriminal_Link
(Id
: E
) return N
is
1115 end Discriminal_Link
;
1117 function Discriminant_Checking_Func
(Id
: E
) return E
is
1119 pragma Assert
(Ekind
(Id
) = E_Component
);
1121 end Discriminant_Checking_Func
;
1123 function Discriminant_Constraint
(Id
: E
) return L
is
1125 pragma Assert
(Is_Composite_Type
(Id
) and then Has_Discriminants
(Id
));
1126 return Elist21
(Id
);
1127 end Discriminant_Constraint
;
1129 function Discriminant_Default_Value
(Id
: E
) return N
is
1131 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
1133 end Discriminant_Default_Value
;
1135 function Discriminant_Number
(Id
: E
) return U
is
1137 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
1139 end Discriminant_Number
;
1141 function Dispatch_Table_Wrappers
(Id
: E
) return L
is
1143 pragma Assert
(Ekind_In
(Id
, E_Record_Type
,
1145 return Elist26
(Implementation_Base_Type
(Id
));
1146 end Dispatch_Table_Wrappers
;
1148 function DT_Entry_Count
(Id
: E
) return U
is
1150 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
1154 function DT_Offset_To_Top_Func
(Id
: E
) return E
is
1156 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
1158 end DT_Offset_To_Top_Func
;
1160 function DT_Position
(Id
: E
) return U
is
1162 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
1163 and then Present
(DTC_Entity
(Id
)));
1167 function DTC_Entity
(Id
: E
) return E
is
1169 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
1173 function Elaborate_Body_Desirable
(Id
: E
) return B
is
1175 pragma Assert
(Ekind
(Id
) = E_Package
);
1176 return Flag210
(Id
);
1177 end Elaborate_Body_Desirable
;
1179 function Elaboration_Entity
(Id
: E
) return E
is
1184 Ekind
(Id
) = E_Package
1186 Is_Generic_Unit
(Id
));
1188 end Elaboration_Entity
;
1190 function Elaboration_Entity_Required
(Id
: E
) return B
is
1195 Ekind
(Id
) = E_Package
1197 Is_Generic_Unit
(Id
));
1198 return Flag174
(Id
);
1199 end Elaboration_Entity_Required
;
1201 function Encapsulating_State
(Id
: E
) return N
is
1203 pragma Assert
(Ekind_In
(Id
, E_Abstract_State
, E_Constant
, E_Variable
));
1205 end Encapsulating_State
;
1207 function Enclosing_Scope
(Id
: E
) return E
is
1210 end Enclosing_Scope
;
1212 function Entry_Accepted
(Id
: E
) return B
is
1214 pragma Assert
(Is_Entry
(Id
));
1215 return Flag152
(Id
);
1218 function Entry_Bodies_Array
(Id
: E
) return E
is
1221 end Entry_Bodies_Array
;
1223 function Entry_Cancel_Parameter
(Id
: E
) return E
is
1226 end Entry_Cancel_Parameter
;
1228 function Entry_Component
(Id
: E
) return E
is
1231 end Entry_Component
;
1233 function Entry_Formal
(Id
: E
) return E
is
1238 function Entry_Index_Constant
(Id
: E
) return N
is
1240 pragma Assert
(Ekind
(Id
) = E_Entry_Index_Parameter
);
1242 end Entry_Index_Constant
;
1244 function Entry_Max_Queue_Lengths_Array
(Id
: E
) return N
is
1246 pragma Assert
(Ekind
(Id
) = E_Protected_Type
);
1248 end Entry_Max_Queue_Lengths_Array
;
1250 function Contains_Ignored_Ghost_Code
(Id
: E
) return B
is
1253 (Ekind_In
(Id
, E_Block
,
1257 E_Generic_Procedure
,
1261 E_Subprogram_Body
));
1262 return Flag279
(Id
);
1263 end Contains_Ignored_Ghost_Code
;
1265 function Contract
(Id
: E
) return N
is
1268 (Ekind_In
(Id
, E_Protected_Type
, -- concurrent types
1272 Ekind_In
(Id
, E_Constant
, -- objects
1275 Ekind_In
(Id
, E_Entry
, -- overloadable
1279 E_Generic_Procedure
,
1284 Ekind_In
(Id
, E_Generic_Package
, -- packages
1288 Ekind
(Id
) = E_Void
); -- special purpose
1292 function Contract_Wrapper
(Id
: E
) return E
is
1294 pragma Assert
(Ekind_In
(Id
, E_Entry
, E_Entry_Family
));
1296 end Contract_Wrapper
;
1298 function Entry_Parameters_Type
(Id
: E
) return E
is
1301 end Entry_Parameters_Type
;
1303 function Enum_Pos_To_Rep
(Id
: E
) return E
is
1305 pragma Assert
(Ekind
(Id
) = E_Enumeration_Type
);
1307 end Enum_Pos_To_Rep
;
1309 function Enumeration_Pos
(Id
: E
) return Uint
is
1311 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
1313 end Enumeration_Pos
;
1315 function Enumeration_Rep
(Id
: E
) return U
is
1317 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
1319 end Enumeration_Rep
;
1321 function Enumeration_Rep_Expr
(Id
: E
) return N
is
1323 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
1325 end Enumeration_Rep_Expr
;
1327 function Equivalent_Type
(Id
: E
) return E
is
1330 (Ekind_In
(Id
, E_Class_Wide_Type
,
1331 E_Class_Wide_Subtype
,
1332 E_Access_Subprogram_Type
,
1333 E_Access_Protected_Subprogram_Type
,
1334 E_Anonymous_Access_Protected_Subprogram_Type
,
1335 E_Access_Subprogram_Type
,
1338 end Equivalent_Type
;
1340 function Esize
(Id
: E
) return Uint
is
1345 function Extra_Accessibility
(Id
: E
) return E
is
1348 (Is_Formal
(Id
) or else Ekind_In
(Id
, E_Variable
, E_Constant
));
1350 end Extra_Accessibility
;
1352 function Extra_Accessibility_Of_Result
(Id
: E
) return E
is
1354 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Operator
, E_Subprogram_Type
));
1356 end Extra_Accessibility_Of_Result
;
1358 function Extra_Constrained
(Id
: E
) return E
is
1360 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
1362 end Extra_Constrained
;
1364 function Extra_Formal
(Id
: E
) return E
is
1369 function Extra_Formals
(Id
: E
) return E
is
1372 (Is_Overloadable
(Id
)
1373 or else Ekind_In
(Id
, E_Entry_Family
,
1375 E_Subprogram_Type
));
1379 function Can_Use_Internal_Rep
(Id
: E
) return B
is
1381 pragma Assert
(Is_Access_Subprogram_Type
(Base_Type
(Id
)));
1382 return Flag229
(Base_Type
(Id
));
1383 end Can_Use_Internal_Rep
;
1385 function Finalization_Master
(Id
: E
) return E
is
1387 pragma Assert
(Is_Access_Type
(Id
));
1388 return Node23
(Root_Type
(Id
));
1389 end Finalization_Master
;
1391 function Finalize_Storage_Only
(Id
: E
) return B
is
1393 pragma Assert
(Is_Type
(Id
));
1394 return Flag158
(Base_Type
(Id
));
1395 end Finalize_Storage_Only
;
1397 function Finalizer
(Id
: E
) return E
is
1399 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Package_Body
));
1403 function First_Entity
(Id
: E
) return E
is
1408 function First_Exit_Statement
(Id
: E
) return N
is
1410 pragma Assert
(Ekind
(Id
) = E_Loop
);
1412 end First_Exit_Statement
;
1414 function First_Index
(Id
: E
) return N
is
1416 pragma Assert
(Is_Array_Type
(Id
));
1420 function First_Literal
(Id
: E
) return E
is
1422 pragma Assert
(Is_Enumeration_Type
(Id
));
1426 function First_Private_Entity
(Id
: E
) return E
is
1428 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
)
1429 or else Ekind
(Id
) in Concurrent_Kind
);
1431 end First_Private_Entity
;
1433 function First_Rep_Item
(Id
: E
) return E
is
1438 function Freeze_Node
(Id
: E
) return N
is
1443 function From_Limited_With
(Id
: E
) return B
is
1445 return Flag159
(Id
);
1446 end From_Limited_With
;
1448 function Full_View
(Id
: E
) return E
is
1450 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Constant
);
1454 function Generic_Homonym
(Id
: E
) return E
is
1456 pragma Assert
(Ekind
(Id
) = E_Generic_Package
);
1458 end Generic_Homonym
;
1460 function Generic_Renamings
(Id
: E
) return L
is
1462 return Elist23
(Id
);
1463 end Generic_Renamings
;
1465 function Handler_Records
(Id
: E
) return S
is
1468 end Handler_Records
;
1470 function Has_Aliased_Components
(Id
: E
) return B
is
1472 return Flag135
(Implementation_Base_Type
(Id
));
1473 end Has_Aliased_Components
;
1475 function Has_Alignment_Clause
(Id
: E
) return B
is
1478 end Has_Alignment_Clause
;
1480 function Has_All_Calls_Remote
(Id
: E
) return B
is
1483 end Has_All_Calls_Remote
;
1485 function Has_Atomic_Components
(Id
: E
) return B
is
1487 return Flag86
(Implementation_Base_Type
(Id
));
1488 end Has_Atomic_Components
;
1490 function Has_Biased_Representation
(Id
: E
) return B
is
1492 return Flag139
(Id
);
1493 end Has_Biased_Representation
;
1495 function Has_Completion
(Id
: E
) return B
is
1500 function Has_Completion_In_Body
(Id
: E
) return B
is
1502 pragma Assert
(Is_Type
(Id
));
1504 end Has_Completion_In_Body
;
1506 function Has_Complex_Representation
(Id
: E
) return B
is
1508 pragma Assert
(Is_Record_Type
(Id
));
1509 return Flag140
(Implementation_Base_Type
(Id
));
1510 end Has_Complex_Representation
;
1512 function Has_Component_Size_Clause
(Id
: E
) return B
is
1514 pragma Assert
(Is_Array_Type
(Id
));
1515 return Flag68
(Implementation_Base_Type
(Id
));
1516 end Has_Component_Size_Clause
;
1518 function Has_Constrained_Partial_View
(Id
: E
) return B
is
1520 pragma Assert
(Is_Type
(Id
));
1521 return Flag187
(Id
);
1522 end Has_Constrained_Partial_View
;
1524 function Has_Controlled_Component
(Id
: E
) return B
is
1526 return Flag43
(Base_Type
(Id
));
1527 end Has_Controlled_Component
;
1529 function Has_Contiguous_Rep
(Id
: E
) return B
is
1531 return Flag181
(Id
);
1532 end Has_Contiguous_Rep
;
1534 function Has_Controlling_Result
(Id
: E
) return B
is
1537 end Has_Controlling_Result
;
1539 function Has_Convention_Pragma
(Id
: E
) return B
is
1541 return Flag119
(Id
);
1542 end Has_Convention_Pragma
;
1544 function Has_Default_Aspect
(Id
: E
) return B
is
1546 return Flag39
(Base_Type
(Id
));
1547 end Has_Default_Aspect
;
1549 function Has_Delayed_Aspects
(Id
: E
) return B
is
1551 pragma Assert
(Nkind
(Id
) in N_Entity
);
1552 return Flag200
(Id
);
1553 end Has_Delayed_Aspects
;
1555 function Has_Delayed_Freeze
(Id
: E
) return B
is
1557 pragma Assert
(Nkind
(Id
) in N_Entity
);
1559 end Has_Delayed_Freeze
;
1561 function Has_Delayed_Rep_Aspects
(Id
: E
) return B
is
1563 pragma Assert
(Nkind
(Id
) in N_Entity
);
1564 return Flag261
(Id
);
1565 end Has_Delayed_Rep_Aspects
;
1567 function Has_Discriminants
(Id
: E
) return B
is
1569 pragma Assert
(Nkind
(Id
) in N_Entity
);
1571 end Has_Discriminants
;
1573 function Has_Dispatch_Table
(Id
: E
) return B
is
1575 pragma Assert
(Is_Tagged_Type
(Id
));
1576 return Flag220
(Id
);
1577 end Has_Dispatch_Table
;
1579 function Has_Dynamic_Predicate_Aspect
(Id
: E
) return B
is
1581 pragma Assert
(Is_Type
(Id
));
1582 return Flag258
(Id
);
1583 end Has_Dynamic_Predicate_Aspect
;
1585 function Has_Enumeration_Rep_Clause
(Id
: E
) return B
is
1587 pragma Assert
(Is_Enumeration_Type
(Id
));
1589 end Has_Enumeration_Rep_Clause
;
1591 function Has_Exit
(Id
: E
) return B
is
1596 function Has_Expanded_Contract
(Id
: E
) return B
is
1598 pragma Assert
(Is_Subprogram
(Id
));
1599 return Flag240
(Id
);
1600 end Has_Expanded_Contract
;
1602 function Has_Forward_Instantiation
(Id
: E
) return B
is
1604 return Flag175
(Id
);
1605 end Has_Forward_Instantiation
;
1607 function Has_Fully_Qualified_Name
(Id
: E
) return B
is
1609 return Flag173
(Id
);
1610 end Has_Fully_Qualified_Name
;
1612 function Has_Gigi_Rep_Item
(Id
: E
) return B
is
1615 end Has_Gigi_Rep_Item
;
1617 function Has_Homonym
(Id
: E
) return B
is
1622 function Has_Implicit_Dereference
(Id
: E
) return B
is
1624 return Flag251
(Id
);
1625 end Has_Implicit_Dereference
;
1627 function Has_Independent_Components
(Id
: E
) return B
is
1629 return Flag34
(Implementation_Base_Type
(Id
));
1630 end Has_Independent_Components
;
1632 function Has_Inheritable_Invariants
(Id
: E
) return B
is
1634 pragma Assert
(Is_Type
(Id
));
1635 return Flag248
(Base_Type
(Id
));
1636 end Has_Inheritable_Invariants
;
1638 function Has_Inherited_DIC
(Id
: E
) return B
is
1640 pragma Assert
(Is_Type
(Id
));
1641 return Flag133
(Base_Type
(Id
));
1642 end Has_Inherited_DIC
;
1644 function Has_Inherited_Invariants
(Id
: E
) return B
is
1646 pragma Assert
(Is_Type
(Id
));
1647 return Flag291
(Base_Type
(Id
));
1648 end Has_Inherited_Invariants
;
1650 function Has_Initial_Value
(Id
: E
) return B
is
1652 pragma Assert
(Ekind
(Id
) = E_Variable
or else Is_Formal
(Id
));
1653 return Flag219
(Id
);
1654 end Has_Initial_Value
;
1656 function Has_Loop_Entry_Attributes
(Id
: E
) return B
is
1658 pragma Assert
(Ekind
(Id
) = E_Loop
);
1659 return Flag260
(Id
);
1660 end Has_Loop_Entry_Attributes
;
1662 function Has_Machine_Radix_Clause
(Id
: E
) return B
is
1664 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
1666 end Has_Machine_Radix_Clause
;
1668 function Has_Master_Entity
(Id
: E
) return B
is
1671 end Has_Master_Entity
;
1673 function Has_Missing_Return
(Id
: E
) return B
is
1675 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Generic_Function
));
1676 return Flag142
(Id
);
1677 end Has_Missing_Return
;
1679 function Has_Nested_Block_With_Handler
(Id
: E
) return B
is
1681 return Flag101
(Id
);
1682 end Has_Nested_Block_With_Handler
;
1684 function Has_Nested_Subprogram
(Id
: E
) return B
is
1686 pragma Assert
(Is_Subprogram
(Id
));
1687 return Flag282
(Id
);
1688 end Has_Nested_Subprogram
;
1690 function Has_Non_Standard_Rep
(Id
: E
) return B
is
1692 return Flag75
(Implementation_Base_Type
(Id
));
1693 end Has_Non_Standard_Rep
;
1695 function Has_Object_Size_Clause
(Id
: E
) return B
is
1697 pragma Assert
(Is_Type
(Id
));
1698 return Flag172
(Id
);
1699 end Has_Object_Size_Clause
;
1701 function Has_Out_Or_In_Out_Parameter
(Id
: E
) return B
is
1704 (Ekind_In
(Id
, E_Entry
, E_Entry_Family
)
1705 or else Is_Subprogram_Or_Generic_Subprogram
(Id
));
1706 return Flag110
(Id
);
1707 end Has_Out_Or_In_Out_Parameter
;
1709 function Has_Own_DIC
(Id
: E
) return B
is
1711 pragma Assert
(Is_Type
(Id
));
1712 return Flag3
(Base_Type
(Id
));
1715 function Has_Own_Invariants
(Id
: E
) return B
is
1717 pragma Assert
(Is_Type
(Id
));
1718 return Flag232
(Base_Type
(Id
));
1719 end Has_Own_Invariants
;
1721 function Has_Partial_Visible_Refinement
(Id
: E
) return B
is
1723 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
1724 return Flag296
(Id
);
1725 end Has_Partial_Visible_Refinement
;
1727 function Has_Per_Object_Constraint
(Id
: E
) return B
is
1729 return Flag154
(Id
);
1730 end Has_Per_Object_Constraint
;
1732 function Has_Pragma_Controlled
(Id
: E
) return B
is
1734 pragma Assert
(Is_Access_Type
(Id
));
1735 return Flag27
(Implementation_Base_Type
(Id
));
1736 end Has_Pragma_Controlled
;
1738 function Has_Pragma_Elaborate_Body
(Id
: E
) return B
is
1740 return Flag150
(Id
);
1741 end Has_Pragma_Elaborate_Body
;
1743 function Has_Pragma_Inline
(Id
: E
) return B
is
1745 return Flag157
(Id
);
1746 end Has_Pragma_Inline
;
1748 function Has_Pragma_Inline_Always
(Id
: E
) return B
is
1750 return Flag230
(Id
);
1751 end Has_Pragma_Inline_Always
;
1753 function Has_Pragma_No_Inline
(Id
: E
) return B
is
1755 return Flag201
(Id
);
1756 end Has_Pragma_No_Inline
;
1758 function Has_Pragma_Ordered
(Id
: E
) return B
is
1760 pragma Assert
(Is_Enumeration_Type
(Id
));
1761 return Flag198
(Implementation_Base_Type
(Id
));
1762 end Has_Pragma_Ordered
;
1764 function Has_Pragma_Pack
(Id
: E
) return B
is
1766 pragma Assert
(Is_Record_Type
(Id
) or else Is_Array_Type
(Id
));
1767 return Flag121
(Implementation_Base_Type
(Id
));
1768 end Has_Pragma_Pack
;
1770 function Has_Pragma_Preelab_Init
(Id
: E
) return B
is
1772 return Flag221
(Id
);
1773 end Has_Pragma_Preelab_Init
;
1775 function Has_Pragma_Pure
(Id
: E
) return B
is
1777 return Flag203
(Id
);
1778 end Has_Pragma_Pure
;
1780 function Has_Pragma_Pure_Function
(Id
: E
) return B
is
1782 return Flag179
(Id
);
1783 end Has_Pragma_Pure_Function
;
1785 function Has_Pragma_Thread_Local_Storage
(Id
: E
) return B
is
1787 return Flag169
(Id
);
1788 end Has_Pragma_Thread_Local_Storage
;
1790 function Has_Pragma_Unmodified
(Id
: E
) return B
is
1792 return Flag233
(Id
);
1793 end Has_Pragma_Unmodified
;
1795 function Has_Pragma_Unreferenced
(Id
: E
) return B
is
1797 return Flag180
(Id
);
1798 end Has_Pragma_Unreferenced
;
1800 function Has_Pragma_Unreferenced_Objects
(Id
: E
) return B
is
1802 pragma Assert
(Is_Type
(Id
));
1803 return Flag212
(Id
);
1804 end Has_Pragma_Unreferenced_Objects
;
1806 function Has_Pragma_Unused
(Id
: E
) return B
is
1808 return Flag294
(Id
);
1809 end Has_Pragma_Unused
;
1811 function Has_Predicates
(Id
: E
) return B
is
1813 pragma Assert
(Is_Type
(Id
));
1814 return Flag250
(Id
);
1817 function Has_Primitive_Operations
(Id
: E
) return B
is
1819 pragma Assert
(Is_Type
(Id
));
1820 return Flag120
(Base_Type
(Id
));
1821 end Has_Primitive_Operations
;
1823 function Has_Private_Ancestor
(Id
: E
) return B
is
1825 return Flag151
(Id
);
1826 end Has_Private_Ancestor
;
1828 function Has_Private_Declaration
(Id
: E
) return B
is
1830 return Flag155
(Id
);
1831 end Has_Private_Declaration
;
1833 function Has_Private_Extension
(Id
: E
) return B
is
1835 pragma Assert
(Is_Tagged_Type
(Id
));
1836 return Flag300
(Id
);
1837 end Has_Private_Extension
;
1839 function Has_Protected
(Id
: E
) return B
is
1841 return Flag271
(Base_Type
(Id
));
1844 function Has_Qualified_Name
(Id
: E
) return B
is
1846 return Flag161
(Id
);
1847 end Has_Qualified_Name
;
1849 function Has_RACW
(Id
: E
) return B
is
1851 pragma Assert
(Ekind
(Id
) = E_Package
);
1852 return Flag214
(Id
);
1855 function Has_Record_Rep_Clause
(Id
: E
) return B
is
1857 pragma Assert
(Is_Record_Type
(Id
));
1858 return Flag65
(Implementation_Base_Type
(Id
));
1859 end Has_Record_Rep_Clause
;
1861 function Has_Recursive_Call
(Id
: E
) return B
is
1863 pragma Assert
(Is_Subprogram
(Id
));
1864 return Flag143
(Id
);
1865 end Has_Recursive_Call
;
1867 function Has_Shift_Operator
(Id
: E
) return B
is
1869 pragma Assert
(Is_Integer_Type
(Id
));
1870 return Flag267
(Base_Type
(Id
));
1871 end Has_Shift_Operator
;
1873 function Has_Size_Clause
(Id
: E
) return B
is
1876 end Has_Size_Clause
;
1878 function Has_Small_Clause
(Id
: E
) return B
is
1880 pragma Assert
(Is_Ordinary_Fixed_Point_Type
(Id
));
1882 end Has_Small_Clause
;
1884 function Has_Specified_Layout
(Id
: E
) return B
is
1886 pragma Assert
(Is_Type
(Id
));
1887 return Flag100
(Implementation_Base_Type
(Id
));
1888 end Has_Specified_Layout
;
1890 function Has_Specified_Stream_Input
(Id
: E
) return B
is
1892 pragma Assert
(Is_Type
(Id
));
1893 return Flag190
(Id
);
1894 end Has_Specified_Stream_Input
;
1896 function Has_Specified_Stream_Output
(Id
: E
) return B
is
1898 pragma Assert
(Is_Type
(Id
));
1899 return Flag191
(Id
);
1900 end Has_Specified_Stream_Output
;
1902 function Has_Specified_Stream_Read
(Id
: E
) return B
is
1904 pragma Assert
(Is_Type
(Id
));
1905 return Flag192
(Id
);
1906 end Has_Specified_Stream_Read
;
1908 function Has_Specified_Stream_Write
(Id
: E
) return B
is
1910 pragma Assert
(Is_Type
(Id
));
1911 return Flag193
(Id
);
1912 end Has_Specified_Stream_Write
;
1914 function Has_Static_Discriminants
(Id
: E
) return B
is
1916 pragma Assert
(Is_Type
(Id
));
1917 return Flag211
(Id
);
1918 end Has_Static_Discriminants
;
1920 function Has_Static_Predicate
(Id
: E
) return B
is
1922 pragma Assert
(Is_Type
(Id
));
1923 return Flag269
(Id
);
1924 end Has_Static_Predicate
;
1926 function Has_Static_Predicate_Aspect
(Id
: E
) return B
is
1928 pragma Assert
(Is_Type
(Id
));
1929 return Flag259
(Id
);
1930 end Has_Static_Predicate_Aspect
;
1932 function Has_Storage_Size_Clause
(Id
: E
) return B
is
1934 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
1935 return Flag23
(Implementation_Base_Type
(Id
));
1936 end Has_Storage_Size_Clause
;
1938 function Has_Stream_Size_Clause
(Id
: E
) return B
is
1940 return Flag184
(Id
);
1941 end Has_Stream_Size_Clause
;
1943 function Has_Task
(Id
: E
) return B
is
1945 return Flag30
(Base_Type
(Id
));
1948 function Has_Thunks
(Id
: E
) return B
is
1950 return Flag228
(Id
);
1953 function Has_Timing_Event
(Id
: E
) return B
is
1955 return Flag289
(Base_Type
(Id
));
1956 end Has_Timing_Event
;
1958 function Has_Unchecked_Union
(Id
: E
) return B
is
1960 return Flag123
(Base_Type
(Id
));
1961 end Has_Unchecked_Union
;
1963 function Has_Unknown_Discriminants
(Id
: E
) return B
is
1965 pragma Assert
(Is_Type
(Id
));
1967 end Has_Unknown_Discriminants
;
1969 function Has_Visible_Refinement
(Id
: E
) return B
is
1971 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
1972 return Flag263
(Id
);
1973 end Has_Visible_Refinement
;
1975 function Has_Volatile_Components
(Id
: E
) return B
is
1977 return Flag87
(Implementation_Base_Type
(Id
));
1978 end Has_Volatile_Components
;
1980 function Has_Xref_Entry
(Id
: E
) return B
is
1982 return Flag182
(Id
);
1985 function Hiding_Loop_Variable
(Id
: E
) return E
is
1987 pragma Assert
(Ekind
(Id
) = E_Variable
);
1989 end Hiding_Loop_Variable
;
1991 function Homonym
(Id
: E
) return E
is
1996 function Ignore_SPARK_Mode_Pragmas
(Id
: E
) return B
is
1999 (Ekind_In
(Id
, E_Protected_Body
, -- concurrent types
2004 Ekind_In
(Id
, E_Entry
, -- overloadable
2008 E_Generic_Procedure
,
2013 Ekind_In
(Id
, E_Generic_Package
, -- packages
2016 return Flag301
(Id
);
2017 end Ignore_SPARK_Mode_Pragmas
;
2019 function Import_Pragma
(Id
: E
) return E
is
2021 pragma Assert
(Is_Subprogram
(Id
));
2025 function Incomplete_Actuals
(Id
: E
) return L
is
2027 pragma Assert
(Ekind
(Id
) = E_Package
);
2028 return Elist24
(Id
);
2029 end Incomplete_Actuals
;
2031 function Interface_Alias
(Id
: E
) return E
is
2033 pragma Assert
(Is_Subprogram
(Id
));
2035 end Interface_Alias
;
2037 function Interfaces
(Id
: E
) return L
is
2039 pragma Assert
(Is_Record_Type
(Id
));
2040 return Elist25
(Id
);
2043 function In_Package_Body
(Id
: E
) return B
is
2046 end In_Package_Body
;
2048 function In_Private_Part
(Id
: E
) return B
is
2051 end In_Private_Part
;
2053 function In_Use
(Id
: E
) return B
is
2055 pragma Assert
(Nkind
(Id
) in N_Entity
);
2059 function Initialization_Statements
(Id
: E
) return N
is
2061 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
2063 end Initialization_Statements
;
2065 function Inner_Instances
(Id
: E
) return L
is
2067 return Elist23
(Id
);
2068 end Inner_Instances
;
2070 function Interface_Name
(Id
: E
) return N
is
2075 function Is_Abstract_Subprogram
(Id
: E
) return B
is
2077 pragma Assert
(Is_Overloadable
(Id
));
2079 end Is_Abstract_Subprogram
;
2081 function Is_Abstract_Type
(Id
: E
) return B
is
2083 pragma Assert
(Is_Type
(Id
));
2084 return Flag146
(Id
);
2085 end Is_Abstract_Type
;
2087 function Is_Access_Constant
(Id
: E
) return B
is
2089 pragma Assert
(Is_Access_Type
(Id
));
2091 end Is_Access_Constant
;
2093 function Is_Actual_Subtype
(Id
: E
) return B
is
2095 pragma Assert
(Is_Type
(Id
));
2096 return Flag293
(Id
);
2097 end Is_Actual_Subtype
;
2099 function Is_Ada_2005_Only
(Id
: E
) return B
is
2101 return Flag185
(Id
);
2102 end Is_Ada_2005_Only
;
2104 function Is_Ada_2012_Only
(Id
: E
) return B
is
2106 return Flag199
(Id
);
2107 end Is_Ada_2012_Only
;
2109 function Is_Aliased
(Id
: E
) return B
is
2111 pragma Assert
(Nkind
(Id
) in N_Entity
);
2115 function Is_Asynchronous
(Id
: E
) return B
is
2117 pragma Assert
(Ekind
(Id
) = E_Procedure
or else Is_Type
(Id
));
2119 end Is_Asynchronous
;
2121 function Is_Atomic
(Id
: E
) return B
is
2126 function Is_Bit_Packed_Array
(Id
: E
) return B
is
2128 return Flag122
(Implementation_Base_Type
(Id
));
2129 end Is_Bit_Packed_Array
;
2131 function Is_Called
(Id
: E
) return B
is
2133 pragma Assert
(Ekind_In
(Id
, E_Procedure
, E_Function
));
2134 return Flag102
(Id
);
2137 function Is_Character_Type
(Id
: E
) return B
is
2140 end Is_Character_Type
;
2142 function Is_Checked_Ghost_Entity
(Id
: E
) return B
is
2144 -- Allow this attribute to appear on unanalyzed entities
2146 pragma Assert
(Nkind
(Id
) in N_Entity
2147 or else Ekind
(Id
) = E_Void
);
2148 return Flag277
(Id
);
2149 end Is_Checked_Ghost_Entity
;
2151 function Is_Child_Unit
(Id
: E
) return B
is
2156 function Is_Class_Wide_Clone
(Id
: E
) return B
is
2158 return Flag290
(Id
);
2159 end Is_Class_Wide_Clone
;
2161 function Is_Class_Wide_Equivalent_Type
(Id
: E
) return B
is
2164 end Is_Class_Wide_Equivalent_Type
;
2166 function Is_Compilation_Unit
(Id
: E
) return B
is
2168 return Flag149
(Id
);
2169 end Is_Compilation_Unit
;
2171 function Is_Completely_Hidden
(Id
: E
) return B
is
2173 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
2174 return Flag103
(Id
);
2175 end Is_Completely_Hidden
;
2177 function Is_Constr_Subt_For_U_Nominal
(Id
: E
) return B
is
2180 end Is_Constr_Subt_For_U_Nominal
;
2182 function Is_Constr_Subt_For_UN_Aliased
(Id
: E
) return B
is
2184 return Flag141
(Id
);
2185 end Is_Constr_Subt_For_UN_Aliased
;
2187 function Is_Constrained
(Id
: E
) return B
is
2189 pragma Assert
(Nkind
(Id
) in N_Entity
);
2193 function Is_Constructor
(Id
: E
) return B
is
2198 function Is_Controlled_Active
(Id
: E
) return B
is
2200 return Flag42
(Base_Type
(Id
));
2201 end Is_Controlled_Active
;
2203 function Is_Controlling_Formal
(Id
: E
) return B
is
2205 pragma Assert
(Is_Formal
(Id
));
2207 end Is_Controlling_Formal
;
2209 function Is_CPP_Class
(Id
: E
) return B
is
2214 function Is_DIC_Procedure
(Id
: E
) return B
is
2216 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2217 return Flag132
(Id
);
2218 end Is_DIC_Procedure
;
2220 function Is_Descendant_Of_Address
(Id
: E
) return B
is
2222 return Flag223
(Id
);
2223 end Is_Descendant_Of_Address
;
2225 function Is_Discrim_SO_Function
(Id
: E
) return B
is
2227 return Flag176
(Id
);
2228 end Is_Discrim_SO_Function
;
2230 function Is_Discriminant_Check_Function
(Id
: E
) return B
is
2232 return Flag264
(Id
);
2233 end Is_Discriminant_Check_Function
;
2235 function Is_Dispatch_Table_Entity
(Id
: E
) return B
is
2237 return Flag234
(Id
);
2238 end Is_Dispatch_Table_Entity
;
2240 function Is_Dispatching_Operation
(Id
: E
) return B
is
2242 pragma Assert
(Nkind
(Id
) in N_Entity
);
2244 end Is_Dispatching_Operation
;
2246 function Is_Elaboration_Checks_OK_Id
(Id
: E
) return B
is
2249 (Ekind_In
(Id
, E_Constant
, E_Variable
)
2250 or else Is_Entry
(Id
)
2251 or else Is_Generic_Unit
(Id
)
2252 or else Is_Subprogram
(Id
)
2253 or else Is_Task_Type
(Id
));
2254 return Flag148
(Id
);
2255 end Is_Elaboration_Checks_OK_Id
;
2257 function Is_Eliminated
(Id
: E
) return B
is
2259 return Flag124
(Id
);
2262 function Is_Entry_Formal
(Id
: E
) return B
is
2265 end Is_Entry_Formal
;
2267 function Is_Entry_Wrapper
(Id
: E
) return B
is
2269 return Flag297
(Id
);
2270 end Is_Entry_Wrapper
;
2272 function Is_Exception_Handler
(Id
: E
) return B
is
2274 pragma Assert
(Ekind
(Id
) = E_Block
);
2275 return Flag286
(Id
);
2276 end Is_Exception_Handler
;
2278 function Is_Exported
(Id
: E
) return B
is
2283 function Is_Finalized_Transient
(Id
: E
) return B
is
2285 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Loop_Parameter
, E_Variable
));
2286 return Flag252
(Id
);
2287 end Is_Finalized_Transient
;
2289 function Is_First_Subtype
(Id
: E
) return B
is
2292 end Is_First_Subtype
;
2294 function Is_For_Access_Subtype
(Id
: E
) return B
is
2296 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
, E_Private_Subtype
));
2297 return Flag118
(Id
);
2298 end Is_For_Access_Subtype
;
2300 function Is_Formal_Subprogram
(Id
: E
) return B
is
2302 return Flag111
(Id
);
2303 end Is_Formal_Subprogram
;
2305 function Is_Frozen
(Id
: E
) return B
is
2310 function Is_Generic_Actual_Subprogram
(Id
: E
) return B
is
2312 pragma Assert
(Ekind
(Id
) = E_Function
or else Ekind
(Id
) = E_Procedure
);
2313 return Flag274
(Id
);
2314 end Is_Generic_Actual_Subprogram
;
2316 function Is_Generic_Actual_Type
(Id
: E
) return B
is
2318 pragma Assert
(Is_Type
(Id
));
2320 end Is_Generic_Actual_Type
;
2322 function Is_Generic_Instance
(Id
: E
) return B
is
2324 return Flag130
(Id
);
2325 end Is_Generic_Instance
;
2327 function Is_Generic_Type
(Id
: E
) return B
is
2329 pragma Assert
(Nkind
(Id
) in N_Entity
);
2331 end Is_Generic_Type
;
2333 function Is_Hidden
(Id
: E
) return B
is
2338 function Is_Hidden_Non_Overridden_Subpgm
(Id
: E
) return B
is
2341 end Is_Hidden_Non_Overridden_Subpgm
;
2343 function Is_Hidden_Open_Scope
(Id
: E
) return B
is
2345 return Flag171
(Id
);
2346 end Is_Hidden_Open_Scope
;
2348 function Is_Ignored_Ghost_Entity
(Id
: E
) return B
is
2350 -- Allow this attribute to appear on unanalyzed entities
2352 pragma Assert
(Nkind
(Id
) in N_Entity
2353 or else Ekind
(Id
) = E_Void
);
2354 return Flag278
(Id
);
2355 end Is_Ignored_Ghost_Entity
;
2357 function Is_Ignored_Transient
(Id
: E
) return B
is
2359 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Loop_Parameter
, E_Variable
));
2360 return Flag295
(Id
);
2361 end Is_Ignored_Transient
;
2363 function Is_Immediately_Visible
(Id
: E
) return B
is
2365 pragma Assert
(Nkind
(Id
) in N_Entity
);
2367 end Is_Immediately_Visible
;
2369 function Is_Implementation_Defined
(Id
: E
) return B
is
2371 return Flag254
(Id
);
2372 end Is_Implementation_Defined
;
2374 function Is_Imported
(Id
: E
) return B
is
2379 function Is_Independent
(Id
: E
) return B
is
2381 return Flag268
(Id
);
2384 function Is_Initial_Condition_Procedure
(Id
: E
) return B
is
2386 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2387 return Flag302
(Id
);
2388 end Is_Initial_Condition_Procedure
;
2390 function Is_Inlined
(Id
: E
) return B
is
2395 function Is_Inlined_Always
(Id
: E
) return B
is
2397 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2399 end Is_Inlined_Always
;
2401 function Is_Interface
(Id
: E
) return B
is
2403 return Flag186
(Id
);
2406 function Is_Instantiated
(Id
: E
) return B
is
2408 return Flag126
(Id
);
2409 end Is_Instantiated
;
2411 function Is_Internal
(Id
: E
) return B
is
2413 pragma Assert
(Nkind
(Id
) in N_Entity
);
2417 function Is_Interrupt_Handler
(Id
: E
) return B
is
2419 pragma Assert
(Nkind
(Id
) in N_Entity
);
2421 end Is_Interrupt_Handler
;
2423 function Is_Intrinsic_Subprogram
(Id
: E
) return B
is
2426 end Is_Intrinsic_Subprogram
;
2428 function Is_Invariant_Procedure
(Id
: E
) return B
is
2430 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2431 return Flag257
(Id
);
2432 end Is_Invariant_Procedure
;
2434 function Is_Itype
(Id
: E
) return B
is
2439 function Is_Known_Non_Null
(Id
: E
) return B
is
2442 end Is_Known_Non_Null
;
2444 function Is_Known_Null
(Id
: E
) return B
is
2446 return Flag204
(Id
);
2449 function Is_Known_Valid
(Id
: E
) return B
is
2451 return Flag170
(Id
);
2454 function Is_Limited_Composite
(Id
: E
) return B
is
2456 return Flag106
(Id
);
2457 end Is_Limited_Composite
;
2459 function Is_Limited_Interface
(Id
: E
) return B
is
2461 return Flag197
(Id
);
2462 end Is_Limited_Interface
;
2464 function Is_Limited_Record
(Id
: E
) return B
is
2467 end Is_Limited_Record
;
2469 function Is_Local_Anonymous_Access
(Id
: E
) return B
is
2471 pragma Assert
(Is_Access_Type
(Id
));
2472 return Flag194
(Id
);
2473 end Is_Local_Anonymous_Access
;
2475 function Is_Machine_Code_Subprogram
(Id
: E
) return B
is
2477 pragma Assert
(Is_Subprogram
(Id
));
2478 return Flag137
(Id
);
2479 end Is_Machine_Code_Subprogram
;
2481 function Is_Non_Static_Subtype
(Id
: E
) return B
is
2483 pragma Assert
(Is_Type
(Id
));
2484 return Flag109
(Id
);
2485 end Is_Non_Static_Subtype
;
2487 function Is_Null_Init_Proc
(Id
: E
) return B
is
2489 pragma Assert
(Ekind
(Id
) = E_Procedure
);
2490 return Flag178
(Id
);
2491 end Is_Null_Init_Proc
;
2493 function Is_Obsolescent
(Id
: E
) return B
is
2495 return Flag153
(Id
);
2498 function Is_Only_Out_Parameter
(Id
: E
) return B
is
2500 pragma Assert
(Is_Formal
(Id
));
2501 return Flag226
(Id
);
2502 end Is_Only_Out_Parameter
;
2504 function Is_Package_Body_Entity
(Id
: E
) return B
is
2506 return Flag160
(Id
);
2507 end Is_Package_Body_Entity
;
2509 function Is_Packed
(Id
: E
) return B
is
2511 return Flag51
(Implementation_Base_Type
(Id
));
2514 function Is_Packed_Array_Impl_Type
(Id
: E
) return B
is
2516 return Flag138
(Id
);
2517 end Is_Packed_Array_Impl_Type
;
2519 function Is_Param_Block_Component_Type
(Id
: E
) return B
is
2521 pragma Assert
(Is_Access_Type
(Id
));
2522 return Flag215
(Base_Type
(Id
));
2523 end Is_Param_Block_Component_Type
;
2525 function Is_Partial_Invariant_Procedure
(Id
: E
) return B
is
2527 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2528 return Flag292
(Id
);
2529 end Is_Partial_Invariant_Procedure
;
2531 function Is_Potentially_Use_Visible
(Id
: E
) return B
is
2533 pragma Assert
(Nkind
(Id
) in N_Entity
);
2535 end Is_Potentially_Use_Visible
;
2537 function Is_Predicate_Function
(Id
: E
) return B
is
2539 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2540 return Flag255
(Id
);
2541 end Is_Predicate_Function
;
2543 function Is_Predicate_Function_M
(Id
: E
) return B
is
2545 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2546 return Flag256
(Id
);
2547 end Is_Predicate_Function_M
;
2549 function Is_Preelaborated
(Id
: E
) return B
is
2552 end Is_Preelaborated
;
2554 function Is_Primitive
(Id
: E
) return B
is
2557 (Is_Overloadable
(Id
)
2558 or else Ekind_In
(Id
, E_Generic_Function
, E_Generic_Procedure
));
2559 return Flag218
(Id
);
2562 function Is_Primitive_Wrapper
(Id
: E
) return B
is
2564 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2565 return Flag195
(Id
);
2566 end Is_Primitive_Wrapper
;
2568 function Is_Private_Composite
(Id
: E
) return B
is
2570 pragma Assert
(Is_Type
(Id
));
2571 return Flag107
(Id
);
2572 end Is_Private_Composite
;
2574 function Is_Private_Descendant
(Id
: E
) return B
is
2577 end Is_Private_Descendant
;
2579 function Is_Private_Primitive
(Id
: E
) return B
is
2581 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
2582 return Flag245
(Id
);
2583 end Is_Private_Primitive
;
2585 function Is_Public
(Id
: E
) return B
is
2587 pragma Assert
(Nkind
(Id
) in N_Entity
);
2591 function Is_Pure
(Id
: E
) return B
is
2596 function Is_Pure_Unit_Access_Type
(Id
: E
) return B
is
2598 pragma Assert
(Is_Access_Type
(Id
));
2599 return Flag189
(Id
);
2600 end Is_Pure_Unit_Access_Type
;
2602 function Is_RACW_Stub_Type
(Id
: E
) return B
is
2604 pragma Assert
(Is_Type
(Id
));
2605 return Flag244
(Id
);
2606 end Is_RACW_Stub_Type
;
2608 function Is_Raised
(Id
: E
) return B
is
2610 pragma Assert
(Ekind
(Id
) = E_Exception
);
2611 return Flag224
(Id
);
2614 function Is_Remote_Call_Interface
(Id
: E
) return B
is
2617 end Is_Remote_Call_Interface
;
2619 function Is_Remote_Types
(Id
: E
) return B
is
2622 end Is_Remote_Types
;
2624 function Is_Renaming_Of_Object
(Id
: E
) return B
is
2626 return Flag112
(Id
);
2627 end Is_Renaming_Of_Object
;
2629 function Is_Return_Object
(Id
: E
) return B
is
2631 return Flag209
(Id
);
2632 end Is_Return_Object
;
2634 function Is_Safe_To_Reevaluate
(Id
: E
) return B
is
2636 return Flag249
(Id
);
2637 end Is_Safe_To_Reevaluate
;
2639 function Is_Shared_Passive
(Id
: E
) return B
is
2642 end Is_Shared_Passive
;
2644 function Is_Static_Type
(Id
: E
) return B
is
2646 return Flag281
(Id
);
2649 function Is_Statically_Allocated
(Id
: E
) return B
is
2652 end Is_Statically_Allocated
;
2654 function Is_Tag
(Id
: E
) return B
is
2656 pragma Assert
(Nkind
(Id
) in N_Entity
);
2660 function Is_Tagged_Type
(Id
: E
) return B
is
2665 function Is_Thunk
(Id
: E
) return B
is
2667 return Flag225
(Id
);
2670 function Is_Trivial_Subprogram
(Id
: E
) return B
is
2672 return Flag235
(Id
);
2673 end Is_Trivial_Subprogram
;
2675 function Is_True_Constant
(Id
: E
) return B
is
2677 return Flag163
(Id
);
2678 end Is_True_Constant
;
2680 function Is_Unchecked_Union
(Id
: E
) return B
is
2682 return Flag117
(Implementation_Base_Type
(Id
));
2683 end Is_Unchecked_Union
;
2685 function Is_Underlying_Full_View
(Id
: E
) return B
is
2687 return Flag298
(Id
);
2688 end Is_Underlying_Full_View
;
2690 function Is_Underlying_Record_View
(Id
: E
) return B
is
2692 return Flag246
(Id
);
2693 end Is_Underlying_Record_View
;
2695 function Is_Unimplemented
(Id
: E
) return B
is
2697 return Flag284
(Id
);
2698 end Is_Unimplemented
;
2700 function Is_Unsigned_Type
(Id
: E
) return B
is
2702 pragma Assert
(Is_Type
(Id
));
2703 return Flag144
(Id
);
2704 end Is_Unsigned_Type
;
2706 function Is_Uplevel_Referenced_Entity
(Id
: E
) return B
is
2708 return Flag283
(Id
);
2709 end Is_Uplevel_Referenced_Entity
;
2711 function Is_Valued_Procedure
(Id
: E
) return B
is
2713 pragma Assert
(Ekind
(Id
) = E_Procedure
);
2714 return Flag127
(Id
);
2715 end Is_Valued_Procedure
;
2717 function Is_Visible_Formal
(Id
: E
) return B
is
2719 return Flag206
(Id
);
2720 end Is_Visible_Formal
;
2722 function Is_Visible_Lib_Unit
(Id
: E
) return B
is
2724 return Flag116
(Id
);
2725 end Is_Visible_Lib_Unit
;
2727 function Is_Volatile
(Id
: E
) return B
is
2729 pragma Assert
(Nkind
(Id
) in N_Entity
);
2731 if Is_Type
(Id
) then
2732 return Flag16
(Base_Type
(Id
));
2738 function Is_Volatile_Full_Access
(Id
: E
) return B
is
2740 return Flag285
(Id
);
2741 end Is_Volatile_Full_Access
;
2743 function Itype_Printed
(Id
: E
) return B
is
2745 pragma Assert
(Is_Itype
(Id
));
2746 return Flag202
(Id
);
2749 function Kill_Elaboration_Checks
(Id
: E
) return B
is
2752 end Kill_Elaboration_Checks
;
2754 function Kill_Range_Checks
(Id
: E
) return B
is
2757 end Kill_Range_Checks
;
2759 function Known_To_Have_Preelab_Init
(Id
: E
) return B
is
2761 pragma Assert
(Is_Type
(Id
));
2762 return Flag207
(Id
);
2763 end Known_To_Have_Preelab_Init
;
2765 function Last_Aggregate_Assignment
(Id
: E
) return N
is
2767 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
2769 end Last_Aggregate_Assignment
;
2771 function Last_Assignment
(Id
: E
) return N
is
2773 pragma Assert
(Is_Assignable
(Id
));
2775 end Last_Assignment
;
2777 function Last_Entity
(Id
: E
) return E
is
2782 function Limited_View
(Id
: E
) return E
is
2784 pragma Assert
(Ekind
(Id
) = E_Package
);
2788 function Linker_Section_Pragma
(Id
: E
) return N
is
2791 (Is_Object
(Id
) or else Is_Subprogram
(Id
) or else Is_Type
(Id
));
2793 end Linker_Section_Pragma
;
2795 function Lit_Indexes
(Id
: E
) return E
is
2797 pragma Assert
(Is_Enumeration_Type
(Id
));
2801 function Lit_Strings
(Id
: E
) return E
is
2803 pragma Assert
(Is_Enumeration_Type
(Id
));
2807 function Low_Bound_Tested
(Id
: E
) return B
is
2809 return Flag205
(Id
);
2810 end Low_Bound_Tested
;
2812 function Machine_Radix_10
(Id
: E
) return B
is
2814 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
2816 end Machine_Radix_10
;
2818 function Master_Id
(Id
: E
) return E
is
2820 pragma Assert
(Is_Access_Type
(Id
));
2824 function Materialize_Entity
(Id
: E
) return B
is
2826 return Flag168
(Id
);
2827 end Materialize_Entity
;
2829 function May_Inherit_Delayed_Rep_Aspects
(Id
: E
) return B
is
2831 return Flag262
(Id
);
2832 end May_Inherit_Delayed_Rep_Aspects
;
2834 function Mechanism
(Id
: E
) return M
is
2836 pragma Assert
(Ekind
(Id
) = E_Function
or else Is_Formal
(Id
));
2837 return UI_To_Int
(Uint8
(Id
));
2840 function Modulus
(Id
: E
) return Uint
is
2842 pragma Assert
(Is_Modular_Integer_Type
(Id
));
2843 return Uint17
(Base_Type
(Id
));
2846 function Must_Be_On_Byte_Boundary
(Id
: E
) return B
is
2848 pragma Assert
(Is_Type
(Id
));
2849 return Flag183
(Id
);
2850 end Must_Be_On_Byte_Boundary
;
2852 function Must_Have_Preelab_Init
(Id
: E
) return B
is
2854 pragma Assert
(Is_Type
(Id
));
2855 return Flag208
(Id
);
2856 end Must_Have_Preelab_Init
;
2858 function Needs_Debug_Info
(Id
: E
) return B
is
2860 return Flag147
(Id
);
2861 end Needs_Debug_Info
;
2863 function Needs_No_Actuals
(Id
: E
) return B
is
2866 (Is_Overloadable
(Id
)
2867 or else Ekind_In
(Id
, E_Subprogram_Type
, E_Entry_Family
));
2869 end Needs_No_Actuals
;
2871 function Nested_Scenarios
(Id
: E
) return L
is
2873 pragma Assert
(Ekind_In
(Id
, E_Function
,
2875 E_Subprogram_Body
));
2876 return Elist36
(Id
);
2877 end Nested_Scenarios
;
2879 function Never_Set_In_Source
(Id
: E
) return B
is
2881 return Flag115
(Id
);
2882 end Never_Set_In_Source
;
2884 function Next_Inlined_Subprogram
(Id
: E
) return E
is
2887 end Next_Inlined_Subprogram
;
2889 function No_Dynamic_Predicate_On_Actual
(Id
: E
) return Boolean is
2891 pragma Assert
(Is_Discrete_Type
(Id
));
2892 return Flag276
(Id
);
2893 end No_Dynamic_Predicate_On_Actual
;
2895 function No_Pool_Assigned
(Id
: E
) return B
is
2897 pragma Assert
(Is_Access_Type
(Id
));
2898 return Flag131
(Root_Type
(Id
));
2899 end No_Pool_Assigned
;
2901 function No_Predicate_On_Actual
(Id
: E
) return Boolean is
2903 pragma Assert
(Is_Discrete_Type
(Id
));
2904 return Flag275
(Id
);
2905 end No_Predicate_On_Actual
;
2907 function No_Reordering
(Id
: E
) return B
is
2909 pragma Assert
(Is_Record_Type
(Id
));
2910 return Flag239
(Implementation_Base_Type
(Id
));
2913 function No_Return
(Id
: E
) return B
is
2915 return Flag113
(Id
);
2918 function No_Strict_Aliasing
(Id
: E
) return B
is
2920 pragma Assert
(Is_Access_Type
(Id
));
2921 return Flag136
(Base_Type
(Id
));
2922 end No_Strict_Aliasing
;
2924 function No_Tagged_Streams_Pragma
(Id
: E
) return N
is
2926 pragma Assert
(Is_Tagged_Type
(Id
));
2928 end No_Tagged_Streams_Pragma
;
2930 function Non_Binary_Modulus
(Id
: E
) return B
is
2932 pragma Assert
(Is_Type
(Id
));
2933 return Flag58
(Base_Type
(Id
));
2934 end Non_Binary_Modulus
;
2936 function Non_Limited_View
(Id
: E
) return E
is
2939 (Ekind
(Id
) in Incomplete_Kind
2941 Ekind
(Id
) in Class_Wide_Kind
2943 Ekind
(Id
) = E_Abstract_State
);
2945 end Non_Limited_View
;
2947 function Nonzero_Is_True
(Id
: E
) return B
is
2949 pragma Assert
(Root_Type
(Id
) = Standard_Boolean
);
2950 return Flag162
(Base_Type
(Id
));
2951 end Nonzero_Is_True
;
2953 function Normalized_First_Bit
(Id
: E
) return U
is
2955 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
2957 end Normalized_First_Bit
;
2959 function Normalized_Position
(Id
: E
) return U
is
2961 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
2963 end Normalized_Position
;
2965 function Normalized_Position_Max
(Id
: E
) return U
is
2967 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
2969 end Normalized_Position_Max
;
2971 function OK_To_Rename
(Id
: E
) return B
is
2973 pragma Assert
(Ekind
(Id
) = E_Variable
);
2974 return Flag247
(Id
);
2977 function Optimize_Alignment_Space
(Id
: E
) return B
is
2980 (Is_Type
(Id
) or else Ekind_In
(Id
, E_Constant
, E_Variable
));
2981 return Flag241
(Id
);
2982 end Optimize_Alignment_Space
;
2984 function Optimize_Alignment_Time
(Id
: E
) return B
is
2987 (Is_Type
(Id
) or else Ekind_In
(Id
, E_Constant
, E_Variable
));
2988 return Flag242
(Id
);
2989 end Optimize_Alignment_Time
;
2991 function Original_Access_Type
(Id
: E
) return E
is
2993 pragma Assert
(Ekind
(Id
) = E_Access_Subprogram_Type
);
2995 end Original_Access_Type
;
2997 function Original_Array_Type
(Id
: E
) return E
is
2999 pragma Assert
(Is_Array_Type
(Id
) or else Is_Modular_Integer_Type
(Id
));
3001 end Original_Array_Type
;
3003 function Original_Protected_Subprogram
(Id
: E
) return N
is
3006 end Original_Protected_Subprogram
;
3008 function Original_Record_Component
(Id
: E
) return E
is
3010 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Component
, E_Discriminant
));
3012 end Original_Record_Component
;
3014 function Overlays_Constant
(Id
: E
) return B
is
3016 return Flag243
(Id
);
3017 end Overlays_Constant
;
3019 function Overridden_Operation
(Id
: E
) return E
is
3021 pragma Assert
(Is_Subprogram
(Id
) or else Is_Generic_Subprogram
(Id
));
3023 end Overridden_Operation
;
3025 function Package_Instantiation
(Id
: E
) return N
is
3027 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
3029 end Package_Instantiation
;
3031 function Packed_Array_Impl_Type
(Id
: E
) return E
is
3033 pragma Assert
(Is_Array_Type
(Id
));
3035 end Packed_Array_Impl_Type
;
3037 function Parent_Subtype
(Id
: E
) return E
is
3039 pragma Assert
(Is_Record_Type
(Id
));
3040 return Node19
(Base_Type
(Id
));
3043 function Part_Of_Constituents
(Id
: E
) return L
is
3045 pragma Assert
(Ekind_In
(Id
, E_Abstract_State
, E_Variable
));
3046 return Elist10
(Id
);
3047 end Part_Of_Constituents
;
3049 function Part_Of_References
(Id
: E
) return L
is
3051 pragma Assert
(Ekind
(Id
) = E_Variable
);
3052 return Elist11
(Id
);
3053 end Part_Of_References
;
3055 function Partial_View_Has_Unknown_Discr
(Id
: E
) return B
is
3057 pragma Assert
(Is_Type
(Id
));
3058 return Flag280
(Id
);
3059 end Partial_View_Has_Unknown_Discr
;
3061 function Pending_Access_Types
(Id
: E
) return L
is
3063 pragma Assert
(Is_Type
(Id
));
3064 return Elist15
(Id
);
3065 end Pending_Access_Types
;
3067 function Postconditions_Proc
(Id
: E
) return E
is
3069 pragma Assert
(Ekind_In
(Id
, E_Entry
,
3074 end Postconditions_Proc
;
3076 function Predicates_Ignored
(Id
: E
) return B
is
3078 pragma Assert
(Is_Type
(Id
));
3079 return Flag288
(Id
);
3080 end Predicates_Ignored
;
3082 function Prival
(Id
: E
) return E
is
3084 pragma Assert
(Is_Protected_Component
(Id
));
3088 function Prival_Link
(Id
: E
) return E
is
3090 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
3094 function Private_Dependents
(Id
: E
) return L
is
3096 pragma Assert
(Is_Incomplete_Or_Private_Type
(Id
));
3097 return Elist18
(Id
);
3098 end Private_Dependents
;
3100 function Private_View
(Id
: E
) return N
is
3102 pragma Assert
(Is_Private_Type
(Id
));
3106 function Protected_Body_Subprogram
(Id
: E
) return E
is
3108 pragma Assert
(Is_Subprogram
(Id
) or else Is_Entry
(Id
));
3110 end Protected_Body_Subprogram
;
3112 function Protected_Formal
(Id
: E
) return E
is
3114 pragma Assert
(Is_Formal
(Id
));
3116 end Protected_Formal
;
3118 function Protected_Subprogram
(Id
: E
) return N
is
3120 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
3122 end Protected_Subprogram
;
3124 function Protection_Object
(Id
: E
) return E
is
3126 pragma Assert
(Ekind_In
(Id
, E_Entry
,
3131 end Protection_Object
;
3133 function Reachable
(Id
: E
) return B
is
3138 function Receiving_Entry
(Id
: E
) return E
is
3140 pragma Assert
(Ekind
(Id
) = E_Procedure
);
3142 end Receiving_Entry
;
3144 function Referenced
(Id
: E
) return B
is
3146 return Flag156
(Id
);
3149 function Referenced_As_LHS
(Id
: E
) return B
is
3152 end Referenced_As_LHS
;
3154 function Referenced_As_Out_Parameter
(Id
: E
) return B
is
3156 return Flag227
(Id
);
3157 end Referenced_As_Out_Parameter
;
3159 function Refinement_Constituents
(Id
: E
) return L
is
3161 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
3163 end Refinement_Constituents
;
3165 function Register_Exception_Call
(Id
: E
) return N
is
3167 pragma Assert
(Ekind
(Id
) = E_Exception
);
3169 end Register_Exception_Call
;
3171 function Related_Array_Object
(Id
: E
) return E
is
3173 pragma Assert
(Is_Array_Type
(Id
));
3175 end Related_Array_Object
;
3177 function Related_Expression
(Id
: E
) return N
is
3179 pragma Assert
(Ekind
(Id
) in Type_Kind
3180 or else Ekind_In
(Id
, E_Constant
, E_Variable
));
3182 end Related_Expression
;
3184 function Related_Instance
(Id
: E
) return E
is
3186 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Package_Body
));
3188 end Related_Instance
;
3190 function Related_Type
(Id
: E
) return E
is
3192 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Constant
, E_Variable
));
3196 function Relative_Deadline_Variable
(Id
: E
) return E
is
3198 pragma Assert
(Is_Task_Type
(Id
));
3199 return Node28
(Implementation_Base_Type
(Id
));
3200 end Relative_Deadline_Variable
;
3202 function Renamed_Entity
(Id
: E
) return N
is
3207 function Renamed_In_Spec
(Id
: E
) return B
is
3209 pragma Assert
(Ekind
(Id
) = E_Package
);
3210 return Flag231
(Id
);
3211 end Renamed_In_Spec
;
3213 function Renamed_Object
(Id
: E
) return N
is
3218 function Renaming_Map
(Id
: E
) return U
is
3223 function Requires_Overriding
(Id
: E
) return B
is
3225 pragma Assert
(Is_Overloadable
(Id
));
3226 return Flag213
(Id
);
3227 end Requires_Overriding
;
3229 function Return_Present
(Id
: E
) return B
is
3234 function Return_Applies_To
(Id
: E
) return N
is
3237 end Return_Applies_To
;
3239 function Returns_By_Ref
(Id
: E
) return B
is
3244 function Reverse_Bit_Order
(Id
: E
) return B
is
3246 pragma Assert
(Is_Record_Type
(Id
));
3247 return Flag164
(Base_Type
(Id
));
3248 end Reverse_Bit_Order
;
3250 function Reverse_Storage_Order
(Id
: E
) return B
is
3252 pragma Assert
(Is_Record_Type
(Id
) or else Is_Array_Type
(Id
));
3253 return Flag93
(Base_Type
(Id
));
3254 end Reverse_Storage_Order
;
3256 function Rewritten_For_C
(Id
: E
) return B
is
3258 pragma Assert
(Ekind
(Id
) = E_Function
);
3259 return Flag287
(Id
);
3260 end Rewritten_For_C
;
3262 function RM_Size
(Id
: E
) return U
is
3264 pragma Assert
(Is_Type
(Id
));
3268 function Scalar_Range
(Id
: E
) return N
is
3273 function Scale_Value
(Id
: E
) return U
is
3278 function Scope_Depth_Value
(Id
: E
) return U
is
3281 end Scope_Depth_Value
;
3283 function Sec_Stack_Needed_For_Return
(Id
: E
) return B
is
3285 return Flag167
(Id
);
3286 end Sec_Stack_Needed_For_Return
;
3288 function Shadow_Entities
(Id
: E
) return S
is
3290 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
3292 end Shadow_Entities
;
3294 function Shared_Var_Procs_Instance
(Id
: E
) return E
is
3296 pragma Assert
(Ekind
(Id
) = E_Variable
);
3298 end Shared_Var_Procs_Instance
;
3300 function Size_Check_Code
(Id
: E
) return N
is
3302 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
3304 end Size_Check_Code
;
3306 function Size_Depends_On_Discriminant
(Id
: E
) return B
is
3308 return Flag177
(Id
);
3309 end Size_Depends_On_Discriminant
;
3311 function Size_Known_At_Compile_Time
(Id
: E
) return B
is
3314 end Size_Known_At_Compile_Time
;
3316 function Small_Value
(Id
: E
) return R
is
3318 pragma Assert
(Is_Fixed_Point_Type
(Id
));
3319 return Ureal21
(Id
);
3322 function SPARK_Aux_Pragma
(Id
: E
) return N
is
3325 (Ekind_In
(Id
, E_Protected_Type
, -- concurrent types
3328 Ekind_In
(Id
, E_Generic_Package
, -- packages
3332 end SPARK_Aux_Pragma
;
3334 function SPARK_Aux_Pragma_Inherited
(Id
: E
) return B
is
3337 (Ekind_In
(Id
, E_Protected_Type
, -- concurrent types
3340 Ekind_In
(Id
, E_Generic_Package
, -- packages
3343 return Flag266
(Id
);
3344 end SPARK_Aux_Pragma_Inherited
;
3346 function SPARK_Pragma
(Id
: E
) return N
is
3349 (Ekind_In
(Id
, E_Constant
, -- objects
3352 Ekind_In
(Id
, E_Abstract_State
, -- overloadable
3357 E_Generic_Procedure
,
3362 Ekind_In
(Id
, E_Generic_Package
, -- packages
3366 Ekind
(Id
) = E_Void
-- special purpose
3368 Ekind_In
(Id
, E_Protected_Body
, -- types
3375 function SPARK_Pragma_Inherited
(Id
: E
) return B
is
3378 (Ekind_In
(Id
, E_Constant
, -- objects
3381 Ekind_In
(Id
, E_Abstract_State
, -- overloadable
3386 E_Generic_Procedure
,
3391 Ekind_In
(Id
, E_Generic_Package
, -- packages
3395 Ekind
(Id
) = E_Void
-- special purpose
3397 Ekind_In
(Id
, E_Protected_Body
, -- types
3401 return Flag265
(Id
);
3402 end SPARK_Pragma_Inherited
;
3404 function Spec_Entity
(Id
: E
) return E
is
3406 pragma Assert
(Ekind
(Id
) = E_Package_Body
or else Is_Formal
(Id
));
3410 function SSO_Set_High_By_Default
(Id
: E
) return B
is
3412 pragma Assert
(Is_Record_Type
(Id
) or else Is_Array_Type
(Id
));
3413 return Flag273
(Base_Type
(Id
));
3414 end SSO_Set_High_By_Default
;
3416 function SSO_Set_Low_By_Default
(Id
: E
) return B
is
3418 pragma Assert
(Is_Record_Type
(Id
) or else Is_Array_Type
(Id
));
3419 return Flag272
(Base_Type
(Id
));
3420 end SSO_Set_Low_By_Default
;
3422 function Static_Discrete_Predicate
(Id
: E
) return S
is
3424 pragma Assert
(Is_Discrete_Type
(Id
));
3426 end Static_Discrete_Predicate
;
3428 function Static_Real_Or_String_Predicate
(Id
: E
) return N
is
3430 pragma Assert
(Is_Real_Type
(Id
) or else Is_String_Type
(Id
));
3432 end Static_Real_Or_String_Predicate
;
3434 function Status_Flag_Or_Transient_Decl
(Id
: E
) return N
is
3436 pragma Assert
(Ekind_In
(Id
, E_Constant
,
3440 end Status_Flag_Or_Transient_Decl
;
3442 function Storage_Size_Variable
(Id
: E
) return E
is
3444 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
3445 return Node26
(Implementation_Base_Type
(Id
));
3446 end Storage_Size_Variable
;
3448 function Static_Elaboration_Desired
(Id
: E
) return B
is
3450 pragma Assert
(Ekind
(Id
) = E_Package
);
3452 end Static_Elaboration_Desired
;
3454 function Static_Initialization
(Id
: E
) return N
is
3457 (Ekind
(Id
) = E_Procedure
and then not Is_Dispatching_Operation
(Id
));
3459 end Static_Initialization
;
3461 function Stored_Constraint
(Id
: E
) return L
is
3464 (Is_Composite_Type
(Id
) and then not Is_Array_Type
(Id
));
3465 return Elist23
(Id
);
3466 end Stored_Constraint
;
3468 function Stores_Attribute_Old_Prefix
(Id
: E
) return B
is
3470 return Flag270
(Id
);
3471 end Stores_Attribute_Old_Prefix
;
3473 function Strict_Alignment
(Id
: E
) return B
is
3475 return Flag145
(Implementation_Base_Type
(Id
));
3476 end Strict_Alignment
;
3478 function String_Literal_Length
(Id
: E
) return U
is
3481 end String_Literal_Length
;
3483 function String_Literal_Low_Bound
(Id
: E
) return N
is
3486 end String_Literal_Low_Bound
;
3488 function Subprograms_For_Type
(Id
: E
) return L
is
3490 pragma Assert
(Is_Type
(Id
));
3491 return Elist29
(Id
);
3492 end Subprograms_For_Type
;
3494 function Subps_Index
(Id
: E
) return U
is
3496 pragma Assert
(Is_Subprogram
(Id
));
3500 function Suppress_Elaboration_Warnings
(Id
: E
) return B
is
3502 return Flag303
(Id
);
3503 end Suppress_Elaboration_Warnings
;
3505 function Suppress_Initialization
(Id
: E
) return B
is
3507 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Variable
);
3508 return Flag105
(Id
);
3509 end Suppress_Initialization
;
3511 function Suppress_Style_Checks
(Id
: E
) return B
is
3513 return Flag165
(Id
);
3514 end Suppress_Style_Checks
;
3516 function Suppress_Value_Tracking_On_Call
(Id
: E
) return B
is
3518 return Flag217
(Id
);
3519 end Suppress_Value_Tracking_On_Call
;
3521 function Task_Body_Procedure
(Id
: E
) return N
is
3523 pragma Assert
(Ekind
(Id
) in Task_Kind
);
3525 end Task_Body_Procedure
;
3527 function Thunk_Entity
(Id
: E
) return E
is
3529 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
3530 and then Is_Thunk
(Id
));
3534 function Treat_As_Volatile
(Id
: E
) return B
is
3537 end Treat_As_Volatile
;
3539 function Underlying_Full_View
(Id
: E
) return E
is
3541 pragma Assert
(Ekind
(Id
) in Private_Kind
);
3543 end Underlying_Full_View
;
3545 function Underlying_Record_View
(Id
: E
) return E
is
3548 end Underlying_Record_View
;
3550 function Universal_Aliasing
(Id
: E
) return B
is
3552 pragma Assert
(Is_Type
(Id
));
3553 return Flag216
(Implementation_Base_Type
(Id
));
3554 end Universal_Aliasing
;
3556 function Unset_Reference
(Id
: E
) return N
is
3559 end Unset_Reference
;
3561 function Used_As_Generic_Actual
(Id
: E
) return B
is
3563 return Flag222
(Id
);
3564 end Used_As_Generic_Actual
;
3566 function Uses_Lock_Free
(Id
: E
) return B
is
3568 pragma Assert
(Is_Protected_Type
(Id
));
3569 return Flag188
(Id
);
3572 function Uses_Sec_Stack
(Id
: E
) return B
is
3577 function Validated_Object
(Id
: E
) return N
is
3579 pragma Assert
(Ekind
(Id
) = E_Variable
);
3581 end Validated_Object
;
3583 function Warnings_Off
(Id
: E
) return B
is
3588 function Warnings_Off_Used
(Id
: E
) return B
is
3590 return Flag236
(Id
);
3591 end Warnings_Off_Used
;
3593 function Warnings_Off_Used_Unmodified
(Id
: E
) return B
is
3595 return Flag237
(Id
);
3596 end Warnings_Off_Used_Unmodified
;
3598 function Warnings_Off_Used_Unreferenced
(Id
: E
) return B
is
3600 return Flag238
(Id
);
3601 end Warnings_Off_Used_Unreferenced
;
3603 function Wrapped_Entity
(Id
: E
) return E
is
3605 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
3606 and then Is_Primitive_Wrapper
(Id
));
3610 function Was_Hidden
(Id
: E
) return B
is
3612 return Flag196
(Id
);
3615 ------------------------------
3616 -- Classification Functions --
3617 ------------------------------
3619 function Is_Access_Type
(Id
: E
) return B
is
3621 return Ekind
(Id
) in Access_Kind
;
3624 function Is_Access_Protected_Subprogram_Type
(Id
: E
) return B
is
3626 return Ekind
(Id
) in Access_Protected_Kind
;
3627 end Is_Access_Protected_Subprogram_Type
;
3629 function Is_Access_Subprogram_Type
(Id
: E
) return B
is
3631 return Ekind
(Id
) in Access_Subprogram_Kind
;
3632 end Is_Access_Subprogram_Type
;
3634 function Is_Aggregate_Type
(Id
: E
) return B
is
3636 return Ekind
(Id
) in Aggregate_Kind
;
3637 end Is_Aggregate_Type
;
3639 function Is_Anonymous_Access_Type
(Id
: E
) return B
is
3641 return Ekind
(Id
) in Anonymous_Access_Kind
;
3642 end Is_Anonymous_Access_Type
;
3644 function Is_Array_Type
(Id
: E
) return B
is
3646 return Ekind
(Id
) in Array_Kind
;
3649 function Is_Assignable
(Id
: E
) return B
is
3651 return Ekind
(Id
) in Assignable_Kind
;
3654 function Is_Class_Wide_Type
(Id
: E
) return B
is
3656 return Ekind
(Id
) in Class_Wide_Kind
;
3657 end Is_Class_Wide_Type
;
3659 function Is_Composite_Type
(Id
: E
) return B
is
3661 return Ekind
(Id
) in Composite_Kind
;
3662 end Is_Composite_Type
;
3664 function Is_Concurrent_Body
(Id
: E
) return B
is
3666 return Ekind
(Id
) in Concurrent_Body_Kind
;
3667 end Is_Concurrent_Body
;
3669 function Is_Concurrent_Record_Type
(Id
: E
) return B
is
3672 end Is_Concurrent_Record_Type
;
3674 function Is_Concurrent_Type
(Id
: E
) return B
is
3676 return Ekind
(Id
) in Concurrent_Kind
;
3677 end Is_Concurrent_Type
;
3679 function Is_Decimal_Fixed_Point_Type
(Id
: E
) return B
is
3681 return Ekind
(Id
) in Decimal_Fixed_Point_Kind
;
3682 end Is_Decimal_Fixed_Point_Type
;
3684 function Is_Digits_Type
(Id
: E
) return B
is
3686 return Ekind
(Id
) in Digits_Kind
;
3689 function Is_Discrete_Or_Fixed_Point_Type
(Id
: E
) return B
is
3691 return Ekind
(Id
) in Discrete_Or_Fixed_Point_Kind
;
3692 end Is_Discrete_Or_Fixed_Point_Type
;
3694 function Is_Discrete_Type
(Id
: E
) return B
is
3696 return Ekind
(Id
) in Discrete_Kind
;
3697 end Is_Discrete_Type
;
3699 function Is_Elementary_Type
(Id
: E
) return B
is
3701 return Ekind
(Id
) in Elementary_Kind
;
3702 end Is_Elementary_Type
;
3704 function Is_Entry
(Id
: E
) return B
is
3706 return Ekind
(Id
) in Entry_Kind
;
3709 function Is_Enumeration_Type
(Id
: E
) return B
is
3711 return Ekind
(Id
) in Enumeration_Kind
;
3712 end Is_Enumeration_Type
;
3714 function Is_Fixed_Point_Type
(Id
: E
) return B
is
3716 return Ekind
(Id
) in Fixed_Point_Kind
;
3717 end Is_Fixed_Point_Type
;
3719 function Is_Floating_Point_Type
(Id
: E
) return B
is
3721 return Ekind
(Id
) in Float_Kind
;
3722 end Is_Floating_Point_Type
;
3724 function Is_Formal
(Id
: E
) return B
is
3726 return Ekind
(Id
) in Formal_Kind
;
3729 function Is_Formal_Object
(Id
: E
) return B
is
3731 return Ekind
(Id
) in Formal_Object_Kind
;
3732 end Is_Formal_Object
;
3734 function Is_Generic_Subprogram
(Id
: E
) return B
is
3736 return Ekind
(Id
) in Generic_Subprogram_Kind
;
3737 end Is_Generic_Subprogram
;
3739 function Is_Generic_Unit
(Id
: E
) return B
is
3741 return Ekind
(Id
) in Generic_Unit_Kind
;
3742 end Is_Generic_Unit
;
3744 function Is_Ghost_Entity
(Id
: Entity_Id
) return Boolean is
3746 return Is_Checked_Ghost_Entity
(Id
) or else Is_Ignored_Ghost_Entity
(Id
);
3747 end Is_Ghost_Entity
;
3749 function Is_Incomplete_Or_Private_Type
(Id
: E
) return B
is
3751 return Ekind
(Id
) in Incomplete_Or_Private_Kind
;
3752 end Is_Incomplete_Or_Private_Type
;
3754 function Is_Incomplete_Type
(Id
: E
) return B
is
3756 return Ekind
(Id
) in Incomplete_Kind
;
3757 end Is_Incomplete_Type
;
3759 function Is_Integer_Type
(Id
: E
) return B
is
3761 return Ekind
(Id
) in Integer_Kind
;
3762 end Is_Integer_Type
;
3764 function Is_Modular_Integer_Type
(Id
: E
) return B
is
3766 return Ekind
(Id
) in Modular_Integer_Kind
;
3767 end Is_Modular_Integer_Type
;
3769 function Is_Named_Number
(Id
: E
) return B
is
3771 return Ekind
(Id
) in Named_Kind
;
3772 end Is_Named_Number
;
3774 function Is_Numeric_Type
(Id
: E
) return B
is
3776 return Ekind
(Id
) in Numeric_Kind
;
3777 end Is_Numeric_Type
;
3779 function Is_Object
(Id
: E
) return B
is
3781 return Ekind
(Id
) in Object_Kind
;
3784 function Is_Ordinary_Fixed_Point_Type
(Id
: E
) return B
is
3786 return Ekind
(Id
) in Ordinary_Fixed_Point_Kind
;
3787 end Is_Ordinary_Fixed_Point_Type
;
3789 function Is_Overloadable
(Id
: E
) return B
is
3791 return Ekind
(Id
) in Overloadable_Kind
;
3792 end Is_Overloadable
;
3794 function Is_Private_Type
(Id
: E
) return B
is
3796 return Ekind
(Id
) in Private_Kind
;
3797 end Is_Private_Type
;
3799 function Is_Protected_Type
(Id
: E
) return B
is
3801 return Ekind
(Id
) in Protected_Kind
;
3802 end Is_Protected_Type
;
3804 function Is_Real_Type
(Id
: E
) return B
is
3806 return Ekind
(Id
) in Real_Kind
;
3809 function Is_Record_Type
(Id
: E
) return B
is
3811 return Ekind
(Id
) in Record_Kind
;
3814 function Is_Scalar_Type
(Id
: E
) return B
is
3816 return Ekind
(Id
) in Scalar_Kind
;
3819 function Is_Signed_Integer_Type
(Id
: E
) return B
is
3821 return Ekind
(Id
) in Signed_Integer_Kind
;
3822 end Is_Signed_Integer_Type
;
3824 function Is_Subprogram
(Id
: E
) return B
is
3826 return Ekind
(Id
) in Subprogram_Kind
;
3829 function Is_Subprogram_Or_Entry
(Id
: E
) return B
is
3831 return Ekind
(Id
) in Subprogram_Kind
3833 Ekind
(Id
) in Entry_Kind
;
3834 end Is_Subprogram_Or_Entry
;
3836 function Is_Subprogram_Or_Generic_Subprogram
(Id
: E
) return B
is
3838 return Ekind
(Id
) in Subprogram_Kind
3840 Ekind
(Id
) in Generic_Subprogram_Kind
;
3841 end Is_Subprogram_Or_Generic_Subprogram
;
3843 function Is_Task_Type
(Id
: E
) return B
is
3845 return Ekind
(Id
) in Task_Kind
;
3848 function Is_Type
(Id
: E
) return B
is
3850 return Ekind
(Id
) in Type_Kind
;
3853 ------------------------------
3854 -- Attribute Set Procedures --
3855 ------------------------------
3857 -- Note: in many of these set procedures an "obvious" assertion is missing.
3858 -- The reason for this is that in many cases, a field is set before the
3859 -- Ekind field is set, so that the field is set when Ekind = E_Void. It
3860 -- it is possible to add assertions that specifically include the E_Void
3861 -- possibility, but in some cases, we just omit the assertions.
3863 procedure Set_Abstract_States
(Id
: E
; V
: L
) is
3865 pragma Assert
(Ekind_In
(Id
, E_Generic_Package
, E_Package
));
3866 Set_Elist25
(Id
, V
);
3867 end Set_Abstract_States
;
3869 procedure Set_Accept_Address
(Id
: E
; V
: L
) is
3871 Set_Elist21
(Id
, V
);
3872 end Set_Accept_Address
;
3874 procedure Set_Access_Disp_Table
(Id
: E
; V
: L
) is
3876 pragma Assert
(Ekind
(Id
) = E_Record_Type
3877 and then Id
= Implementation_Base_Type
(Id
));
3878 pragma Assert
(V
= No_Elist
or else Is_Tagged_Type
(Id
));
3879 Set_Elist16
(Id
, V
);
3880 end Set_Access_Disp_Table
;
3882 procedure Set_Access_Disp_Table_Elab_Flag
(Id
: E
; V
: E
) is
3884 pragma Assert
(Ekind
(Id
) = E_Record_Type
3885 and then Id
= Implementation_Base_Type
(Id
));
3886 pragma Assert
(Is_Tagged_Type
(Id
));
3888 end Set_Access_Disp_Table_Elab_Flag
;
3890 procedure Set_Anonymous_Designated_Type
(Id
: E
; V
: E
) is
3892 pragma Assert
(Ekind
(Id
) = E_Variable
);
3894 end Set_Anonymous_Designated_Type
;
3896 procedure Set_Anonymous_Masters
(Id
: E
; V
: L
) is
3898 pragma Assert
(Ekind_In
(Id
, E_Function
,
3901 E_Subprogram_Body
));
3902 Set_Elist29
(Id
, V
);
3903 end Set_Anonymous_Masters
;
3905 procedure Set_Anonymous_Object
(Id
: E
; V
: E
) is
3907 pragma Assert
(Ekind_In
(Id
, E_Protected_Type
, E_Task_Type
));
3909 end Set_Anonymous_Object
;
3911 procedure Set_Associated_Entity
(Id
: E
; V
: E
) is
3914 end Set_Associated_Entity
;
3916 procedure Set_Associated_Formal_Package
(Id
: E
; V
: E
) is
3919 end Set_Associated_Formal_Package
;
3921 procedure Set_Associated_Node_For_Itype
(Id
: E
; V
: E
) is
3924 end Set_Associated_Node_For_Itype
;
3926 procedure Set_Associated_Storage_Pool
(Id
: E
; V
: E
) is
3928 pragma Assert
(Is_Access_Type
(Id
) and then Is_Base_Type
(Id
));
3930 end Set_Associated_Storage_Pool
;
3932 procedure Set_Activation_Record_Component
(Id
: E
; V
: E
) is
3934 pragma Assert
(Ekind_In
(Id
, E_Constant
,
3941 end Set_Activation_Record_Component
;
3943 procedure Set_Actual_Subtype
(Id
: E
; V
: E
) is
3946 (Ekind_In
(Id
, E_Constant
, E_Variable
, E_Generic_In_Out_Parameter
)
3947 or else Is_Formal
(Id
));
3949 end Set_Actual_Subtype
;
3951 procedure Set_Address_Taken
(Id
: E
; V
: B
:= True) is
3953 Set_Flag104
(Id
, V
);
3954 end Set_Address_Taken
;
3956 procedure Set_Alias
(Id
: E
; V
: E
) is
3959 (Is_Overloadable
(Id
) or else Ekind
(Id
) = E_Subprogram_Type
);
3963 procedure Set_Alignment
(Id
: E
; V
: U
) is
3965 pragma Assert
(Is_Type
(Id
)
3966 or else Is_Formal
(Id
)
3967 or else Ekind_In
(Id
, E_Loop_Parameter
,
3974 procedure Set_Barrier_Function
(Id
: E
; V
: N
) is
3976 pragma Assert
(Is_Entry
(Id
));
3978 end Set_Barrier_Function
;
3980 procedure Set_Block_Node
(Id
: E
; V
: N
) is
3982 pragma Assert
(Ekind
(Id
) = E_Block
);
3986 procedure Set_Body_Entity
(Id
: E
; V
: E
) is
3988 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
3990 end Set_Body_Entity
;
3992 procedure Set_Body_Needed_For_Inlining
(Id
: E
; V
: B
:= True) is
3994 pragma Assert
(Ekind
(Id
) = E_Package
);
3995 Set_Flag299
(Id
, V
);
3996 end Set_Body_Needed_For_Inlining
;
3998 procedure Set_Body_Needed_For_SAL
(Id
: E
; V
: B
:= True) is
4001 (Ekind
(Id
) = E_Package
4002 or else Is_Subprogram
(Id
)
4003 or else Is_Generic_Unit
(Id
));
4005 end Set_Body_Needed_For_SAL
;
4007 procedure Set_Body_References
(Id
: E
; V
: L
) is
4009 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
4010 Set_Elist16
(Id
, V
);
4011 end Set_Body_References
;
4013 procedure Set_BIP_Initialization_Call
(Id
: E
; V
: N
) is
4015 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
4017 end Set_BIP_Initialization_Call
;
4019 procedure Set_C_Pass_By_Copy
(Id
: E
; V
: B
:= True) is
4021 pragma Assert
(Is_Record_Type
(Id
) and then Is_Base_Type
(Id
));
4022 Set_Flag125
(Id
, V
);
4023 end Set_C_Pass_By_Copy
;
4025 procedure Set_Can_Never_Be_Null
(Id
: E
; V
: B
:= True) is
4028 end Set_Can_Never_Be_Null
;
4030 procedure Set_Can_Use_Internal_Rep
(Id
: E
; V
: B
:= True) is
4033 (Is_Access_Subprogram_Type
(Id
) and then Is_Base_Type
(Id
));
4034 Set_Flag229
(Id
, V
);
4035 end Set_Can_Use_Internal_Rep
;
4037 procedure Set_Checks_May_Be_Suppressed
(Id
: E
; V
: B
:= True) is
4040 end Set_Checks_May_Be_Suppressed
;
4042 procedure Set_Class_Wide_Clone
(Id
: E
; V
: E
) is
4044 pragma Assert
(Is_Subprogram
(Id
));
4046 end Set_Class_Wide_Clone
;
4048 procedure Set_Class_Wide_Type
(Id
: E
; V
: E
) is
4050 pragma Assert
(Is_Type
(Id
));
4052 end Set_Class_Wide_Type
;
4054 procedure Set_Cloned_Subtype
(Id
: E
; V
: E
) is
4056 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
, E_Class_Wide_Subtype
));
4058 end Set_Cloned_Subtype
;
4060 procedure Set_Component_Bit_Offset
(Id
: E
; V
: U
) is
4062 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
4064 end Set_Component_Bit_Offset
;
4066 procedure Set_Component_Clause
(Id
: E
; V
: N
) is
4068 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
4070 end Set_Component_Clause
;
4072 procedure Set_Component_Size
(Id
: E
; V
: U
) is
4074 pragma Assert
(Is_Array_Type
(Id
) and then Is_Base_Type
(Id
));
4076 end Set_Component_Size
;
4078 procedure Set_Component_Type
(Id
: E
; V
: E
) is
4080 pragma Assert
(Is_Array_Type
(Id
) and then Is_Base_Type
(Id
));
4082 end Set_Component_Type
;
4084 procedure Set_Contains_Ignored_Ghost_Code
(Id
: E
; V
: B
:= True) is
4087 (Ekind_In
(Id
, E_Block
,
4091 E_Generic_Procedure
,
4095 E_Subprogram_Body
));
4096 Set_Flag279
(Id
, V
);
4097 end Set_Contains_Ignored_Ghost_Code
;
4099 procedure Set_Contract
(Id
: E
; V
: N
) is
4102 (Ekind_In
(Id
, E_Protected_Type
, -- concurrent types
4106 Ekind_In
(Id
, E_Constant
, -- objects
4109 Ekind_In
(Id
, E_Entry
, -- overloadable
4113 E_Generic_Procedure
,
4118 Ekind_In
(Id
, E_Generic_Package
, -- packages
4122 Ekind
(Id
) = E_Void
); -- special purpose
4126 procedure Set_Contract_Wrapper
(Id
: E
; V
: E
) is
4128 pragma Assert
(Ekind_In
(Id
, E_Entry
, E_Entry_Family
));
4130 end Set_Contract_Wrapper
;
4132 procedure Set_Corresponding_Concurrent_Type
(Id
: E
; V
: E
) is
4135 (Ekind
(Id
) = E_Record_Type
and then Is_Concurrent_Type
(V
));
4137 end Set_Corresponding_Concurrent_Type
;
4139 procedure Set_Corresponding_Discriminant
(Id
: E
; V
: E
) is
4141 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
4143 end Set_Corresponding_Discriminant
;
4145 procedure Set_Corresponding_Equality
(Id
: E
; V
: E
) is
4148 (Ekind
(Id
) = E_Function
4149 and then not Comes_From_Source
(Id
)
4150 and then Chars
(Id
) = Name_Op_Ne
);
4152 end Set_Corresponding_Equality
;
4154 procedure Set_Corresponding_Function
(Id
: E
; V
: E
) is
4156 pragma Assert
(Ekind
(Id
) = E_Procedure
and then Rewritten_For_C
(V
));
4158 end Set_Corresponding_Function
;
4160 procedure Set_Corresponding_Procedure
(Id
: E
; V
: E
) is
4162 pragma Assert
(Ekind
(Id
) = E_Function
and then Rewritten_For_C
(Id
));
4164 end Set_Corresponding_Procedure
;
4166 procedure Set_Corresponding_Protected_Entry
(Id
: E
; V
: E
) is
4168 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Subprogram_Body
));
4170 end Set_Corresponding_Protected_Entry
;
4172 procedure Set_Corresponding_Record_Component
(Id
: E
; V
: E
) is
4174 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
4176 end Set_Corresponding_Record_Component
;
4178 procedure Set_Corresponding_Record_Type
(Id
: E
; V
: E
) is
4180 pragma Assert
(Is_Concurrent_Type
(Id
));
4182 end Set_Corresponding_Record_Type
;
4184 procedure Set_Corresponding_Remote_Type
(Id
: E
; V
: E
) is
4187 end Set_Corresponding_Remote_Type
;
4189 procedure Set_Current_Use_Clause
(Id
: E
; V
: E
) is
4191 pragma Assert
(Ekind
(Id
) = E_Package
or else Is_Type
(Id
));
4193 end Set_Current_Use_Clause
;
4195 procedure Set_Current_Value
(Id
: E
; V
: N
) is
4197 pragma Assert
(Ekind
(Id
) in Object_Kind
or else Ekind
(Id
) = E_Void
);
4199 end Set_Current_Value
;
4201 procedure Set_CR_Discriminant
(Id
: E
; V
: E
) is
4204 end Set_CR_Discriminant
;
4206 procedure Set_Debug_Info_Off
(Id
: E
; V
: B
:= True) is
4208 Set_Flag166
(Id
, V
);
4209 end Set_Debug_Info_Off
;
4211 procedure Set_Debug_Renaming_Link
(Id
: E
; V
: E
) is
4214 end Set_Debug_Renaming_Link
;
4216 procedure Set_Default_Aspect_Component_Value
(Id
: E
; V
: E
) is
4218 pragma Assert
(Is_Array_Type
(Id
) and then Is_Base_Type
(Id
));
4220 end Set_Default_Aspect_Component_Value
;
4222 procedure Set_Default_Aspect_Value
(Id
: E
; V
: E
) is
4224 pragma Assert
(Is_Scalar_Type
(Id
) and then Is_Base_Type
(Id
));
4226 end Set_Default_Aspect_Value
;
4228 procedure Set_Default_Expr_Function
(Id
: E
; V
: E
) is
4230 pragma Assert
(Is_Formal
(Id
));
4232 end Set_Default_Expr_Function
;
4234 procedure Set_Default_Expressions_Processed
(Id
: E
; V
: B
:= True) is
4236 Set_Flag108
(Id
, V
);
4237 end Set_Default_Expressions_Processed
;
4239 procedure Set_Default_Value
(Id
: E
; V
: N
) is
4241 pragma Assert
(Is_Formal
(Id
));
4243 end Set_Default_Value
;
4245 procedure Set_Delay_Cleanups
(Id
: E
; V
: B
:= True) is
4249 or else Is_Task_Type
(Id
)
4250 or else Ekind
(Id
) = E_Block
);
4251 Set_Flag114
(Id
, V
);
4252 end Set_Delay_Cleanups
;
4254 procedure Set_Delay_Subprogram_Descriptors
(Id
: E
; V
: B
:= True) is
4257 (Is_Subprogram
(Id
) or else Ekind_In
(Id
, E_Package
, E_Package_Body
));
4260 end Set_Delay_Subprogram_Descriptors
;
4262 procedure Set_Delta_Value
(Id
: E
; V
: R
) is
4264 pragma Assert
(Is_Fixed_Point_Type
(Id
));
4265 Set_Ureal18
(Id
, V
);
4266 end Set_Delta_Value
;
4268 procedure Set_Dependent_Instances
(Id
: E
; V
: L
) is
4270 pragma Assert
(Is_Generic_Instance
(Id
));
4272 end Set_Dependent_Instances
;
4274 procedure Set_Depends_On_Private
(Id
: E
; V
: B
:= True) is
4276 pragma Assert
(Nkind
(Id
) in N_Entity
);
4278 end Set_Depends_On_Private
;
4280 procedure Set_Derived_Type_Link
(Id
: E
; V
: E
) is
4282 pragma Assert
(Is_Type
(Id
) and then Is_Base_Type
(Id
));
4284 end Set_Derived_Type_Link
;
4286 procedure Set_Digits_Value
(Id
: E
; V
: U
) is
4289 (Is_Floating_Point_Type
(Id
)
4290 or else Is_Decimal_Fixed_Point_Type
(Id
));
4292 end Set_Digits_Value
;
4294 procedure Set_Directly_Designated_Type
(Id
: E
; V
: E
) is
4297 end Set_Directly_Designated_Type
;
4299 procedure Set_Disable_Controlled
(Id
: E
; V
: B
:= True) is
4301 pragma Assert
(Is_Type
(Id
) and then Is_Base_Type
(Id
));
4302 Set_Flag253
(Id
, V
);
4303 end Set_Disable_Controlled
;
4305 procedure Set_Discard_Names
(Id
: E
; V
: B
:= True) is
4308 end Set_Discard_Names
;
4310 procedure Set_Discriminal
(Id
: E
; V
: E
) is
4312 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
4314 end Set_Discriminal
;
4316 procedure Set_Discriminal_Link
(Id
: E
; V
: E
) is
4319 end Set_Discriminal_Link
;
4321 procedure Set_Discriminant_Checking_Func
(Id
: E
; V
: E
) is
4323 pragma Assert
(Ekind
(Id
) = E_Component
);
4325 end Set_Discriminant_Checking_Func
;
4327 procedure Set_Discriminant_Constraint
(Id
: E
; V
: L
) is
4329 pragma Assert
(Nkind
(Id
) in N_Entity
);
4330 Set_Elist21
(Id
, V
);
4331 end Set_Discriminant_Constraint
;
4333 procedure Set_Discriminant_Default_Value
(Id
: E
; V
: N
) is
4336 end Set_Discriminant_Default_Value
;
4338 procedure Set_Discriminant_Number
(Id
: E
; V
: U
) is
4341 end Set_Discriminant_Number
;
4343 procedure Set_Dispatch_Table_Wrappers
(Id
: E
; V
: L
) is
4345 pragma Assert
(Ekind
(Id
) = E_Record_Type
4346 and then Id
= Implementation_Base_Type
(Id
));
4347 pragma Assert
(V
= No_Elist
or else Is_Tagged_Type
(Id
));
4348 Set_Elist26
(Id
, V
);
4349 end Set_Dispatch_Table_Wrappers
;
4351 procedure Set_DT_Entry_Count
(Id
: E
; V
: U
) is
4353 pragma Assert
(Ekind
(Id
) = E_Component
);
4355 end Set_DT_Entry_Count
;
4357 procedure Set_DT_Offset_To_Top_Func
(Id
: E
; V
: E
) is
4359 pragma Assert
(Ekind
(Id
) = E_Component
and then Is_Tag
(Id
));
4361 end Set_DT_Offset_To_Top_Func
;
4363 procedure Set_DT_Position
(Id
: E
; V
: U
) is
4365 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
4367 end Set_DT_Position
;
4369 procedure Set_DTC_Entity
(Id
: E
; V
: E
) is
4371 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
4375 procedure Set_Elaborate_Body_Desirable
(Id
: E
; V
: B
:= True) is
4377 pragma Assert
(Ekind
(Id
) = E_Package
);
4378 Set_Flag210
(Id
, V
);
4379 end Set_Elaborate_Body_Desirable
;
4381 procedure Set_Elaboration_Entity
(Id
: E
; V
: E
) is
4386 Ekind
(Id
) = E_Package
4388 Is_Generic_Unit
(Id
));
4390 end Set_Elaboration_Entity
;
4392 procedure Set_Elaboration_Entity_Required
(Id
: E
; V
: B
:= True) is
4397 Ekind
(Id
) = E_Package
4399 Is_Generic_Unit
(Id
));
4400 Set_Flag174
(Id
, V
);
4401 end Set_Elaboration_Entity_Required
;
4403 procedure Set_Encapsulating_State
(Id
: E
; V
: E
) is
4405 pragma Assert
(Ekind_In
(Id
, E_Abstract_State
, E_Constant
, E_Variable
));
4407 end Set_Encapsulating_State
;
4409 procedure Set_Enclosing_Scope
(Id
: E
; V
: E
) is
4412 end Set_Enclosing_Scope
;
4414 procedure Set_Entry_Accepted
(Id
: E
; V
: B
:= True) is
4416 pragma Assert
(Is_Entry
(Id
));
4417 Set_Flag152
(Id
, V
);
4418 end Set_Entry_Accepted
;
4420 procedure Set_Entry_Bodies_Array
(Id
: E
; V
: E
) is
4423 end Set_Entry_Bodies_Array
;
4425 procedure Set_Entry_Cancel_Parameter
(Id
: E
; V
: E
) is
4428 end Set_Entry_Cancel_Parameter
;
4430 procedure Set_Entry_Component
(Id
: E
; V
: E
) is
4433 end Set_Entry_Component
;
4435 procedure Set_Entry_Formal
(Id
: E
; V
: E
) is
4438 end Set_Entry_Formal
;
4440 procedure Set_Entry_Index_Constant
(Id
: E
; V
: E
) is
4442 pragma Assert
(Ekind
(Id
) = E_Entry_Index_Parameter
);
4444 end Set_Entry_Index_Constant
;
4446 procedure Set_Entry_Max_Queue_Lengths_Array
(Id
: E
; V
: E
) is
4448 pragma Assert
(Ekind
(Id
) = E_Protected_Type
);
4450 end Set_Entry_Max_Queue_Lengths_Array
;
4452 procedure Set_Entry_Parameters_Type
(Id
: E
; V
: E
) is
4455 end Set_Entry_Parameters_Type
;
4457 procedure Set_Enum_Pos_To_Rep
(Id
: E
; V
: E
) is
4459 pragma Assert
(Ekind
(Id
) = E_Enumeration_Type
);
4461 end Set_Enum_Pos_To_Rep
;
4463 procedure Set_Enumeration_Pos
(Id
: E
; V
: U
) is
4465 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
4467 end Set_Enumeration_Pos
;
4469 procedure Set_Enumeration_Rep
(Id
: E
; V
: U
) is
4471 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
4473 end Set_Enumeration_Rep
;
4475 procedure Set_Enumeration_Rep_Expr
(Id
: E
; V
: N
) is
4477 pragma Assert
(Ekind
(Id
) = E_Enumeration_Literal
);
4479 end Set_Enumeration_Rep_Expr
;
4481 procedure Set_Equivalent_Type
(Id
: E
; V
: E
) is
4484 (Ekind_In
(Id
, E_Class_Wide_Type
,
4485 E_Class_Wide_Subtype
,
4486 E_Access_Protected_Subprogram_Type
,
4487 E_Anonymous_Access_Protected_Subprogram_Type
,
4488 E_Access_Subprogram_Type
,
4491 end Set_Equivalent_Type
;
4493 procedure Set_Esize
(Id
: E
; V
: U
) is
4498 procedure Set_Extra_Accessibility
(Id
: E
; V
: E
) is
4501 (Is_Formal
(Id
) or else Ekind_In
(Id
, E_Variable
, E_Constant
));
4503 end Set_Extra_Accessibility
;
4505 procedure Set_Extra_Accessibility_Of_Result
(Id
: E
; V
: E
) is
4507 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Operator
, E_Subprogram_Type
));
4509 end Set_Extra_Accessibility_Of_Result
;
4511 procedure Set_Extra_Constrained
(Id
: E
; V
: E
) is
4513 pragma Assert
(Is_Formal
(Id
) or else Ekind
(Id
) = E_Variable
);
4515 end Set_Extra_Constrained
;
4517 procedure Set_Extra_Formal
(Id
: E
; V
: E
) is
4520 end Set_Extra_Formal
;
4522 procedure Set_Extra_Formals
(Id
: E
; V
: E
) is
4525 (Is_Overloadable
(Id
)
4526 or else Ekind_In
(Id
, E_Entry_Family
,
4528 E_Subprogram_Type
));
4530 end Set_Extra_Formals
;
4532 procedure Set_Finalization_Master
(Id
: E
; V
: E
) is
4534 pragma Assert
(Is_Access_Type
(Id
) and then Is_Base_Type
(Id
));
4536 end Set_Finalization_Master
;
4538 procedure Set_Finalize_Storage_Only
(Id
: E
; V
: B
:= True) is
4540 pragma Assert
(Is_Type
(Id
) and then Is_Base_Type
(Id
));
4541 Set_Flag158
(Id
, V
);
4542 end Set_Finalize_Storage_Only
;
4544 procedure Set_Finalizer
(Id
: E
; V
: E
) is
4546 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Package_Body
));
4550 procedure Set_First_Entity
(Id
: E
; V
: E
) is
4553 end Set_First_Entity
;
4555 procedure Set_First_Exit_Statement
(Id
: E
; V
: N
) is
4557 pragma Assert
(Ekind
(Id
) = E_Loop
);
4559 end Set_First_Exit_Statement
;
4561 procedure Set_First_Index
(Id
: E
; V
: N
) is
4563 pragma Assert
(Is_Array_Type
(Id
));
4565 end Set_First_Index
;
4567 procedure Set_First_Literal
(Id
: E
; V
: E
) is
4569 pragma Assert
(Is_Enumeration_Type
(Id
));
4571 end Set_First_Literal
;
4573 procedure Set_First_Private_Entity
(Id
: E
; V
: E
) is
4575 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
)
4576 or else Ekind
(Id
) in Concurrent_Kind
);
4578 end Set_First_Private_Entity
;
4580 procedure Set_First_Rep_Item
(Id
: E
; V
: N
) is
4583 end Set_First_Rep_Item
;
4585 procedure Set_Float_Rep
(Id
: E
; V
: F
) is
4586 pragma Assert
(Ekind
(Id
) = E_Floating_Point_Type
);
4588 Set_Uint10
(Id
, UI_From_Int
(F
'Pos (V
)));
4591 procedure Set_Freeze_Node
(Id
: E
; V
: N
) is
4594 end Set_Freeze_Node
;
4596 procedure Set_From_Limited_With
(Id
: E
; V
: B
:= True) is
4599 (Is_Type
(Id
) or else Ekind_In
(Id
, E_Abstract_State
, E_Package
));
4600 Set_Flag159
(Id
, V
);
4601 end Set_From_Limited_With
;
4603 procedure Set_Full_View
(Id
: E
; V
: E
) is
4605 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Constant
);
4609 procedure Set_Generic_Homonym
(Id
: E
; V
: E
) is
4612 end Set_Generic_Homonym
;
4614 procedure Set_Generic_Renamings
(Id
: E
; V
: L
) is
4616 Set_Elist23
(Id
, V
);
4617 end Set_Generic_Renamings
;
4619 procedure Set_Handler_Records
(Id
: E
; V
: S
) is
4622 end Set_Handler_Records
;
4624 procedure Set_Has_Aliased_Components
(Id
: E
; V
: B
:= True) is
4626 pragma Assert
(Id
= Base_Type
(Id
));
4627 Set_Flag135
(Id
, V
);
4628 end Set_Has_Aliased_Components
;
4630 procedure Set_Has_Alignment_Clause
(Id
: E
; V
: B
:= True) is
4633 end Set_Has_Alignment_Clause
;
4635 procedure Set_Has_All_Calls_Remote
(Id
: E
; V
: B
:= True) is
4638 end Set_Has_All_Calls_Remote
;
4640 procedure Set_Has_Atomic_Components
(Id
: E
; V
: B
:= True) is
4642 pragma Assert
(not Is_Type
(Id
) or else Is_Base_Type
(Id
));
4644 end Set_Has_Atomic_Components
;
4646 procedure Set_Has_Biased_Representation
(Id
: E
; V
: B
:= True) is
4649 ((V
= False) or else (Is_Discrete_Type
(Id
) or else Is_Object
(Id
)));
4650 Set_Flag139
(Id
, V
);
4651 end Set_Has_Biased_Representation
;
4653 procedure Set_Has_Completion
(Id
: E
; V
: B
:= True) is
4656 end Set_Has_Completion
;
4658 procedure Set_Has_Completion_In_Body
(Id
: E
; V
: B
:= True) is
4660 pragma Assert
(Is_Type
(Id
));
4662 end Set_Has_Completion_In_Body
;
4664 procedure Set_Has_Complex_Representation
(Id
: E
; V
: B
:= True) is
4666 pragma Assert
(Is_Record_Type
(Id
) and then Is_Base_Type
(Id
));
4667 Set_Flag140
(Id
, V
);
4668 end Set_Has_Complex_Representation
;
4670 procedure Set_Has_Component_Size_Clause
(Id
: E
; V
: B
:= True) is
4672 pragma Assert
(Ekind
(Id
) = E_Array_Type
);
4674 end Set_Has_Component_Size_Clause
;
4676 procedure Set_Has_Constrained_Partial_View
(Id
: E
; V
: B
:= True) is
4678 pragma Assert
(Is_Type
(Id
));
4679 Set_Flag187
(Id
, V
);
4680 end Set_Has_Constrained_Partial_View
;
4682 procedure Set_Has_Contiguous_Rep
(Id
: E
; V
: B
:= True) is
4684 Set_Flag181
(Id
, V
);
4685 end Set_Has_Contiguous_Rep
;
4687 procedure Set_Has_Controlled_Component
(Id
: E
; V
: B
:= True) is
4689 pragma Assert
(Id
= Base_Type
(Id
));
4691 end Set_Has_Controlled_Component
;
4693 procedure Set_Has_Controlling_Result
(Id
: E
; V
: B
:= True) is
4696 end Set_Has_Controlling_Result
;
4698 procedure Set_Has_Convention_Pragma
(Id
: E
; V
: B
:= True) is
4700 Set_Flag119
(Id
, V
);
4701 end Set_Has_Convention_Pragma
;
4703 procedure Set_Has_Default_Aspect
(Id
: E
; V
: B
:= True) is
4706 ((Is_Scalar_Type
(Id
) or else Is_Array_Type
(Id
))
4707 and then Is_Base_Type
(Id
));
4709 end Set_Has_Default_Aspect
;
4711 procedure Set_Has_Delayed_Aspects
(Id
: E
; V
: B
:= True) is
4713 pragma Assert
(Nkind
(Id
) in N_Entity
);
4714 Set_Flag200
(Id
, V
);
4715 end Set_Has_Delayed_Aspects
;
4717 procedure Set_Has_Delayed_Freeze
(Id
: E
; V
: B
:= True) is
4719 pragma Assert
(Nkind
(Id
) in N_Entity
);
4721 end Set_Has_Delayed_Freeze
;
4723 procedure Set_Has_Delayed_Rep_Aspects
(Id
: E
; V
: B
:= True) is
4725 pragma Assert
(Nkind
(Id
) in N_Entity
);
4726 Set_Flag261
(Id
, V
);
4727 end Set_Has_Delayed_Rep_Aspects
;
4729 procedure Set_Has_Discriminants
(Id
: E
; V
: B
:= True) is
4731 pragma Assert
(Nkind
(Id
) in N_Entity
);
4733 end Set_Has_Discriminants
;
4735 procedure Set_Has_Dispatch_Table
(Id
: E
; V
: B
:= True) is
4737 pragma Assert
(Ekind
(Id
) = E_Record_Type
4738 and then Is_Tagged_Type
(Id
));
4739 Set_Flag220
(Id
, V
);
4740 end Set_Has_Dispatch_Table
;
4742 procedure Set_Has_Dynamic_Predicate_Aspect
(Id
: E
; V
: B
:= True) is
4744 pragma Assert
(Is_Type
(Id
));
4745 Set_Flag258
(Id
, V
);
4746 end Set_Has_Dynamic_Predicate_Aspect
;
4748 procedure Set_Has_Enumeration_Rep_Clause
(Id
: E
; V
: B
:= True) is
4750 pragma Assert
(Is_Enumeration_Type
(Id
));
4752 end Set_Has_Enumeration_Rep_Clause
;
4754 procedure Set_Has_Exit
(Id
: E
; V
: B
:= True) is
4759 procedure Set_Has_Expanded_Contract
(Id
: E
; V
: B
:= True) is
4761 pragma Assert
(Ekind_In
(Id
, E_Entry
,
4765 Set_Flag240
(Id
, V
);
4766 end Set_Has_Expanded_Contract
;
4768 procedure Set_Has_Forward_Instantiation
(Id
: E
; V
: B
:= True) is
4770 Set_Flag175
(Id
, V
);
4771 end Set_Has_Forward_Instantiation
;
4773 procedure Set_Has_Fully_Qualified_Name
(Id
: E
; V
: B
:= True) is
4775 Set_Flag173
(Id
, V
);
4776 end Set_Has_Fully_Qualified_Name
;
4778 procedure Set_Has_Gigi_Rep_Item
(Id
: E
; V
: B
:= True) is
4781 end Set_Has_Gigi_Rep_Item
;
4783 procedure Set_Has_Homonym
(Id
: E
; V
: B
:= True) is
4786 end Set_Has_Homonym
;
4788 procedure Set_Has_Implicit_Dereference
(Id
: E
; V
: B
:= True) is
4790 Set_Flag251
(Id
, V
);
4791 end Set_Has_Implicit_Dereference
;
4793 procedure Set_Has_Independent_Components
(Id
: E
; V
: B
:= True) is
4795 pragma Assert
(not Is_Type
(Id
) or else Is_Base_Type
(Id
));
4797 end Set_Has_Independent_Components
;
4799 procedure Set_Has_Inheritable_Invariants
(Id
: E
; V
: B
:= True) is
4801 pragma Assert
(Is_Type
(Id
));
4802 Set_Flag248
(Base_Type
(Id
), V
);
4803 end Set_Has_Inheritable_Invariants
;
4805 procedure Set_Has_Inherited_DIC
(Id
: E
; V
: B
:= True) is
4807 pragma Assert
(Is_Type
(Id
));
4808 Set_Flag133
(Base_Type
(Id
), V
);
4809 end Set_Has_Inherited_DIC
;
4811 procedure Set_Has_Inherited_Invariants
(Id
: E
; V
: B
:= True) is
4813 pragma Assert
(Is_Type
(Id
));
4814 Set_Flag291
(Base_Type
(Id
), V
);
4815 end Set_Has_Inherited_Invariants
;
4817 procedure Set_Has_Initial_Value
(Id
: E
; V
: B
:= True) is
4819 pragma Assert
(Ekind_In
(Id
, E_Variable
, E_Out_Parameter
));
4820 Set_Flag219
(Id
, V
);
4821 end Set_Has_Initial_Value
;
4823 procedure Set_Has_Loop_Entry_Attributes
(Id
: E
; V
: B
:= True) is
4825 pragma Assert
(Ekind
(Id
) = E_Loop
);
4826 Set_Flag260
(Id
, V
);
4827 end Set_Has_Loop_Entry_Attributes
;
4829 procedure Set_Has_Machine_Radix_Clause
(Id
: E
; V
: B
:= True) is
4831 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
4833 end Set_Has_Machine_Radix_Clause
;
4835 procedure Set_Has_Master_Entity
(Id
: E
; V
: B
:= True) is
4838 end Set_Has_Master_Entity
;
4840 procedure Set_Has_Missing_Return
(Id
: E
; V
: B
:= True) is
4842 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Generic_Function
));
4843 Set_Flag142
(Id
, V
);
4844 end Set_Has_Missing_Return
;
4846 procedure Set_Has_Nested_Block_With_Handler
(Id
: E
; V
: B
:= True) is
4848 Set_Flag101
(Id
, V
);
4849 end Set_Has_Nested_Block_With_Handler
;
4851 procedure Set_Has_Nested_Subprogram
(Id
: E
; V
: B
:= True) is
4853 pragma Assert
(Is_Subprogram
(Id
));
4854 Set_Flag282
(Id
, V
);
4855 end Set_Has_Nested_Subprogram
;
4857 procedure Set_Has_Non_Standard_Rep
(Id
: E
; V
: B
:= True) is
4859 pragma Assert
(Id
= Base_Type
(Id
));
4861 end Set_Has_Non_Standard_Rep
;
4863 procedure Set_Has_Object_Size_Clause
(Id
: E
; V
: B
:= True) is
4865 pragma Assert
(Is_Type
(Id
));
4866 Set_Flag172
(Id
, V
);
4867 end Set_Has_Object_Size_Clause
;
4869 procedure Set_Has_Out_Or_In_Out_Parameter
(Id
: E
; V
: B
:= True) is
4872 (Ekind_In
(Id
, E_Entry
, E_Entry_Family
)
4873 or else Is_Subprogram_Or_Generic_Subprogram
(Id
));
4874 Set_Flag110
(Id
, V
);
4875 end Set_Has_Out_Or_In_Out_Parameter
;
4877 procedure Set_Has_Own_DIC
(Id
: E
; V
: B
:= True) is
4879 pragma Assert
(Is_Type
(Id
));
4880 Set_Flag3
(Base_Type
(Id
), V
);
4881 end Set_Has_Own_DIC
;
4883 procedure Set_Has_Own_Invariants
(Id
: E
; V
: B
:= True) is
4885 pragma Assert
(Is_Type
(Id
));
4886 Set_Flag232
(Base_Type
(Id
), V
);
4887 end Set_Has_Own_Invariants
;
4889 procedure Set_Has_Partial_Visible_Refinement
(Id
: E
; V
: B
:= True) is
4891 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
4892 Set_Flag296
(Id
, V
);
4893 end Set_Has_Partial_Visible_Refinement
;
4895 procedure Set_Has_Per_Object_Constraint
(Id
: E
; V
: B
:= True) is
4897 Set_Flag154
(Id
, V
);
4898 end Set_Has_Per_Object_Constraint
;
4900 procedure Set_Has_Pragma_Controlled
(Id
: E
; V
: B
:= True) is
4902 pragma Assert
(Is_Access_Type
(Id
));
4903 Set_Flag27
(Base_Type
(Id
), V
);
4904 end Set_Has_Pragma_Controlled
;
4906 procedure Set_Has_Pragma_Elaborate_Body
(Id
: E
; V
: B
:= True) is
4908 Set_Flag150
(Id
, V
);
4909 end Set_Has_Pragma_Elaborate_Body
;
4911 procedure Set_Has_Pragma_Inline
(Id
: E
; V
: B
:= True) is
4913 Set_Flag157
(Id
, V
);
4914 end Set_Has_Pragma_Inline
;
4916 procedure Set_Has_Pragma_Inline_Always
(Id
: E
; V
: B
:= True) is
4918 Set_Flag230
(Id
, V
);
4919 end Set_Has_Pragma_Inline_Always
;
4921 procedure Set_Has_Pragma_No_Inline
(Id
: E
; V
: B
:= True) is
4923 Set_Flag201
(Id
, V
);
4924 end Set_Has_Pragma_No_Inline
;
4926 procedure Set_Has_Pragma_Ordered
(Id
: E
; V
: B
:= True) is
4928 pragma Assert
(Is_Enumeration_Type
(Id
));
4929 pragma Assert
(Id
= Base_Type
(Id
));
4930 Set_Flag198
(Id
, V
);
4931 end Set_Has_Pragma_Ordered
;
4933 procedure Set_Has_Pragma_Pack
(Id
: E
; V
: B
:= True) is
4935 pragma Assert
(Is_Array_Type
(Id
) or else Is_Record_Type
(Id
));
4936 pragma Assert
(Id
= Base_Type
(Id
));
4937 Set_Flag121
(Id
, V
);
4938 end Set_Has_Pragma_Pack
;
4940 procedure Set_Has_Pragma_Preelab_Init
(Id
: E
; V
: B
:= True) is
4942 Set_Flag221
(Id
, V
);
4943 end Set_Has_Pragma_Preelab_Init
;
4945 procedure Set_Has_Pragma_Pure
(Id
: E
; V
: B
:= True) is
4947 Set_Flag203
(Id
, V
);
4948 end Set_Has_Pragma_Pure
;
4950 procedure Set_Has_Pragma_Pure_Function
(Id
: E
; V
: B
:= True) is
4952 Set_Flag179
(Id
, V
);
4953 end Set_Has_Pragma_Pure_Function
;
4955 procedure Set_Has_Pragma_Thread_Local_Storage
(Id
: E
; V
: B
:= True) is
4957 Set_Flag169
(Id
, V
);
4958 end Set_Has_Pragma_Thread_Local_Storage
;
4960 procedure Set_Has_Pragma_Unmodified
(Id
: E
; V
: B
:= True) is
4962 Set_Flag233
(Id
, V
);
4963 end Set_Has_Pragma_Unmodified
;
4965 procedure Set_Has_Pragma_Unreferenced
(Id
: E
; V
: B
:= True) is
4967 Set_Flag180
(Id
, V
);
4968 end Set_Has_Pragma_Unreferenced
;
4970 procedure Set_Has_Pragma_Unreferenced_Objects
(Id
: E
; V
: B
:= True) is
4972 pragma Assert
(Is_Type
(Id
));
4973 Set_Flag212
(Id
, V
);
4974 end Set_Has_Pragma_Unreferenced_Objects
;
4976 procedure Set_Has_Pragma_Unused
(Id
: E
; V
: B
:= True) is
4978 Set_Flag294
(Id
, V
);
4979 end Set_Has_Pragma_Unused
;
4981 procedure Set_Has_Predicates
(Id
: E
; V
: B
:= True) is
4983 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Void
);
4984 Set_Flag250
(Id
, V
);
4985 end Set_Has_Predicates
;
4987 procedure Set_Has_Primitive_Operations
(Id
: E
; V
: B
:= True) is
4989 pragma Assert
(Id
= Base_Type
(Id
));
4990 Set_Flag120
(Id
, V
);
4991 end Set_Has_Primitive_Operations
;
4993 procedure Set_Has_Private_Ancestor
(Id
: E
; V
: B
:= True) is
4995 pragma Assert
(Is_Type
(Id
));
4996 Set_Flag151
(Id
, V
);
4997 end Set_Has_Private_Ancestor
;
4999 procedure Set_Has_Private_Declaration
(Id
: E
; V
: B
:= True) is
5001 Set_Flag155
(Id
, V
);
5002 end Set_Has_Private_Declaration
;
5004 procedure Set_Has_Private_Extension
(Id
: E
; V
: B
:= True) is
5006 pragma Assert
(Is_Tagged_Type
(Id
));
5007 Set_Flag300
(Id
, V
);
5008 end Set_Has_Private_Extension
;
5010 procedure Set_Has_Protected
(Id
: E
; V
: B
:= True) is
5012 Set_Flag271
(Id
, V
);
5013 end Set_Has_Protected
;
5015 procedure Set_Has_Qualified_Name
(Id
: E
; V
: B
:= True) is
5017 Set_Flag161
(Id
, V
);
5018 end Set_Has_Qualified_Name
;
5020 procedure Set_Has_RACW
(Id
: E
; V
: B
:= True) is
5022 pragma Assert
(Ekind
(Id
) = E_Package
);
5023 Set_Flag214
(Id
, V
);
5026 procedure Set_Has_Record_Rep_Clause
(Id
: E
; V
: B
:= True) is
5028 pragma Assert
(Id
= Base_Type
(Id
));
5030 end Set_Has_Record_Rep_Clause
;
5032 procedure Set_Has_Recursive_Call
(Id
: E
; V
: B
:= True) is
5034 pragma Assert
(Is_Subprogram
(Id
));
5035 Set_Flag143
(Id
, V
);
5036 end Set_Has_Recursive_Call
;
5038 procedure Set_Has_Shift_Operator
(Id
: E
; V
: B
:= True) is
5040 pragma Assert
(Is_Integer_Type
(Id
) and then Is_Base_Type
(Id
));
5041 Set_Flag267
(Id
, V
);
5042 end Set_Has_Shift_Operator
;
5044 procedure Set_Has_Size_Clause
(Id
: E
; V
: B
:= True) is
5047 end Set_Has_Size_Clause
;
5049 procedure Set_Has_Small_Clause
(Id
: E
; V
: B
:= True) is
5051 pragma Assert
(Is_Ordinary_Fixed_Point_Type
(Id
));
5053 end Set_Has_Small_Clause
;
5055 procedure Set_Has_Specified_Layout
(Id
: E
; V
: B
:= True) is
5057 pragma Assert
(Id
= Base_Type
(Id
));
5058 Set_Flag100
(Id
, V
);
5059 end Set_Has_Specified_Layout
;
5061 procedure Set_Has_Specified_Stream_Input
(Id
: E
; V
: B
:= True) is
5063 pragma Assert
(Is_Type
(Id
));
5064 Set_Flag190
(Id
, V
);
5065 end Set_Has_Specified_Stream_Input
;
5067 procedure Set_Has_Specified_Stream_Output
(Id
: E
; V
: B
:= True) is
5069 pragma Assert
(Is_Type
(Id
));
5070 Set_Flag191
(Id
, V
);
5071 end Set_Has_Specified_Stream_Output
;
5073 procedure Set_Has_Specified_Stream_Read
(Id
: E
; V
: B
:= True) is
5075 pragma Assert
(Is_Type
(Id
));
5076 Set_Flag192
(Id
, V
);
5077 end Set_Has_Specified_Stream_Read
;
5079 procedure Set_Has_Specified_Stream_Write
(Id
: E
; V
: B
:= True) is
5081 pragma Assert
(Is_Type
(Id
));
5082 Set_Flag193
(Id
, V
);
5083 end Set_Has_Specified_Stream_Write
;
5085 procedure Set_Has_Static_Discriminants
(Id
: E
; V
: B
:= True) is
5087 Set_Flag211
(Id
, V
);
5088 end Set_Has_Static_Discriminants
;
5090 procedure Set_Has_Static_Predicate
(Id
: E
; V
: B
:= True) is
5092 pragma Assert
(Is_Type
(Id
));
5093 Set_Flag269
(Id
, V
);
5094 end Set_Has_Static_Predicate
;
5096 procedure Set_Has_Static_Predicate_Aspect
(Id
: E
; V
: B
:= True) is
5098 pragma Assert
(Is_Type
(Id
));
5099 Set_Flag259
(Id
, V
);
5100 end Set_Has_Static_Predicate_Aspect
;
5102 procedure Set_Has_Storage_Size_Clause
(Id
: E
; V
: B
:= True) is
5104 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
5105 pragma Assert
(Id
= Base_Type
(Id
));
5107 end Set_Has_Storage_Size_Clause
;
5109 procedure Set_Has_Stream_Size_Clause
(Id
: E
; V
: B
:= True) is
5111 pragma Assert
(Is_Elementary_Type
(Id
));
5112 Set_Flag184
(Id
, V
);
5113 end Set_Has_Stream_Size_Clause
;
5115 procedure Set_Has_Task
(Id
: E
; V
: B
:= True) is
5117 pragma Assert
(Id
= Base_Type
(Id
));
5121 procedure Set_Has_Thunks
(Id
: E
; V
: B
:= True) is
5123 pragma Assert
(Is_Tag
(Id
));
5124 Set_Flag228
(Id
, V
);
5127 procedure Set_Has_Timing_Event
(Id
: E
; V
: B
:= True) is
5129 pragma Assert
(Id
= Base_Type
(Id
));
5130 Set_Flag289
(Id
, V
);
5131 end Set_Has_Timing_Event
;
5133 procedure Set_Has_Unchecked_Union
(Id
: E
; V
: B
:= True) is
5135 pragma Assert
(Id
= Base_Type
(Id
));
5136 Set_Flag123
(Id
, V
);
5137 end Set_Has_Unchecked_Union
;
5139 procedure Set_Has_Unknown_Discriminants
(Id
: E
; V
: B
:= True) is
5141 pragma Assert
(Is_Type
(Id
));
5143 end Set_Has_Unknown_Discriminants
;
5145 procedure Set_Has_Visible_Refinement
(Id
: E
; V
: B
:= True) is
5147 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
5148 Set_Flag263
(Id
, V
);
5149 end Set_Has_Visible_Refinement
;
5151 procedure Set_Has_Volatile_Components
(Id
: E
; V
: B
:= True) is
5153 pragma Assert
(not Is_Type
(Id
) or else Is_Base_Type
(Id
));
5155 end Set_Has_Volatile_Components
;
5157 procedure Set_Has_Xref_Entry
(Id
: E
; V
: B
:= True) is
5159 Set_Flag182
(Id
, V
);
5160 end Set_Has_Xref_Entry
;
5162 procedure Set_Hiding_Loop_Variable
(Id
: E
; V
: E
) is
5164 pragma Assert
(Ekind
(Id
) = E_Variable
);
5166 end Set_Hiding_Loop_Variable
;
5168 procedure Set_Homonym
(Id
: E
; V
: E
) is
5170 pragma Assert
(Id
/= V
);
5174 procedure Set_Incomplete_Actuals
(Id
: E
; V
: L
) is
5176 pragma Assert
(Ekind
(Id
) = E_Package
);
5177 Set_Elist24
(Id
, V
);
5178 end Set_Incomplete_Actuals
;
5180 procedure Set_Ignore_SPARK_Mode_Pragmas
(Id
: E
; V
: B
:= True) is
5183 (Ekind_In
(Id
, E_Protected_Body
, -- concurrent types
5188 Ekind_In
(Id
, E_Entry
, -- overloadable
5192 E_Generic_Procedure
,
5197 Ekind_In
(Id
, E_Generic_Package
, -- packages
5200 Set_Flag301
(Id
, V
);
5201 end Set_Ignore_SPARK_Mode_Pragmas
;
5203 procedure Set_Import_Pragma
(Id
: E
; V
: E
) is
5205 pragma Assert
(Is_Subprogram
(Id
));
5207 end Set_Import_Pragma
;
5209 procedure Set_Interface_Alias
(Id
: E
; V
: E
) is
5213 and then Is_Hidden
(Id
)
5214 and then (Ekind_In
(Id
, E_Procedure
, E_Function
)));
5216 end Set_Interface_Alias
;
5218 procedure Set_Interfaces
(Id
: E
; V
: L
) is
5220 pragma Assert
(Is_Record_Type
(Id
));
5221 Set_Elist25
(Id
, V
);
5224 procedure Set_In_Package_Body
(Id
: E
; V
: B
:= True) is
5227 end Set_In_Package_Body
;
5229 procedure Set_In_Private_Part
(Id
: E
; V
: B
:= True) is
5232 end Set_In_Private_Part
;
5234 procedure Set_In_Use
(Id
: E
; V
: B
:= True) is
5236 pragma Assert
(Nkind
(Id
) in N_Entity
);
5240 procedure Set_Initialization_Statements
(Id
: E
; V
: N
) is
5242 -- Tolerate an E_Void entity since this can be called while resolving
5243 -- an aggregate used as the initialization expression for an object
5244 -- declaration, and this occurs before the Ekind for the object is set.
5246 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Constant
, E_Variable
));
5248 end Set_Initialization_Statements
;
5250 procedure Set_Inner_Instances
(Id
: E
; V
: L
) is
5252 Set_Elist23
(Id
, V
);
5253 end Set_Inner_Instances
;
5255 procedure Set_Interface_Name
(Id
: E
; V
: N
) is
5258 end Set_Interface_Name
;
5260 procedure Set_Is_Abstract_Subprogram
(Id
: E
; V
: B
:= True) is
5262 pragma Assert
(Is_Overloadable
(Id
));
5264 end Set_Is_Abstract_Subprogram
;
5266 procedure Set_Is_Abstract_Type
(Id
: E
; V
: B
:= True) is
5268 pragma Assert
(Is_Type
(Id
));
5269 Set_Flag146
(Id
, V
);
5270 end Set_Is_Abstract_Type
;
5272 procedure Set_Is_Local_Anonymous_Access
(Id
: E
; V
: B
:= True) is
5274 pragma Assert
(Is_Access_Type
(Id
));
5275 Set_Flag194
(Id
, V
);
5276 end Set_Is_Local_Anonymous_Access
;
5278 procedure Set_Is_Access_Constant
(Id
: E
; V
: B
:= True) is
5280 pragma Assert
(Is_Access_Type
(Id
));
5282 end Set_Is_Access_Constant
;
5284 procedure Set_Is_Actual_Subtype
(Id
: E
; V
: B
:= True) is
5286 pragma Assert
(Is_Type
(Id
));
5287 Set_Flag293
(Id
, V
);
5288 end Set_Is_Actual_Subtype
;
5290 procedure Set_Is_Ada_2005_Only
(Id
: E
; V
: B
:= True) is
5292 Set_Flag185
(Id
, V
);
5293 end Set_Is_Ada_2005_Only
;
5295 procedure Set_Is_Ada_2012_Only
(Id
: E
; V
: B
:= True) is
5297 Set_Flag199
(Id
, V
);
5298 end Set_Is_Ada_2012_Only
;
5300 procedure Set_Is_Aliased
(Id
: E
; V
: B
:= True) is
5302 pragma Assert
(Nkind
(Id
) in N_Entity
);
5306 procedure Set_Is_Asynchronous
(Id
: E
; V
: B
:= True) is
5309 (Ekind
(Id
) = E_Procedure
or else Is_Type
(Id
));
5311 end Set_Is_Asynchronous
;
5313 procedure Set_Is_Atomic
(Id
: E
; V
: B
:= True) is
5318 procedure Set_Is_Bit_Packed_Array
(Id
: E
; V
: B
:= True) is
5320 pragma Assert
((not V
)
5321 or else (Is_Array_Type
(Id
) and then Is_Base_Type
(Id
)));
5322 Set_Flag122
(Id
, V
);
5323 end Set_Is_Bit_Packed_Array
;
5325 procedure Set_Is_Called
(Id
: E
; V
: B
:= True) is
5327 pragma Assert
(Ekind_In
(Id
, E_Procedure
, E_Function
));
5328 Set_Flag102
(Id
, V
);
5331 procedure Set_Is_Character_Type
(Id
: E
; V
: B
:= True) is
5334 end Set_Is_Character_Type
;
5336 procedure Set_Is_Checked_Ghost_Entity
(Id
: E
; V
: B
:= True) is
5338 -- Allow this attribute to appear on unanalyzed entities
5340 pragma Assert
(Nkind
(Id
) in N_Entity
5341 or else Ekind
(Id
) = E_Void
);
5342 Set_Flag277
(Id
, V
);
5343 end Set_Is_Checked_Ghost_Entity
;
5345 procedure Set_Is_Child_Unit
(Id
: E
; V
: B
:= True) is
5348 end Set_Is_Child_Unit
;
5350 procedure Set_Is_Class_Wide_Clone
(Id
: E
; V
: B
:= True) is
5352 Set_Flag290
(Id
, V
);
5353 end Set_Is_Class_Wide_Clone
;
5355 procedure Set_Is_Class_Wide_Equivalent_Type
(Id
: E
; V
: B
:= True) is
5358 end Set_Is_Class_Wide_Equivalent_Type
;
5360 procedure Set_Is_Compilation_Unit
(Id
: E
; V
: B
:= True) is
5362 Set_Flag149
(Id
, V
);
5363 end Set_Is_Compilation_Unit
;
5365 procedure Set_Is_Completely_Hidden
(Id
: E
; V
: B
:= True) is
5367 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
5368 Set_Flag103
(Id
, V
);
5369 end Set_Is_Completely_Hidden
;
5371 procedure Set_Is_Concurrent_Record_Type
(Id
: E
; V
: B
:= True) is
5374 end Set_Is_Concurrent_Record_Type
;
5376 procedure Set_Is_Constr_Subt_For_U_Nominal
(Id
: E
; V
: B
:= True) is
5379 end Set_Is_Constr_Subt_For_U_Nominal
;
5381 procedure Set_Is_Constr_Subt_For_UN_Aliased
(Id
: E
; V
: B
:= True) is
5383 Set_Flag141
(Id
, V
);
5384 end Set_Is_Constr_Subt_For_UN_Aliased
;
5386 procedure Set_Is_Constrained
(Id
: E
; V
: B
:= True) is
5388 pragma Assert
(Nkind
(Id
) in N_Entity
);
5390 end Set_Is_Constrained
;
5392 procedure Set_Is_Constructor
(Id
: E
; V
: B
:= True) is
5395 end Set_Is_Constructor
;
5397 procedure Set_Is_Controlled_Active
(Id
: E
; V
: B
:= True) is
5399 pragma Assert
(Id
= Base_Type
(Id
));
5401 end Set_Is_Controlled_Active
;
5403 procedure Set_Is_Controlling_Formal
(Id
: E
; V
: B
:= True) is
5405 pragma Assert
(Is_Formal
(Id
));
5407 end Set_Is_Controlling_Formal
;
5409 procedure Set_Is_CPP_Class
(Id
: E
; V
: B
:= True) is
5412 end Set_Is_CPP_Class
;
5414 procedure Set_Is_DIC_Procedure
(Id
: E
; V
: B
:= True) is
5416 pragma Assert
(Ekind
(Id
) = E_Procedure
);
5417 Set_Flag132
(Id
, V
);
5418 end Set_Is_DIC_Procedure
;
5420 procedure Set_Is_Descendant_Of_Address
(Id
: E
; V
: B
:= True) is
5422 pragma Assert
(Is_Type
(Id
));
5423 Set_Flag223
(Id
, V
);
5424 end Set_Is_Descendant_Of_Address
;
5426 procedure Set_Is_Discrim_SO_Function
(Id
: E
; V
: B
:= True) is
5428 Set_Flag176
(Id
, V
);
5429 end Set_Is_Discrim_SO_Function
;
5431 procedure Set_Is_Discriminant_Check_Function
(Id
: E
; V
: B
:= True) is
5433 Set_Flag264
(Id
, V
);
5434 end Set_Is_Discriminant_Check_Function
;
5436 procedure Set_Is_Dispatch_Table_Entity
(Id
: E
; V
: B
:= True) is
5438 Set_Flag234
(Id
, V
);
5439 end Set_Is_Dispatch_Table_Entity
;
5441 procedure Set_Is_Dispatching_Operation
(Id
: E
; V
: B
:= True) is
5446 Is_Overloadable
(Id
)
5448 Ekind
(Id
) = E_Subprogram_Type
);
5451 end Set_Is_Dispatching_Operation
;
5453 procedure Set_Is_Elaboration_Checks_OK_Id
(Id
: E
; V
: B
:= True) is
5456 (Ekind_In
(Id
, E_Constant
, E_Variable
)
5457 or else Is_Entry
(Id
)
5458 or else Is_Generic_Unit
(Id
)
5459 or else Is_Subprogram
(Id
)
5460 or else Is_Task_Type
(Id
));
5461 Set_Flag148
(Id
, V
);
5462 end Set_Is_Elaboration_Checks_OK_Id
;
5464 procedure Set_Is_Eliminated
(Id
: E
; V
: B
:= True) is
5466 Set_Flag124
(Id
, V
);
5467 end Set_Is_Eliminated
;
5469 procedure Set_Is_Entry_Formal
(Id
: E
; V
: B
:= True) is
5472 end Set_Is_Entry_Formal
;
5474 procedure Set_Is_Entry_Wrapper
(Id
: E
; V
: B
:= True) is
5476 Set_Flag297
(Id
, V
);
5477 end Set_Is_Entry_Wrapper
;
5479 procedure Set_Is_Exception_Handler
(Id
: E
; V
: B
:= True) is
5481 pragma Assert
(Ekind
(Id
) = E_Block
);
5482 Set_Flag286
(Id
, V
);
5483 end Set_Is_Exception_Handler
;
5485 procedure Set_Is_Exported
(Id
: E
; V
: B
:= True) is
5488 end Set_Is_Exported
;
5490 procedure Set_Is_Finalized_Transient
(Id
: E
; V
: B
:= True) is
5492 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Loop_Parameter
, E_Variable
));
5493 Set_Flag252
(Id
, V
);
5494 end Set_Is_Finalized_Transient
;
5496 procedure Set_Is_First_Subtype
(Id
: E
; V
: B
:= True) is
5499 end Set_Is_First_Subtype
;
5501 procedure Set_Is_For_Access_Subtype
(Id
: E
; V
: B
:= True) is
5503 pragma Assert
(Ekind_In
(Id
, E_Record_Subtype
, E_Private_Subtype
));
5504 Set_Flag118
(Id
, V
);
5505 end Set_Is_For_Access_Subtype
;
5507 procedure Set_Is_Formal_Subprogram
(Id
: E
; V
: B
:= True) is
5509 Set_Flag111
(Id
, V
);
5510 end Set_Is_Formal_Subprogram
;
5512 procedure Set_Is_Frozen
(Id
: E
; V
: B
:= True) is
5514 pragma Assert
(Nkind
(Id
) in N_Entity
);
5518 procedure Set_Is_Generic_Actual_Subprogram
(Id
: E
; V
: B
:= True) is
5520 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
5521 Set_Flag274
(Id
, V
);
5522 end Set_Is_Generic_Actual_Subprogram
;
5524 procedure Set_Is_Generic_Actual_Type
(Id
: E
; V
: B
:= True) is
5526 pragma Assert
(Is_Type
(Id
));
5528 end Set_Is_Generic_Actual_Type
;
5530 procedure Set_Is_Generic_Instance
(Id
: E
; V
: B
:= True) is
5532 Set_Flag130
(Id
, V
);
5533 end Set_Is_Generic_Instance
;
5535 procedure Set_Is_Generic_Type
(Id
: E
; V
: B
:= True) is
5537 pragma Assert
(Nkind
(Id
) in N_Entity
);
5539 end Set_Is_Generic_Type
;
5541 procedure Set_Is_Hidden
(Id
: E
; V
: B
:= True) is
5546 procedure Set_Is_Hidden_Non_Overridden_Subpgm
(Id
: E
; V
: B
:= True) is
5548 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
5550 end Set_Is_Hidden_Non_Overridden_Subpgm
;
5552 procedure Set_Is_Hidden_Open_Scope
(Id
: E
; V
: B
:= True) is
5554 Set_Flag171
(Id
, V
);
5555 end Set_Is_Hidden_Open_Scope
;
5557 procedure Set_Is_Ignored_Ghost_Entity
(Id
: E
; V
: B
:= True) is
5559 -- Allow this attribute to appear on unanalyzed entities
5561 pragma Assert
(Nkind
(Id
) in N_Entity
5562 or else Ekind
(Id
) = E_Void
);
5563 Set_Flag278
(Id
, V
);
5564 end Set_Is_Ignored_Ghost_Entity
;
5566 procedure Set_Is_Ignored_Transient
(Id
: E
; V
: B
:= True) is
5568 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Loop_Parameter
, E_Variable
));
5569 Set_Flag295
(Id
, V
);
5570 end Set_Is_Ignored_Transient
;
5572 procedure Set_Is_Immediately_Visible
(Id
: E
; V
: B
:= True) is
5574 pragma Assert
(Nkind
(Id
) in N_Entity
);
5576 end Set_Is_Immediately_Visible
;
5578 procedure Set_Is_Implementation_Defined
(Id
: E
; V
: B
:= True) is
5580 Set_Flag254
(Id
, V
);
5581 end Set_Is_Implementation_Defined
;
5583 procedure Set_Is_Imported
(Id
: E
; V
: B
:= True) is
5586 end Set_Is_Imported
;
5588 procedure Set_Is_Independent
(Id
: E
; V
: B
:= True) is
5590 Set_Flag268
(Id
, V
);
5591 end Set_Is_Independent
;
5593 procedure Set_Is_Initial_Condition_Procedure
(Id
: E
; V
: B
:= True) is
5595 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
5596 Set_Flag302
(Id
, V
);
5597 end Set_Is_Initial_Condition_Procedure
;
5599 procedure Set_Is_Inlined
(Id
: E
; V
: B
:= True) is
5604 procedure Set_Is_Inlined_Always
(Id
: E
; V
: B
:= True) is
5606 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
5608 end Set_Is_Inlined_Always
;
5610 procedure Set_Is_Interface
(Id
: E
; V
: B
:= True) is
5612 pragma Assert
(Is_Record_Type
(Id
));
5613 Set_Flag186
(Id
, V
);
5614 end Set_Is_Interface
;
5616 procedure Set_Is_Instantiated
(Id
: E
; V
: B
:= True) is
5618 Set_Flag126
(Id
, V
);
5619 end Set_Is_Instantiated
;
5621 procedure Set_Is_Internal
(Id
: E
; V
: B
:= True) is
5623 pragma Assert
(Nkind
(Id
) in N_Entity
);
5625 end Set_Is_Internal
;
5627 procedure Set_Is_Interrupt_Handler
(Id
: E
; V
: B
:= True) is
5629 pragma Assert
(Nkind
(Id
) in N_Entity
);
5631 end Set_Is_Interrupt_Handler
;
5633 procedure Set_Is_Intrinsic_Subprogram
(Id
: E
; V
: B
:= True) is
5636 end Set_Is_Intrinsic_Subprogram
;
5638 procedure Set_Is_Invariant_Procedure
(Id
: E
; V
: B
:= True) is
5640 pragma Assert
(Ekind
(Id
) = E_Procedure
);
5641 Set_Flag257
(Id
, V
);
5642 end Set_Is_Invariant_Procedure
;
5644 procedure Set_Is_Itype
(Id
: E
; V
: B
:= True) is
5649 procedure Set_Is_Known_Non_Null
(Id
: E
; V
: B
:= True) is
5652 end Set_Is_Known_Non_Null
;
5654 procedure Set_Is_Known_Null
(Id
: E
; V
: B
:= True) is
5656 Set_Flag204
(Id
, V
);
5657 end Set_Is_Known_Null
;
5659 procedure Set_Is_Known_Valid
(Id
: E
; V
: B
:= True) is
5661 Set_Flag170
(Id
, V
);
5662 end Set_Is_Known_Valid
;
5664 procedure Set_Is_Limited_Composite
(Id
: E
; V
: B
:= True) is
5666 pragma Assert
(Is_Type
(Id
));
5667 Set_Flag106
(Id
, V
);
5668 end Set_Is_Limited_Composite
;
5670 procedure Set_Is_Limited_Interface
(Id
: E
; V
: B
:= True) is
5672 pragma Assert
(Is_Interface
(Id
));
5673 Set_Flag197
(Id
, V
);
5674 end Set_Is_Limited_Interface
;
5676 procedure Set_Is_Limited_Record
(Id
: E
; V
: B
:= True) is
5679 end Set_Is_Limited_Record
;
5681 procedure Set_Is_Machine_Code_Subprogram
(Id
: E
; V
: B
:= True) is
5683 pragma Assert
(Is_Subprogram
(Id
));
5684 Set_Flag137
(Id
, V
);
5685 end Set_Is_Machine_Code_Subprogram
;
5687 procedure Set_Is_Non_Static_Subtype
(Id
: E
; V
: B
:= True) is
5689 pragma Assert
(Is_Type
(Id
));
5690 Set_Flag109
(Id
, V
);
5691 end Set_Is_Non_Static_Subtype
;
5693 procedure Set_Is_Null_Init_Proc
(Id
: E
; V
: B
:= True) is
5695 pragma Assert
(Ekind
(Id
) = E_Procedure
);
5696 Set_Flag178
(Id
, V
);
5697 end Set_Is_Null_Init_Proc
;
5699 procedure Set_Is_Obsolescent
(Id
: E
; V
: B
:= True) is
5701 Set_Flag153
(Id
, V
);
5702 end Set_Is_Obsolescent
;
5704 procedure Set_Is_Only_Out_Parameter
(Id
: E
; V
: B
:= True) is
5706 pragma Assert
(Ekind
(Id
) = E_Out_Parameter
);
5707 Set_Flag226
(Id
, V
);
5708 end Set_Is_Only_Out_Parameter
;
5710 procedure Set_Is_Package_Body_Entity
(Id
: E
; V
: B
:= True) is
5712 Set_Flag160
(Id
, V
);
5713 end Set_Is_Package_Body_Entity
;
5715 procedure Set_Is_Packed
(Id
: E
; V
: B
:= True) is
5717 pragma Assert
(Id
= Base_Type
(Id
));
5721 procedure Set_Is_Packed_Array_Impl_Type
(Id
: E
; V
: B
:= True) is
5723 Set_Flag138
(Id
, V
);
5724 end Set_Is_Packed_Array_Impl_Type
;
5726 procedure Set_Is_Param_Block_Component_Type
(Id
: E
; V
: B
:= True) is
5728 pragma Assert
(Ekind_In
(Id
, E_Void
, E_General_Access_Type
));
5729 Set_Flag215
(Id
, V
);
5730 end Set_Is_Param_Block_Component_Type
;
5732 procedure Set_Is_Partial_Invariant_Procedure
(Id
: E
; V
: B
:= True) is
5734 pragma Assert
(Ekind
(Id
) = E_Procedure
);
5735 Set_Flag292
(Id
, V
);
5736 end Set_Is_Partial_Invariant_Procedure
;
5738 procedure Set_Is_Potentially_Use_Visible
(Id
: E
; V
: B
:= True) is
5740 pragma Assert
(Nkind
(Id
) in N_Entity
);
5742 end Set_Is_Potentially_Use_Visible
;
5744 procedure Set_Is_Predicate_Function
(Id
: E
; V
: B
:= True) is
5746 pragma Assert
(Ekind
(Id
) = E_Function
);
5747 Set_Flag255
(Id
, V
);
5748 end Set_Is_Predicate_Function
;
5750 procedure Set_Is_Predicate_Function_M
(Id
: E
; V
: B
:= True) is
5752 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
5753 Set_Flag256
(Id
, V
);
5754 end Set_Is_Predicate_Function_M
;
5756 procedure Set_Is_Preelaborated
(Id
: E
; V
: B
:= True) is
5759 end Set_Is_Preelaborated
;
5761 procedure Set_Is_Primitive
(Id
: E
; V
: B
:= True) is
5764 (Is_Overloadable
(Id
)
5765 or else Ekind_In
(Id
, E_Generic_Function
, E_Generic_Procedure
));
5766 Set_Flag218
(Id
, V
);
5767 end Set_Is_Primitive
;
5769 procedure Set_Is_Primitive_Wrapper
(Id
: E
; V
: B
:= True) is
5771 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
5772 Set_Flag195
(Id
, V
);
5773 end Set_Is_Primitive_Wrapper
;
5775 procedure Set_Is_Private_Composite
(Id
: E
; V
: B
:= True) is
5777 pragma Assert
(Is_Type
(Id
));
5778 Set_Flag107
(Id
, V
);
5779 end Set_Is_Private_Composite
;
5781 procedure Set_Is_Private_Descendant
(Id
: E
; V
: B
:= True) is
5784 end Set_Is_Private_Descendant
;
5786 procedure Set_Is_Private_Primitive
(Id
: E
; V
: B
:= True) is
5788 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
5789 Set_Flag245
(Id
, V
);
5790 end Set_Is_Private_Primitive
;
5792 procedure Set_Is_Public
(Id
: E
; V
: B
:= True) is
5794 pragma Assert
(Nkind
(Id
) in N_Entity
);
5798 procedure Set_Is_Pure
(Id
: E
; V
: B
:= True) is
5803 procedure Set_Is_Pure_Unit_Access_Type
(Id
: E
; V
: B
:= True) is
5805 pragma Assert
(Is_Access_Type
(Id
));
5806 Set_Flag189
(Id
, V
);
5807 end Set_Is_Pure_Unit_Access_Type
;
5809 procedure Set_Is_RACW_Stub_Type
(Id
: E
; V
: B
:= True) is
5811 pragma Assert
(Is_Type
(Id
));
5812 Set_Flag244
(Id
, V
);
5813 end Set_Is_RACW_Stub_Type
;
5815 procedure Set_Is_Raised
(Id
: E
; V
: B
:= True) is
5817 pragma Assert
(Ekind
(Id
) = E_Exception
);
5818 Set_Flag224
(Id
, V
);
5821 procedure Set_Is_Remote_Call_Interface
(Id
: E
; V
: B
:= True) is
5824 end Set_Is_Remote_Call_Interface
;
5826 procedure Set_Is_Remote_Types
(Id
: E
; V
: B
:= True) is
5829 end Set_Is_Remote_Types
;
5831 procedure Set_Is_Renaming_Of_Object
(Id
: E
; V
: B
:= True) is
5833 Set_Flag112
(Id
, V
);
5834 end Set_Is_Renaming_Of_Object
;
5836 procedure Set_Is_Return_Object
(Id
: E
; V
: B
:= True) is
5838 Set_Flag209
(Id
, V
);
5839 end Set_Is_Return_Object
;
5841 procedure Set_Is_Safe_To_Reevaluate
(Id
: E
; V
: B
:= True) is
5843 pragma Assert
(Ekind
(Id
) = E_Variable
);
5844 Set_Flag249
(Id
, V
);
5845 end Set_Is_Safe_To_Reevaluate
;
5847 procedure Set_Is_Shared_Passive
(Id
: E
; V
: B
:= True) is
5850 end Set_Is_Shared_Passive
;
5852 procedure Set_Is_Static_Type
(Id
: E
; V
: B
:= True) is
5854 pragma Assert
(Is_Type
(Id
));
5855 Set_Flag281
(Id
, V
);
5856 end Set_Is_Static_Type
;
5858 procedure Set_Is_Statically_Allocated
(Id
: E
; V
: B
:= True) is
5862 or else Ekind_In
(Id
, E_Exception
,
5867 end Set_Is_Statically_Allocated
;
5869 procedure Set_Is_Tag
(Id
: E
; V
: B
:= True) is
5871 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Constant
, E_Variable
));
5875 procedure Set_Is_Tagged_Type
(Id
: E
; V
: B
:= True) is
5878 end Set_Is_Tagged_Type
;
5880 procedure Set_Is_Thunk
(Id
: E
; V
: B
:= True) is
5882 pragma Assert
(Is_Subprogram
(Id
));
5883 Set_Flag225
(Id
, V
);
5886 procedure Set_Is_Trivial_Subprogram
(Id
: E
; V
: B
:= True) is
5888 Set_Flag235
(Id
, V
);
5889 end Set_Is_Trivial_Subprogram
;
5891 procedure Set_Is_True_Constant
(Id
: E
; V
: B
:= True) is
5893 Set_Flag163
(Id
, V
);
5894 end Set_Is_True_Constant
;
5896 procedure Set_Is_Unchecked_Union
(Id
: E
; V
: B
:= True) is
5898 pragma Assert
(Id
= Base_Type
(Id
));
5899 Set_Flag117
(Id
, V
);
5900 end Set_Is_Unchecked_Union
;
5902 procedure Set_Is_Underlying_Full_View
(Id
: E
; V
: B
:= True) is
5904 pragma Assert
(Is_Type
(Id
));
5905 Set_Flag298
(Id
, V
);
5906 end Set_Is_Underlying_Full_View
;
5908 procedure Set_Is_Underlying_Record_View
(Id
: E
; V
: B
:= True) is
5910 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
5911 Set_Flag246
(Id
, V
);
5912 end Set_Is_Underlying_Record_View
;
5914 procedure Set_Is_Unimplemented
(Id
: E
; V
: B
:= True) is
5916 Set_Flag284
(Id
, V
);
5917 end Set_Is_Unimplemented
;
5919 procedure Set_Is_Unsigned_Type
(Id
: E
; V
: B
:= True) is
5921 pragma Assert
(Is_Discrete_Or_Fixed_Point_Type
(Id
));
5922 Set_Flag144
(Id
, V
);
5923 end Set_Is_Unsigned_Type
;
5925 procedure Set_Is_Uplevel_Referenced_Entity
(Id
: E
; V
: B
:= True) is
5928 (Ekind_In
(Id
, E_Constant
, E_Variable
)
5929 or else Is_Formal
(Id
)
5930 or else Is_Type
(Id
));
5931 Set_Flag283
(Id
, V
);
5932 end Set_Is_Uplevel_Referenced_Entity
;
5934 procedure Set_Is_Valued_Procedure
(Id
: E
; V
: B
:= True) is
5936 pragma Assert
(Ekind
(Id
) = E_Procedure
);
5937 Set_Flag127
(Id
, V
);
5938 end Set_Is_Valued_Procedure
;
5940 procedure Set_Is_Visible_Formal
(Id
: E
; V
: B
:= True) is
5942 Set_Flag206
(Id
, V
);
5943 end Set_Is_Visible_Formal
;
5945 procedure Set_Is_Visible_Lib_Unit
(Id
: E
; V
: B
:= True) is
5947 Set_Flag116
(Id
, V
);
5948 end Set_Is_Visible_Lib_Unit
;
5950 procedure Set_Is_Volatile
(Id
: E
; V
: B
:= True) is
5952 pragma Assert
(Nkind
(Id
) in N_Entity
);
5954 end Set_Is_Volatile
;
5956 procedure Set_Is_Volatile_Full_Access
(Id
: E
; V
: B
:= True) is
5958 Set_Flag285
(Id
, V
);
5959 end Set_Is_Volatile_Full_Access
;
5961 procedure Set_Itype_Printed
(Id
: E
; V
: B
:= True) is
5963 pragma Assert
(Is_Itype
(Id
));
5964 Set_Flag202
(Id
, V
);
5965 end Set_Itype_Printed
;
5967 procedure Set_Kill_Elaboration_Checks
(Id
: E
; V
: B
:= True) is
5970 end Set_Kill_Elaboration_Checks
;
5972 procedure Set_Kill_Range_Checks
(Id
: E
; V
: B
:= True) is
5975 end Set_Kill_Range_Checks
;
5977 procedure Set_Known_To_Have_Preelab_Init
(Id
: E
; V
: B
:= True) is
5979 pragma Assert
(Is_Type
(Id
));
5980 Set_Flag207
(Id
, V
);
5981 end Set_Known_To_Have_Preelab_Init
;
5983 procedure Set_Last_Aggregate_Assignment
(Id
: E
; V
: N
) is
5985 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
5987 end Set_Last_Aggregate_Assignment
;
5989 procedure Set_Last_Assignment
(Id
: E
; V
: N
) is
5991 pragma Assert
(Is_Assignable
(Id
));
5993 end Set_Last_Assignment
;
5995 procedure Set_Last_Entity
(Id
: E
; V
: E
) is
5998 end Set_Last_Entity
;
6000 procedure Set_Limited_View
(Id
: E
; V
: E
) is
6002 pragma Assert
(Ekind
(Id
) = E_Package
);
6004 end Set_Limited_View
;
6006 procedure Set_Linker_Section_Pragma
(Id
: E
; V
: N
) is
6009 (Is_Object
(Id
) or else Is_Subprogram
(Id
) or else Is_Type
(Id
));
6011 end Set_Linker_Section_Pragma
;
6013 procedure Set_Lit_Indexes
(Id
: E
; V
: E
) is
6015 pragma Assert
(Is_Enumeration_Type
(Id
) and then Root_Type
(Id
) = Id
);
6017 end Set_Lit_Indexes
;
6019 procedure Set_Lit_Strings
(Id
: E
; V
: E
) is
6021 pragma Assert
(Is_Enumeration_Type
(Id
) and then Root_Type
(Id
) = Id
);
6023 end Set_Lit_Strings
;
6025 procedure Set_Low_Bound_Tested
(Id
: E
; V
: B
:= True) is
6027 pragma Assert
(Is_Formal
(Id
));
6028 Set_Flag205
(Id
, V
);
6029 end Set_Low_Bound_Tested
;
6031 procedure Set_Machine_Radix_10
(Id
: E
; V
: B
:= True) is
6033 pragma Assert
(Is_Decimal_Fixed_Point_Type
(Id
));
6035 end Set_Machine_Radix_10
;
6037 procedure Set_Master_Id
(Id
: E
; V
: E
) is
6039 pragma Assert
(Is_Access_Type
(Id
));
6043 procedure Set_Materialize_Entity
(Id
: E
; V
: B
:= True) is
6045 Set_Flag168
(Id
, V
);
6046 end Set_Materialize_Entity
;
6048 procedure Set_May_Inherit_Delayed_Rep_Aspects
(Id
: E
; V
: B
:= True) is
6050 Set_Flag262
(Id
, V
);
6051 end Set_May_Inherit_Delayed_Rep_Aspects
;
6053 procedure Set_Mechanism
(Id
: E
; V
: M
) is
6055 pragma Assert
(Ekind
(Id
) = E_Function
or else Is_Formal
(Id
));
6056 Set_Uint8
(Id
, UI_From_Int
(V
));
6059 procedure Set_Modulus
(Id
: E
; V
: U
) is
6061 pragma Assert
(Ekind
(Id
) = E_Modular_Integer_Type
);
6065 procedure Set_Must_Be_On_Byte_Boundary
(Id
: E
; V
: B
:= True) is
6067 pragma Assert
(Is_Type
(Id
));
6068 Set_Flag183
(Id
, V
);
6069 end Set_Must_Be_On_Byte_Boundary
;
6071 procedure Set_Must_Have_Preelab_Init
(Id
: E
; V
: B
:= True) is
6073 pragma Assert
(Is_Type
(Id
));
6074 Set_Flag208
(Id
, V
);
6075 end Set_Must_Have_Preelab_Init
;
6077 procedure Set_Needs_Debug_Info
(Id
: E
; V
: B
:= True) is
6079 Set_Flag147
(Id
, V
);
6080 end Set_Needs_Debug_Info
;
6082 procedure Set_Needs_No_Actuals
(Id
: E
; V
: B
:= True) is
6085 (Is_Overloadable
(Id
)
6086 or else Ekind_In
(Id
, E_Subprogram_Type
, E_Entry_Family
));
6088 end Set_Needs_No_Actuals
;
6090 procedure Set_Nested_Scenarios
(Id
: E
; V
: L
) is
6092 pragma Assert
(Ekind_In
(Id
, E_Function
,
6094 E_Subprogram_Body
));
6095 Set_Elist36
(Id
, V
);
6096 end Set_Nested_Scenarios
;
6098 procedure Set_Never_Set_In_Source
(Id
: E
; V
: B
:= True) is
6100 Set_Flag115
(Id
, V
);
6101 end Set_Never_Set_In_Source
;
6103 procedure Set_Next_Inlined_Subprogram
(Id
: E
; V
: E
) is
6106 end Set_Next_Inlined_Subprogram
;
6108 procedure Set_No_Dynamic_Predicate_On_Actual
(Id
: E
; V
: B
:= True) is
6110 pragma Assert
(Is_Discrete_Type
(Id
));
6111 Set_Flag276
(Id
, V
);
6112 end Set_No_Dynamic_Predicate_On_Actual
;
6114 procedure Set_No_Pool_Assigned
(Id
: E
; V
: B
:= True) is
6116 pragma Assert
(Is_Access_Type
(Id
) and then Is_Base_Type
(Id
));
6117 Set_Flag131
(Id
, V
);
6118 end Set_No_Pool_Assigned
;
6120 procedure Set_No_Predicate_On_Actual
(Id
: E
; V
: B
:= True) is
6122 pragma Assert
(Is_Discrete_Type
(Id
));
6123 Set_Flag275
(Id
, V
);
6124 end Set_No_Predicate_On_Actual
;
6126 procedure Set_No_Reordering
(Id
: E
; V
: B
:= True) is
6128 pragma Assert
(Is_Record_Type
(Id
) and then Is_Base_Type
(Id
));
6129 Set_Flag239
(Id
, V
);
6130 end Set_No_Reordering
;
6132 procedure Set_No_Return
(Id
: E
; V
: B
:= True) is
6135 (V
= False or else Ekind_In
(Id
, E_Procedure
, E_Generic_Procedure
));
6136 Set_Flag113
(Id
, V
);
6139 procedure Set_No_Strict_Aliasing
(Id
: E
; V
: B
:= True) is
6141 pragma Assert
(Is_Access_Type
(Id
) and then Is_Base_Type
(Id
));
6142 Set_Flag136
(Id
, V
);
6143 end Set_No_Strict_Aliasing
;
6145 procedure Set_No_Tagged_Streams_Pragma
(Id
: E
; V
: E
) is
6147 pragma Assert
(Is_Tagged_Type
(Id
));
6149 end Set_No_Tagged_Streams_Pragma
;
6151 procedure Set_Non_Binary_Modulus
(Id
: E
; V
: B
:= True) is
6153 pragma Assert
(Is_Type
(Id
) and then Is_Base_Type
(Id
));
6155 end Set_Non_Binary_Modulus
;
6157 procedure Set_Non_Limited_View
(Id
: E
; V
: E
) is
6160 (Ekind
(Id
) in Incomplete_Kind
6161 or else Ekind_In
(Id
, E_Abstract_State
, E_Class_Wide_Type
));
6163 end Set_Non_Limited_View
;
6165 procedure Set_Nonzero_Is_True
(Id
: E
; V
: B
:= True) is
6168 (Root_Type
(Id
) = Standard_Boolean
6169 and then Ekind
(Id
) = E_Enumeration_Type
);
6170 Set_Flag162
(Id
, V
);
6171 end Set_Nonzero_Is_True
;
6173 procedure Set_Normalized_First_Bit
(Id
: E
; V
: U
) is
6175 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
6177 end Set_Normalized_First_Bit
;
6179 procedure Set_Normalized_Position
(Id
: E
; V
: U
) is
6181 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
6183 end Set_Normalized_Position
;
6185 procedure Set_Normalized_Position_Max
(Id
: E
; V
: U
) is
6187 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Discriminant
));
6189 end Set_Normalized_Position_Max
;
6191 procedure Set_OK_To_Rename
(Id
: E
; V
: B
:= True) is
6193 pragma Assert
(Ekind
(Id
) = E_Variable
);
6194 Set_Flag247
(Id
, V
);
6195 end Set_OK_To_Rename
;
6197 procedure Set_Optimize_Alignment_Space
(Id
: E
; V
: B
:= True) is
6200 (Is_Type
(Id
) or else Ekind_In
(Id
, E_Constant
, E_Variable
));
6201 Set_Flag241
(Id
, V
);
6202 end Set_Optimize_Alignment_Space
;
6204 procedure Set_Optimize_Alignment_Time
(Id
: E
; V
: B
:= True) is
6207 (Is_Type
(Id
) or else Ekind_In
(Id
, E_Constant
, E_Variable
));
6208 Set_Flag242
(Id
, V
);
6209 end Set_Optimize_Alignment_Time
;
6211 procedure Set_Original_Access_Type
(Id
: E
; V
: E
) is
6213 pragma Assert
(Ekind
(Id
) = E_Access_Subprogram_Type
);
6215 end Set_Original_Access_Type
;
6217 procedure Set_Original_Array_Type
(Id
: E
; V
: E
) is
6219 pragma Assert
(Is_Array_Type
(Id
) or else Is_Modular_Integer_Type
(Id
));
6221 end Set_Original_Array_Type
;
6223 procedure Set_Original_Protected_Subprogram
(Id
: E
; V
: N
) is
6225 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
6227 end Set_Original_Protected_Subprogram
;
6229 procedure Set_Original_Record_Component
(Id
: E
; V
: E
) is
6231 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Component
, E_Discriminant
));
6233 end Set_Original_Record_Component
;
6235 procedure Set_Overlays_Constant
(Id
: E
; V
: B
:= True) is
6237 Set_Flag243
(Id
, V
);
6238 end Set_Overlays_Constant
;
6240 procedure Set_Overridden_Operation
(Id
: E
; V
: E
) is
6242 pragma Assert
(Is_Subprogram
(Id
) or else Is_Generic_Subprogram
(Id
));
6244 end Set_Overridden_Operation
;
6246 procedure Set_Package_Instantiation
(Id
: E
; V
: N
) is
6248 pragma Assert
(Ekind_In
(Id
, E_Void
, E_Generic_Package
, E_Package
));
6250 end Set_Package_Instantiation
;
6252 procedure Set_Packed_Array_Impl_Type
(Id
: E
; V
: E
) is
6254 pragma Assert
(Is_Array_Type
(Id
));
6256 end Set_Packed_Array_Impl_Type
;
6258 procedure Set_Parent_Subtype
(Id
: E
; V
: E
) is
6260 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
6262 end Set_Parent_Subtype
;
6264 procedure Set_Part_Of_Constituents
(Id
: E
; V
: L
) is
6266 pragma Assert
(Ekind_In
(Id
, E_Abstract_State
, E_Variable
));
6267 Set_Elist10
(Id
, V
);
6268 end Set_Part_Of_Constituents
;
6270 procedure Set_Part_Of_References
(Id
: E
; V
: L
) is
6272 pragma Assert
(Ekind
(Id
) = E_Variable
);
6273 Set_Elist11
(Id
, V
);
6274 end Set_Part_Of_References
;
6276 procedure Set_Partial_View_Has_Unknown_Discr
(Id
: E
; V
: B
:= True) is
6278 pragma Assert
(Is_Type
(Id
));
6279 Set_Flag280
(Id
, V
);
6280 end Set_Partial_View_Has_Unknown_Discr
;
6282 procedure Set_Pending_Access_Types
(Id
: E
; V
: L
) is
6284 pragma Assert
(Is_Type
(Id
));
6285 Set_Elist15
(Id
, V
);
6286 end Set_Pending_Access_Types
;
6288 procedure Set_Postconditions_Proc
(Id
: E
; V
: E
) is
6290 pragma Assert
(Ekind_In
(Id
, E_Entry
,
6295 end Set_Postconditions_Proc
;
6297 procedure Set_Predicates_Ignored
(Id
: E
; V
: B
) is
6299 pragma Assert
(Is_Type
(Id
));
6300 Set_Flag288
(Id
, V
);
6301 end Set_Predicates_Ignored
;
6303 procedure Set_Direct_Primitive_Operations
(Id
: E
; V
: L
) is
6305 pragma Assert
(Is_Tagged_Type
(Id
));
6306 Set_Elist10
(Id
, V
);
6307 end Set_Direct_Primitive_Operations
;
6309 procedure Set_Prival
(Id
: E
; V
: E
) is
6311 pragma Assert
(Is_Protected_Component
(Id
));
6315 procedure Set_Prival_Link
(Id
: E
; V
: E
) is
6317 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
6319 end Set_Prival_Link
;
6321 procedure Set_Private_Dependents
(Id
: E
; V
: L
) is
6323 pragma Assert
(Is_Incomplete_Or_Private_Type
(Id
));
6324 Set_Elist18
(Id
, V
);
6325 end Set_Private_Dependents
;
6327 procedure Set_Private_View
(Id
: E
; V
: N
) is
6329 pragma Assert
(Is_Private_Type
(Id
));
6331 end Set_Private_View
;
6333 procedure Set_Protected_Body_Subprogram
(Id
: E
; V
: E
) is
6335 pragma Assert
(Is_Subprogram
(Id
) or else Is_Entry
(Id
));
6337 end Set_Protected_Body_Subprogram
;
6339 procedure Set_Protected_Formal
(Id
: E
; V
: E
) is
6341 pragma Assert
(Is_Formal
(Id
));
6343 end Set_Protected_Formal
;
6345 procedure Set_Protected_Subprogram
(Id
: E
; V
: E
) is
6347 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
));
6349 end Set_Protected_Subprogram
;
6351 procedure Set_Protection_Object
(Id
: E
; V
: E
) is
6353 pragma Assert
(Ekind_In
(Id
, E_Entry
,
6358 end Set_Protection_Object
;
6360 procedure Set_Reachable
(Id
: E
; V
: B
:= True) is
6365 procedure Set_Receiving_Entry
(Id
: E
; V
: E
) is
6367 pragma Assert
(Ekind
(Id
) = E_Procedure
);
6369 end Set_Receiving_Entry
;
6371 procedure Set_Referenced
(Id
: E
; V
: B
:= True) is
6373 Set_Flag156
(Id
, V
);
6376 procedure Set_Referenced_As_LHS
(Id
: E
; V
: B
:= True) is
6379 end Set_Referenced_As_LHS
;
6381 procedure Set_Referenced_As_Out_Parameter
(Id
: E
; V
: B
:= True) is
6383 Set_Flag227
(Id
, V
);
6384 end Set_Referenced_As_Out_Parameter
;
6386 procedure Set_Refinement_Constituents
(Id
: E
; V
: L
) is
6388 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
6390 end Set_Refinement_Constituents
;
6392 procedure Set_Register_Exception_Call
(Id
: E
; V
: N
) is
6394 pragma Assert
(Ekind
(Id
) = E_Exception
);
6396 end Set_Register_Exception_Call
;
6398 procedure Set_Related_Array_Object
(Id
: E
; V
: E
) is
6400 pragma Assert
(Is_Array_Type
(Id
));
6402 end Set_Related_Array_Object
;
6404 procedure Set_Related_Expression
(Id
: E
; V
: N
) is
6406 pragma Assert
(Ekind
(Id
) in Type_Kind
6407 or else Ekind_In
(Id
, E_Constant
, E_Variable
, E_Void
));
6409 end Set_Related_Expression
;
6411 procedure Set_Related_Instance
(Id
: E
; V
: E
) is
6413 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Package_Body
));
6415 end Set_Related_Instance
;
6417 procedure Set_Related_Type
(Id
: E
; V
: E
) is
6419 pragma Assert
(Ekind_In
(Id
, E_Component
, E_Constant
, E_Variable
));
6421 end Set_Related_Type
;
6423 procedure Set_Relative_Deadline_Variable
(Id
: E
; V
: E
) is
6425 pragma Assert
(Is_Task_Type
(Id
) and then Is_Base_Type
(Id
));
6427 end Set_Relative_Deadline_Variable
;
6429 procedure Set_Renamed_Entity
(Id
: E
; V
: N
) is
6432 end Set_Renamed_Entity
;
6434 procedure Set_Renamed_In_Spec
(Id
: E
; V
: B
:= True) is
6436 pragma Assert
(Ekind
(Id
) = E_Package
);
6437 Set_Flag231
(Id
, V
);
6438 end Set_Renamed_In_Spec
;
6440 procedure Set_Renamed_Object
(Id
: E
; V
: N
) is
6443 end Set_Renamed_Object
;
6445 procedure Set_Renaming_Map
(Id
: E
; V
: U
) is
6448 end Set_Renaming_Map
;
6450 procedure Set_Requires_Overriding
(Id
: E
; V
: B
:= True) is
6452 pragma Assert
(Is_Overloadable
(Id
));
6453 Set_Flag213
(Id
, V
);
6454 end Set_Requires_Overriding
;
6456 procedure Set_Return_Present
(Id
: E
; V
: B
:= True) is
6459 end Set_Return_Present
;
6461 procedure Set_Return_Applies_To
(Id
: E
; V
: N
) is
6464 end Set_Return_Applies_To
;
6466 procedure Set_Returns_By_Ref
(Id
: E
; V
: B
:= True) is
6469 end Set_Returns_By_Ref
;
6471 procedure Set_Reverse_Bit_Order
(Id
: E
; V
: B
:= True) is
6474 (Is_Record_Type
(Id
) and then Is_Base_Type
(Id
));
6475 Set_Flag164
(Id
, V
);
6476 end Set_Reverse_Bit_Order
;
6478 procedure Set_Reverse_Storage_Order
(Id
: E
; V
: B
:= True) is
6482 and then (Is_Record_Type
(Id
) or else Is_Array_Type
(Id
)));
6484 end Set_Reverse_Storage_Order
;
6486 procedure Set_Rewritten_For_C
(Id
: E
; V
: B
:= True) is
6488 pragma Assert
(Ekind
(Id
) = E_Function
);
6489 Set_Flag287
(Id
, V
);
6490 end Set_Rewritten_For_C
;
6492 procedure Set_RM_Size
(Id
: E
; V
: U
) is
6494 pragma Assert
(Is_Type
(Id
));
6498 procedure Set_Scalar_Range
(Id
: E
; V
: N
) is
6501 end Set_Scalar_Range
;
6503 procedure Set_Scale_Value
(Id
: E
; V
: U
) is
6506 end Set_Scale_Value
;
6508 procedure Set_Scope_Depth_Value
(Id
: E
; V
: U
) is
6510 pragma Assert
(not Is_Record_Type
(Id
));
6512 end Set_Scope_Depth_Value
;
6514 procedure Set_Sec_Stack_Needed_For_Return
(Id
: E
; V
: B
:= True) is
6516 Set_Flag167
(Id
, V
);
6517 end Set_Sec_Stack_Needed_For_Return
;
6519 procedure Set_Shadow_Entities
(Id
: E
; V
: S
) is
6521 pragma Assert
(Ekind_In
(Id
, E_Package
, E_Generic_Package
));
6523 end Set_Shadow_Entities
;
6525 procedure Set_Shared_Var_Procs_Instance
(Id
: E
; V
: E
) is
6527 pragma Assert
(Ekind
(Id
) = E_Variable
);
6529 end Set_Shared_Var_Procs_Instance
;
6531 procedure Set_Size_Check_Code
(Id
: E
; V
: N
) is
6533 pragma Assert
(Ekind_In
(Id
, E_Constant
, E_Variable
));
6535 end Set_Size_Check_Code
;
6537 procedure Set_Size_Depends_On_Discriminant
(Id
: E
; V
: B
:= True) is
6539 Set_Flag177
(Id
, V
);
6540 end Set_Size_Depends_On_Discriminant
;
6542 procedure Set_Size_Known_At_Compile_Time
(Id
: E
; V
: B
:= True) is
6545 end Set_Size_Known_At_Compile_Time
;
6547 procedure Set_Small_Value
(Id
: E
; V
: R
) is
6549 pragma Assert
(Is_Fixed_Point_Type
(Id
));
6550 Set_Ureal21
(Id
, V
);
6551 end Set_Small_Value
;
6553 procedure Set_SPARK_Aux_Pragma
(Id
: E
; V
: N
) is
6556 (Ekind_In
(Id
, E_Protected_Type
, -- concurrent types
6559 Ekind_In
(Id
, E_Generic_Package
, -- packages
6563 end Set_SPARK_Aux_Pragma
;
6565 procedure Set_SPARK_Aux_Pragma_Inherited
(Id
: E
; V
: B
:= True) is
6568 (Ekind_In
(Id
, E_Protected_Type
, -- concurrent types
6571 Ekind_In
(Id
, E_Generic_Package
, -- packages
6574 Set_Flag266
(Id
, V
);
6575 end Set_SPARK_Aux_Pragma_Inherited
;
6577 procedure Set_SPARK_Pragma
(Id
: E
; V
: N
) is
6580 (Ekind_In
(Id
, E_Constant
, -- objects
6583 Ekind_In
(Id
, E_Abstract_State
, -- overloadable
6588 E_Generic_Procedure
,
6593 Ekind_In
(Id
, E_Generic_Package
, -- packages
6597 Ekind
(Id
) = E_Void
-- special purpose
6599 Ekind_In
(Id
, E_Protected_Body
, -- types
6604 end Set_SPARK_Pragma
;
6606 procedure Set_SPARK_Pragma_Inherited
(Id
: E
; V
: B
:= True) is
6609 (Ekind_In
(Id
, E_Constant
, -- objects
6612 Ekind_In
(Id
, E_Abstract_State
, -- overloadable
6617 E_Generic_Procedure
,
6622 Ekind_In
(Id
, E_Generic_Package
, -- packages
6626 Ekind
(Id
) = E_Void
-- special purpose
6628 Ekind_In
(Id
, E_Protected_Body
, -- types
6632 Set_Flag265
(Id
, V
);
6633 end Set_SPARK_Pragma_Inherited
;
6635 procedure Set_Spec_Entity
(Id
: E
; V
: E
) is
6637 pragma Assert
(Ekind
(Id
) = E_Package_Body
or else Is_Formal
(Id
));
6639 end Set_Spec_Entity
;
6641 procedure Set_SSO_Set_High_By_Default
(Id
: E
; V
: B
:= True) is
6645 and then (Is_Record_Type
(Id
) or else Is_Array_Type
(Id
)));
6646 Set_Flag273
(Id
, V
);
6647 end Set_SSO_Set_High_By_Default
;
6649 procedure Set_SSO_Set_Low_By_Default
(Id
: E
; V
: B
:= True) is
6653 and then (Is_Record_Type
(Id
) or else Is_Array_Type
(Id
)));
6654 Set_Flag272
(Id
, V
);
6655 end Set_SSO_Set_Low_By_Default
;
6657 procedure Set_Static_Discrete_Predicate
(Id
: E
; V
: S
) is
6659 pragma Assert
(Is_Discrete_Type
(Id
) and then Has_Predicates
(Id
));
6661 end Set_Static_Discrete_Predicate
;
6663 procedure Set_Static_Real_Or_String_Predicate
(Id
: E
; V
: N
) is
6665 pragma Assert
((Is_Real_Type
(Id
) or else Is_String_Type
(Id
))
6666 and then Has_Predicates
(Id
));
6668 end Set_Static_Real_Or_String_Predicate
;
6670 procedure Set_Status_Flag_Or_Transient_Decl
(Id
: E
; V
: E
) is
6672 pragma Assert
(Ekind_In
(Id
, E_Constant
,
6676 end Set_Status_Flag_Or_Transient_Decl
;
6678 procedure Set_Storage_Size_Variable
(Id
: E
; V
: E
) is
6680 pragma Assert
(Is_Access_Type
(Id
) or else Is_Task_Type
(Id
));
6681 pragma Assert
(Id
= Base_Type
(Id
));
6683 end Set_Storage_Size_Variable
;
6685 procedure Set_Static_Elaboration_Desired
(Id
: E
; V
: B
) is
6687 pragma Assert
(Ekind
(Id
) = E_Package
);
6689 end Set_Static_Elaboration_Desired
;
6691 procedure Set_Static_Initialization
(Id
: E
; V
: N
) is
6694 (Ekind
(Id
) = E_Procedure
and then not Is_Dispatching_Operation
(Id
));
6696 end Set_Static_Initialization
;
6698 procedure Set_Stored_Constraint
(Id
: E
; V
: L
) is
6700 pragma Assert
(Nkind
(Id
) in N_Entity
);
6701 Set_Elist23
(Id
, V
);
6702 end Set_Stored_Constraint
;
6704 procedure Set_Stores_Attribute_Old_Prefix
(Id
: E
; V
: B
:= True) is
6706 pragma Assert
(Ekind
(Id
) = E_Constant
);
6707 Set_Flag270
(Id
, V
);
6708 end Set_Stores_Attribute_Old_Prefix
;
6710 procedure Set_Strict_Alignment
(Id
: E
; V
: B
:= True) is
6712 pragma Assert
(Id
= Base_Type
(Id
));
6713 Set_Flag145
(Id
, V
);
6714 end Set_Strict_Alignment
;
6716 procedure Set_String_Literal_Length
(Id
: E
; V
: U
) is
6718 pragma Assert
(Ekind
(Id
) = E_String_Literal_Subtype
);
6720 end Set_String_Literal_Length
;
6722 procedure Set_String_Literal_Low_Bound
(Id
: E
; V
: N
) is
6724 pragma Assert
(Ekind
(Id
) = E_String_Literal_Subtype
);
6726 end Set_String_Literal_Low_Bound
;
6728 procedure Set_Subprograms_For_Type
(Id
: E
; V
: L
) is
6730 pragma Assert
(Is_Type
(Id
));
6731 Set_Elist29
(Id
, V
);
6732 end Set_Subprograms_For_Type
;
6734 procedure Set_Subps_Index
(Id
: E
; V
: U
) is
6736 pragma Assert
(Is_Subprogram
(Id
));
6738 end Set_Subps_Index
;
6740 procedure Set_Suppress_Elaboration_Warnings
(Id
: E
; V
: B
:= True) is
6742 Set_Flag303
(Id
, V
);
6743 end Set_Suppress_Elaboration_Warnings
;
6745 procedure Set_Suppress_Initialization
(Id
: E
; V
: B
:= True) is
6747 pragma Assert
(Is_Type
(Id
) or else Ekind
(Id
) = E_Variable
);
6748 Set_Flag105
(Id
, V
);
6749 end Set_Suppress_Initialization
;
6751 procedure Set_Suppress_Style_Checks
(Id
: E
; V
: B
:= True) is
6753 Set_Flag165
(Id
, V
);
6754 end Set_Suppress_Style_Checks
;
6756 procedure Set_Suppress_Value_Tracking_On_Call
(Id
: E
; V
: B
:= True) is
6758 Set_Flag217
(Id
, V
);
6759 end Set_Suppress_Value_Tracking_On_Call
;
6761 procedure Set_Task_Body_Procedure
(Id
: E
; V
: N
) is
6763 pragma Assert
(Ekind
(Id
) in Task_Kind
);
6765 end Set_Task_Body_Procedure
;
6767 procedure Set_Thunk_Entity
(Id
: E
; V
: E
) is
6769 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
6770 and then Is_Thunk
(Id
));
6772 end Set_Thunk_Entity
;
6774 procedure Set_Treat_As_Volatile
(Id
: E
; V
: B
:= True) is
6777 end Set_Treat_As_Volatile
;
6779 procedure Set_Underlying_Full_View
(Id
: E
; V
: E
) is
6781 pragma Assert
(Ekind
(Id
) in Private_Kind
);
6783 end Set_Underlying_Full_View
;
6785 procedure Set_Underlying_Record_View
(Id
: E
; V
: E
) is
6787 pragma Assert
(Ekind
(Id
) = E_Record_Type
);
6789 end Set_Underlying_Record_View
;
6791 procedure Set_Universal_Aliasing
(Id
: E
; V
: B
:= True) is
6793 pragma Assert
(Is_Type
(Id
) and then Is_Base_Type
(Id
));
6794 Set_Flag216
(Id
, V
);
6795 end Set_Universal_Aliasing
;
6797 procedure Set_Unset_Reference
(Id
: E
; V
: N
) is
6800 end Set_Unset_Reference
;
6802 procedure Set_Used_As_Generic_Actual
(Id
: E
; V
: B
:= True) is
6804 Set_Flag222
(Id
, V
);
6805 end Set_Used_As_Generic_Actual
;
6807 procedure Set_Uses_Lock_Free
(Id
: E
; V
: B
:= True) is
6809 pragma Assert
(Ekind
(Id
) = E_Protected_Type
);
6810 Set_Flag188
(Id
, V
);
6811 end Set_Uses_Lock_Free
;
6813 procedure Set_Uses_Sec_Stack
(Id
: E
; V
: B
:= True) is
6816 end Set_Uses_Sec_Stack
;
6818 procedure Set_Validated_Object
(Id
: E
; V
: N
) is
6820 pragma Assert
(Ekind
(Id
) = E_Variable
);
6822 end Set_Validated_Object
;
6824 procedure Set_Warnings_Off
(Id
: E
; V
: B
:= True) is
6827 end Set_Warnings_Off
;
6829 procedure Set_Warnings_Off_Used
(Id
: E
; V
: B
:= True) is
6831 Set_Flag236
(Id
, V
);
6832 end Set_Warnings_Off_Used
;
6834 procedure Set_Warnings_Off_Used_Unmodified
(Id
: E
; V
: B
:= True) is
6836 Set_Flag237
(Id
, V
);
6837 end Set_Warnings_Off_Used_Unmodified
;
6839 procedure Set_Warnings_Off_Used_Unreferenced
(Id
: E
; V
: B
:= True) is
6841 Set_Flag238
(Id
, V
);
6842 end Set_Warnings_Off_Used_Unreferenced
;
6844 procedure Set_Was_Hidden
(Id
: E
; V
: B
:= True) is
6846 Set_Flag196
(Id
, V
);
6849 procedure Set_Wrapped_Entity
(Id
: E
; V
: E
) is
6851 pragma Assert
(Ekind_In
(Id
, E_Function
, E_Procedure
)
6852 and then Is_Primitive_Wrapper
(Id
));
6854 end Set_Wrapped_Entity
;
6856 -----------------------------------
6857 -- Field Initialization Routines --
6858 -----------------------------------
6860 procedure Init_Alignment
(Id
: E
) is
6862 Set_Uint14
(Id
, Uint_0
);
6865 procedure Init_Alignment
(Id
: E
; V
: Int
) is
6867 Set_Uint14
(Id
, UI_From_Int
(V
));
6870 procedure Init_Component_Bit_Offset
(Id
: E
) is
6872 Set_Uint11
(Id
, No_Uint
);
6873 end Init_Component_Bit_Offset
;
6875 procedure Init_Component_Bit_Offset
(Id
: E
; V
: Int
) is
6877 Set_Uint11
(Id
, UI_From_Int
(V
));
6878 end Init_Component_Bit_Offset
;
6880 procedure Init_Component_Size
(Id
: E
) is
6882 Set_Uint22
(Id
, Uint_0
);
6883 end Init_Component_Size
;
6885 procedure Init_Component_Size
(Id
: E
; V
: Int
) is
6887 Set_Uint22
(Id
, UI_From_Int
(V
));
6888 end Init_Component_Size
;
6890 procedure Init_Digits_Value
(Id
: E
) is
6892 Set_Uint17
(Id
, Uint_0
);
6893 end Init_Digits_Value
;
6895 procedure Init_Digits_Value
(Id
: E
; V
: Int
) is
6897 Set_Uint17
(Id
, UI_From_Int
(V
));
6898 end Init_Digits_Value
;
6900 procedure Init_Esize
(Id
: E
) is
6902 Set_Uint12
(Id
, Uint_0
);
6905 procedure Init_Esize
(Id
: E
; V
: Int
) is
6907 Set_Uint12
(Id
, UI_From_Int
(V
));
6910 procedure Init_Normalized_First_Bit
(Id
: E
) is
6912 Set_Uint8
(Id
, No_Uint
);
6913 end Init_Normalized_First_Bit
;
6915 procedure Init_Normalized_First_Bit
(Id
: E
; V
: Int
) is
6917 Set_Uint8
(Id
, UI_From_Int
(V
));
6918 end Init_Normalized_First_Bit
;
6920 procedure Init_Normalized_Position
(Id
: E
) is
6922 Set_Uint14
(Id
, No_Uint
);
6923 end Init_Normalized_Position
;
6925 procedure Init_Normalized_Position
(Id
: E
; V
: Int
) is
6927 Set_Uint14
(Id
, UI_From_Int
(V
));
6928 end Init_Normalized_Position
;
6930 procedure Init_Normalized_Position_Max
(Id
: E
) is
6932 Set_Uint10
(Id
, No_Uint
);
6933 end Init_Normalized_Position_Max
;
6935 procedure Init_Normalized_Position_Max
(Id
: E
; V
: Int
) is
6937 Set_Uint10
(Id
, UI_From_Int
(V
));
6938 end Init_Normalized_Position_Max
;
6940 procedure Init_RM_Size
(Id
: E
) is
6942 Set_Uint13
(Id
, Uint_0
);
6945 procedure Init_RM_Size
(Id
: E
; V
: Int
) is
6947 Set_Uint13
(Id
, UI_From_Int
(V
));
6950 -----------------------------
6951 -- Init_Component_Location --
6952 -----------------------------
6954 procedure Init_Component_Location
(Id
: E
) is
6956 Set_Uint8
(Id
, No_Uint
); -- Normalized_First_Bit
6957 Set_Uint10
(Id
, No_Uint
); -- Normalized_Position_Max
6958 Set_Uint11
(Id
, No_Uint
); -- Component_Bit_Offset
6959 Set_Uint12
(Id
, Uint_0
); -- Esize
6960 Set_Uint14
(Id
, No_Uint
); -- Normalized_Position
6961 end Init_Component_Location
;
6963 ----------------------------
6964 -- Init_Object_Size_Align --
6965 ----------------------------
6967 procedure Init_Object_Size_Align
(Id
: E
) is
6969 Set_Uint12
(Id
, Uint_0
); -- Esize
6970 Set_Uint14
(Id
, Uint_0
); -- Alignment
6971 end Init_Object_Size_Align
;
6977 procedure Init_Size
(Id
: E
; V
: Int
) is
6979 pragma Assert
(not Is_Object
(Id
));
6980 Set_Uint12
(Id
, UI_From_Int
(V
)); -- Esize
6981 Set_Uint13
(Id
, UI_From_Int
(V
)); -- RM_Size
6984 ---------------------
6985 -- Init_Size_Align --
6986 ---------------------
6988 procedure Init_Size_Align
(Id
: E
) is
6990 pragma Assert
(not Is_Object
(Id
));
6991 Set_Uint12
(Id
, Uint_0
); -- Esize
6992 Set_Uint13
(Id
, Uint_0
); -- RM_Size
6993 Set_Uint14
(Id
, Uint_0
); -- Alignment
6994 end Init_Size_Align
;
6996 ----------------------------------------------
6997 -- Type Representation Attribute Predicates --
6998 ----------------------------------------------
7000 function Known_Alignment
(E
: Entity_Id
) return B
is
7002 return Uint14
(E
) /= Uint_0
7003 and then Uint14
(E
) /= No_Uint
;
7004 end Known_Alignment
;
7006 function Known_Component_Bit_Offset
(E
: Entity_Id
) return B
is
7008 return Uint11
(E
) /= No_Uint
;
7009 end Known_Component_Bit_Offset
;
7011 function Known_Component_Size
(E
: Entity_Id
) return B
is
7013 return Uint22
(Base_Type
(E
)) /= Uint_0
7014 and then Uint22
(Base_Type
(E
)) /= No_Uint
;
7015 end Known_Component_Size
;
7017 function Known_Esize
(E
: Entity_Id
) return B
is
7019 return Uint12
(E
) /= Uint_0
7020 and then Uint12
(E
) /= No_Uint
;
7023 function Known_Normalized_First_Bit
(E
: Entity_Id
) return B
is
7025 return Uint8
(E
) /= No_Uint
;
7026 end Known_Normalized_First_Bit
;
7028 function Known_Normalized_Position
(E
: Entity_Id
) return B
is
7030 return Uint14
(E
) /= No_Uint
;
7031 end Known_Normalized_Position
;
7033 function Known_Normalized_Position_Max
(E
: Entity_Id
) return B
is
7035 return Uint10
(E
) /= No_Uint
;
7036 end Known_Normalized_Position_Max
;
7038 function Known_RM_Size
(E
: Entity_Id
) return B
is
7040 return Uint13
(E
) /= No_Uint
7041 and then (Uint13
(E
) /= Uint_0
7042 or else Is_Discrete_Type
(E
)
7043 or else Is_Fixed_Point_Type
(E
));
7046 function Known_Static_Component_Bit_Offset
(E
: Entity_Id
) return B
is
7048 return Uint11
(E
) /= No_Uint
7049 and then Uint11
(E
) >= Uint_0
;
7050 end Known_Static_Component_Bit_Offset
;
7052 function Known_Static_Component_Size
(E
: Entity_Id
) return B
is
7054 return Uint22
(Base_Type
(E
)) > Uint_0
;
7055 end Known_Static_Component_Size
;
7057 function Known_Static_Esize
(E
: Entity_Id
) return B
is
7059 return Uint12
(E
) > Uint_0
7060 and then not Is_Generic_Type
(E
);
7061 end Known_Static_Esize
;
7063 function Known_Static_Normalized_First_Bit
(E
: Entity_Id
) return B
is
7065 return Uint8
(E
) /= No_Uint
7066 and then Uint8
(E
) >= Uint_0
;
7067 end Known_Static_Normalized_First_Bit
;
7069 function Known_Static_Normalized_Position
(E
: Entity_Id
) return B
is
7071 return Uint14
(E
) /= No_Uint
7072 and then Uint14
(E
) >= Uint_0
;
7073 end Known_Static_Normalized_Position
;
7075 function Known_Static_Normalized_Position_Max
(E
: Entity_Id
) return B
is
7077 return Uint10
(E
) /= No_Uint
7078 and then Uint10
(E
) >= Uint_0
;
7079 end Known_Static_Normalized_Position_Max
;
7081 function Known_Static_RM_Size
(E
: Entity_Id
) return B
is
7083 return (Uint13
(E
) > Uint_0
7084 or else Is_Discrete_Type
(E
)
7085 or else Is_Fixed_Point_Type
(E
))
7086 and then not Is_Generic_Type
(E
);
7087 end Known_Static_RM_Size
;
7089 function Unknown_Alignment
(E
: Entity_Id
) return B
is
7091 return Uint14
(E
) = Uint_0
7092 or else Uint14
(E
) = No_Uint
;
7093 end Unknown_Alignment
;
7095 function Unknown_Component_Bit_Offset
(E
: Entity_Id
) return B
is
7097 return Uint11
(E
) = No_Uint
;
7098 end Unknown_Component_Bit_Offset
;
7100 function Unknown_Component_Size
(E
: Entity_Id
) return B
is
7102 return Uint22
(Base_Type
(E
)) = Uint_0
7104 Uint22
(Base_Type
(E
)) = No_Uint
;
7105 end Unknown_Component_Size
;
7107 function Unknown_Esize
(E
: Entity_Id
) return B
is
7109 return Uint12
(E
) = No_Uint
7111 Uint12
(E
) = Uint_0
;
7114 function Unknown_Normalized_First_Bit
(E
: Entity_Id
) return B
is
7116 return Uint8
(E
) = No_Uint
;
7117 end Unknown_Normalized_First_Bit
;
7119 function Unknown_Normalized_Position
(E
: Entity_Id
) return B
is
7121 return Uint14
(E
) = No_Uint
;
7122 end Unknown_Normalized_Position
;
7124 function Unknown_Normalized_Position_Max
(E
: Entity_Id
) return B
is
7126 return Uint10
(E
) = No_Uint
;
7127 end Unknown_Normalized_Position_Max
;
7129 function Unknown_RM_Size
(E
: Entity_Id
) return B
is
7131 return (Uint13
(E
) = Uint_0
7132 and then not Is_Discrete_Type
(E
)
7133 and then not Is_Fixed_Point_Type
(E
))
7134 or else Uint13
(E
) = No_Uint
;
7135 end Unknown_RM_Size
;
7137 --------------------
7138 -- Address_Clause --
7139 --------------------
7141 function Address_Clause
(Id
: E
) return N
is
7143 return Get_Attribute_Definition_Clause
(Id
, Attribute_Address
);
7150 function Aft_Value
(Id
: E
) return U
is
7152 Delta_Val
: Ureal
:= Delta_Value
(Id
);
7154 while Delta_Val
< Ureal_Tenth
loop
7155 Delta_Val
:= Delta_Val
* Ureal_10
;
7156 Result
:= Result
+ 1;
7159 return UI_From_Int
(Result
);
7162 ----------------------
7163 -- Alignment_Clause --
7164 ----------------------
7166 function Alignment_Clause
(Id
: E
) return N
is
7168 return Get_Attribute_Definition_Clause
(Id
, Attribute_Alignment
);
7169 end Alignment_Clause
;
7175 procedure Append_Entity
(Id
: Entity_Id
; V
: Entity_Id
) is
7177 if Last_Entity
(V
) = Empty
then
7178 Set_First_Entity
(Id
=> V
, V
=> Id
);
7180 Set_Next_Entity
(Last_Entity
(V
), Id
);
7183 Set_Next_Entity
(Id
, Empty
);
7185 Set_Last_Entity
(Id
=> V
, V
=> Id
);
7192 function Base_Type
(Id
: E
) return E
is
7194 if Is_Base_Type
(Id
) then
7197 pragma Assert
(Is_Type
(Id
));
7202 -------------------------
7203 -- Component_Alignment --
7204 -------------------------
7206 -- Component Alignment is encoded using two flags, Flag128/129 as
7207 -- follows. Note that both flags False = Align_Default, so that the
7208 -- default initialization of flags to False initializes component
7209 -- alignment to the default value as required.
7211 -- Flag128 Flag129 Value
7212 -- ------- ------- -----
7213 -- False False Calign_Default
7214 -- False True Calign_Component_Size
7215 -- True False Calign_Component_Size_4
7216 -- True True Calign_Storage_Unit
7218 function Component_Alignment
(Id
: E
) return C
is
7219 BT
: constant Node_Id
:= Base_Type
(Id
);
7222 pragma Assert
(Is_Array_Type
(Id
) or else Is_Record_Type
(Id
));
7224 if Flag128
(BT
) then
7225 if Flag129
(BT
) then
7226 return Calign_Storage_Unit
;
7228 return Calign_Component_Size_4
;
7232 if Flag129
(BT
) then
7233 return Calign_Component_Size
;
7235 return Calign_Default
;
7238 end Component_Alignment
;
7240 ----------------------
7241 -- Declaration_Node --
7242 ----------------------
7244 function Declaration_Node
(Id
: E
) return N
is
7248 if Ekind
(Id
) = E_Incomplete_Type
7249 and then Present
(Full_View
(Id
))
7251 P
:= Parent
(Full_View
(Id
));
7257 if Nkind_In
(P
, N_Selected_Component
, N_Expanded_Name
)
7258 or else (Nkind
(P
) = N_Defining_Program_Unit_Name
7259 and then Is_Child_Unit
(Id
))
7266 end Declaration_Node
;
7268 ---------------------
7269 -- Designated_Type --
7270 ---------------------
7272 function Designated_Type
(Id
: E
) return E
is
7276 Desig_Type
:= Directly_Designated_Type
(Id
);
7278 if Is_Incomplete_Type
(Desig_Type
)
7279 and then Present
(Full_View
(Desig_Type
))
7281 return Full_View
(Desig_Type
);
7283 elsif Is_Class_Wide_Type
(Desig_Type
)
7284 and then Is_Incomplete_Type
(Etype
(Desig_Type
))
7285 and then Present
(Full_View
(Etype
(Desig_Type
)))
7286 and then Present
(Class_Wide_Type
(Full_View
(Etype
(Desig_Type
))))
7288 return Class_Wide_Type
(Full_View
(Etype
(Desig_Type
)));
7293 end Designated_Type
;
7299 function DIC_Procedure
(Id
: E
) return E
is
7300 Subp_Elmt
: Elmt_Id
;
7301 Subp_Id
: Entity_Id
;
7305 pragma Assert
(Is_Type
(Id
));
7307 Subps
:= Subprograms_For_Type
(Base_Type
(Id
));
7309 if Present
(Subps
) then
7310 Subp_Elmt
:= First_Elmt
(Subps
);
7311 while Present
(Subp_Elmt
) loop
7312 Subp_Id
:= Node
(Subp_Elmt
);
7314 if Is_DIC_Procedure
(Subp_Id
) then
7318 Next_Elmt
(Subp_Elmt
);
7325 ----------------------
7326 -- Entry_Index_Type --
7327 ----------------------
7329 function Entry_Index_Type
(Id
: E
) return N
is
7331 pragma Assert
(Ekind
(Id
) = E_Entry_Family
);
7332 return Etype
(Discrete_Subtype_Definition
(Parent
(Id
)));
7333 end Entry_Index_Type
;
7335 ---------------------
7336 -- First_Component --
7337 ---------------------
7339 function First_Component
(Id
: E
) return E
is
7344 (Is_Concurrent_Type
(Id
)
7345 or else Is_Incomplete_Or_Private_Type
(Id
)
7346 or else Is_Record_Type
(Id
));
7348 Comp_Id
:= First_Entity
(Id
);
7349 while Present
(Comp_Id
) loop
7350 exit when Ekind
(Comp_Id
) = E_Component
;
7351 Comp_Id
:= Next_Entity
(Comp_Id
);
7355 end First_Component
;
7357 -------------------------------------
7358 -- First_Component_Or_Discriminant --
7359 -------------------------------------
7361 function First_Component_Or_Discriminant
(Id
: E
) return E
is
7366 (Is_Concurrent_Type
(Id
)
7367 or else Is_Incomplete_Or_Private_Type
(Id
)
7368 or else Is_Record_Type
(Id
)
7369 or else Has_Discriminants
(Id
));
7371 Comp_Id
:= First_Entity
(Id
);
7372 while Present
(Comp_Id
) loop
7373 exit when Ekind_In
(Comp_Id
, E_Component
, E_Discriminant
);
7374 Comp_Id
:= Next_Entity
(Comp_Id
);
7378 end First_Component_Or_Discriminant
;
7384 function First_Formal
(Id
: E
) return E
is
7389 (Is_Generic_Subprogram
(Id
)
7390 or else Is_Overloadable
(Id
)
7391 or else Ekind_In
(Id
, E_Entry_Family
,
7393 E_Subprogram_Type
));
7395 if Ekind
(Id
) = E_Enumeration_Literal
then
7399 Formal
:= First_Entity
(Id
);
7401 -- Deal with the common, non-generic case first
7403 if No
(Formal
) or else Is_Formal
(Formal
) then
7407 -- The first/next entity chain of a generic subprogram contains all
7408 -- generic formal parameters, followed by the formal parameters.
7410 if Is_Generic_Subprogram
(Id
) then
7411 while Present
(Formal
) and then not Is_Formal
(Formal
) loop
7412 Next_Entity
(Formal
);
7421 ------------------------------
7422 -- First_Formal_With_Extras --
7423 ------------------------------
7425 function First_Formal_With_Extras
(Id
: E
) return E
is
7430 (Is_Generic_Subprogram
(Id
)
7431 or else Is_Overloadable
(Id
)
7432 or else Ekind_In
(Id
, E_Entry_Family
,
7434 E_Subprogram_Type
));
7436 if Ekind
(Id
) = E_Enumeration_Literal
then
7440 Formal
:= First_Entity
(Id
);
7442 -- The first/next entity chain of a generic subprogram contains all
7443 -- generic formal parameters, followed by the formal parameters. Go
7444 -- directly to the parameters by skipping the formal part.
7446 if Is_Generic_Subprogram
(Id
) then
7447 while Present
(Formal
) and then not Is_Formal
(Formal
) loop
7448 Next_Entity
(Formal
);
7452 if Present
(Formal
) and then Is_Formal
(Formal
) then
7455 return Extra_Formals
(Id
); -- Empty if no extra formals
7458 end First_Formal_With_Extras
;
7460 -------------------------------------
7461 -- Get_Attribute_Definition_Clause --
7462 -------------------------------------
7464 function Get_Attribute_Definition_Clause
7466 Id
: Attribute_Id
) return Node_Id
7471 N
:= First_Rep_Item
(E
);
7472 while Present
(N
) loop
7473 if Nkind
(N
) = N_Attribute_Definition_Clause
7474 and then Get_Attribute_Id
(Chars
(N
)) = Id
7483 end Get_Attribute_Definition_Clause
;
7485 ---------------------------
7486 -- Get_Class_Wide_Pragma --
7487 ---------------------------
7489 function Get_Class_Wide_Pragma
7491 Id
: Pragma_Id
) return Node_Id
7497 Items
:= Contract
(E
);
7503 Item
:= Pre_Post_Conditions
(Items
);
7504 while Present
(Item
) loop
7505 if Nkind
(Item
) = N_Pragma
7506 and then Get_Pragma_Id
(Pragma_Name_Unmapped
(Item
)) = Id
7507 and then Class_Present
(Item
)
7512 Item
:= Next_Pragma
(Item
);
7516 end Get_Class_Wide_Pragma
;
7522 function Get_Full_View
(T
: Entity_Id
) return Entity_Id
is
7524 if Is_Incomplete_Type
(T
) and then Present
(Full_View
(T
)) then
7525 return Full_View
(T
);
7527 elsif Is_Class_Wide_Type
(T
)
7528 and then Is_Incomplete_Type
(Root_Type
(T
))
7529 and then Present
(Full_View
(Root_Type
(T
)))
7531 return Class_Wide_Type
(Full_View
(Root_Type
(T
)));
7542 function Get_Pragma
(E
: Entity_Id
; Id
: Pragma_Id
) return Node_Id
is
7544 -- Classification pragmas
7546 Is_CLS
: constant Boolean :=
7547 Id
= Pragma_Abstract_State
or else
7548 Id
= Pragma_Attach_Handler
or else
7549 Id
= Pragma_Async_Readers
or else
7550 Id
= Pragma_Async_Writers
or else
7551 Id
= Pragma_Constant_After_Elaboration
or else
7552 Id
= Pragma_Depends
or else
7553 Id
= Pragma_Effective_Reads
or else
7554 Id
= Pragma_Effective_Writes
or else
7555 Id
= Pragma_Extensions_Visible
or else
7556 Id
= Pragma_Global
or else
7557 Id
= Pragma_Initial_Condition
or else
7558 Id
= Pragma_Initializes
or else
7559 Id
= Pragma_Interrupt_Handler
or else
7560 Id
= Pragma_Part_Of
or else
7561 Id
= Pragma_Refined_Depends
or else
7562 Id
= Pragma_Refined_Global
or else
7563 Id
= Pragma_Refined_State
or else
7564 Id
= Pragma_Volatile_Function
;
7566 -- Contract / test case pragmas
7568 Is_CTC
: constant Boolean :=
7569 Id
= Pragma_Contract_Cases
or else
7570 Id
= Pragma_Test_Case
;
7572 -- Pre / postcondition pragmas
7574 Is_PPC
: constant Boolean :=
7575 Id
= Pragma_Precondition
or else
7576 Id
= Pragma_Postcondition
or else
7577 Id
= Pragma_Refined_Post
;
7579 In_Contract
: constant Boolean := Is_CLS
or Is_CTC
or Is_PPC
;
7585 -- Handle pragmas that appear in N_Contract nodes. Those have to be
7586 -- extracted from their specialized list.
7589 Items
:= Contract
(E
);
7595 Item
:= Classifications
(Items
);
7598 Item
:= Contract_Test_Cases
(Items
);
7601 Item
:= Pre_Post_Conditions
(Items
);
7607 Item
:= First_Rep_Item
(E
);
7610 while Present
(Item
) loop
7611 if Nkind
(Item
) = N_Pragma
7612 and then Get_Pragma_Id
(Pragma_Name_Unmapped
(Item
)) = Id
7616 -- All nodes in N_Contract are chained using Next_Pragma
7618 elsif In_Contract
then
7619 Item
:= Next_Pragma
(Item
);
7624 Next_Rep_Item
(Item
);
7631 --------------------------------------
7632 -- Get_Record_Representation_Clause --
7633 --------------------------------------
7635 function Get_Record_Representation_Clause
(E
: Entity_Id
) return Node_Id
is
7639 N
:= First_Rep_Item
(E
);
7640 while Present
(N
) loop
7641 if Nkind
(N
) = N_Record_Representation_Clause
then
7649 end Get_Record_Representation_Clause
;
7651 ------------------------
7652 -- Has_Attach_Handler --
7653 ------------------------
7655 function Has_Attach_Handler
(Id
: E
) return B
is
7659 pragma Assert
(Is_Protected_Type
(Id
));
7661 Ritem
:= First_Rep_Item
(Id
);
7662 while Present
(Ritem
) loop
7663 if Nkind
(Ritem
) = N_Pragma
7664 and then Pragma_Name
(Ritem
) = Name_Attach_Handler
7668 Next_Rep_Item
(Ritem
);
7673 end Has_Attach_Handler
;
7679 function Has_DIC
(Id
: E
) return B
is
7681 return Has_Own_DIC
(Id
) or else Has_Inherited_DIC
(Id
);
7688 function Has_Entries
(Id
: E
) return B
is
7692 pragma Assert
(Is_Concurrent_Type
(Id
));
7694 Ent
:= First_Entity
(Id
);
7695 while Present
(Ent
) loop
7696 if Is_Entry
(Ent
) then
7700 Ent
:= Next_Entity
(Ent
);
7706 ----------------------------
7707 -- Has_Foreign_Convention --
7708 ----------------------------
7710 function Has_Foreign_Convention
(Id
: E
) return B
is
7712 -- While regular Intrinsics such as the Standard operators fit in the
7713 -- "Ada" convention, those with an Interface_Name materialize GCC
7714 -- builtin imports for which Ada special treatments shouldn't apply.
7716 return Convention
(Id
) in Foreign_Convention
7717 or else (Convention
(Id
) = Convention_Intrinsic
7718 and then Present
(Interface_Name
(Id
)));
7719 end Has_Foreign_Convention
;
7721 ---------------------------
7722 -- Has_Interrupt_Handler --
7723 ---------------------------
7725 function Has_Interrupt_Handler
(Id
: E
) return B
is
7729 pragma Assert
(Is_Protected_Type
(Id
));
7731 Ritem
:= First_Rep_Item
(Id
);
7732 while Present
(Ritem
) loop
7733 if Nkind
(Ritem
) = N_Pragma
7734 and then Pragma_Name
(Ritem
) = Name_Interrupt_Handler
7738 Next_Rep_Item
(Ritem
);
7743 end Has_Interrupt_Handler
;
7745 --------------------
7746 -- Has_Invariants --
7747 --------------------
7749 function Has_Invariants
(Id
: E
) return B
is
7751 return Has_Own_Invariants
(Id
) or else Has_Inherited_Invariants
(Id
);
7754 --------------------------
7755 -- Has_Non_Limited_View --
7756 --------------------------
7758 function Has_Non_Limited_View
(Id
: E
) return B
is
7760 return (Ekind
(Id
) in Incomplete_Kind
7761 or else Ekind
(Id
) in Class_Wide_Kind
7762 or else Ekind
(Id
) = E_Abstract_State
)
7763 and then Present
(Non_Limited_View
(Id
));
7764 end Has_Non_Limited_View
;
7766 ---------------------------------
7767 -- Has_Non_Null_Abstract_State --
7768 ---------------------------------
7770 function Has_Non_Null_Abstract_State
(Id
: E
) return B
is
7772 pragma Assert
(Ekind_In
(Id
, E_Generic_Package
, E_Package
));
7775 Present
(Abstract_States
(Id
))
7777 not Is_Null_State
(Node
(First_Elmt
(Abstract_States
(Id
))));
7778 end Has_Non_Null_Abstract_State
;
7780 -------------------------------------
7781 -- Has_Non_Null_Visible_Refinement --
7782 -------------------------------------
7784 function Has_Non_Null_Visible_Refinement
(Id
: E
) return B
is
7785 Constits
: Elist_Id
;
7788 -- "Refinement" is a concept applicable only to abstract states
7790 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
7791 Constits
:= Refinement_Constituents
(Id
);
7793 -- A partial refinement is always non-null. For a full refinement to be
7794 -- non-null, the first constituent must be anything other than null.
7797 Has_Partial_Visible_Refinement
(Id
)
7798 or else (Has_Visible_Refinement
(Id
)
7799 and then Present
(Constits
)
7800 and then Nkind
(Node
(First_Elmt
(Constits
))) /= N_Null
);
7801 end Has_Non_Null_Visible_Refinement
;
7803 -----------------------------
7804 -- Has_Null_Abstract_State --
7805 -----------------------------
7807 function Has_Null_Abstract_State
(Id
: E
) return B
is
7808 pragma Assert
(Ekind_In
(Id
, E_Generic_Package
, E_Package
));
7810 States
: constant Elist_Id
:= Abstract_States
(Id
);
7813 -- Check first available state of related package. A null abstract
7814 -- state always appears as the sole element of the state list.
7818 and then Is_Null_State
(Node
(First_Elmt
(States
)));
7819 end Has_Null_Abstract_State
;
7821 ---------------------------------
7822 -- Has_Null_Visible_Refinement --
7823 ---------------------------------
7825 function Has_Null_Visible_Refinement
(Id
: E
) return B
is
7826 Constits
: Elist_Id
;
7829 -- "Refinement" is a concept applicable only to abstract states
7831 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
7832 Constits
:= Refinement_Constituents
(Id
);
7834 -- For a refinement to be null, the state's sole constituent must be a
7838 Has_Visible_Refinement
(Id
)
7839 and then Present
(Constits
)
7840 and then Nkind
(Node
(First_Elmt
(Constits
))) = N_Null
;
7841 end Has_Null_Visible_Refinement
;
7843 --------------------
7844 -- Has_Unmodified --
7845 --------------------
7847 function Has_Unmodified
(E
: Entity_Id
) return Boolean is
7849 if Has_Pragma_Unmodified
(E
) then
7851 elsif Warnings_Off
(E
) then
7852 Set_Warnings_Off_Used_Unmodified
(E
);
7859 ---------------------
7860 -- Has_Unreferenced --
7861 ---------------------
7863 function Has_Unreferenced
(E
: Entity_Id
) return Boolean is
7865 if Has_Pragma_Unreferenced
(E
) then
7867 elsif Warnings_Off
(E
) then
7868 Set_Warnings_Off_Used_Unreferenced
(E
);
7873 end Has_Unreferenced
;
7875 ----------------------
7876 -- Has_Warnings_Off --
7877 ----------------------
7879 function Has_Warnings_Off
(E
: Entity_Id
) return Boolean is
7881 if Warnings_Off
(E
) then
7882 Set_Warnings_Off_Used
(E
);
7887 end Has_Warnings_Off
;
7889 ------------------------------
7890 -- Implementation_Base_Type --
7891 ------------------------------
7893 function Implementation_Base_Type
(Id
: E
) return E
is
7898 Bastyp
:= Base_Type
(Id
);
7900 if Is_Incomplete_Or_Private_Type
(Bastyp
) then
7901 Imptyp
:= Underlying_Type
(Bastyp
);
7903 -- If we have an implementation type, then just return it,
7904 -- otherwise we return the Base_Type anyway. This can only
7905 -- happen in error situations and should avoid some error bombs.
7907 if Present
(Imptyp
) then
7908 return Base_Type
(Imptyp
);
7916 end Implementation_Base_Type
;
7918 -------------------------
7919 -- Invariant_Procedure --
7920 -------------------------
7922 function Invariant_Procedure
(Id
: E
) return E
is
7923 Subp_Elmt
: Elmt_Id
;
7924 Subp_Id
: Entity_Id
;
7928 pragma Assert
(Is_Type
(Id
));
7930 Subps
:= Subprograms_For_Type
(Base_Type
(Id
));
7932 if Present
(Subps
) then
7933 Subp_Elmt
:= First_Elmt
(Subps
);
7934 while Present
(Subp_Elmt
) loop
7935 Subp_Id
:= Node
(Subp_Elmt
);
7937 if Is_Invariant_Procedure
(Subp_Id
) then
7941 Next_Elmt
(Subp_Elmt
);
7946 end Invariant_Procedure
;
7948 ----------------------
7949 -- Is_Atomic_Or_VFA --
7950 ----------------------
7952 function Is_Atomic_Or_VFA
(Id
: E
) return B
is
7954 return Is_Atomic
(Id
) or else Is_Volatile_Full_Access
(Id
);
7955 end Is_Atomic_Or_VFA
;
7961 -- Global flag table allowing rapid computation of this function
7963 Entity_Is_Base_Type
: constant array (Entity_Kind
) of Boolean :=
7964 (E_Enumeration_Subtype |
7965 E_Incomplete_Subtype |
7966 E_Signed_Integer_Subtype |
7967 E_Modular_Integer_Subtype |
7968 E_Floating_Point_Subtype |
7969 E_Ordinary_Fixed_Point_Subtype |
7970 E_Decimal_Fixed_Point_Subtype |
7974 E_Record_Subtype_With_Private |
7975 E_Limited_Private_Subtype |
7977 E_Protected_Subtype |
7979 E_String_Literal_Subtype |
7980 E_Class_Wide_Subtype
=> False,
7983 function Is_Base_Type
(Id
: E
) return Boolean is
7985 return Entity_Is_Base_Type
(Ekind
(Id
));
7988 ---------------------
7989 -- Is_Boolean_Type --
7990 ---------------------
7992 function Is_Boolean_Type
(Id
: E
) return B
is
7994 return Root_Type
(Id
) = Standard_Boolean
;
7995 end Is_Boolean_Type
;
7997 ------------------------
7998 -- Is_Constant_Object --
7999 ------------------------
8001 function Is_Constant_Object
(Id
: E
) return B
is
8002 K
: constant Entity_Kind
:= Ekind
(Id
);
8005 K
= E_Constant
or else K
= E_In_Parameter
or else K
= E_Loop_Parameter
;
8006 end Is_Constant_Object
;
8012 function Is_Controlled
(Id
: E
) return B
is
8014 return Is_Controlled_Active
(Id
) and then not Disable_Controlled
(Id
);
8017 --------------------
8018 -- Is_Discriminal --
8019 --------------------
8021 function Is_Discriminal
(Id
: E
) return B
is
8023 return (Ekind_In
(Id
, E_Constant
, E_In_Parameter
)
8024 and then Present
(Discriminal_Link
(Id
)));
8027 ----------------------
8028 -- Is_Dynamic_Scope --
8029 ----------------------
8031 function Is_Dynamic_Scope
(Id
: E
) return B
is
8034 Ekind
(Id
) = E_Block
8036 Ekind
(Id
) = E_Function
8038 Ekind
(Id
) = E_Procedure
8040 Ekind
(Id
) = E_Subprogram_Body
8042 Ekind
(Id
) = E_Task_Type
8044 (Ekind
(Id
) = E_Limited_Private_Type
8045 and then Present
(Full_View
(Id
))
8046 and then Ekind
(Full_View
(Id
)) = E_Task_Type
)
8048 Ekind
(Id
) = E_Entry
8050 Ekind
(Id
) = E_Entry_Family
8052 Ekind
(Id
) = E_Return_Statement
;
8053 end Is_Dynamic_Scope
;
8055 --------------------
8056 -- Is_Entity_Name --
8057 --------------------
8059 function Is_Entity_Name
(N
: Node_Id
) return Boolean is
8060 Kind
: constant Node_Kind
:= Nkind
(N
);
8063 -- Identifiers, operator symbols, expanded names are entity names
8065 return Kind
= N_Identifier
8066 or else Kind
= N_Operator_Symbol
8067 or else Kind
= N_Expanded_Name
8069 -- Attribute references are entity names if they refer to an entity.
8070 -- Note that we don't do this by testing for the presence of the
8071 -- Entity field in the N_Attribute_Reference node, since it may not
8072 -- have been set yet.
8074 or else (Kind
= N_Attribute_Reference
8075 and then Is_Entity_Attribute_Name
(Attribute_Name
(N
)));
8078 -----------------------
8079 -- Is_External_State --
8080 -----------------------
8082 function Is_External_State
(Id
: E
) return B
is
8085 Ekind
(Id
) = E_Abstract_State
and then Has_Option
(Id
, Name_External
);
8086 end Is_External_State
;
8092 function Is_Finalizer
(Id
: E
) return B
is
8094 return Ekind
(Id
) = E_Procedure
and then Chars
(Id
) = Name_uFinalizer
;
8101 function Is_Null_State
(Id
: E
) return B
is
8104 Ekind
(Id
) = E_Abstract_State
and then Nkind
(Parent
(Id
)) = N_Null
;
8107 ---------------------
8108 -- Is_Packed_Array --
8109 ---------------------
8111 function Is_Packed_Array
(Id
: E
) return B
is
8113 return Is_Array_Type
(Id
) and then Is_Packed
(Id
);
8114 end Is_Packed_Array
;
8116 -----------------------------------
8117 -- Is_Package_Or_Generic_Package --
8118 -----------------------------------
8120 function Is_Package_Or_Generic_Package
(Id
: E
) return B
is
8122 return Ekind_In
(Id
, E_Generic_Package
, E_Package
);
8123 end Is_Package_Or_Generic_Package
;
8129 function Is_Prival
(Id
: E
) return B
is
8131 return (Ekind_In
(Id
, E_Constant
, E_Variable
)
8132 and then Present
(Prival_Link
(Id
)));
8135 ----------------------------
8136 -- Is_Protected_Component --
8137 ----------------------------
8139 function Is_Protected_Component
(Id
: E
) return B
is
8141 return Ekind
(Id
) = E_Component
and then Is_Protected_Type
(Scope
(Id
));
8142 end Is_Protected_Component
;
8144 ----------------------------
8145 -- Is_Protected_Interface --
8146 ----------------------------
8148 function Is_Protected_Interface
(Id
: E
) return B
is
8149 Typ
: constant Entity_Id
:= Base_Type
(Id
);
8151 if not Is_Interface
(Typ
) then
8153 elsif Is_Class_Wide_Type
(Typ
) then
8154 return Is_Protected_Interface
(Etype
(Typ
));
8156 return Protected_Present
(Type_Definition
(Parent
(Typ
)));
8158 end Is_Protected_Interface
;
8160 ------------------------------
8161 -- Is_Protected_Record_Type --
8162 ------------------------------
8164 function Is_Protected_Record_Type
(Id
: E
) return B
is
8167 Is_Concurrent_Record_Type
(Id
)
8168 and then Is_Protected_Type
(Corresponding_Concurrent_Type
(Id
));
8169 end Is_Protected_Record_Type
;
8171 --------------------------------
8172 -- Is_Standard_Character_Type --
8173 --------------------------------
8175 function Is_Standard_Character_Type
(Id
: E
) return B
is
8177 if Is_Type
(Id
) then
8179 R
: constant Entity_Id
:= Root_Type
(Id
);
8182 R
= Standard_Character
8184 R
= Standard_Wide_Character
8186 R
= Standard_Wide_Wide_Character
;
8192 end Is_Standard_Character_Type
;
8194 -----------------------------
8195 -- Is_Standard_String_Type --
8196 -----------------------------
8198 function Is_Standard_String_Type
(Id
: E
) return B
is
8200 if Is_Type
(Id
) then
8202 R
: constant Entity_Id
:= Root_Type
(Id
);
8207 R
= Standard_Wide_String
8209 R
= Standard_Wide_Wide_String
;
8215 end Is_Standard_String_Type
;
8217 --------------------
8218 -- Is_String_Type --
8219 --------------------
8221 function Is_String_Type
(Id
: E
) return B
is
8223 return Is_Array_Type
(Id
)
8224 and then Id
/= Any_Composite
8225 and then Number_Dimensions
(Id
) = 1
8226 and then Is_Character_Type
(Component_Type
(Id
));
8229 -------------------------------
8230 -- Is_Synchronized_Interface --
8231 -------------------------------
8233 function Is_Synchronized_Interface
(Id
: E
) return B
is
8234 Typ
: constant Entity_Id
:= Base_Type
(Id
);
8237 if not Is_Interface
(Typ
) then
8240 elsif Is_Class_Wide_Type
(Typ
) then
8241 return Is_Synchronized_Interface
(Etype
(Typ
));
8244 return Protected_Present
(Type_Definition
(Parent
(Typ
)))
8245 or else Synchronized_Present
(Type_Definition
(Parent
(Typ
)))
8246 or else Task_Present
(Type_Definition
(Parent
(Typ
)));
8248 end Is_Synchronized_Interface
;
8250 ---------------------------
8251 -- Is_Synchronized_State --
8252 ---------------------------
8254 function Is_Synchronized_State
(Id
: E
) return B
is
8257 Ekind
(Id
) = E_Abstract_State
8258 and then Has_Option
(Id
, Name_Synchronous
);
8259 end Is_Synchronized_State
;
8261 -----------------------
8262 -- Is_Task_Interface --
8263 -----------------------
8265 function Is_Task_Interface
(Id
: E
) return B
is
8266 Typ
: constant Entity_Id
:= Base_Type
(Id
);
8268 if not Is_Interface
(Typ
) then
8270 elsif Is_Class_Wide_Type
(Typ
) then
8271 return Is_Task_Interface
(Etype
(Typ
));
8273 return Task_Present
(Type_Definition
(Parent
(Typ
)));
8275 end Is_Task_Interface
;
8277 -------------------------
8278 -- Is_Task_Record_Type --
8279 -------------------------
8281 function Is_Task_Record_Type
(Id
: E
) return B
is
8284 Is_Concurrent_Record_Type
(Id
)
8285 and then Is_Task_Type
(Corresponding_Concurrent_Type
(Id
));
8286 end Is_Task_Record_Type
;
8288 ------------------------
8289 -- Is_Wrapper_Package --
8290 ------------------------
8292 function Is_Wrapper_Package
(Id
: E
) return B
is
8294 return (Ekind
(Id
) = E_Package
and then Present
(Related_Instance
(Id
)));
8295 end Is_Wrapper_Package
;
8301 function Last_Formal
(Id
: E
) return E
is
8306 (Is_Overloadable
(Id
)
8307 or else Ekind_In
(Id
, E_Entry_Family
,
8309 E_Subprogram_Type
));
8311 if Ekind
(Id
) = E_Enumeration_Literal
then
8315 Formal
:= First_Formal
(Id
);
8317 if Present
(Formal
) then
8318 while Present
(Next_Formal
(Formal
)) loop
8319 Formal
:= Next_Formal
(Formal
);
8327 function Model_Emin_Value
(Id
: E
) return Uint
is
8329 return Machine_Emin_Value
(Id
);
8330 end Model_Emin_Value
;
8332 -------------------------
8333 -- Model_Epsilon_Value --
8334 -------------------------
8336 function Model_Epsilon_Value
(Id
: E
) return Ureal
is
8337 Radix
: constant Ureal
:= UR_From_Uint
(Machine_Radix_Value
(Id
));
8339 return Radix
** (1 - Model_Mantissa_Value
(Id
));
8340 end Model_Epsilon_Value
;
8342 --------------------------
8343 -- Model_Mantissa_Value --
8344 --------------------------
8346 function Model_Mantissa_Value
(Id
: E
) return Uint
is
8348 return Machine_Mantissa_Value
(Id
);
8349 end Model_Mantissa_Value
;
8351 -----------------------
8352 -- Model_Small_Value --
8353 -----------------------
8355 function Model_Small_Value
(Id
: E
) return Ureal
is
8356 Radix
: constant Ureal
:= UR_From_Uint
(Machine_Radix_Value
(Id
));
8358 return Radix
** (Model_Emin_Value
(Id
) - 1);
8359 end Model_Small_Value
;
8361 ------------------------
8362 -- Machine_Emax_Value --
8363 ------------------------
8365 function Machine_Emax_Value
(Id
: E
) return Uint
is
8366 Digs
: constant Pos
:= UI_To_Int
(Digits_Value
(Base_Type
(Id
)));
8369 case Float_Rep
(Id
) is
8372 when 1 .. 6 => return Uint_128
;
8373 when 7 .. 15 => return 2**10;
8374 when 16 .. 33 => return 2**14;
8375 when others => return No_Uint
;
8379 return Uint_2
** Uint_7
- Uint_1
;
8381 end Machine_Emax_Value
;
8383 ------------------------
8384 -- Machine_Emin_Value --
8385 ------------------------
8387 function Machine_Emin_Value
(Id
: E
) return Uint
is
8389 case Float_Rep
(Id
) is
8390 when IEEE_Binary
=> return Uint_3
- Machine_Emax_Value
(Id
);
8391 when AAMP
=> return -Machine_Emax_Value
(Id
);
8393 end Machine_Emin_Value
;
8395 ----------------------------
8396 -- Machine_Mantissa_Value --
8397 ----------------------------
8399 function Machine_Mantissa_Value
(Id
: E
) return Uint
is
8400 Digs
: constant Pos
:= UI_To_Int
(Digits_Value
(Base_Type
(Id
)));
8403 case Float_Rep
(Id
) is
8406 when 1 .. 6 => return Uint_24
;
8407 when 7 .. 15 => return UI_From_Int
(53);
8408 when 16 .. 18 => return Uint_64
;
8409 when 19 .. 33 => return UI_From_Int
(113);
8410 when others => return No_Uint
;
8415 when 1 .. 6 => return Uint_24
;
8416 when 7 .. 9 => return UI_From_Int
(40);
8417 when others => return No_Uint
;
8420 end Machine_Mantissa_Value
;
8422 -------------------------
8423 -- Machine_Radix_Value --
8424 -------------------------
8426 function Machine_Radix_Value
(Id
: E
) return U
is
8428 case Float_Rep
(Id
) is
8434 end Machine_Radix_Value
;
8436 --------------------
8437 -- Next_Component --
8438 --------------------
8440 function Next_Component
(Id
: E
) return E
is
8444 Comp_Id
:= Next_Entity
(Id
);
8445 while Present
(Comp_Id
) loop
8446 exit when Ekind
(Comp_Id
) = E_Component
;
8447 Comp_Id
:= Next_Entity
(Comp_Id
);
8453 ------------------------------------
8454 -- Next_Component_Or_Discriminant --
8455 ------------------------------------
8457 function Next_Component_Or_Discriminant
(Id
: E
) return E
is
8461 Comp_Id
:= Next_Entity
(Id
);
8462 while Present
(Comp_Id
) loop
8463 exit when Ekind_In
(Comp_Id
, E_Component
, E_Discriminant
);
8464 Comp_Id
:= Next_Entity
(Comp_Id
);
8468 end Next_Component_Or_Discriminant
;
8470 -----------------------
8471 -- Next_Discriminant --
8472 -----------------------
8474 -- This function actually implements both Next_Discriminant and
8475 -- Next_Stored_Discriminant by making sure that the Discriminant
8476 -- returned is of the same variety as Id.
8478 function Next_Discriminant
(Id
: E
) return E
is
8480 -- Derived Tagged types with private extensions look like this...
8482 -- E_Discriminant d1
8483 -- E_Discriminant d2
8485 -- E_Discriminant d1
8486 -- E_Discriminant d2
8489 -- so it is critical not to go past the leading discriminants
8494 pragma Assert
(Ekind
(Id
) = E_Discriminant
);
8497 D
:= Next_Entity
(D
);
8499 or else (Ekind
(D
) /= E_Discriminant
8500 and then not Is_Itype
(D
))
8505 exit when Ekind
(D
) = E_Discriminant
8506 and then (Is_Completely_Hidden
(D
) = Is_Completely_Hidden
(Id
));
8510 end Next_Discriminant
;
8516 function Next_Formal
(Id
: E
) return E
is
8520 -- Follow the chain of declared entities as long as the kind of the
8521 -- entity corresponds to a formal parameter. Skip internal entities
8522 -- that may have been created for implicit subtypes, in the process
8523 -- of analyzing default expressions.
8529 if No
(P
) or else Is_Formal
(P
) then
8531 elsif not Is_Internal
(P
) then
8537 -----------------------------
8538 -- Next_Formal_With_Extras --
8539 -----------------------------
8541 function Next_Formal_With_Extras
(Id
: E
) return E
is
8543 if Present
(Extra_Formal
(Id
)) then
8544 return Extra_Formal
(Id
);
8546 return Next_Formal
(Id
);
8548 end Next_Formal_With_Extras
;
8554 function Next_Index
(Id
: Node_Id
) return Node_Id
is
8563 function Next_Literal
(Id
: E
) return E
is
8565 pragma Assert
(Nkind
(Id
) in N_Entity
);
8569 ------------------------------
8570 -- Next_Stored_Discriminant --
8571 ------------------------------
8573 function Next_Stored_Discriminant
(Id
: E
) return E
is
8575 -- See comment in Next_Discriminant
8577 return Next_Discriminant
(Id
);
8578 end Next_Stored_Discriminant
;
8580 -----------------------
8581 -- Number_Dimensions --
8582 -----------------------
8584 function Number_Dimensions
(Id
: E
) return Pos
is
8589 if Ekind
(Id
) = E_String_Literal_Subtype
then
8594 T
:= First_Index
(Id
);
8595 while Present
(T
) loop
8602 end Number_Dimensions
;
8604 --------------------
8605 -- Number_Entries --
8606 --------------------
8608 function Number_Entries
(Id
: E
) return Nat
is
8613 pragma Assert
(Is_Concurrent_Type
(Id
));
8616 Ent
:= First_Entity
(Id
);
8617 while Present
(Ent
) loop
8618 if Is_Entry
(Ent
) then
8622 Ent
:= Next_Entity
(Ent
);
8628 --------------------
8629 -- Number_Formals --
8630 --------------------
8632 function Number_Formals
(Id
: E
) return Pos
is
8638 Formal
:= First_Formal
(Id
);
8639 while Present
(Formal
) loop
8641 Formal
:= Next_Formal
(Formal
);
8647 --------------------
8648 -- Parameter_Mode --
8649 --------------------
8651 function Parameter_Mode
(Id
: E
) return Formal_Kind
is
8656 ---------------------------------
8657 -- Partial_Invariant_Procedure --
8658 ---------------------------------
8660 function Partial_Invariant_Procedure
(Id
: E
) return E
is
8661 Subp_Elmt
: Elmt_Id
;
8662 Subp_Id
: Entity_Id
;
8666 pragma Assert
(Is_Type
(Id
));
8668 Subps
:= Subprograms_For_Type
(Base_Type
(Id
));
8670 if Present
(Subps
) then
8671 Subp_Elmt
:= First_Elmt
(Subps
);
8672 while Present
(Subp_Elmt
) loop
8673 Subp_Id
:= Node
(Subp_Elmt
);
8675 if Is_Partial_Invariant_Procedure
(Subp_Id
) then
8679 Next_Elmt
(Subp_Elmt
);
8684 end Partial_Invariant_Procedure
;
8686 -------------------------------------
8687 -- Partial_Refinement_Constituents --
8688 -------------------------------------
8690 function Partial_Refinement_Constituents
(Id
: E
) return L
is
8691 Constits
: Elist_Id
:= No_Elist
;
8693 procedure Add_Usable_Constituents
(Item
: E
);
8694 -- Add global item Item and/or its constituents to list Constits when
8695 -- they can be used in a global refinement within the current scope. The
8697 -- 1) If Item is an abstract state with full refinement visible, add
8698 -- its constituents.
8699 -- 2) If Item is an abstract state with only partial refinement
8700 -- visible, add both Item and its constituents.
8701 -- 3) If Item is an abstract state without a visible refinement, add
8703 -- 4) If Id is not an abstract state, add it.
8705 procedure Add_Usable_Constituents
(List
: Elist_Id
);
8706 -- Apply Add_Usable_Constituents to every constituent in List
8708 -----------------------------
8709 -- Add_Usable_Constituents --
8710 -----------------------------
8712 procedure Add_Usable_Constituents
(Item
: E
) is
8714 if Ekind
(Item
) = E_Abstract_State
then
8715 if Has_Visible_Refinement
(Item
) then
8716 Add_Usable_Constituents
(Refinement_Constituents
(Item
));
8718 elsif Has_Partial_Visible_Refinement
(Item
) then
8719 Append_New_Elmt
(Item
, Constits
);
8720 Add_Usable_Constituents
(Part_Of_Constituents
(Item
));
8723 Append_New_Elmt
(Item
, Constits
);
8727 Append_New_Elmt
(Item
, Constits
);
8729 end Add_Usable_Constituents
;
8731 procedure Add_Usable_Constituents
(List
: Elist_Id
) is
8732 Constit_Elmt
: Elmt_Id
;
8734 if Present
(List
) then
8735 Constit_Elmt
:= First_Elmt
(List
);
8736 while Present
(Constit_Elmt
) loop
8737 Add_Usable_Constituents
(Node
(Constit_Elmt
));
8738 Next_Elmt
(Constit_Elmt
);
8741 end Add_Usable_Constituents
;
8743 -- Start of processing for Partial_Refinement_Constituents
8746 -- "Refinement" is a concept applicable only to abstract states
8748 pragma Assert
(Ekind
(Id
) = E_Abstract_State
);
8750 if Has_Visible_Refinement
(Id
) then
8751 Constits
:= Refinement_Constituents
(Id
);
8753 -- A refinement may be partially visible when objects declared in the
8754 -- private part of a package are subject to a Part_Of indicator.
8756 elsif Has_Partial_Visible_Refinement
(Id
) then
8757 Add_Usable_Constituents
(Part_Of_Constituents
(Id
));
8759 -- Function should only be called when full or partial refinement is
8763 raise Program_Error
;
8767 end Partial_Refinement_Constituents
;
8769 ------------------------
8770 -- Predicate_Function --
8771 ------------------------
8773 function Predicate_Function
(Id
: E
) return E
is
8774 Subp_Elmt
: Elmt_Id
;
8775 Subp_Id
: Entity_Id
;
8780 pragma Assert
(Is_Type
(Id
));
8782 -- If type is private and has a completion, predicate may be defined on
8785 if Is_Private_Type
(Id
)
8787 (not Has_Predicates
(Id
) or else No
(Subprograms_For_Type
(Id
)))
8788 and then Present
(Full_View
(Id
))
8790 Typ
:= Full_View
(Id
);
8796 Subps
:= Subprograms_For_Type
(Typ
);
8798 if Present
(Subps
) then
8799 Subp_Elmt
:= First_Elmt
(Subps
);
8800 while Present
(Subp_Elmt
) loop
8801 Subp_Id
:= Node
(Subp_Elmt
);
8803 if Ekind
(Subp_Id
) = E_Function
8804 and then Is_Predicate_Function
(Subp_Id
)
8809 Next_Elmt
(Subp_Elmt
);
8814 end Predicate_Function
;
8816 --------------------------
8817 -- Predicate_Function_M --
8818 --------------------------
8820 function Predicate_Function_M
(Id
: E
) return E
is
8821 Subp_Elmt
: Elmt_Id
;
8822 Subp_Id
: Entity_Id
;
8827 pragma Assert
(Is_Type
(Id
));
8829 -- If type is private and has a completion, predicate may be defined on
8832 if Is_Private_Type
(Id
)
8834 (not Has_Predicates
(Id
) or else No
(Subprograms_For_Type
(Id
)))
8835 and then Present
(Full_View
(Id
))
8837 Typ
:= Full_View
(Id
);
8843 Subps
:= Subprograms_For_Type
(Typ
);
8845 if Present
(Subps
) then
8846 Subp_Elmt
:= First_Elmt
(Subps
);
8847 while Present
(Subp_Elmt
) loop
8848 Subp_Id
:= Node
(Subp_Elmt
);
8850 if Ekind
(Subp_Id
) = E_Function
8851 and then Is_Predicate_Function_M
(Subp_Id
)
8856 Next_Elmt
(Subp_Elmt
);
8861 end Predicate_Function_M
;
8863 -------------------------
8864 -- Present_In_Rep_Item --
8865 -------------------------
8867 function Present_In_Rep_Item
(E
: Entity_Id
; N
: Node_Id
) return Boolean is
8871 Ritem
:= First_Rep_Item
(E
);
8873 while Present
(Ritem
) loop
8878 Next_Rep_Item
(Ritem
);
8882 end Present_In_Rep_Item
;
8884 --------------------------
8885 -- Primitive_Operations --
8886 --------------------------
8888 function Primitive_Operations
(Id
: E
) return L
is
8890 if Is_Concurrent_Type
(Id
) then
8891 if Present
(Corresponding_Record_Type
(Id
)) then
8892 return Direct_Primitive_Operations
8893 (Corresponding_Record_Type
(Id
));
8895 -- If expansion is disabled the corresponding record type is absent,
8896 -- but if the type has ancestors it may have primitive operations.
8898 elsif Is_Tagged_Type
(Id
) then
8899 return Direct_Primitive_Operations
(Id
);
8905 return Direct_Primitive_Operations
(Id
);
8907 end Primitive_Operations
;
8909 ---------------------
8910 -- Record_Rep_Item --
8911 ---------------------
8913 procedure Record_Rep_Item
(E
: Entity_Id
; N
: Node_Id
) is
8915 Set_Next_Rep_Item
(N
, First_Rep_Item
(E
));
8916 Set_First_Rep_Item
(E
, N
);
8917 end Record_Rep_Item
;
8923 function Root_Type
(Id
: E
) return E
is
8927 pragma Assert
(Nkind
(Id
) in N_Entity
);
8929 T
:= Base_Type
(Id
);
8931 if Ekind
(T
) = E_Class_Wide_Type
then
8943 -- Following test catches some error cases resulting from
8946 elsif No
(Etyp
) then
8947 Check_Error_Detected
;
8950 elsif Is_Private_Type
(T
) and then Etyp
= Full_View
(T
) then
8953 elsif Is_Private_Type
(Etyp
) and then Full_View
(Etyp
) = T
then
8959 -- Return if there is a circularity in the inheritance chain. This
8960 -- happens in some error situations and we do not want to get
8961 -- stuck in this loop.
8963 if T
= Base_Type
(Id
) then
8970 ---------------------
8971 -- Safe_Emax_Value --
8972 ---------------------
8974 function Safe_Emax_Value
(Id
: E
) return Uint
is
8976 return Machine_Emax_Value
(Id
);
8977 end Safe_Emax_Value
;
8979 ----------------------
8980 -- Safe_First_Value --
8981 ----------------------
8983 function Safe_First_Value
(Id
: E
) return Ureal
is
8985 return -Safe_Last_Value
(Id
);
8986 end Safe_First_Value
;
8988 ---------------------
8989 -- Safe_Last_Value --
8990 ---------------------
8992 function Safe_Last_Value
(Id
: E
) return Ureal
is
8993 Radix
: constant Uint
:= Machine_Radix_Value
(Id
);
8994 Mantissa
: constant Uint
:= Machine_Mantissa_Value
(Id
);
8995 Emax
: constant Uint
:= Safe_Emax_Value
(Id
);
8996 Significand
: constant Uint
:= Radix
** Mantissa
- 1;
8997 Exponent
: constant Uint
:= Emax
- Mantissa
;
9003 (Num
=> Significand
* 2 ** (Exponent
mod 4),
9004 Den
=> -Exponent
/ 4,
9009 (Num
=> Significand
,
9013 end Safe_Last_Value
;
9019 function Scope_Depth
(Id
: E
) return Uint
is
9024 while Is_Record_Type
(Scop
) loop
9025 Scop
:= Scope
(Scop
);
9028 return Scope_Depth_Value
(Scop
);
9031 ---------------------
9032 -- Scope_Depth_Set --
9033 ---------------------
9035 function Scope_Depth_Set
(Id
: E
) return B
is
9037 return not Is_Record_Type
(Id
)
9038 and then Field22
(Id
) /= Union_Id
(Empty
);
9039 end Scope_Depth_Set
;
9041 -----------------------------
9042 -- Set_Component_Alignment --
9043 -----------------------------
9045 -- Component Alignment is encoded using two flags, Flag128/129 as
9046 -- follows. Note that both flags False = Align_Default, so that the
9047 -- default initialization of flags to False initializes component
9048 -- alignment to the default value as required.
9050 -- Flag128 Flag129 Value
9051 -- ------- ------- -----
9052 -- False False Calign_Default
9053 -- False True Calign_Component_Size
9054 -- True False Calign_Component_Size_4
9055 -- True True Calign_Storage_Unit
9057 procedure Set_Component_Alignment
(Id
: E
; V
: C
) is
9059 pragma Assert
((Is_Array_Type
(Id
) or else Is_Record_Type
(Id
))
9060 and then Is_Base_Type
(Id
));
9063 when Calign_Default
=>
9064 Set_Flag128
(Id
, False);
9065 Set_Flag129
(Id
, False);
9067 when Calign_Component_Size
=>
9068 Set_Flag128
(Id
, False);
9069 Set_Flag129
(Id
, True);
9071 when Calign_Component_Size_4
=>
9072 Set_Flag128
(Id
, True);
9073 Set_Flag129
(Id
, False);
9075 when Calign_Storage_Unit
=>
9076 Set_Flag128
(Id
, True);
9077 Set_Flag129
(Id
, True);
9079 end Set_Component_Alignment
;
9081 -----------------------
9082 -- Set_DIC_Procedure --
9083 -----------------------
9085 procedure Set_DIC_Procedure
(Id
: E
; V
: E
) is
9086 Base_Typ
: Entity_Id
;
9087 Subp_Elmt
: Elmt_Id
;
9088 Subp_Id
: Entity_Id
;
9092 pragma Assert
(Is_Type
(Id
));
9094 Base_Typ
:= Base_Type
(Id
);
9095 Subps
:= Subprograms_For_Type
(Base_Typ
);
9098 Subps
:= New_Elmt_List
;
9099 Set_Subprograms_For_Type
(Base_Typ
, Subps
);
9102 Subp_Elmt
:= First_Elmt
(Subps
);
9103 Prepend_Elmt
(V
, Subps
);
9105 -- Check for a duplicate default initial condition procedure
9107 while Present
(Subp_Elmt
) loop
9108 Subp_Id
:= Node
(Subp_Elmt
);
9110 if Is_DIC_Procedure
(Subp_Id
) then
9111 raise Program_Error
;
9114 Next_Elmt
(Subp_Elmt
);
9116 end Set_DIC_Procedure
;
9118 -----------------------------
9119 -- Set_Invariant_Procedure --
9120 -----------------------------
9122 procedure Set_Invariant_Procedure
(Id
: E
; V
: E
) is
9123 Base_Typ
: Entity_Id
;
9124 Subp_Elmt
: Elmt_Id
;
9125 Subp_Id
: Entity_Id
;
9129 pragma Assert
(Is_Type
(Id
));
9131 Base_Typ
:= Base_Type
(Id
);
9132 Subps
:= Subprograms_For_Type
(Base_Typ
);
9135 Subps
:= New_Elmt_List
;
9136 Set_Subprograms_For_Type
(Base_Typ
, Subps
);
9139 Subp_Elmt
:= First_Elmt
(Subps
);
9140 Prepend_Elmt
(V
, Subps
);
9142 -- Check for a duplicate invariant procedure
9144 while Present
(Subp_Elmt
) loop
9145 Subp_Id
:= Node
(Subp_Elmt
);
9147 if Is_Invariant_Procedure
(Subp_Id
) then
9148 raise Program_Error
;
9151 Next_Elmt
(Subp_Elmt
);
9153 end Set_Invariant_Procedure
;
9155 -------------------------------------
9156 -- Set_Partial_Invariant_Procedure --
9157 -------------------------------------
9159 procedure Set_Partial_Invariant_Procedure
(Id
: E
; V
: E
) is
9160 Base_Typ
: Entity_Id
;
9161 Subp_Elmt
: Elmt_Id
;
9162 Subp_Id
: Entity_Id
;
9166 pragma Assert
(Is_Type
(Id
));
9168 Base_Typ
:= Base_Type
(Id
);
9169 Subps
:= Subprograms_For_Type
(Base_Typ
);
9172 Subps
:= New_Elmt_List
;
9173 Set_Subprograms_For_Type
(Base_Typ
, Subps
);
9176 Subp_Elmt
:= First_Elmt
(Subps
);
9177 Prepend_Elmt
(V
, Subps
);
9179 -- Check for a duplicate partial invariant procedure
9181 while Present
(Subp_Elmt
) loop
9182 Subp_Id
:= Node
(Subp_Elmt
);
9184 if Is_Partial_Invariant_Procedure
(Subp_Id
) then
9185 raise Program_Error
;
9188 Next_Elmt
(Subp_Elmt
);
9190 end Set_Partial_Invariant_Procedure
;
9192 ----------------------------
9193 -- Set_Predicate_Function --
9194 ----------------------------
9196 procedure Set_Predicate_Function
(Id
: E
; V
: E
) is
9197 Subp_Elmt
: Elmt_Id
;
9198 Subp_Id
: Entity_Id
;
9202 pragma Assert
(Is_Type
(Id
) and then Has_Predicates
(Id
));
9204 Subps
:= Subprograms_For_Type
(Id
);
9207 Subps
:= New_Elmt_List
;
9208 Set_Subprograms_For_Type
(Id
, Subps
);
9211 Subp_Elmt
:= First_Elmt
(Subps
);
9212 Prepend_Elmt
(V
, Subps
);
9214 -- Check for a duplicate predication function
9216 while Present
(Subp_Elmt
) loop
9217 Subp_Id
:= Node
(Subp_Elmt
);
9219 if Ekind
(Subp_Id
) = E_Function
9220 and then Is_Predicate_Function
(Subp_Id
)
9222 raise Program_Error
;
9225 Next_Elmt
(Subp_Elmt
);
9227 end Set_Predicate_Function
;
9229 ------------------------------
9230 -- Set_Predicate_Function_M --
9231 ------------------------------
9233 procedure Set_Predicate_Function_M
(Id
: E
; V
: E
) is
9234 Subp_Elmt
: Elmt_Id
;
9235 Subp_Id
: Entity_Id
;
9239 pragma Assert
(Is_Type
(Id
) and then Has_Predicates
(Id
));
9241 Subps
:= Subprograms_For_Type
(Id
);
9244 Subps
:= New_Elmt_List
;
9245 Set_Subprograms_For_Type
(Id
, Subps
);
9248 Subp_Elmt
:= First_Elmt
(Subps
);
9249 Prepend_Elmt
(V
, Subps
);
9251 -- Check for a duplicate predication function
9253 while Present
(Subp_Elmt
) loop
9254 Subp_Id
:= Node
(Subp_Elmt
);
9256 if Ekind
(Subp_Id
) = E_Function
9257 and then Is_Predicate_Function_M
(Subp_Id
)
9259 raise Program_Error
;
9262 Next_Elmt
(Subp_Elmt
);
9264 end Set_Predicate_Function_M
;
9270 function Size_Clause
(Id
: E
) return N
is
9272 return Get_Attribute_Definition_Clause
(Id
, Attribute_Size
);
9275 ------------------------
9276 -- Stream_Size_Clause --
9277 ------------------------
9279 function Stream_Size_Clause
(Id
: E
) return N
is
9281 return Get_Attribute_Definition_Clause
(Id
, Attribute_Stream_Size
);
9282 end Stream_Size_Clause
;
9288 function Subtype_Kind
(K
: Entity_Kind
) return Entity_Kind
is
9294 Kind
:= E_Access_Subtype
;
9296 when E_Array_Subtype
9299 Kind
:= E_Array_Subtype
;
9301 when E_Class_Wide_Subtype
9304 Kind
:= E_Class_Wide_Subtype
;
9306 when E_Decimal_Fixed_Point_Subtype
9307 | E_Decimal_Fixed_Point_Type
9309 Kind
:= E_Decimal_Fixed_Point_Subtype
;
9311 when E_Ordinary_Fixed_Point_Subtype
9312 | E_Ordinary_Fixed_Point_Type
9314 Kind
:= E_Ordinary_Fixed_Point_Subtype
;
9316 when E_Private_Subtype
9319 Kind
:= E_Private_Subtype
;
9321 when E_Limited_Private_Subtype
9322 | E_Limited_Private_Type
9324 Kind
:= E_Limited_Private_Subtype
;
9326 when E_Record_Subtype_With_Private
9327 | E_Record_Type_With_Private
9329 Kind
:= E_Record_Subtype_With_Private
;
9331 when E_Record_Subtype
9334 Kind
:= E_Record_Subtype
;
9336 when Enumeration_Kind
=>
9337 Kind
:= E_Enumeration_Subtype
;
9339 when E_Incomplete_Type
=>
9340 Kind
:= E_Incomplete_Subtype
;
9343 Kind
:= E_Floating_Point_Subtype
;
9345 when Signed_Integer_Kind
=>
9346 Kind
:= E_Signed_Integer_Subtype
;
9348 when Modular_Integer_Kind
=>
9349 Kind
:= E_Modular_Integer_Subtype
;
9351 when Protected_Kind
=>
9352 Kind
:= E_Protected_Subtype
;
9355 Kind
:= E_Task_Subtype
;
9359 raise Program_Error
;
9365 ---------------------
9366 -- Type_High_Bound --
9367 ---------------------
9369 function Type_High_Bound
(Id
: E
) return Node_Id
is
9370 Rng
: constant Node_Id
:= Scalar_Range
(Id
);
9372 if Nkind
(Rng
) = N_Subtype_Indication
then
9373 return High_Bound
(Range_Expression
(Constraint
(Rng
)));
9375 return High_Bound
(Rng
);
9377 end Type_High_Bound
;
9379 --------------------
9380 -- Type_Low_Bound --
9381 --------------------
9383 function Type_Low_Bound
(Id
: E
) return Node_Id
is
9384 Rng
: constant Node_Id
:= Scalar_Range
(Id
);
9386 if Nkind
(Rng
) = N_Subtype_Indication
then
9387 return Low_Bound
(Range_Expression
(Constraint
(Rng
)));
9389 return Low_Bound
(Rng
);
9393 ---------------------
9394 -- Underlying_Type --
9395 ---------------------
9397 function Underlying_Type
(Id
: E
) return E
is
9399 -- For record_with_private the underlying type is always the direct full
9400 -- view. Never try to take the full view of the parent it does not make
9403 if Ekind
(Id
) = E_Record_Type_With_Private
then
9404 return Full_View
(Id
);
9406 -- If we have a class-wide type that comes from the limited view then we
9407 -- return the Underlying_Type of its nonlimited view.
9409 elsif Ekind
(Id
) = E_Class_Wide_Type
9410 and then From_Limited_With
(Id
)
9411 and then Present
(Non_Limited_View
(Id
))
9413 return Underlying_Type
(Non_Limited_View
(Id
));
9415 elsif Ekind
(Id
) in Incomplete_Or_Private_Kind
then
9417 -- If we have an incomplete or private type with a full view, then we
9418 -- return the Underlying_Type of this full view.
9420 if Present
(Full_View
(Id
)) then
9421 if Id
= Full_View
(Id
) then
9423 -- Previous error in declaration
9428 return Underlying_Type
(Full_View
(Id
));
9431 -- If we have a private type with an underlying full view, then we
9432 -- return the Underlying_Type of this underlying full view.
9434 elsif Ekind
(Id
) in Private_Kind
9435 and then Present
(Underlying_Full_View
(Id
))
9437 return Underlying_Type
(Underlying_Full_View
(Id
));
9439 -- If we have an incomplete entity that comes from the limited view
9440 -- then we return the Underlying_Type of its nonlimited view.
9442 elsif From_Limited_With
(Id
)
9443 and then Present
(Non_Limited_View
(Id
))
9445 return Underlying_Type
(Non_Limited_View
(Id
));
9447 -- Otherwise check for the case where we have a derived type or
9448 -- subtype, and if so get the Underlying_Type of the parent type.
9450 elsif Etype
(Id
) /= Id
then
9451 return Underlying_Type
(Etype
(Id
));
9453 -- Otherwise we have an incomplete or private type that has no full
9454 -- view, which means that we have not encountered the completion, so
9455 -- return Empty to indicate the underlying type is not yet known.
9461 -- For non-incomplete, non-private types, return the type itself Also
9462 -- for entities that are not types at all return the entity itself.
9467 end Underlying_Type
;
9469 ------------------------
9470 -- Write_Entity_Flags --
9471 ------------------------
9473 procedure Write_Entity_Flags
(Id
: Entity_Id
; Prefix
: String) is
9475 procedure W
(Flag_Name
: String; Flag
: Boolean);
9476 -- Write out given flag if it is set
9482 procedure W
(Flag_Name
: String; Flag
: Boolean) is
9486 Write_Str
(Flag_Name
);
9487 Write_Str
(" = True");
9492 -- Start of processing for Write_Entity_Flags
9495 if (Is_Array_Type
(Id
) or else Is_Record_Type
(Id
))
9496 and then Is_Base_Type
(Id
)
9499 Write_Str
("Component_Alignment = ");
9501 case Component_Alignment
(Id
) is
9502 when Calign_Default
=>
9503 Write_Str
("Calign_Default");
9505 when Calign_Component_Size
=>
9506 Write_Str
("Calign_Component_Size");
9508 when Calign_Component_Size_4
=>
9509 Write_Str
("Calign_Component_Size_4");
9511 when Calign_Storage_Unit
=>
9512 Write_Str
("Calign_Storage_Unit");
9518 W
("Address_Taken", Flag104
(Id
));
9519 W
("Body_Needed_For_Inlining", Flag299
(Id
));
9520 W
("Body_Needed_For_SAL", Flag40
(Id
));
9521 W
("C_Pass_By_Copy", Flag125
(Id
));
9522 W
("Can_Never_Be_Null", Flag38
(Id
));
9523 W
("Checks_May_Be_Suppressed", Flag31
(Id
));
9524 W
("Contains_Ignored_Ghost_Code", Flag279
(Id
));
9525 W
("Debug_Info_Off", Flag166
(Id
));
9526 W
("Default_Expressions_Processed", Flag108
(Id
));
9527 W
("Delay_Cleanups", Flag114
(Id
));
9528 W
("Delay_Subprogram_Descriptors", Flag50
(Id
));
9529 W
("Depends_On_Private", Flag14
(Id
));
9530 W
("Discard_Names", Flag88
(Id
));
9531 W
("Elaboration_Entity_Required", Flag174
(Id
));
9532 W
("Elaborate_Body_Desirable", Flag210
(Id
));
9533 W
("Entry_Accepted", Flag152
(Id
));
9534 W
("Can_Use_Internal_Rep", Flag229
(Id
));
9535 W
("Finalize_Storage_Only", Flag158
(Id
));
9536 W
("From_Limited_With", Flag159
(Id
));
9537 W
("Has_Aliased_Components", Flag135
(Id
));
9538 W
("Has_Alignment_Clause", Flag46
(Id
));
9539 W
("Has_All_Calls_Remote", Flag79
(Id
));
9540 W
("Has_Atomic_Components", Flag86
(Id
));
9541 W
("Has_Biased_Representation", Flag139
(Id
));
9542 W
("Has_Completion", Flag26
(Id
));
9543 W
("Has_Completion_In_Body", Flag71
(Id
));
9544 W
("Has_Complex_Representation", Flag140
(Id
));
9545 W
("Has_Component_Size_Clause", Flag68
(Id
));
9546 W
("Has_Contiguous_Rep", Flag181
(Id
));
9547 W
("Has_Controlled_Component", Flag43
(Id
));
9548 W
("Has_Controlling_Result", Flag98
(Id
));
9549 W
("Has_Convention_Pragma", Flag119
(Id
));
9550 W
("Has_Default_Aspect", Flag39
(Id
));
9551 W
("Has_Delayed_Aspects", Flag200
(Id
));
9552 W
("Has_Delayed_Freeze", Flag18
(Id
));
9553 W
("Has_Delayed_Rep_Aspects", Flag261
(Id
));
9554 W
("Has_Discriminants", Flag5
(Id
));
9555 W
("Has_Dispatch_Table", Flag220
(Id
));
9556 W
("Has_Dynamic_Predicate_Aspect", Flag258
(Id
));
9557 W
("Has_Enumeration_Rep_Clause", Flag66
(Id
));
9558 W
("Has_Exit", Flag47
(Id
));
9559 W
("Has_Expanded_Contract", Flag240
(Id
));
9560 W
("Has_Forward_Instantiation", Flag175
(Id
));
9561 W
("Has_Fully_Qualified_Name", Flag173
(Id
));
9562 W
("Has_Gigi_Rep_Item", Flag82
(Id
));
9563 W
("Has_Homonym", Flag56
(Id
));
9564 W
("Has_Implicit_Dereference", Flag251
(Id
));
9565 W
("Has_Independent_Components", Flag34
(Id
));
9566 W
("Has_Inheritable_Invariants", Flag248
(Id
));
9567 W
("Has_Inherited_DIC", Flag133
(Id
));
9568 W
("Has_Inherited_Invariants", Flag291
(Id
));
9569 W
("Has_Initial_Value", Flag219
(Id
));
9570 W
("Has_Loop_Entry_Attributes", Flag260
(Id
));
9571 W
("Has_Machine_Radix_Clause", Flag83
(Id
));
9572 W
("Has_Master_Entity", Flag21
(Id
));
9573 W
("Has_Missing_Return", Flag142
(Id
));
9574 W
("Has_Nested_Block_With_Handler", Flag101
(Id
));
9575 W
("Has_Nested_Subprogram", Flag282
(Id
));
9576 W
("Has_Non_Standard_Rep", Flag75
(Id
));
9577 W
("Has_Out_Or_In_Out_Parameter", Flag110
(Id
));
9578 W
("Has_Object_Size_Clause", Flag172
(Id
));
9579 W
("Has_Own_DIC", Flag3
(Id
));
9580 W
("Has_Own_Invariants", Flag232
(Id
));
9581 W
("Has_Per_Object_Constraint", Flag154
(Id
));
9582 W
("Has_Pragma_Controlled", Flag27
(Id
));
9583 W
("Has_Pragma_Elaborate_Body", Flag150
(Id
));
9584 W
("Has_Pragma_Inline", Flag157
(Id
));
9585 W
("Has_Pragma_Inline_Always", Flag230
(Id
));
9586 W
("Has_Pragma_No_Inline", Flag201
(Id
));
9587 W
("Has_Pragma_Ordered", Flag198
(Id
));
9588 W
("Has_Pragma_Pack", Flag121
(Id
));
9589 W
("Has_Pragma_Preelab_Init", Flag221
(Id
));
9590 W
("Has_Pragma_Pure", Flag203
(Id
));
9591 W
("Has_Pragma_Pure_Function", Flag179
(Id
));
9592 W
("Has_Pragma_Thread_Local_Storage", Flag169
(Id
));
9593 W
("Has_Pragma_Unmodified", Flag233
(Id
));
9594 W
("Has_Pragma_Unreferenced", Flag180
(Id
));
9595 W
("Has_Pragma_Unreferenced_Objects", Flag212
(Id
));
9596 W
("Has_Pragma_Unused", Flag294
(Id
));
9597 W
("Has_Predicates", Flag250
(Id
));
9598 W
("Has_Primitive_Operations", Flag120
(Id
));
9599 W
("Has_Private_Ancestor", Flag151
(Id
));
9600 W
("Has_Private_Declaration", Flag155
(Id
));
9601 W
("Has_Private_Extension", Flag300
(Id
));
9602 W
("Has_Protected", Flag271
(Id
));
9603 W
("Has_Qualified_Name", Flag161
(Id
));
9604 W
("Has_RACW", Flag214
(Id
));
9605 W
("Has_Record_Rep_Clause", Flag65
(Id
));
9606 W
("Has_Recursive_Call", Flag143
(Id
));
9607 W
("Has_Shift_Operator", Flag267
(Id
));
9608 W
("Has_Size_Clause", Flag29
(Id
));
9609 W
("Has_Small_Clause", Flag67
(Id
));
9610 W
("Has_Specified_Layout", Flag100
(Id
));
9611 W
("Has_Specified_Stream_Input", Flag190
(Id
));
9612 W
("Has_Specified_Stream_Output", Flag191
(Id
));
9613 W
("Has_Specified_Stream_Read", Flag192
(Id
));
9614 W
("Has_Specified_Stream_Write", Flag193
(Id
));
9615 W
("Has_Static_Discriminants", Flag211
(Id
));
9616 W
("Has_Static_Predicate", Flag269
(Id
));
9617 W
("Has_Static_Predicate_Aspect", Flag259
(Id
));
9618 W
("Has_Storage_Size_Clause", Flag23
(Id
));
9619 W
("Has_Stream_Size_Clause", Flag184
(Id
));
9620 W
("Has_Task", Flag30
(Id
));
9621 W
("Has_Timing_Event", Flag289
(Id
));
9622 W
("Has_Thunks", Flag228
(Id
));
9623 W
("Has_Unchecked_Union", Flag123
(Id
));
9624 W
("Has_Unknown_Discriminants", Flag72
(Id
));
9625 W
("Has_Visible_Refinement", Flag263
(Id
));
9626 W
("Has_Volatile_Components", Flag87
(Id
));
9627 W
("Has_Xref_Entry", Flag182
(Id
));
9628 W
("Ignore_SPARK_Mode_Pragmas", Flag301
(Id
));
9629 W
("In_Package_Body", Flag48
(Id
));
9630 W
("In_Private_Part", Flag45
(Id
));
9631 W
("In_Use", Flag8
(Id
));
9632 W
("Is_Abstract_Subprogram", Flag19
(Id
));
9633 W
("Is_Abstract_Type", Flag146
(Id
));
9634 W
("Is_Access_Constant", Flag69
(Id
));
9635 W
("Is_Actual_Subtype", Flag293
(Id
));
9636 W
("Is_Ada_2005_Only", Flag185
(Id
));
9637 W
("Is_Ada_2012_Only", Flag199
(Id
));
9638 W
("Is_Aliased", Flag15
(Id
));
9639 W
("Is_Asynchronous", Flag81
(Id
));
9640 W
("Is_Atomic", Flag85
(Id
));
9641 W
("Is_Bit_Packed_Array", Flag122
(Id
));
9642 W
("Is_CPP_Class", Flag74
(Id
));
9643 W
("Is_Called", Flag102
(Id
));
9644 W
("Is_Character_Type", Flag63
(Id
));
9645 W
("Is_Checked_Ghost_Entity", Flag277
(Id
));
9646 W
("Is_Child_Unit", Flag73
(Id
));
9647 W
("Is_Class_Wide_Equivalent_Type", Flag35
(Id
));
9648 W
("Is_Compilation_Unit", Flag149
(Id
));
9649 W
("Is_Completely_Hidden", Flag103
(Id
));
9650 W
("Is_Concurrent_Record_Type", Flag20
(Id
));
9651 W
("Is_Constr_Subt_For_UN_Aliased", Flag141
(Id
));
9652 W
("Is_Constr_Subt_For_U_Nominal", Flag80
(Id
));
9653 W
("Is_Constrained", Flag12
(Id
));
9654 W
("Is_Constructor", Flag76
(Id
));
9655 W
("Is_Controlled_Active", Flag42
(Id
));
9656 W
("Is_Controlling_Formal", Flag97
(Id
));
9657 W
("Is_Descendant_Of_Address", Flag223
(Id
));
9658 W
("Is_DIC_Procedure", Flag132
(Id
));
9659 W
("Is_Discrim_SO_Function", Flag176
(Id
));
9660 W
("Is_Discriminant_Check_Function", Flag264
(Id
));
9661 W
("Is_Dispatch_Table_Entity", Flag234
(Id
));
9662 W
("Is_Dispatching_Operation", Flag6
(Id
));
9663 W
("Is_Elaboration_Checks_OK_Id", Flag148
(Id
));
9664 W
("Is_Eliminated", Flag124
(Id
));
9665 W
("Is_Entry_Formal", Flag52
(Id
));
9666 W
("Is_Exception_Handler", Flag286
(Id
));
9667 W
("Is_Exported", Flag99
(Id
));
9668 W
("Is_Finalized_Transient", Flag252
(Id
));
9669 W
("Is_First_Subtype", Flag70
(Id
));
9670 W
("Is_For_Access_Subtype", Flag118
(Id
));
9671 W
("Is_Formal_Subprogram", Flag111
(Id
));
9672 W
("Is_Frozen", Flag4
(Id
));
9673 W
("Is_Generic_Actual_Subprogram", Flag274
(Id
));
9674 W
("Is_Generic_Actual_Type", Flag94
(Id
));
9675 W
("Is_Generic_Instance", Flag130
(Id
));
9676 W
("Is_Generic_Type", Flag13
(Id
));
9677 W
("Is_Hidden", Flag57
(Id
));
9678 W
("Is_Hidden_Non_Overridden_Subpgm", Flag2
(Id
));
9679 W
("Is_Hidden_Open_Scope", Flag171
(Id
));
9680 W
("Is_Ignored_Ghost_Entity", Flag278
(Id
));
9681 W
("Is_Ignored_Transient", Flag295
(Id
));
9682 W
("Is_Immediately_Visible", Flag7
(Id
));
9683 W
("Is_Implementation_Defined", Flag254
(Id
));
9684 W
("Is_Imported", Flag24
(Id
));
9685 W
("Is_Independent", Flag268
(Id
));
9686 W
("Is_Initial_Condition_Procedure", Flag302
(Id
));
9687 W
("Is_Inlined", Flag11
(Id
));
9688 W
("Is_Inlined_Always", Flag1
(Id
));
9689 W
("Is_Instantiated", Flag126
(Id
));
9690 W
("Is_Interface", Flag186
(Id
));
9691 W
("Is_Internal", Flag17
(Id
));
9692 W
("Is_Interrupt_Handler", Flag89
(Id
));
9693 W
("Is_Intrinsic_Subprogram", Flag64
(Id
));
9694 W
("Is_Invariant_Procedure", Flag257
(Id
));
9695 W
("Is_Itype", Flag91
(Id
));
9696 W
("Is_Known_Non_Null", Flag37
(Id
));
9697 W
("Is_Known_Null", Flag204
(Id
));
9698 W
("Is_Known_Valid", Flag170
(Id
));
9699 W
("Is_Limited_Composite", Flag106
(Id
));
9700 W
("Is_Limited_Interface", Flag197
(Id
));
9701 W
("Is_Limited_Record", Flag25
(Id
));
9702 W
("Is_Local_Anonymous_Access", Flag194
(Id
));
9703 W
("Is_Machine_Code_Subprogram", Flag137
(Id
));
9704 W
("Is_Non_Static_Subtype", Flag109
(Id
));
9705 W
("Is_Null_Init_Proc", Flag178
(Id
));
9706 W
("Is_Obsolescent", Flag153
(Id
));
9707 W
("Is_Only_Out_Parameter", Flag226
(Id
));
9708 W
("Is_Package_Body_Entity", Flag160
(Id
));
9709 W
("Is_Packed", Flag51
(Id
));
9710 W
("Is_Packed_Array_Impl_Type", Flag138
(Id
));
9711 W
("Is_Param_Block_Component_Type", Flag215
(Id
));
9712 W
("Is_Partial_Invariant_Procedure", Flag292
(Id
));
9713 W
("Is_Potentially_Use_Visible", Flag9
(Id
));
9714 W
("Is_Predicate_Function", Flag255
(Id
));
9715 W
("Is_Predicate_Function_M", Flag256
(Id
));
9716 W
("Is_Preelaborated", Flag59
(Id
));
9717 W
("Is_Primitive", Flag218
(Id
));
9718 W
("Is_Primitive_Wrapper", Flag195
(Id
));
9719 W
("Is_Private_Composite", Flag107
(Id
));
9720 W
("Is_Private_Descendant", Flag53
(Id
));
9721 W
("Is_Private_Primitive", Flag245
(Id
));
9722 W
("Is_Public", Flag10
(Id
));
9723 W
("Is_Pure", Flag44
(Id
));
9724 W
("Is_Pure_Unit_Access_Type", Flag189
(Id
));
9725 W
("Is_RACW_Stub_Type", Flag244
(Id
));
9726 W
("Is_Raised", Flag224
(Id
));
9727 W
("Is_Remote_Call_Interface", Flag62
(Id
));
9728 W
("Is_Remote_Types", Flag61
(Id
));
9729 W
("Is_Renaming_Of_Object", Flag112
(Id
));
9730 W
("Is_Return_Object", Flag209
(Id
));
9731 W
("Is_Safe_To_Reevaluate", Flag249
(Id
));
9732 W
("Is_Shared_Passive", Flag60
(Id
));
9733 W
("Is_Static_Type", Flag281
(Id
));
9734 W
("Is_Statically_Allocated", Flag28
(Id
));
9735 W
("Is_Tag", Flag78
(Id
));
9736 W
("Is_Tagged_Type", Flag55
(Id
));
9737 W
("Is_Thunk", Flag225
(Id
));
9738 W
("Is_Trivial_Subprogram", Flag235
(Id
));
9739 W
("Is_True_Constant", Flag163
(Id
));
9740 W
("Is_Unchecked_Union", Flag117
(Id
));
9741 W
("Is_Underlying_Full_View", Flag298
(Id
));
9742 W
("Is_Underlying_Record_View", Flag246
(Id
));
9743 W
("Is_Unimplemented", Flag284
(Id
));
9744 W
("Is_Unsigned_Type", Flag144
(Id
));
9745 W
("Is_Uplevel_Referenced_Entity", Flag283
(Id
));
9746 W
("Is_Valued_Procedure", Flag127
(Id
));
9747 W
("Is_Visible_Formal", Flag206
(Id
));
9748 W
("Is_Visible_Lib_Unit", Flag116
(Id
));
9749 W
("Is_Volatile", Flag16
(Id
));
9750 W
("Is_Volatile_Full_Access", Flag285
(Id
));
9751 W
("Itype_Printed", Flag202
(Id
));
9752 W
("Kill_Elaboration_Checks", Flag32
(Id
));
9753 W
("Kill_Range_Checks", Flag33
(Id
));
9754 W
("Known_To_Have_Preelab_Init", Flag207
(Id
));
9755 W
("Low_Bound_Tested", Flag205
(Id
));
9756 W
("Machine_Radix_10", Flag84
(Id
));
9757 W
("Materialize_Entity", Flag168
(Id
));
9758 W
("May_Inherit_Delayed_Rep_Aspects", Flag262
(Id
));
9759 W
("Must_Be_On_Byte_Boundary", Flag183
(Id
));
9760 W
("Must_Have_Preelab_Init", Flag208
(Id
));
9761 W
("Needs_Debug_Info", Flag147
(Id
));
9762 W
("Needs_No_Actuals", Flag22
(Id
));
9763 W
("Never_Set_In_Source", Flag115
(Id
));
9764 W
("No_Dynamic_Predicate_On_actual", Flag276
(Id
));
9765 W
("No_Pool_Assigned", Flag131
(Id
));
9766 W
("No_Predicate_On_actual", Flag275
(Id
));
9767 W
("No_Reordering", Flag239
(Id
));
9768 W
("No_Return", Flag113
(Id
));
9769 W
("No_Strict_Aliasing", Flag136
(Id
));
9770 W
("Non_Binary_Modulus", Flag58
(Id
));
9771 W
("Nonzero_Is_True", Flag162
(Id
));
9772 W
("OK_To_Rename", Flag247
(Id
));
9773 W
("Optimize_Alignment_Space", Flag241
(Id
));
9774 W
("Optimize_Alignment_Time", Flag242
(Id
));
9775 W
("Overlays_Constant", Flag243
(Id
));
9776 W
("Partial_View_Has_Unknown_Discr", Flag280
(Id
));
9777 W
("Reachable", Flag49
(Id
));
9778 W
("Referenced", Flag156
(Id
));
9779 W
("Referenced_As_LHS", Flag36
(Id
));
9780 W
("Referenced_As_Out_Parameter", Flag227
(Id
));
9781 W
("Renamed_In_Spec", Flag231
(Id
));
9782 W
("Requires_Overriding", Flag213
(Id
));
9783 W
("Return_Present", Flag54
(Id
));
9784 W
("Returns_By_Ref", Flag90
(Id
));
9785 W
("Reverse_Bit_Order", Flag164
(Id
));
9786 W
("Reverse_Storage_Order", Flag93
(Id
));
9787 W
("Rewritten_For_C", Flag287
(Id
));
9788 W
("Predicates_Ignored", Flag288
(Id
));
9789 W
("Sec_Stack_Needed_For_Return", Flag167
(Id
));
9790 W
("Size_Depends_On_Discriminant", Flag177
(Id
));
9791 W
("Size_Known_At_Compile_Time", Flag92
(Id
));
9792 W
("SPARK_Aux_Pragma_Inherited", Flag266
(Id
));
9793 W
("SPARK_Pragma_Inherited", Flag265
(Id
));
9794 W
("SSO_Set_High_By_Default", Flag273
(Id
));
9795 W
("SSO_Set_Low_By_Default", Flag272
(Id
));
9796 W
("Static_Elaboration_Desired", Flag77
(Id
));
9797 W
("Stores_Attribute_Old_Prefix", Flag270
(Id
));
9798 W
("Strict_Alignment", Flag145
(Id
));
9799 W
("Suppress_Elaboration_Warnings", Flag303
(Id
));
9800 W
("Suppress_Initialization", Flag105
(Id
));
9801 W
("Suppress_Style_Checks", Flag165
(Id
));
9802 W
("Suppress_Value_Tracking_On_Call", Flag217
(Id
));
9803 W
("Treat_As_Volatile", Flag41
(Id
));
9804 W
("Universal_Aliasing", Flag216
(Id
));
9805 W
("Used_As_Generic_Actual", Flag222
(Id
));
9806 W
("Uses_Sec_Stack", Flag95
(Id
));
9807 W
("Warnings_Off", Flag96
(Id
));
9808 W
("Warnings_Off_Used", Flag236
(Id
));
9809 W
("Warnings_Off_Used_Unmodified", Flag237
(Id
));
9810 W
("Warnings_Off_Used_Unreferenced", Flag238
(Id
));
9811 W
("Was_Hidden", Flag196
(Id
));
9812 end Write_Entity_Flags
;
9814 -----------------------
9815 -- Write_Entity_Info --
9816 -----------------------
9818 procedure Write_Entity_Info
(Id
: Entity_Id
; Prefix
: String) is
9820 procedure Write_Attribute
(Which
: String; Nam
: E
);
9821 -- Write attribute value with given string name
9823 procedure Write_Kind
(Id
: Entity_Id
);
9824 -- Write Ekind field of entity
9826 ---------------------
9827 -- Write_Attribute --
9828 ---------------------
9830 procedure Write_Attribute
(Which
: String; Nam
: E
) is
9834 Write_Int
(Int
(Nam
));
9836 Write_Name
(Chars
(Nam
));
9838 end Write_Attribute
;
9844 procedure Write_Kind
(Id
: Entity_Id
) is
9845 K
: constant String := Entity_Kind
'Image (Ekind
(Id
));
9849 Write_Str
(" Kind ");
9851 if Is_Type
(Id
) and then Is_Tagged_Type
(Id
) then
9852 Write_Str
("TAGGED ");
9855 Write_Str
(K
(3 .. K
'Length));
9858 if Is_Type
(Id
) and then Depends_On_Private
(Id
) then
9859 Write_Str
("Depends_On_Private ");
9863 -- Start of processing for Write_Entity_Info
9867 Write_Attribute
("Name ", Id
);
9868 Write_Int
(Int
(Id
));
9872 Write_Attribute
(" Type ", Etype
(Id
));
9874 Write_Attribute
(" Scope ", Scope
(Id
));
9878 when Discrete_Kind
=>
9879 Write_Str
("Bounds: Id = ");
9881 if Present
(Scalar_Range
(Id
)) then
9882 Write_Int
(Int
(Type_Low_Bound
(Id
)));
9883 Write_Str
(" .. Id = ");
9884 Write_Int
(Int
(Type_High_Bound
(Id
)));
9886 Write_Str
("Empty");
9897 (" Component Type ", Component_Type
(Id
));
9900 Write_Str
(" Indexes ");
9902 Index
:= First_Index
(Id
);
9903 while Present
(Index
) loop
9904 Write_Attribute
(" ", Etype
(Index
));
9905 Index
:= Next_Index
(Index
);
9913 (" Directly Designated Type ",
9914 Directly_Designated_Type
(Id
));
9917 when Overloadable_Kind
=>
9918 if Present
(Homonym
(Id
)) then
9919 Write_Str
(" Homonym ");
9920 Write_Name
(Chars
(Homonym
(Id
)));
9922 Write_Int
(Int
(Homonym
(Id
)));
9929 if Ekind
(Scope
(Id
)) in Record_Kind
then
9931 " Original_Record_Component ",
9932 Original_Record_Component
(Id
));
9933 Write_Int
(Int
(Original_Record_Component
(Id
)));
9940 end Write_Entity_Info
;
9942 -----------------------
9943 -- Write_Field6_Name --
9944 -----------------------
9946 procedure Write_Field6_Name
(Id
: Entity_Id
) is
9947 pragma Unreferenced
(Id
);
9949 Write_Str
("First_Rep_Item");
9950 end Write_Field6_Name
;
9952 -----------------------
9953 -- Write_Field7_Name --
9954 -----------------------
9956 procedure Write_Field7_Name
(Id
: Entity_Id
) is
9957 pragma Unreferenced
(Id
);
9959 Write_Str
("Freeze_Node");
9960 end Write_Field7_Name
;
9962 -----------------------
9963 -- Write_Field8_Name --
9964 -----------------------
9966 procedure Write_Field8_Name
(Id
: Entity_Id
) is
9970 Write_Str
("Associated_Node_For_Itype");
9973 Write_Str
("Dependent_Instances");
9976 Write_Str
("First_Exit_Statement");
9979 Write_Str
("Hiding_Loop_Variable");
9985 Write_Str
("Mechanism");
9990 Write_Str
("Normalized_First_Bit");
9992 when E_Abstract_State
=>
9993 Write_Str
("Refinement_Constituents");
9995 when E_Return_Statement
=>
9996 Write_Str
("Return_Applies_To");
9999 Write_Str
("Field8??");
10001 end Write_Field8_Name
;
10003 -----------------------
10004 -- Write_Field9_Name --
10005 -----------------------
10007 procedure Write_Field9_Name
(Id
: Entity_Id
) is
10011 Write_Str
("Class_Wide_Type");
10013 when Object_Kind
=>
10014 Write_Str
("Current_Value");
10017 | E_Generic_Function
10018 | E_Generic_Package
10019 | E_Generic_Procedure
10023 Write_Str
("Renaming_Map");
10026 Write_Str
("Field9??");
10028 end Write_Field9_Name
;
10030 ------------------------
10031 -- Write_Field10_Name --
10032 ------------------------
10034 procedure Write_Field10_Name
(Id
: Entity_Id
) is
10037 when Class_Wide_Kind
10044 Write_Str
("Direct_Primitive_Operations");
10049 Write_Str
("Discriminal_Link");
10052 Write_Str
("Float_Rep");
10059 Write_Str
("Handler_Records");
10064 Write_Str
("Normalized_Position_Max");
10066 when E_Abstract_State
10069 Write_Str
("Part_Of_Constituents");
10072 Write_Str
("Field10??");
10074 end Write_Field10_Name
;
10076 ------------------------
10077 -- Write_Field11_Name --
10078 ------------------------
10080 procedure Write_Field11_Name
(Id
: Entity_Id
) is
10084 Write_Str
("Block_Node");
10089 Write_Str
("Component_Bit_Offset");
10091 when Formal_Kind
=>
10092 Write_Str
("Entry_Component");
10094 when E_Enumeration_Literal
=>
10095 Write_Str
("Enumeration_Pos");
10100 Write_Str
("Full_View");
10102 when E_Generic_Package
=>
10103 Write_Str
("Generic_Homonym");
10106 Write_Str
("Part_Of_References");
10113 Write_Str
("Protected_Body_Subprogram");
10116 Write_Str
("Field11??");
10118 end Write_Field11_Name
;
10120 ------------------------
10121 -- Write_Field12_Name --
10122 ------------------------
10124 procedure Write_Field12_Name
(Id
: Entity_Id
) is
10128 Write_Str
("Associated_Formal_Package");
10131 Write_Str
("Barrier_Function");
10133 when E_Enumeration_Literal
=>
10134 Write_Str
("Enumeration_Rep");
10142 | E_In_Out_Parameter
10147 Write_Str
("Esize");
10152 Write_Str
("Next_Inlined_Subprogram");
10155 Write_Str
("Field12??");
10157 end Write_Field12_Name
;
10159 ------------------------
10160 -- Write_Field13_Name --
10161 ------------------------
10163 procedure Write_Field13_Name
(Id
: Entity_Id
) is
10169 Write_Str
("Component_Clause");
10174 | Generic_Unit_Kind
10176 Write_Str
("Elaboration_Entity");
10181 Write_Str
("Extra_Accessibility");
10184 Write_Str
("RM_Size");
10187 Write_Str
("Field13??");
10189 end Write_Field13_Name
;
10191 -----------------------
10192 -- Write_Field14_Name --
10193 -----------------------
10195 procedure Write_Field14_Name
(Id
: Entity_Id
) is
10205 Write_Str
("Alignment");
10210 Write_Str
("Normalized_Position");
10217 Write_Str
("Postconditions_Proc");
10219 when E_Generic_Package
10222 Write_Str
("Shadow_Entities");
10225 Write_Str
("Field14??");
10227 end Write_Field14_Name
;
10229 ------------------------
10230 -- Write_Field15_Name --
10231 ------------------------
10233 procedure Write_Field15_Name
(Id
: Entity_Id
) is
10236 when E_Discriminant
=>
10237 Write_Str
("Discriminant_Number");
10239 when E_Component
=>
10240 Write_Str
("DT_Entry_Count");
10245 Write_Str
("DT_Position");
10248 Write_Str
("Entry_Parameters_Type");
10250 when Formal_Kind
=>
10251 Write_Str
("Extra_Formal");
10254 Write_Str
("Pending_Access_Types");
10259 Write_Str
("Related_Instance");
10265 Write_Str
("Status_Flag_Or_Transient_Decl");
10268 Write_Str
("Field15??");
10270 end Write_Field15_Name
;
10272 ------------------------
10273 -- Write_Field16_Name --
10274 ------------------------
10276 procedure Write_Field16_Name
(Id
: Entity_Id
) is
10280 | E_Record_Type_With_Private
10282 Write_Str
("Access_Disp_Table");
10284 when E_Abstract_State
=>
10285 Write_Str
("Body_References");
10287 when E_Class_Wide_Subtype
10290 Write_Str
("Cloned_Subtype");
10295 Write_Str
("DTC_Entity");
10297 when E_Component
=>
10298 Write_Str
("Entry_Formal");
10300 when Concurrent_Kind
10301 | E_Generic_Package
10304 Write_Str
("First_Private_Entity");
10306 when Enumeration_Kind
=>
10307 Write_Str
("Lit_Strings");
10309 when Decimal_Fixed_Point_Kind
=>
10310 Write_Str
("Scale_Value");
10312 when E_String_Literal_Subtype
=>
10313 Write_Str
("String_Literal_Length");
10315 when E_Out_Parameter
10318 Write_Str
("Unset_Reference");
10321 Write_Str
("Field16??");
10323 end Write_Field16_Name
;
10325 ------------------------
10326 -- Write_Field17_Name --
10327 ------------------------
10329 procedure Write_Field17_Name
(Id
: Entity_Id
) is
10334 | E_Generic_In_Out_Parameter
10337 Write_Str
("Actual_Subtype");
10339 when Digits_Kind
=>
10340 Write_Str
("Digits_Value");
10342 when E_Discriminant
=>
10343 Write_Str
("Discriminal");
10345 when Class_Wide_Kind
10352 | E_Generic_Function
10353 | E_Generic_Package
10354 | E_Generic_Procedure
10362 | E_Return_Statement
10363 | E_Subprogram_Body
10364 | E_Subprogram_Type
10366 Write_Str
("First_Entity");
10369 Write_Str
("First_Index");
10371 when Enumeration_Kind
=>
10372 Write_Str
("First_Literal");
10374 when Access_Kind
=>
10375 Write_Str
("Master_Id");
10377 when Modular_Integer_Kind
=>
10378 Write_Str
("Modulus");
10380 when E_Component
=>
10381 Write_Str
("Prival");
10384 Write_Str
("Field17??");
10386 end Write_Field17_Name
;
10388 ------------------------
10389 -- Write_Field18_Name --
10390 ------------------------
10392 procedure Write_Field18_Name
(Id
: Entity_Id
) is
10395 when E_Enumeration_Literal
10400 Write_Str
("Alias");
10402 when E_Record_Type
=>
10403 Write_Str
("Corresponding_Concurrent_Type");
10405 when E_Subprogram_Body
=>
10406 Write_Str
("Corresponding_Protected_Entry");
10408 when Concurrent_Kind
=>
10409 Write_Str
("Corresponding_Record_Type");
10415 Write_Str
("Enclosing_Scope");
10417 when E_Entry_Index_Parameter
=>
10418 Write_Str
("Entry_Index_Constant");
10420 when E_Access_Protected_Subprogram_Type
10421 | E_Access_Subprogram_Type
10422 | E_Anonymous_Access_Protected_Subprogram_Type
10424 | E_Class_Wide_Subtype
10426 Write_Str
("Equivalent_Type");
10428 when Fixed_Point_Kind
=>
10429 Write_Str
("Delta_Value");
10431 when Enumeration_Kind
=>
10432 Write_Str
("Lit_Indexes");
10434 when Incomplete_Or_Private_Kind
10437 Write_Str
("Private_Dependents");
10440 | E_Generic_Function
10441 | E_Generic_Package
10442 | E_Generic_Procedure
10445 Write_Str
("Renamed_Entity");
10447 when Object_Kind
=>
10448 Write_Str
("Renamed_Object");
10450 when E_String_Literal_Subtype
=>
10451 Write_Str
("String_Literal_Low_Bound");
10454 Write_Str
("Field18??");
10456 end Write_Field18_Name
;
10458 -----------------------
10459 -- Write_Field19_Name --
10460 -----------------------
10462 procedure Write_Field19_Name
(Id
: Entity_Id
) is
10465 when E_Generic_Package
10468 Write_Str
("Body_Entity");
10470 when E_Discriminant
=>
10471 Write_Str
("Corresponding_Discriminant");
10473 when Scalar_Kind
=>
10474 Write_Str
("Default_Aspect_Value");
10476 when E_Array_Type
=>
10477 Write_Str
("Default_Component_Value");
10479 when E_Protected_Type
=>
10480 Write_Str
("Entry_Bodies_Array");
10484 | E_Subprogram_Type
10486 Write_Str
("Extra_Accessibility_Of_Result");
10488 when E_Abstract_State
10489 | E_Class_Wide_Type
10490 | E_Incomplete_Type
10492 Write_Str
("Non_Limited_View");
10494 when E_Incomplete_Subtype
=>
10495 if From_Limited_With
(Id
) then
10496 Write_Str
("Non_Limited_View");
10499 when E_Record_Type
=>
10500 Write_Str
("Parent_Subtype");
10502 when E_Procedure
=>
10503 Write_Str
("Receiving_Entry");
10508 Write_Str
("Size_Check_Code");
10513 Write_Str
("Spec_Entity");
10515 when Private_Kind
=>
10516 Write_Str
("Underlying_Full_View");
10519 Write_Str
("Field19??");
10521 end Write_Field19_Name
;
10523 -----------------------
10524 -- Write_Field20_Name --
10525 -----------------------
10527 procedure Write_Field20_Name
(Id
: Entity_Id
) is
10531 Write_Str
("Component_Type");
10533 when E_Generic_In_Parameter
10536 Write_Str
("Default_Value");
10538 when Access_Kind
=>
10539 Write_Str
("Directly_Designated_Type");
10541 when E_Component
=>
10542 Write_Str
("Discriminant_Checking_Func");
10544 when E_Discriminant
=>
10545 Write_Str
("Discriminant_Default_Value");
10547 when Class_Wide_Kind
10554 | E_Generic_Function
10555 | E_Generic_Package
10556 | E_Generic_Procedure
10564 | E_Return_Statement
10565 | E_Subprogram_Body
10566 | E_Subprogram_Type
10568 Write_Str
("Last_Entity");
10573 Write_Str
("Prival_Link");
10575 when E_Exception
=>
10576 Write_Str
("Register_Exception_Call");
10578 when Scalar_Kind
=>
10579 Write_Str
("Scalar_Range");
10582 Write_Str
("Field20??");
10584 end Write_Field20_Name
;
10586 -----------------------
10587 -- Write_Field21_Name --
10588 -----------------------
10590 procedure Write_Field21_Name
(Id
: Entity_Id
) is
10594 Write_Str
("Accept_Address");
10599 Write_Str
("Corresponding_Record_Component");
10601 when E_In_Parameter
=>
10602 Write_Str
("Default_Expr_Function");
10604 when Concurrent_Kind
10605 | Incomplete_Or_Private_Kind
10610 Write_Str
("Discriminant_Constraint");
10615 | E_Generic_Function
10616 | E_Generic_Procedure
10620 Write_Str
("Interface_Name");
10623 | Modular_Integer_Kind
10625 Write_Str
("Original_Array_Type");
10627 when Fixed_Point_Kind
=>
10628 Write_Str
("Small_Value");
10631 Write_Str
("Field21??");
10633 end Write_Field21_Name
;
10635 -----------------------
10636 -- Write_Field22_Name --
10637 -----------------------
10639 procedure Write_Field22_Name
(Id
: Entity_Id
) is
10642 when Access_Kind
=>
10643 Write_Str
("Associated_Storage_Pool");
10646 Write_Str
("Component_Size");
10648 when E_Record_Type
=>
10649 Write_Str
("Corresponding_Remote_Type");
10654 Write_Str
("Original_Record_Component");
10656 when E_Enumeration_Literal
=>
10657 Write_Str
("Enumeration_Rep_Expr");
10659 when E_Limited_Private_Subtype
10660 | E_Limited_Private_Type
10661 | E_Private_Subtype
10663 | E_Record_Subtype_With_Private
10664 | E_Record_Type_With_Private
10666 Write_Str
("Private_View");
10668 when Formal_Kind
=>
10669 Write_Str
("Protected_Formal");
10675 | E_Generic_Function
10676 | E_Generic_Package
10677 | E_Generic_Procedure
10683 | E_Return_Statement
10684 | E_Subprogram_Body
10687 Write_Str
("Scope_Depth_Value");
10690 Write_Str
("Shared_Var_Procs_Instance");
10693 Write_Str
("Field22??");
10695 end Write_Field22_Name
;
10697 ------------------------
10698 -- Write_Field23_Name --
10699 ------------------------
10701 procedure Write_Field23_Name
(Id
: Entity_Id
) is
10704 when E_Discriminant
=>
10705 Write_Str
("CR_Discriminant");
10708 Write_Str
("Entry_Cancel_Parameter");
10710 when E_Enumeration_Type
=>
10711 Write_Str
("Enum_Pos_To_Rep");
10716 Write_Str
("Extra_Constrained");
10718 when Access_Kind
=>
10719 Write_Str
("Finalization_Master");
10721 when E_Generic_Function
10722 | E_Generic_Package
10723 | E_Generic_Procedure
10725 Write_Str
("Inner_Instances");
10728 Write_Str
("Packed_Array_Impl_Type");
10731 Write_Str
("Protection_Object");
10733 when Class_Wide_Kind
10735 | Incomplete_Or_Private_Kind
10739 Write_Str
("Stored_Constraint");
10744 if Present
(Scope
(Id
))
10745 and then Is_Protected_Type
(Scope
(Id
))
10747 Write_Str
("Protection_Object");
10749 Write_Str
("Generic_Renamings");
10753 if Is_Generic_Instance
(Id
) then
10754 Write_Str
("Generic_Renamings");
10756 Write_Str
("Limited_View");
10760 Write_Str
("Field23??");
10762 end Write_Field23_Name
;
10764 ------------------------
10765 -- Write_Field24_Name --
10766 ------------------------
10768 procedure Write_Field24_Name
(Id
: Entity_Id
) is
10775 Write_Str
("Related_Expression");
10781 Write_Str
("Subps_Index");
10784 Write_Str
("Incomplete_Actuals");
10787 Write_Str
("Field24???");
10789 end Write_Field24_Name
;
10791 ------------------------
10792 -- Write_Field25_Name --
10793 ------------------------
10795 procedure Write_Field25_Name
(Id
: Entity_Id
) is
10798 when E_Generic_Package
10801 Write_Str
("Abstract_States");
10806 Write_Str
("Contract_Wrapper");
10809 Write_Str
("Debug_Renaming_Link");
10811 when E_Component
=>
10812 Write_Str
("DT_Offset_To_Top_Func");
10817 Write_Str
("Interface_Alias");
10819 when E_Record_Subtype
10820 | E_Record_Subtype_With_Private
10822 | E_Record_Type_With_Private
10824 Write_Str
("Interfaces");
10826 when E_Array_Subtype
10829 Write_Str
("Related_Array_Object");
10831 when Discrete_Kind
=>
10832 Write_Str
("Static_Discrete_Predicate");
10835 Write_Str
("Static_Real_Or_String_Predicate");
10838 Write_Str
("Task_Body_Procedure");
10841 Write_Str
("Field25??");
10843 end Write_Field25_Name
;
10845 ------------------------
10846 -- Write_Field26_Name --
10847 ------------------------
10849 procedure Write_Field26_Name
(Id
: Entity_Id
) is
10853 | E_Record_Type_With_Private
10855 Write_Str
("Dispatch_Table_Wrappers");
10857 when E_In_Out_Parameter
10861 Write_Str
("Last_Assignment");
10866 Write_Str
("Overridden_Operation");
10868 when E_Generic_Package
10871 Write_Str
("Package_Instantiation");
10876 Write_Str
("Related_Type");
10881 Write_Str
("Storage_Size_Variable");
10884 Write_Str
("Field26??");
10886 end Write_Field26_Name
;
10888 ------------------------
10889 -- Write_Field27_Name --
10890 ------------------------
10892 procedure Write_Field27_Name
(Id
: Entity_Id
) is
10898 Write_Str
("Current_Use_Clause");
10904 Write_Str
("Related_Type");
10909 Write_Str
("Wrapped_Entity");
10912 Write_Str
("Field27??");
10914 end Write_Field27_Name
;
10916 ------------------------
10917 -- Write_Field28_Name --
10918 ------------------------
10920 procedure Write_Field28_Name
(Id
: Entity_Id
) is
10927 | E_Subprogram_Body
10928 | E_Subprogram_Type
10930 Write_Str
("Extra_Formals");
10935 Write_Str
("Finalizer");
10940 Write_Str
("Initialization_Statements");
10942 when E_Access_Subprogram_Type
=>
10943 Write_Str
("Original_Access_Type");
10946 Write_Str
("Relative_Deadline_Variable");
10948 when E_Record_Type
=>
10949 Write_Str
("Underlying_Record_View");
10952 Write_Str
("Field28??");
10954 end Write_Field28_Name
;
10956 ------------------------
10957 -- Write_Field29_Name --
10958 ------------------------
10960 procedure Write_Field29_Name
(Id
: Entity_Id
) is
10966 | E_Subprogram_Body
10968 Write_Str
("Anonymous_Masters");
10973 Write_Str
("BIP_Initialization_Call");
10976 Write_Str
("Subprograms_For_Type");
10979 Write_Str
("Field29??");
10981 end Write_Field29_Name
;
10983 ------------------------
10984 -- Write_Field30_Name --
10985 ------------------------
10987 procedure Write_Field30_Name
(Id
: Entity_Id
) is
10991 | E_Record_Type_With_Private
10993 Write_Str
("Access_Disp_Table_Elab_Flag");
10995 when E_Protected_Type
10998 Write_Str
("Anonymous_Object");
11001 Write_Str
("Corresponding_Equality");
11006 Write_Str
("Last_Aggregate_Assignment");
11008 when E_Procedure
=>
11009 Write_Str
("Static_Initialization");
11012 Write_Str
("Field30??");
11014 end Write_Field30_Name
;
11016 ------------------------
11017 -- Write_Field31_Name --
11018 ------------------------
11020 procedure Write_Field31_Name
(Id
: Entity_Id
) is
11025 | E_In_Out_Parameter
11030 Write_Str
("Activation_Record_Component");
11033 Write_Str
("Derived_Type_Link");
11038 Write_Str
("Thunk_Entity");
11041 Write_Str
("Field31??");
11043 end Write_Field31_Name
;
11045 ------------------------
11046 -- Write_Field32_Name --
11047 ------------------------
11049 procedure Write_Field32_Name
(Id
: Entity_Id
) is
11052 when E_Procedure
=>
11053 Write_Str
("Corresponding_Function");
11056 Write_Str
("Corresponding_Procedure");
11058 when E_Abstract_State
11062 Write_Str
("Encapsulating_State");
11065 Write_Str
("No_Tagged_Streams_Pragma");
11068 Write_Str
("Field32??");
11070 end Write_Field32_Name
;
11072 ------------------------
11073 -- Write_Field33_Name --
11074 ------------------------
11076 procedure Write_Field33_Name
(Id
: Entity_Id
) is
11079 when Subprogram_Kind
11084 Write_Str
("Linker_Section_Pragma");
11087 Write_Str
("Field33??");
11089 end Write_Field33_Name
;
11091 ------------------------
11092 -- Write_Field34_Name --
11093 ------------------------
11095 procedure Write_Field34_Name
(Id
: Entity_Id
) is
11102 | E_Generic_Function
11103 | E_Generic_Package
11104 | E_Generic_Procedure
11110 | E_Subprogram_Body
11116 Write_Str
("Contract");
11119 Write_Str
("Field34??");
11121 end Write_Field34_Name
;
11123 ------------------------
11124 -- Write_Field35_Name --
11125 ------------------------
11127 procedure Write_Field35_Name
(Id
: Entity_Id
) is
11131 Write_Str
("Anonymous_Designated_Type");
11136 Write_Str
("Entry_Max_Queue_Lenghts_Array");
11138 when Subprogram_Kind
=>
11139 Write_Str
("Import_Pragma");
11142 Write_Str
("Field35??");
11144 end Write_Field35_Name
;
11146 ------------------------
11147 -- Write_Field36_Name --
11148 ------------------------
11150 procedure Write_Field36_Name
(Id
: Entity_Id
) is
11155 | E_Subprogram_Body
11157 Write_Str
("Nested_Scenarios");
11160 Write_Str
("Validated_Object");
11163 Write_Str
("Field36??");
11165 end Write_Field36_Name
;
11167 ------------------------
11168 -- Write_Field37_Name --
11169 ------------------------
11171 procedure Write_Field37_Name
(Id
: Entity_Id
) is
11172 pragma Unreferenced
(Id
);
11174 Write_Str
("Associated_Entity");
11175 end Write_Field37_Name
;
11177 ------------------------
11178 -- Write_Field38_Name --
11179 ------------------------
11181 procedure Write_Field38_Name
(Id
: Entity_Id
) is
11187 Write_Str
("class-wide clone");
11190 Write_Str
("Field38??");
11192 end Write_Field38_Name
;
11194 ------------------------
11195 -- Write_Field39_Name --
11196 ------------------------
11198 procedure Write_Field39_Name
(Id
: Entity_Id
) is
11204 Write_Str
("Protected_Subprogram");
11207 Write_Str
("Field39??");
11209 end Write_Field39_Name
;
11211 ------------------------
11212 -- Write_Field40_Name --
11213 ------------------------
11215 procedure Write_Field40_Name
(Id
: Entity_Id
) is
11218 when E_Abstract_State
11223 | E_Generic_Function
11224 | E_Generic_Package
11225 | E_Generic_Procedure
11231 | E_Subprogram_Body
11237 Write_Str
("SPARK_Pragma");
11240 Write_Str
("Field40??");
11242 end Write_Field40_Name
;
11244 ------------------------
11245 -- Write_Field41_Name --
11246 ------------------------
11248 procedure Write_Field41_Name
(Id
: Entity_Id
) is
11254 Write_Str
("Original_Protected_Subprogram");
11256 when E_Generic_Package
11262 Write_Str
("SPARK_Aux_Pragma");
11265 Write_Str
("Field41??");
11267 end Write_Field41_Name
;
11269 -------------------------
11270 -- Iterator Procedures --
11271 -------------------------
11273 procedure Proc_Next_Component
(N
: in out Node_Id
) is
11275 N
:= Next_Component
(N
);
11276 end Proc_Next_Component
;
11278 procedure Proc_Next_Component_Or_Discriminant
(N
: in out Node_Id
) is
11280 N
:= Next_Entity
(N
);
11281 while Present
(N
) loop
11282 exit when Ekind_In
(N
, E_Component
, E_Discriminant
);
11283 N
:= Next_Entity
(N
);
11285 end Proc_Next_Component_Or_Discriminant
;
11287 procedure Proc_Next_Discriminant
(N
: in out Node_Id
) is
11289 N
:= Next_Discriminant
(N
);
11290 end Proc_Next_Discriminant
;
11292 procedure Proc_Next_Formal
(N
: in out Node_Id
) is
11294 N
:= Next_Formal
(N
);
11295 end Proc_Next_Formal
;
11297 procedure Proc_Next_Formal_With_Extras
(N
: in out Node_Id
) is
11299 N
:= Next_Formal_With_Extras
(N
);
11300 end Proc_Next_Formal_With_Extras
;
11302 procedure Proc_Next_Index
(N
: in out Node_Id
) is
11304 N
:= Next_Index
(N
);
11305 end Proc_Next_Index
;
11307 procedure Proc_Next_Inlined_Subprogram
(N
: in out Node_Id
) is
11309 N
:= Next_Inlined_Subprogram
(N
);
11310 end Proc_Next_Inlined_Subprogram
;
11312 procedure Proc_Next_Literal
(N
: in out Node_Id
) is
11314 N
:= Next_Literal
(N
);
11315 end Proc_Next_Literal
;
11317 procedure Proc_Next_Stored_Discriminant
(N
: in out Node_Id
) is
11319 N
:= Next_Stored_Discriminant
(N
);
11320 end Proc_Next_Stored_Discriminant
;