[multiple changes]
[gcc.git] / gcc / ada / sinfo.ads
1 ------------------------------------------------------------------------------
2 -- --
3 -- GNAT COMPILER COMPONENTS --
4 -- --
5 -- S I N F O --
6 -- --
7 -- S p e c --
8 -- --
9 -- Copyright (C) 1992-2010, Free Software Foundation, Inc. --
10 -- --
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. --
17 -- --
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. --
21 -- --
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/>. --
26 -- --
27 -- GNAT was originally developed by the GNAT team at New York University. --
28 -- Extensive contributions were provided by Ada Core Technologies Inc. --
29 -- --
30 ------------------------------------------------------------------------------
31
32 -- This package defines the structure of the abstract syntax tree. The Tree
33 -- package provides a basic tree structure. Sinfo describes how this structure
34 -- is used to represent the syntax of an Ada program.
35
36 -- The grammar in the RM is followed very closely in the tree design, and is
37 -- repeated as part of this source file.
38
39 -- The tree contains not only the full syntactic representation of the
40 -- program, but also the results of semantic analysis. In particular, the
41 -- nodes for defining identifiers, defining character literals and defining
42 -- operator symbols, collectively referred to as entities, represent what
43 -- would normally be regarded as the symbol table information. In addition a
44 -- number of the tree nodes contain semantic information.
45
46 -- WARNING: Several files are automatically generated from this package.
47 -- See below for details.
48
49 with Namet; use Namet;
50 with Types; use Types;
51 with Uintp; use Uintp;
52 with Urealp; use Urealp;
53
54 package Sinfo is
55
56 ---------------------------------
57 -- Making Changes to This File --
58 ---------------------------------
59
60 -- If changes are made to this file, a number of related steps must be
61 -- carried out to ensure consistency. First, if a field access function is
62 -- added, it appears in these places:
63
64 -- In sinfo.ads:
65 -- The documentation associated with the field (if semantic)
66 -- The documentation associated with the node
67 -- The spec of the access function
68 -- The spec of the set procedure
69 -- The entries in Is_Syntactic_Field
70 -- The pragma Inline for the access function
71 -- The pragma Inline for the set procedure
72 -- In sinfo.adb:
73 -- The body of the access function
74 -- The body of the set procedure
75
76 -- The field chosen must be consistent in all places, and, for a node that
77 -- is a subexpression, must not overlap any of the standard expression
78 -- fields.
79
80 -- In addition, if any of the standard expression fields is changed, then
81 -- the utility program which creates the Treeprs spec (in file treeprs.ads)
82 -- must be updated appropriately, since it special cases expression fields.
83
84 -- If a new tree node is added, then the following changes are made
85
86 -- Add it to the documentation in the appropriate place
87 -- Add its fields to this documentation section
88 -- Define it in the appropriate classification in Node_Kind
89 -- In the body (sinfo), add entries to the access functions for all
90 -- its fields (except standard expression fields) to include the new
91 -- node in the checks.
92 -- Add an appropriate section to the case statement in sprint.adb
93 -- Add an appropriate section to the case statement in sem.adb
94 -- Add an appropriate section to the case statement in exp_util.adb
95 -- (Insert_Actions procedure)
96 -- For a subexpression, add an appropriate section to the case
97 -- statement in sem_eval.adb
98 -- For a subexpression, add an appropriate section to the case
99 -- statement in sem_res.adb
100
101 -- Finally, four utility programs must be run:
102
103 -- Run CSinfo to check that you have made the changes consistently. It
104 -- checks most of the rules given above, with clear error messages. This
105 -- utility reads sinfo.ads and sinfo.adb and generates a report to
106 -- standard output.
107
108 -- Run XSinfo to create sinfo.h, the corresponding C header. This
109 -- utility reads sinfo.ads and generates sinfo.h. Note that it does
110 -- not need to read sinfo.adb, since the contents of the body are
111 -- algorithmically determinable from the spec.
112
113 -- Run XTreeprs to create treeprs.ads, an updated version of the module
114 -- that is used to drive the tree print routine. This utility reads (but
115 -- does not modify) treeprs.adt, the template that provides the basic
116 -- structure of the file, and then fills in the data from the comments
117 -- in sinfo.ads.
118
119 -- Run XNmake to create nmake.ads and nmake.adb, the package body and
120 -- spec of the Nmake package which contains functions for constructing
121 -- nodes.
122
123 -- All of the above steps except CSinfo are done automatically by the
124 -- build scripts when you do a full bootstrap.
125
126 -- Note: sometime we could write a utility that actually generated the body
127 -- of sinfo from the spec instead of simply checking it, since, as noted
128 -- above, the contents of the body can be determined from the spec.
129
130 --------------------------------
131 -- Implicit Nodes in the Tree --
132 --------------------------------
133
134 -- Generally the structure of the tree very closely follows the grammar as
135 -- defined in the RM. However, certain nodes are omitted to save space and
136 -- simplify semantic processing. Two general classes of such omitted nodes
137 -- are as follows:
138
139 -- If the only possibilities for a non-terminal are one or more other
140 -- non-terminals (i.e. the rule is a "skinny" rule), then usually the
141 -- corresponding node is omitted from the tree, and the target construct
142 -- appears directly. For example, a real type definition is either
143 -- floating point definition or a fixed point definition. No explicit node
144 -- appears for real type definition. Instead either the floating point
145 -- definition or fixed point definition appears directly.
146
147 -- If a non-terminal corresponds to a list of some other non-terminal
148 -- (possibly with separating punctuation), then usually it is omitted from
149 -- the tree, and a list of components appears instead. For example,
150 -- sequence of statements does not appear explicitly in the tree. Instead
151 -- a list of statements appears directly.
152
153 -- Some additional cases of omitted nodes occur and are documented
154 -- individually. In particular, many nodes are omitted in the tree
155 -- generated for an expression.
156
157 -------------------------------------------
158 -- Handling of Defining Identifier Lists --
159 -------------------------------------------
160
161 -- In several declarative forms in the syntax, lists of defining
162 -- identifiers appear (object declarations, component declarations, number
163 -- declarations etc.)
164
165 -- The semantics of such statements are equivalent to a series of identical
166 -- declarations of single defining identifiers (except that conformance
167 -- checks require the same grouping of identifiers in the parameter case).
168
169 -- To simplify semantic processing, the parser breaks down such multiple
170 -- declaration cases into sequences of single declarations, duplicating
171 -- type and initialization information as required. The flags More_Ids and
172 -- Prev_Ids are used to record the original form of the source in the case
173 -- where the original source used a list of names, More_Ids being set on
174 -- all but the last name and Prev_Ids being set on all but the first name.
175 -- These flags are used to reconstruct the original source (e.g. in the
176 -- Sprint package), and also are included in the conformance checks, but
177 -- otherwise have no semantic significance.
178
179 -- Note: the reason that we use More_Ids and Prev_Ids rather than
180 -- First_Name and Last_Name flags is so that the flags are off in the
181 -- normal one identifier case, which minimizes tree print output.
182
183 -----------------------
184 -- Use of Node Lists --
185 -----------------------
186
187 -- With a few exceptions, if a construction of the form {non-terminal}
188 -- appears in the tree, lists are used in the corresponding tree node (see
189 -- package Nlists for handling of node lists). In this case a field of the
190 -- parent node points to a list of nodes for the non-terminal. The field
191 -- name for such fields has a plural name which always ends in "s". For
192 -- example, a case statement has a field Alternatives pointing to list of
193 -- case statement alternative nodes.
194
195 -- Only fields pointing to lists have names ending in "s", so generally the
196 -- structure is strongly typed, fields not ending in s point to single
197 -- nodes, and fields ending in s point to lists.
198
199 -- The following example shows how a traversal of a list is written. We
200 -- suppose here that Stmt points to a N_Case_Statement node which has a
201 -- list field called Alternatives:
202
203 -- Alt := First (Alternatives (Stmt));
204 -- while Present (Alt) loop
205 -- ..
206 -- -- processing for case statement alternative Alt
207 -- ..
208 -- Alt := Next (Alt);
209 -- end loop;
210
211 -- The Present function tests for Empty, which in this case signals the end
212 -- of the list. First returns Empty immediately if the list is empty.
213 -- Present is defined in Atree, First and Next are defined in Nlists.
214
215 -- The exceptions to this rule occur with {DEFINING_IDENTIFIERS} in all
216 -- contexts, which is handled as described in the previous section, and
217 -- with {,library_unit_NAME} in the N_With_Clause mode, which is handled
218 -- using the First_Name and Last_Name flags, as further detailed in the
219 -- description of the N_With_Clause node.
220
221 -------------
222 -- Pragmas --
223 -------------
224
225 -- Pragmas can appear in many different context, but are not included in
226 -- the grammar. Still they must appear in the tree, so they can be properly
227 -- processed.
228
229 -- Two approaches are used. In some cases, an extra field is defined in an
230 -- appropriate node that contains a list of pragmas appearing in the
231 -- expected context. For example pragmas can appear before an
232 -- Accept_Alternative in a Selective_Accept_Statement, and these pragmas
233 -- appear in the Pragmas_Before field of the N_Accept_Alternative node.
234
235 -- The other approach is to simply allow pragmas to appear in syntactic
236 -- lists where the grammar (of course) does not include the possibility.
237 -- For example, the Variants field of an N_Variant_Part node points to a
238 -- list that can contain both N_Pragma and N_Variant nodes.
239
240 -- To make processing easier in the latter case, the Nlists package
241 -- provides a set of routines (First_Non_Pragma, Last_Non_Pragma,
242 -- Next_Non_Pragma, Prev_Non_Pragma) that allow such lists to be handled
243 -- ignoring all pragmas.
244
245 -- In the case of the variants list, we can either write:
246
247 -- Variant := First (Variants (N));
248 -- while Present (Variant) loop
249 -- ...
250 -- Variant := Next (Variant);
251 -- end loop;
252
253 -- or
254
255 -- Variant := First_Non_Pragma (Variants (N));
256 -- while Present (Variant) loop
257 -- ...
258 -- Variant := Next_Non_Pragma (Variant);
259 -- end loop;
260
261 -- In the first form of the loop, Variant can either be an N_Pragma or an
262 -- N_Variant node. In the second form, Variant can only be N_Variant since
263 -- all pragmas are skipped.
264
265 ---------------------
266 -- Optional Fields --
267 ---------------------
268
269 -- Fields which correspond to a section of the syntax enclosed in square
270 -- brackets are generally omitted (and the corresponding field set to Empty
271 -- for a node, or No_List for a list). The documentation of such fields
272 -- notes these cases. One exception to this rule occurs in the case of
273 -- possibly empty statement sequences (such as the sequence of statements
274 -- in an entry call alternative). Such cases appear in the syntax rules as
275 -- [SEQUENCE_OF_STATEMENTS] and the fields corresponding to such optional
276 -- statement sequences always contain an empty list (not No_List) if no
277 -- statements are present.
278
279 -- Note: the utility program that constructs the body and spec of the Nmake
280 -- package relies on the format of the comments to determine if a field
281 -- should have a default value in the corresponding make routine. The rule
282 -- is that if the first line of the description of the field contains the
283 -- string "(set to xxx if", then a default value of xxx is provided for
284 -- this field in the corresponding Make_yyy routine.
285
286 -----------------------------------
287 -- Note on Body/Spec Terminology --
288 -----------------------------------
289
290 -- In informal discussions about Ada, it is customary to refer to package
291 -- and subprogram specs and bodies. However, this is not technically
292 -- correct, what is normally referred to as a spec or specification is in
293 -- fact a package declaration or subprogram declaration. We are careful in
294 -- GNAT to use the correct terminology and in particular, the full word
295 -- specification is never used as an incorrect substitute for declaration.
296 -- The structure and terminology used in the tree also reflects the grammar
297 -- and thus uses declaration and specification in the technically correct
298 -- manner.
299
300 -- However, there are contexts in which the informal terminology is useful.
301 -- We have the word "body" to refer to the Interp_Etype declared by the
302 -- declaration of a unit body, and in some contexts we need similar term to
303 -- refer to the entity declared by the package or subprogram declaration,
304 -- and simply using declaration can be confusing since the body also has a
305 -- declaration.
306
307 -- An example of such a context is the link between the package body and
308 -- its declaration. With_Declaration is confusing, since the package body
309 -- itself is a declaration.
310
311 -- To deal with this problem, we reserve the informal term Spec, i.e. the
312 -- popular abbreviation used in this context, to refer to the entity
313 -- declared by the package or subprogram declaration. So in the above
314 -- example case, the field in the body is called With_Spec.
315
316 -- Another important context for the use of the word Spec is in error
317 -- messages, where a hyper-correct use of declaration would be confusing to
318 -- a typical Ada programmer, and even for an expert programmer can cause
319 -- confusion since the body has a declaration as well.
320
321 -- So, to summarize:
322
323 -- Declaration always refers to the syntactic entity that is called
324 -- a declaration. In particular, subprogram declaration
325 -- and package declaration are used to describe the
326 -- syntactic entity that includes the semicolon.
327
328 -- Specification always refers to the syntactic entity that is called
329 -- a specification. In particular, the terms procedure
330 -- specification, function specification, package
331 -- specification, subprogram specification always refer
332 -- to the syntactic entity that has no semicolon.
333
334 -- Spec is an informal term, used to refer to the entity
335 -- that is declared by a task declaration, protected
336 -- declaration, generic declaration, subprogram
337 -- declaration or package declaration.
338
339 -- This convention is followed throughout the GNAT documentation
340 -- both internal and external, and in all error message text.
341
342 ------------------------
343 -- Internal Use Nodes --
344 ------------------------
345
346 -- These are Node_Kind settings used in the internal implementation which
347 -- are not logically part of the specification.
348
349 -- N_Unused_At_Start
350 -- Completely unused entry at the start of the enumeration type. This
351 -- is inserted so that no legitimate value is zero, which helps to get
352 -- better debugging behavior, since zero is a likely uninitialized value).
353
354 -- N_Unused_At_End
355 -- Completely unused entry at the end of the enumeration type. This is
356 -- handy so that arrays with Node_Kind as the index type have an extra
357 -- entry at the end (see for example the use of the Pchar_Pos_Array in
358 -- Treepr, where the extra entry provides the limit value when dealing with
359 -- the last used entry in the array).
360
361 -----------------------------------------
362 -- Note on the settings of Sloc fields --
363 -----------------------------------------
364
365 -- The Sloc field of nodes that come from the source is set by the parser.
366 -- For internal nodes, and nodes generated during expansion the Sloc is
367 -- usually set in the call to the constructor for the node. In general the
368 -- Sloc value chosen for an internal node is the Sloc of the source node
369 -- whose processing is responsible for the expansion. For example, the Sloc
370 -- of an inherited primitive operation is the Sloc of the corresponding
371 -- derived type declaration.
372
373 -- For the nodes of a generic instantiation, the Sloc value is encoded to
374 -- represent both the original Sloc in the generic unit, and the Sloc of
375 -- the instantiation itself. See Sinput.ads for details.
376
377 -- Subprogram instances create two callable entities: one is the visible
378 -- subprogram instance, and the other is an anonymous subprogram nested
379 -- within a wrapper package that contains the renamings for the actuals.
380 -- Both of these entities have the Sloc of the defining entity in the
381 -- instantiation node. This simplifies some ASIS queries.
382
383 -----------------------
384 -- Field Definitions --
385 -----------------------
386
387 -- In the following node definitions, all fields, both syntactic and
388 -- semantic, are documented. The one exception is in the case of entities
389 -- (defining identifiers, character literals and operator symbols), where
390 -- the usage of the fields depends on the entity kind. Entity fields are
391 -- fully documented in the separate package Einfo.
392
393 -- In the node definitions, three common sets of fields are abbreviated to
394 -- save both space in the documentation, and also space in the string
395 -- (defined in Tree_Print_Strings) used to print trees. The following
396 -- abbreviations are used:
397
398 -- Note: the utility program that creates the Treeprs spec (in the file
399 -- xtreeprs.adb) knows about the special fields here, so it must be
400 -- modified if any change is made to these fields.
401
402 -- "plus fields for binary operator"
403 -- Chars (Name1) Name_Id for the operator
404 -- Left_Opnd (Node2) left operand expression
405 -- Right_Opnd (Node3) right operand expression
406 -- Entity (Node4-Sem) defining entity for operator
407 -- Associated_Node (Node4-Sem) for generic processing
408 -- Do_Overflow_Check (Flag17-Sem) set if overflow check needed
409 -- Has_Private_View (Flag11-Sem) set in generic units.
410
411 -- "plus fields for unary operator"
412 -- Chars (Name1) Name_Id for the operator
413 -- Right_Opnd (Node3) right operand expression
414 -- Entity (Node4-Sem) defining entity for operator
415 -- Associated_Node (Node4-Sem) for generic processing
416 -- Do_Overflow_Check (Flag17-Sem) set if overflow check needed
417 -- Has_Private_View (Flag11-Sem) set in generic units.
418
419 -- "plus fields for expression"
420 -- Paren_Count number of parentheses levels
421 -- Etype (Node5-Sem) type of the expression
422 -- Is_Overloaded (Flag5-Sem) >1 type interpretation exists
423 -- Is_Static_Expression (Flag6-Sem) set for static expression
424 -- Raises_Constraint_Error (Flag7-Sem) evaluation raises CE
425 -- Must_Not_Freeze (Flag8-Sem) set if must not freeze
426 -- Do_Range_Check (Flag9-Sem) set if a range check needed
427 -- Assignment_OK (Flag15-Sem) set if modification is OK
428 -- Is_Controlling_Actual (Flag16-Sem) set for controlling argument
429
430 -- Note: see under (EXPRESSION) for further details on the use of
431 -- the Paren_Count field to record the number of parentheses levels.
432
433 -- Node_Kind is the type used in the Nkind field to indicate the node kind.
434 -- The actual definition of this type is given later (the reason for this
435 -- is that we want the descriptions ordered by logical chapter in the RM,
436 -- but the type definition is reordered to facilitate the definition of
437 -- some subtype ranges. The individual descriptions of the nodes show how
438 -- the various fields are used in each node kind, as well as providing
439 -- logical names for the fields. Functions and procedures are provided for
440 -- accessing and setting these fields using these logical names.
441
442 -----------------------
443 -- Gigi Restrictions --
444 -----------------------
445
446 -- The tree passed to Gigi is more restricted than the general tree form.
447 -- For example, as a result of expansion, most of the tasking nodes can
448 -- never appear. For each node to which either a complete or partial
449 -- restriction applies, a note entitled "Gigi restriction" appears which
450 -- documents the restriction.
451
452 -- Note that most of these restrictions apply only to trees generated when
453 -- code is being generated, since they involved expander actions that
454 -- destroy the tree.
455
456 ------------------------
457 -- Common Flag Fields --
458 ------------------------
459
460 -- The following flag fields appear in all nodes
461
462 -- Analyzed
463 -- This flag is used to indicate that a node (and all its children have
464 -- been analyzed. It is used to avoid reanalysis of a node that has
465 -- already been analyzed, both for efficiency and functional correctness
466 -- reasons.
467
468 -- Comes_From_Source
469 -- This flag is set if the node comes directly from an explicit construct
470 -- in the source. It is normally on for any nodes built by the scanner or
471 -- parser from the source program, with the exception that in a few cases
472 -- the parser adds nodes to normalize the representation (in particular
473 -- a null statement is added to a package body if there is no begin/end
474 -- initialization section.
475 --
476 -- Most nodes inserted by the analyzer or expander are not considered
477 -- as coming from source, so the flag is off for such nodes. In a few
478 -- cases, the expander constructs nodes closely equivalent to nodes
479 -- from the source program (e.g. the allocator built for build-in-place
480 -- case), and the Comes_From_Source flag is deliberately set.
481
482 -- Error_Posted
483 -- This flag is used to avoid multiple error messages being posted on or
484 -- referring to the same node. This flag is set if an error message
485 -- refers to a node or is posted on its source location, and has the
486 -- effect of inhibiting further messages involving this same node.
487
488 -- Has_Dynamic_Length_Check (Flag10-Sem)
489 -- This flag is present on all nodes. It is set to indicate that one of
490 -- the routines in unit Checks has generated a length check action which
491 -- has been inserted at the flagged node. This is used to avoid the
492 -- generation of duplicate checks.
493
494 -- Has_Dynamic_Range_Check (Flag12-Sem)
495 -- This flag is present on all nodes. It is set to indicate that one of
496 -- the routines in unit Checks has generated a range check action which
497 -- has been inserted at the flagged node. This is used to avoid the
498 -- generation of duplicate checks.
499
500 -- Has_Local_Raise (Flag8-Sem)
501 -- Present in exception handler nodes. Set if the handler can be entered
502 -- via a local raise that gets transformed to a goto statement. This will
503 -- always be set if Local_Raise_Statements is non-empty, but can also be
504 -- set as a result of generation of N_Raise_xxx nodes, or flags set in
505 -- nodes requiring generation of back end checks.
506
507 ------------------------------------
508 -- Description of Semantic Fields --
509 ------------------------------------
510
511 -- The meaning of the syntactic fields is generally clear from their names
512 -- without any further description, since the names are chosen to
513 -- correspond very closely to the syntax in the reference manual. This
514 -- section describes the usage of the semantic fields, which are used to
515 -- contain additional information determined during semantic analysis.
516
517 -- ABE_Is_Certain (Flag18-Sem)
518 -- This flag is set in an instantiation node or a call node is determined
519 -- to be sure to raise an ABE. This is used to trigger special handling
520 -- of such cases, particularly in the instantiation case where we avoid
521 -- instantiating the body if this flag is set. This flag is also present
522 -- in an N_Formal_Package_Declaration_Node since formal package
523 -- declarations are treated like instantiations, but it is always set to
524 -- False in this context.
525
526 -- Accept_Handler_Records (List5-Sem)
527 -- This field is present only in an N_Accept_Alternative node. It is used
528 -- to temporarily hold the exception handler records from an accept
529 -- statement in a selective accept. These exception handlers will
530 -- eventually be placed in the Handler_Records list of the procedure
531 -- built for this accept (see Expand_N_Selective_Accept procedure in
532 -- Exp_Ch9 for further details).
533
534 -- Access_Types_To_Process (Elist2-Sem)
535 -- Present in N_Freeze_Entity nodes for Incomplete or private types.
536 -- Contains the list of access types which may require specific treatment
537 -- when the nature of the type completion is completely known. An example
538 -- of such treatment is the generation of the associated_final_chain.
539
540 -- Actions (List1-Sem)
541 -- This field contains a sequence of actions that are associated with the
542 -- node holding the field. See the individual node types for details of
543 -- how this field is used, as well as the description of the specific use
544 -- for a particular node type.
545
546 -- Activation_Chain_Entity (Node3-Sem)
547 -- This is used in tree nodes representing task activators (blocks,
548 -- subprogram bodies, package declarations, and task bodies). It is
549 -- initially Empty, and then gets set to point to the entity for the
550 -- declared Activation_Chain variable when the first task is declared.
551 -- When tasks are declared in the corresponding declarative region this
552 -- entity is located by name (its name is always _Chain) and the declared
553 -- tasks are added to the chain. Note that N_Extended_Return_Statement
554 -- does not have this attribute, although it does have an activation
555 -- chain. This chain is used to store the tasks temporarily, and is not
556 -- used for activating them. On successful completion of the return
557 -- statement, the tasks are moved to the caller's chain, and the caller
558 -- activates them.
559
560 -- Acts_As_Spec (Flag4-Sem)
561 -- A flag set in the N_Subprogram_Body node for a subprogram body which
562 -- is acting as its own spec, except in the case of a library level
563 -- subprogram, in which case the flag is set on the parent compilation
564 -- unit node instead (see further description in spec of Lib package).
565 -- ??? Above note about Lib is dubious since lib.ads does not mention
566 -- Acts_As_Spec at all.
567
568 -- Actual_Designated_Subtype (Node4-Sem)
569 -- Present in N_Free_Statement and N_Explicit_Dereference nodes. If gigi
570 -- needs to known the dynamic constrained subtype of the designated
571 -- object, this attribute is set to that type. This is done for
572 -- N_Free_Statements for access-to-classwide types and access to
573 -- unconstrained packed array types, and for N_Explicit_Dereference when
574 -- the designated type is an unconstrained packed array and the
575 -- dereference is the prefix of a 'Size attribute reference.
576
577 -- Address_Warning_Posted (Flag18-Sem)
578 -- Present in N_Attribute_Definition nodes. Set to indicate that we have
579 -- posted a warning for the address clause regarding size or alignment
580 -- issues. Used to inhibit multiple redundant messages.
581
582 -- Aggregate_Bounds (Node3-Sem)
583 -- Present in array N_Aggregate nodes. If the bounds of the aggregate are
584 -- known at compile time, this field points to an N_Range node with those
585 -- bounds. Otherwise Empty.
586
587 -- All_Others (Flag11-Sem)
588 -- Present in an N_Others_Choice node. This flag is set for an others
589 -- exception where all exceptions are to be caught, even those that are
590 -- not normally handled (in particular the tasking abort signal). This
591 -- is used for translation of the at end handler into a normal exception
592 -- handler.
593
594 -- Aspect_Cancel (Flag11-Sem)
595 -- Processing of aspect specifications typically generates pragmas and
596 -- attribute definition clauses that are inserted into the tree after
597 -- the declaration node to get the desired aspect effect. In the case
598 -- of Boolean aspects that use "=> False" to cancel the effect of an
599 -- aspect (i.e. turn if off), the generated pragma has the Aspect_Cancel
600 -- flag set to indicate that the pragma operates in the opposite sense.
601
602 -- Aspect_Rep_Item (Node2-Sem)
603 -- Present in N_Aspect_Specification nodes. Points to the corresponding
604 -- pragma/attribute definition node used to process the aspect.
605
606 -- Assignment_OK (Flag15-Sem)
607 -- This flag is set in a subexpression node for an object, indicating
608 -- that the associated object can be modified, even if this would not
609 -- normally be permissible (either by direct assignment, or by being
610 -- passed as an out or in-out parameter). This is used by the expander
611 -- for a number of purposes, including initialization of constants and
612 -- limited type objects (such as tasks), setting discriminant fields,
613 -- setting tag values, etc. N_Object_Declaration nodes also have this
614 -- flag defined. Here it is used to indicate that an initialization
615 -- expression is valid, even where it would normally not be allowed
616 -- (e.g. where the type involved is limited).
617
618 -- Associated_Node (Node4-Sem)
619 -- Present in nodes that can denote an entity: identifiers, character
620 -- literals, operator symbols, expanded names, operator nodes, and
621 -- attribute reference nodes (all these nodes have an Entity field).
622 -- This field is also present in N_Aggregate, N_Selected_Component, and
623 -- N_Extension_Aggregate nodes. This field is used in generic processing
624 -- to create links between the generic template and the generic copy.
625 -- See Sem_Ch12.Get_Associated_Node for full details. Note that this
626 -- field overlaps Entity, which is fine, since, as explained in Sem_Ch12,
627 -- the normal function of Entity is not required at the point where the
628 -- Associated_Node is set. Note also, that in generic templates, this
629 -- means that the Entity field does not necessarily point to an Entity.
630 -- Since the back end is expected to ignore generic templates, this is
631 -- harmless.
632
633 -- At_End_Proc (Node1)
634 -- This field is present in an N_Handled_Sequence_Of_Statements node.
635 -- It contains an identifier reference for the cleanup procedure to be
636 -- called. See description of this node for further details.
637
638 -- Backwards_OK (Flag6-Sem)
639 -- A flag present in the N_Assignment_Statement node. It is used only
640 -- if the type being assigned is an array type, and is set if analysis
641 -- determines that it is definitely safe to do the copy backwards, i.e.
642 -- starting at the highest addressed element. This is the case if either
643 -- the operands do not overlap, or they may overlap, but if they do,
644 -- then the left operand is at a higher address than the right operand.
645 --
646 -- Note: If neither of the flags Forwards_OK or Backwards_OK is set, it
647 -- means that the front end could not determine that either direction is
648 -- definitely safe, and a runtime check may be required if the backend
649 -- cannot figure it out. If both flags Forwards_OK and Backwards_OK are
650 -- set, it means that the front end can assure no overlap of operands.
651
652 -- Body_To_Inline (Node3-Sem)
653 -- present in subprogram declarations. Denotes analyzed but unexpanded
654 -- body of subprogram, to be used when inlining calls. Present when the
655 -- subprogram has an Inline pragma and inlining is enabled. If the
656 -- declaration is completed by a renaming_as_body, and the renamed en-
657 -- tity is a subprogram, the Body_To_Inline is the name of that entity,
658 -- which is used directly in later calls to the original subprogram.
659
660 -- Body_Required (Flag13-Sem)
661 -- A flag that appears in the N_Compilation_Unit node indicating that
662 -- the corresponding unit requires a body. For the package case, this
663 -- indicates that a completion is required. In Ada 95, if the flag is not
664 -- set for the package case, then a body may not be present. In Ada 83,
665 -- if the flag is not set for the package case, then body is optional.
666 -- For a subprogram declaration, the flag is set except in the case where
667 -- a pragma Import or Interface applies, in which case no body is
668 -- permitted (in Ada 83 or Ada 95).
669
670 -- By_Ref (Flag5-Sem)
671 -- Present in N_Simple_Return_Statement and N_Extended_Return_Statement,
672 -- this flag is set when the returned expression is already allocated on
673 -- the secondary stack and thus the result is passed by reference rather
674 -- than copied another time.
675
676 -- Check_Address_Alignment (Flag11-Sem)
677 -- A flag present in N_Attribute_Definition clause for a 'Address
678 -- attribute definition. This flag is set if a dynamic check should be
679 -- generated at the freeze point for the entity to which this address
680 -- clause applies. The reason that we need this flag is that we want to
681 -- check for range checks being suppressed at the point where the
682 -- attribute definition clause is given, rather than testing this at the
683 -- freeze point.
684
685 -- Coextensions (Elist4-Sem)
686 -- Present in allocators nodes. Points to list of allocators for the
687 -- access discriminants of the allocated object.
688
689 -- Comes_From_Extended_Return_Statement (Flag18-Sem)
690 -- Present in N_Simple_Return_Statement nodes. True if this node was
691 -- constructed as part of the N_Extended_Return_Statement expansion.
692
693 -- Compile_Time_Known_Aggregate (Flag18-Sem)
694 -- Present in N_Aggregate nodes. Set for aggregates which can be fully
695 -- evaluated at compile time without raising constraint error. Such
696 -- aggregates can be passed as is to Gigi without any expansion. See
697 -- Sem_Aggr for the specific conditions under which an aggregate has this
698 -- flag set. See also the flag Static_Processing_OK.
699
700 -- Componentwise_Assignment (Flag14-Sem)
701 -- Present in N_Assignment_Statement nodes. Set for a record assignment
702 -- where all that needs doing is to expand it into component-by-component
703 -- assignments. This is used internally for the case of tagged types with
704 -- rep clauses, where we need to avoid recursion (we don't want to try to
705 -- generate a call to the primitive operation, because this is the case
706 -- where we are compiling the primitive operation). Note that when we are
707 -- expanding component assignments in this case, we never assign the _tag
708 -- field, but we recursively assign components of the parent type.
709
710 -- Condition_Actions (List3-Sem)
711 -- This field appears in else-if nodes and in the iteration scheme node
712 -- for while loops. This field is only used during semantic processing to
713 -- temporarily hold actions inserted into the tree. In the tree passed
714 -- to gigi, the condition actions field is always set to No_List. For
715 -- details on how this field is used, see the routine Insert_Actions in
716 -- package Exp_Util, and also the expansion routines for the relevant
717 -- nodes.
718
719 -- Context_Pending (Flag16-Sem)
720 -- This field appears in Compilation_Unit nodes, to indicate that the
721 -- context of the unit is being compiled. Used to detect circularities
722 -- that are not otherwise detected by the loading mechanism. Such
723 -- circularities can occur in the presence of limited and non-limited
724 -- with_clauses that mention the same units.
725
726 -- Controlling_Argument (Node1-Sem)
727 -- This field is set in procedure and function call nodes if the call
728 -- is a dispatching call (it is Empty for a non-dispatching call). It
729 -- indicates the source of the call's controlling tag. For procedure
730 -- calls, the Controlling_Argument is one of the actuals. For function
731 -- that has a dispatching result, it is an entity in the context of the
732 -- call that can provide a tag, or else it is the tag of the root type
733 -- of the class. It can also specify a tag directly rather than being a
734 -- tagged object. The latter is needed by the implementations of AI-239
735 -- and AI-260.
736
737 -- Conversion_OK (Flag14-Sem)
738 -- A flag set on type conversion nodes to indicate that the conversion
739 -- is to be considered as being valid, even though it is the case that
740 -- the conversion is not valid Ada. This is used for attributes Enum_Rep,
741 -- Fixed_Value and Integer_Value, for internal conversions done for
742 -- fixed-point operations, and for certain conversions for calls to
743 -- initialization procedures. If Conversion_OK is set, then Etype must be
744 -- set (the analyzer assumes that Etype has been set). For the case of
745 -- fixed-point operands, it also indicates that the conversion is to be
746 -- direct conversion of the underlying integer result, with no regard to
747 -- the small operand.
748
749 -- Corresponding_Body (Node5-Sem)
750 -- This field is set in subprogram declarations, package declarations,
751 -- entry declarations of protected types, and in generic units. It
752 -- points to the defining entity for the corresponding body (NOT the
753 -- node for the body itself).
754
755 -- Corresponding_Formal_Spec (Node3-Sem)
756 -- This field is set in subprogram renaming declarations, where it points
757 -- to the defining entity for a formal subprogram in the case where the
758 -- renaming corresponds to a generic formal subprogram association in an
759 -- instantiation. The field is Empty if the renaming does not correspond
760 -- to such a formal association.
761
762 -- Corresponding_Generic_Association (Node5-Sem)
763 -- This field is defined for object declarations and object renaming
764 -- declarations. It is set for the declarations within an instance that
765 -- map generic formals to their actuals. If set, the field points to
766 -- a generic_association which is the original parent of the expression
767 -- or name appearing in the declaration. This simplifies ASIS queries.
768
769 -- Corresponding_Integer_Value (Uint4-Sem)
770 -- This field is set in real literals of fixed-point types (it is not
771 -- used for floating-point types). It contains the integer value used
772 -- to represent the fixed-point value. It is also set on the universal
773 -- real literals used to represent bounds of fixed-point base types
774 -- and their first named subtypes.
775
776 -- Corresponding_Spec (Node5-Sem)
777 -- This field is set in subprogram, package, task, and protected body
778 -- nodes, where it points to the defining entity in the corresponding
779 -- spec. The attribute is also set in N_With_Clause nodes where it points
780 -- to the defining entity for the with'ed spec, and in a subprogram
781 -- renaming declaration when it is a Renaming_As_Body. The field is Empty
782 -- if there is no corresponding spec, as in the case of a subprogram body
783 -- that serves as its own spec.
784
785 -- Corresponding_Stub (Node3-Sem)
786 -- This field is present in an N_Subunit node. It holds the node in
787 -- the parent unit that is the stub declaration for the subunit. It is
788 -- set when analysis of the stub forces loading of the proper body. If
789 -- expansion of the proper body creates new declarative nodes, they are
790 -- inserted at the point of the corresponding_stub.
791
792 -- Dcheck_Function (Node5-Sem)
793 -- This field is present in an N_Variant node, It references the entity
794 -- for the discriminant checking function for the variant.
795
796 -- Debug_Statement (Node3)
797 -- This field is present in an N_Pragma node. It is used only for a Debug
798 -- pragma. The parameter is of the form of an expression, as required by
799 -- the pragma syntax, but is actually a procedure call. To simplify
800 -- semantic processing, the parser creates a copy of the argument
801 -- rearranged into a procedure call statement and places it in the
802 -- Debug_Statement field. Note that this field is considered syntactic
803 -- field, since it is created by the parser.
804
805 -- Default_Expression (Node5-Sem)
806 -- This field is Empty if there is no default expression. If there is a
807 -- simple default expression (one with no side effects), then this field
808 -- simply contains a copy of the Expression field (both point to the tree
809 -- for the default expression). Default_Expression is used for
810 -- conformance checking.
811
812 -- Default_Storage_Pool (Node3-Sem)
813 -- This field is present in N_Compilation_Unit_Aux nodes. It is set to a
814 -- copy of Opt.Default_Pool at the end of the compilation unit. See
815 -- package Opt for details. This is used for inheriting the
816 -- Default_Storage_Pool in child units.
817
818 -- Discr_Check_Funcs_Built (Flag11-Sem)
819 -- This flag is present in N_Full_Type_Declaration nodes. It is set when
820 -- discriminant checking functions are constructed. The purpose is to
821 -- avoid attempting to set these functions more than once.
822
823 -- Do_Accessibility_Check (Flag13-Sem)
824 -- This flag is set on N_Parameter_Specification nodes to indicate
825 -- that an accessibility check is required for the parameter. It is
826 -- not yet decided who takes care of this check (TBD ???).
827
828 -- Do_Discriminant_Check (Flag13-Sem)
829 -- This flag is set on N_Selected_Component nodes to indicate that a
830 -- discriminant check is required using the discriminant check routine
831 -- associated with the selector. The actual check is generated by the
832 -- expander when processing selected components.
833
834 -- Do_Division_Check (Flag13-Sem)
835 -- This flag is set on a division operator (/ mod rem) to indicate
836 -- that a zero divide check is required. The actual check is dealt
837 -- with by the backend (all the front end does is to set the flag).
838
839 -- Do_Length_Check (Flag4-Sem)
840 -- This flag is set in an N_Assignment_Statement, N_Op_And, N_Op_Or,
841 -- N_Op_Xor, or N_Type_Conversion node to indicate that a length check
842 -- is required. It is not determined who deals with this flag (???).
843
844 -- Do_Overflow_Check (Flag17-Sem)
845 -- This flag is set on an operator where an overflow check is required on
846 -- the operation. The actual check is dealt with by the backend (all the
847 -- front end does is to set the flag). The other cases where this flag is
848 -- used is on a Type_Conversion node and for attribute reference nodes.
849 -- For a type conversion, it means that the conversion is from one base
850 -- type to another, and the value may not fit in the target base type.
851 -- See also the description of Do_Range_Check for this case. The only
852 -- attribute references which use this flag are Pred and Succ, where it
853 -- means that the result should be checked for going outside the base
854 -- range. Note that this flag is not set for modular types.
855
856 -- Do_Range_Check (Flag9-Sem)
857 -- This flag is set on an expression which appears in a context where a
858 -- range check is required. The target type is clear from the context.
859 -- The contexts in which this flag can appear are the following:
860
861 -- Right side of an assignment. In this case the target type is
862 -- taken from the left side of the assignment, which is referenced
863 -- by the Name of the N_Assignment_Statement node.
864
865 -- Subscript expressions in an indexed component. In this case the
866 -- target type is determined from the type of the array, which is
867 -- referenced by the Prefix of the N_Indexed_Component node.
868
869 -- Argument expression for a parameter, appearing either directly in
870 -- the Parameter_Associations list of a call or as the Expression of an
871 -- N_Parameter_Association node that appears in this list. In either
872 -- case, the check is against the type of the formal. Note that the
873 -- flag is relevant only in IN and IN OUT parameters, and will be
874 -- ignored for OUT parameters, where no check is required in the call,
875 -- and if a check is required on the return, it is generated explicitly
876 -- with a type conversion.
877
878 -- Initialization expression for the initial value in an object
879 -- declaration. In this case the Do_Range_Check flag is set on
880 -- the initialization expression, and the check is against the
881 -- range of the type of the object being declared.
882
883 -- The expression of a type conversion. In this case the range check is
884 -- against the target type of the conversion. See also the use of
885 -- Do_Overflow_Check on a type conversion. The distinction is that the
886 -- overflow check protects against a value that is outside the range of
887 -- the target base type, whereas a range check checks that the
888 -- resulting value (which is a value of the base type of the target
889 -- type), satisfies the range constraint of the target type.
890
891 -- Note: when a range check is required in contexts other than those
892 -- listed above (e.g. in a return statement), an additional type
893 -- conversion node is introduced to represent the required check.
894
895 -- Do_Storage_Check (Flag17-Sem)
896 -- This flag is set in an N_Allocator node to indicate that a storage
897 -- check is required for the allocation, or in an N_Subprogram_Body node
898 -- to indicate that a stack check is required in the subprogram prolog.
899 -- The N_Allocator case is handled by the routine that expands the call
900 -- to the runtime routine. The N_Subprogram_Body case is handled by the
901 -- backend, and all the semantics does is set the flag.
902
903 -- Do_Tag_Check (Flag13-Sem)
904 -- This flag is set on an N_Assignment_Statement, N_Function_Call,
905 -- N_Procedure_Call_Statement, N_Type_Conversion,
906 -- N_Simple_Return_Statement, or N_Extended_Return_Statement
907 -- node to indicate that the tag check can be suppressed. It is not
908 -- yet decided how this flag is used (TBD ???).
909
910 -- Elaborate_Present (Flag4-Sem)
911 -- This flag is set in the N_With_Clause node to indicate that pragma
912 -- Elaborate pragma appears for the with'ed units.
913
914 -- Elaborate_All_Desirable (Flag9-Sem)
915 -- This flag is set in the N_With_Clause mode to indicate that the static
916 -- elaboration processing has determined that an Elaborate_All pragma is
917 -- desirable for correct elaboration for this unit.
918
919 -- Elaborate_All_Present (Flag14-Sem)
920 -- This flag is set in the N_With_Clause node to indicate that a
921 -- pragma Elaborate_All pragma appears for the with'ed units.
922
923 -- Elaborate_Desirable (Flag11-Sem)
924 -- This flag is set in the N_With_Clause mode to indicate that the static
925 -- elaboration processing has determined that an Elaborate pragma is
926 -- desirable for correct elaboration for this unit.
927
928 -- Elaboration_Boolean (Node2-Sem)
929 -- This field is present in function and procedure specification nodes.
930 -- If set, it points to the entity for a Boolean flag that must be tested
931 -- for certain calls to check for access before elaboration. See body of
932 -- Sem_Elab for further details. This field is Empty if no elaboration
933 -- boolean is required.
934
935 -- Else_Actions (List3-Sem)
936 -- This field is present in conditional expression nodes. During code
937 -- expansion we use the Insert_Actions procedure (in Exp_Util) to insert
938 -- actions at an appropriate place in the tree to get elaborated at the
939 -- right time. For conditional expressions, we have to be sure that the
940 -- actions for the Else branch are only elaborated if the condition is
941 -- False. The Else_Actions field is used as a temporary parking place for
942 -- these actions. The final tree is always rewritten to eliminate the
943 -- need for this field, so in the tree passed to Gigi, this field is
944 -- always set to No_List.
945
946 -- Enclosing_Variant (Node2-Sem)
947 -- This field is present in the N_Variant node and identifies the Node_Id
948 -- corresponding to the immediately enclosing variant when the variant is
949 -- nested, and N_Empty otherwise. Set during semantic processing of the
950 -- variant part of a record type.
951
952 -- Entity (Node4-Sem)
953 -- Appears in all direct names (identifiers, character literals, and
954 -- operator symbols), as well as expanded names, and attributes that
955 -- denote entities, such as 'Class. Points to entity for corresponding
956 -- defining occurrence. Set after name resolution. For identifiers in a
957 -- WITH list, the corresponding defining occurrence is in a separately
958 -- compiled file, and Entity must be set by the library Load procedure.
959 --
960 -- Note: During name resolution, the value in Entity may be temporarily
961 -- incorrect (e.g. during overload resolution, Entity is initially set to
962 -- the first possible correct interpretation, and then later modified if
963 -- necessary to contain the correct value after resolution).
964 --
965 -- Note: This field overlaps Associated_Node, which is used during
966 -- generic processing (see Sem_Ch12 for details). Note also that in
967 -- generic templates, this means that the Entity field does not always
968 -- point to an Entity. Since the back end is expected to ignore generic
969 -- templates, this is harmless.
970 --
971 -- Note: This field also appears in N_Attribute_Definition_Clause nodes.
972 -- It is used only for stream attributes definition clauses. In this
973 -- case, it denotes a (possibly dummy) subprogram entity that is declared
974 -- conceptually at the point of the clause. Thus the visibility of the
975 -- attribute definition clause (in the sense of 8.3(23) as amended by
976 -- AI-195) can be checked by testing the visibility of that subprogram.
977 --
978 -- Note: Normally the Entity field of an identifier points to the entity
979 -- for the corresponding defining identifier, and hence the Chars field
980 -- of an identifier will match the Chars field of the entity. However,
981 -- there is no requirement that these match, and there are obscure cases
982 -- of generated code where they do not match.
983
984 -- Entity_Or_Associated_Node (Node4-Sem)
985 -- A synonym for both Entity and Associated_Node. Used by convention in
986 -- the code when referencing this field in cases where it is not known
987 -- whether the field contains an Entity or an Associated_Node.
988
989 -- Etype (Node5-Sem)
990 -- Appears in all expression nodes, all direct names, and all entities.
991 -- Points to the entity for the related type. Set after type resolution.
992 -- Normally this is the actual subtype of the expression. However, in
993 -- certain contexts such as the right side of an assignment, subscripts,
994 -- arguments to calls, returned value in a function, initial value etc.
995 -- it is the desired target type. In the event that this is different
996 -- from the actual type, the Do_Range_Check flag will be set if a range
997 -- check is required. Note: if the Is_Overloaded flag is set, then Etype
998 -- points to an essentially arbitrary choice from the possible set of
999 -- types.
1000
1001 -- Exception_Junk (Flag8-Sem)
1002 -- This flag is set in a various nodes appearing in a statement sequence
1003 -- to indicate that the corresponding node is an artifact of the
1004 -- generated code for exception handling, and should be ignored when
1005 -- analyzing the control flow of the relevant sequence of statements
1006 -- (e.g. to check that it does not end with a bad return statement).
1007
1008 -- Exception_Label (Node5-Sem)
1009 -- Appears in N_Push_xxx_Label nodes. Points to the entity of the label
1010 -- to be used for transforming the corresponding exception into a goto,
1011 -- or contains Empty, if this exception is not to be transformed. Also
1012 -- appears in N_Exception_Handler nodes, where, if set, it indicates
1013 -- that there may be a local raise for the handler, so that expansion
1014 -- to allow a goto is required (and this field contains the label for
1015 -- this goto). See Exp_Ch11.Expand_Local_Exception_Handlers for details.
1016
1017 -- Expansion_Delayed (Flag11-Sem)
1018 -- Set on aggregates and extension aggregates that need a top-down rather
1019 -- than bottom-up expansion. Typically aggregate expansion happens bottom
1020 -- up. For nested aggregates the expansion is delayed until the enclosing
1021 -- aggregate itself is expanded, e.g. in the context of a declaration. To
1022 -- delay it we set this flag. This is done to avoid creating a temporary
1023 -- for each level of a nested aggregates, and also to prevent the
1024 -- premature generation of constraint checks. This is also a requirement
1025 -- if we want to generate the proper attachment to the internal
1026 -- finalization lists (for record with controlled components). Top down
1027 -- expansion of aggregates is also used for in-place array aggregate
1028 -- assignment or initialization. When the full context is known, the
1029 -- target of the assignment or initialization is used to generate the
1030 -- left-hand side of individual assignment to each sub-component.
1031
1032 -- First_Inlined_Subprogram (Node3-Sem)
1033 -- Present in the N_Compilation_Unit node for the main program. Points
1034 -- to a chain of entities for subprograms that are to be inlined. The
1035 -- Next_Inlined_Subprogram field of these entities is used as a link
1036 -- pointer with Empty marking the end of the list. This field is Empty
1037 -- if there are no inlined subprograms or inlining is not active.
1038
1039 -- First_Named_Actual (Node4-Sem)
1040 -- Present in procedure call statement and function call nodes, and also
1041 -- in Intrinsic nodes. Set during semantic analysis to point to the first
1042 -- named parameter where parameters are ordered by declaration order (as
1043 -- opposed to the actual order in the call which may be different due to
1044 -- named associations). Note: this field points to the explicit actual
1045 -- parameter itself, not the N_Parameter_Association node (its parent).
1046
1047 -- First_Real_Statement (Node2-Sem)
1048 -- Present in N_Handled_Sequence_Of_Statements node. Normally set to
1049 -- Empty. Used only when declarations are moved into the statement part
1050 -- of a construct as a result of wrapping an AT END handler that is
1051 -- required to cover the declarations. In this case, this field is used
1052 -- to remember the location in the statements list of the first real
1053 -- statement, i.e. the statement that used to be first in the statement
1054 -- list before the declarations were prepended.
1055
1056 -- First_Subtype_Link (Node5-Sem)
1057 -- Present in N_Freeze_Entity node for an anonymous base type that is
1058 -- implicitly created by the declaration of a first subtype. It points
1059 -- to the entity for the first subtype.
1060
1061 -- Float_Truncate (Flag11-Sem)
1062 -- A flag present in type conversion nodes. This is used for float to
1063 -- integer conversions where truncation is required rather than rounding.
1064 -- Note that Gigi does not handle type conversions from real to integer
1065 -- with rounding (see Expand_N_Type_Conversion).
1066
1067 -- Forwards_OK (Flag5-Sem)
1068 -- A flag present in the N_Assignment_Statement node. It is used only
1069 -- if the type being assigned is an array type, and is set if analysis
1070 -- determines that it is definitely safe to do the copy forwards, i.e.
1071 -- starting at the lowest addressed element. This is the case if either
1072 -- the operands do not overlap, or they may overlap, but if they do,
1073 -- then the left operand is at a lower address than the right operand.
1074 --
1075 -- Note: If neither of the flags Forwards_OK or Backwards_OK is set, it
1076 -- means that the front end could not determine that either direction is
1077 -- definitely safe, and a runtime check may be required if the backend
1078 -- cannot figure it out. If both flags Forwards_OK and Backwards_OK are
1079 -- set, it means that the front end can assure no overlap of operands.
1080
1081 -- From_Aspect_Specification (Flag13-Sem)
1082 -- Processing of aspect specifications typically results in insertion in
1083 -- the tree of corresponding pragma or attribute definition clause nodes.
1084 -- These generated nodes have the From_Aspect_Specification flag set to
1085 -- indicate that they came from aspect specifications originally.
1086
1087 -- From_At_End (Flag4-Sem)
1088 -- This flag is set on an N_Raise_Statement node if it corresponds to
1089 -- the reraise statement generated as the last statement of an AT END
1090 -- handler when SJLJ exception handling is active. It is used to stop
1091 -- a bogus violation of restriction (No_Exception_Propagation), bogus
1092 -- because if the restriction is set, the reraise is not generated.
1093
1094 -- From_At_Mod (Flag4-Sem)
1095 -- This flag is set on the attribute definition clause node that is
1096 -- generated by a transformation of an at mod phrase in a record
1097 -- representation clause. This is used to give slightly different (Ada 83
1098 -- compatible) semantics to such a clause, namely it is used to specify a
1099 -- minimum acceptable alignment for the base type and all subtypes. In
1100 -- Ada 95 terms, the actual alignment of the base type and all subtypes
1101 -- must be a multiple of the given value, and the representation clause
1102 -- is considered to be type specific instead of subtype specific.
1103
1104 -- From_Default (Flag6-Sem)
1105 -- This flag is set on the subprogram renaming declaration created in an
1106 -- instance for a formal subprogram, when the formal is declared with a
1107 -- box, and there is no explicit actual. If the flag is present, the
1108 -- declaration is treated as an implicit reference to the formal in the
1109 -- ali file.
1110
1111 -- Generic_Parent (Node5-Sem)
1112 -- Generic_Parent is defined on declaration nodes that are instances. The
1113 -- value of Generic_Parent is the generic entity from which the instance
1114 -- is obtained. Generic_Parent is also defined for the renaming
1115 -- declarations and object declarations created for the actuals in an
1116 -- instantiation. The generic parent of such a declaration is the
1117 -- corresponding generic association in the Instantiation node.
1118
1119 -- Generic_Parent_Type (Node4-Sem)
1120 -- Generic_Parent_Type is defined on Subtype_Declaration nodes for the
1121 -- actuals of formal private and derived types. Within the instance, the
1122 -- operations on the actual are those inherited from the parent. For a
1123 -- formal private type, the parent type is the generic type itself. The
1124 -- Generic_Parent_Type is also used in an instance to determine whether a
1125 -- private operation overrides an inherited one.
1126
1127 -- Handler_List_Entry (Node2-Sem)
1128 -- This field is present in N_Object_Declaration nodes. It is set only
1129 -- for the Handler_Record entry generated for an exception in zero cost
1130 -- exception handling mode. It references the corresponding item in the
1131 -- handler list, and is used to delete this entry if the corresponding
1132 -- handler is deleted during optimization. For further details on why
1133 -- this is required, see Exp_Ch11.Remove_Handler_Entries.
1134
1135 -- Has_No_Elaboration_Code (Flag17-Sem)
1136 -- A flag that appears in the N_Compilation_Unit node to indicate whether
1137 -- or not elaboration code is present for this unit. It is initially set
1138 -- true for subprogram specs and bodies and for all generic units and
1139 -- false for non-generic package specs and bodies. Gigi may set the flag
1140 -- in the non-generic package case if it determines that no elaboration
1141 -- code is generated. Note that this flag is not related to the
1142 -- Is_Preelaborated status, there can be preelaborated packages that
1143 -- generate elaboration code, and non-preelaborated packages which do
1144 -- not generate elaboration code.
1145
1146 -- Has_Pragma_CPU (Flag14-Sem)
1147 -- A flag present in N_Subprogram_Body and N_Task_Definition nodes to
1148 -- flag the presence of a CPU pragma in the declaration sequence (public
1149 -- or private in the task case).
1150
1151 -- Has_Pragma_Suppress_All (Flag14-Sem)
1152 -- This flag is set in an N_Compilation_Unit node if the Suppress_All
1153 -- pragma appears anywhere in the unit. This accomodates the rather
1154 -- strange placement rules of other compilers (DEC permits it at the
1155 -- end of a unit, and Rational allows it as a program unit pragma). We
1156 -- allow it anywhere at all, and consider it equivalent to a pragma
1157 -- Suppress (All_Checks) appearing at the start of the configuration
1158 -- pragmas for the unit.
1159
1160 -- Has_Pragma_Priority (Flag6-Sem)
1161 -- A flag present in N_Subprogram_Body, N_Task_Definition and
1162 -- N_Protected_Definition nodes to flag the presence of either a Priority
1163 -- or Interrupt_Priority pragma in the declaration sequence (public or
1164 -- private in the task and protected cases)
1165
1166 -- Has_Private_View (Flag11-Sem)
1167 -- A flag present in generic nodes that have an entity, to indicate that
1168 -- the node has a private type. Used to exchange private and full
1169 -- declarations if the visibility at instantiation is different from the
1170 -- visibility at generic definition.
1171
1172 -- Has_Relative_Deadline_Pragma (Flag9-Sem)
1173 -- A flag present in N_Subprogram_Body and N_Task_Definition nodes to
1174 -- flag the presence of a pragma Relative_Deadline.
1175
1176 -- Has_Self_Reference (Flag13-Sem)
1177 -- Present in N_Aggregate and N_Extension_Aggregate. Indicates that one
1178 -- of the expressions contains an access attribute reference to the
1179 -- enclosing type. Such a self-reference can only appear in default-
1180 -- initialized aggregate for a record type.
1181
1182 -- Has_Storage_Size_Pragma (Flag5-Sem)
1183 -- A flag present in an N_Task_Definition node to flag the presence of a
1184 -- Storage_Size pragma.
1185
1186 -- Has_Task_Info_Pragma (Flag7-Sem)
1187 -- A flag present in an N_Task_Definition node to flag the presence of a
1188 -- Task_Info pragma. Used to detect duplicate pragmas.
1189
1190 -- Has_Task_Name_Pragma (Flag8-Sem)
1191 -- A flag present in N_Task_Definition nodes to flag the presence of a
1192 -- Task_Name pragma in the declaration sequence for the task.
1193
1194 -- Has_Wide_Character (Flag11-Sem)
1195 -- Present in string literals, set if any wide character (i.e. character
1196 -- code outside the Character range but within Wide_Character range)
1197 -- appears in the string. Used to implement pragma preference rules.
1198
1199 -- Has_Wide_Wide_Character (Flag13-Sem)
1200 -- Present in string literals, set if any wide character (i.e. character
1201 -- code outside the Wide_Character range) appears in the string. Used to
1202 -- implement pragma preference rules.
1203
1204 -- Hidden_By_Use_Clause (Elist4-Sem)
1205 -- An entity list present in use clauses that appear within
1206 -- instantiations. For the resolution of local entities, entities
1207 -- introduced by these use clauses have priority over global ones, and
1208 -- outer entities must be explicitly hidden/restored on exit.
1209
1210 -- Implicit_With (Flag16-Sem)
1211 -- This flag is set in the N_With_Clause node that is implicitly
1212 -- generated for runtime units that are loaded by the expander, and also
1213 -- for package System, if it is loaded implicitly by a use of the
1214 -- 'Address or 'Tag attribute. ???There are other implicit with clauses
1215 -- as well.
1216
1217 -- Import_Interface_Present (Flag16-Sem)
1218 -- This flag is set in an Interface or Import pragma if a matching
1219 -- pragma of the other kind is also present. This is used to avoid
1220 -- generating some unwanted error messages.
1221
1222 -- Includes_Infinities (Flag11-Sem)
1223 -- This flag is present in N_Range nodes. It is set for the range of
1224 -- unconstrained float types defined in Standard, which include not only
1225 -- the given range of values, but also legitimately can include infinite
1226 -- values. This flag is false for any float type for which an explicit
1227 -- range is given by the programmer, even if that range is identical to
1228 -- the range for Float.
1229
1230 -- Inherited_Discriminant (Flag13-Sem)
1231 -- This flag is present in N_Component_Association nodes. It indicates
1232 -- that a given component association in an extension aggregate is the
1233 -- value obtained from a constraint on an ancestor. Used to prevent
1234 -- double expansion when the aggregate has expansion delayed.
1235
1236 -- Instance_Spec (Node5-Sem)
1237 -- This field is present in generic instantiation nodes, and also in
1238 -- formal package declaration nodes (formal package declarations are
1239 -- treated in a manner very similar to package instantiations). It points
1240 -- to the node for the spec of the instance, inserted as part of the
1241 -- semantic processing for instantiations in Sem_Ch12.
1242
1243 -- Is_Accessibility_Actual (Flag12-Sem)
1244 -- Present in N_Parameter_Association nodes. True if the parameter is
1245 -- an extra actual that carries the accessibility level of the actual
1246 -- for an access parameter, in a function that dispatches on result and
1247 -- is called in a dispatching context. Used to prevent a formal/actual
1248 -- mismatch when the call is rewritten as a dispatching call.
1249
1250 -- Is_Asynchronous_Call_Block (Flag7-Sem)
1251 -- A flag set in a Block_Statement node to indicate that it is the
1252 -- expansion of an asynchronous entry call. Such a block needs cleanup
1253 -- handler to assure that the call is cancelled.
1254
1255 -- Is_Component_Left_Opnd (Flag13-Sem)
1256 -- Is_Component_Right_Opnd (Flag14-Sem)
1257 -- Present in concatenation nodes, to indicate that the corresponding
1258 -- operand is of the component type of the result. Used in resolving
1259 -- concatenation nodes in instances.
1260
1261 -- Is_Delayed_Aspect (Flag14-Sem)
1262 -- Present in N_Pragma and N_Attribute_Definition_Clause nodes which
1263 -- come from aspect specifications, where the evaluation of the aspect
1264 -- must be delayed to the freeze point.
1265
1266 -- Is_Controlling_Actual (Flag16-Sem)
1267 -- This flag is set on in an expression that is a controlling argument in
1268 -- a dispatching call. It is off in all other cases. See Sem_Disp for
1269 -- details of its use.
1270
1271 -- Is_Dynamic_Coextension (Flag18-Sem)
1272 -- Present in allocator nodes, to indicate that this is an allocator
1273 -- for an access discriminant of a dynamically allocated object. The
1274 -- coextension must be deallocated and finalized at the same time as
1275 -- the enclosing object.
1276
1277 -- Is_Entry_Barrier_Function (Flag8-Sem)
1278 -- This flag is set in an N_Subprogram_Body node which is the expansion
1279 -- of an entry barrier from a protected entry body. It is used for the
1280 -- circuitry checking for incorrect use of Current_Task.
1281
1282 -- Is_Expanded_Build_In_Place_Call (Flag11-Sem)
1283 -- This flag is set in an N_Function_Call node to indicate that the extra
1284 -- actuals to support a build-in-place style of call have been added to
1285 -- the call.
1286
1287 -- Is_In_Discriminant_Check (Flag11-Sem)
1288 -- This flag is present in a selected component, and is used to indicate
1289 -- that the reference occurs within a discriminant check. The
1290 -- significance is that optimizations based on assuming that the
1291 -- discriminant check has a correct value cannot be performed in this
1292 -- case (or the discriminant check may be optimized away!)
1293
1294 -- Is_Machine_Number (Flag11-Sem)
1295 -- This flag is set in an N_Real_Literal node to indicate that the value
1296 -- is a machine number. This avoids some unnecessary cases of converting
1297 -- real literals to machine numbers.
1298
1299 -- Is_Null_Loop (Flag16-Sem)
1300 -- This flag is set in an N_Loop_Statement node if the corresponding loop
1301 -- can be determined to be null at compile time. This is used to remove
1302 -- the loop entirely at expansion time.
1303
1304 -- Is_Overloaded (Flag5-Sem)
1305 -- A flag present in all expression nodes. Used temporarily during
1306 -- overloading determination. The setting of this flag is not relevant
1307 -- once overloading analysis is complete.
1308
1309 -- Is_Power_Of_2_For_Shift (Flag13-Sem)
1310 -- A flag present only in N_Op_Expon nodes. It is set when the
1311 -- exponentiation is of the form 2 ** N, where the type of N is an
1312 -- unsigned integral subtype whose size does not exceed the size of
1313 -- Standard_Integer (i.e. a type that can be safely converted to
1314 -- Natural), and the exponentiation appears as the right operand of an
1315 -- integer multiplication or an integer division where the dividend is
1316 -- unsigned. It is also required that overflow checking is off for both
1317 -- the exponentiation and the multiply/divide node. If this set of
1318 -- conditions holds, and the flag is set, then the division or
1319 -- multiplication can be (and is) converted to a shift.
1320
1321 -- Is_Protected_Subprogram_Body (Flag7-Sem)
1322 -- A flag set in a Subprogram_Body block to indicate that it is the
1323 -- implementation of a protected subprogram. Such a body needs cleanup
1324 -- handler to make sure that the associated protected object is unlocked
1325 -- when the subprogram completes.
1326
1327 -- Is_Static_Coextension (Flag14-Sem)
1328 -- Present in N_Allocator nodes. Set if the allocator is a coextension
1329 -- of an object allocated on the stack rather than the heap.
1330
1331 -- Is_Static_Expression (Flag6-Sem)
1332 -- Indicates that an expression is a static expression (RM 4.9). See spec
1333 -- of package Sem_Eval for full details on the use of this flag.
1334
1335 -- Is_Subprogram_Descriptor (Flag16-Sem)
1336 -- Present in N_Object_Declaration, and set only for the object
1337 -- declaration generated for a subprogram descriptor in fast exception
1338 -- mode. See Exp_Ch11 for details of use.
1339
1340 -- Is_Task_Allocation_Block (Flag6-Sem)
1341 -- A flag set in a Block_Statement node to indicate that it is the
1342 -- expansion of a task allocator, or the allocator of an object
1343 -- containing tasks. Such a block requires a cleanup handler to call
1344 -- Expunge_Unactivated_Tasks to complete any tasks that have been
1345 -- allocated but not activated when the allocator completes abnormally.
1346
1347 -- Is_Task_Master (Flag5-Sem)
1348 -- A flag set in a Subprogram_Body, Block_Statement or Task_Body node to
1349 -- indicate that the construct is a task master (i.e. has declared tasks
1350 -- or declares an access to a task type).
1351
1352 -- Itype (Node1-Sem)
1353 -- Used in N_Itype_Reference node to reference an itype for which it is
1354 -- important to ensure that it is defined. See description of this node
1355 -- for further details.
1356
1357 -- Kill_Range_Check (Flag11-Sem)
1358 -- Used in an N_Unchecked_Type_Conversion node to indicate that the
1359 -- result should not be subjected to range checks. This is used for the
1360 -- implementation of Normalize_Scalars.
1361
1362 -- Label_Construct (Node2-Sem)
1363 -- Used in an N_Implicit_Label_Declaration node. Refers to an N_Label,
1364 -- N_Block_Statement or N_Loop_Statement node to which the label
1365 -- declaration applies. This is not currently used in the compiler
1366 -- itself, but it is useful in the implementation of ASIS queries.
1367 -- This field is left empty for the special labels generated as part
1368 -- of expanding raise statements with a local exception handler.
1369
1370 -- Library_Unit (Node4-Sem)
1371 -- In a stub node, Library_Unit points to the compilation unit node of
1372 -- the corresponding subunit.
1373 --
1374 -- In a with clause node, Library_Unit points to the spec of the with'ed
1375 -- unit.
1376 --
1377 -- In a compilation unit node, the usage depends on the unit type:
1378 --
1379 -- For a library unit body, Library_Unit points to the compilation unit
1380 -- node of the corresponding spec, unless it's a subprogram body with
1381 -- Acts_As_Spec set, in which case it points to itself.
1382 --
1383 -- For a spec, Library_Unit points to the compilation unit node of the
1384 -- corresponding body, if present. The body will be present if the spec
1385 -- is or contains generics that we needed to instantiate. Similarly, the
1386 -- body will be present if we needed it for inlining purposes. Thus, if
1387 -- we have a spec/body pair, both of which are present, they point to
1388 -- each other via Library_Unit.
1389 --
1390 -- For a subunit, Library_Unit points to the compilation unit node of
1391 -- the parent body.
1392 --
1393 -- Note that this field is not used to hold the parent pointer for child
1394 -- unit (which might in any case need to use it for some other purpose as
1395 -- described above). Instead for a child unit, implicit with's are
1396 -- generated for all parents.
1397
1398 -- Local_Raise_Statements (Elist1)
1399 -- This field is present in exception handler nodes. It is set to
1400 -- No_Elist in the normal case. If there is at least one raise statement
1401 -- which can potentially be handled as a local raise, then this field
1402 -- points to a list of raise nodes, which are calls to a routine to raise
1403 -- an exception. These are raise nodes which can be optimized into gotos
1404 -- if the handler turns out to meet the conditions which permit this
1405 -- transformation. Note that this does NOT include instances of the
1406 -- N_Raise_xxx_Error nodes since the transformation of these nodes is
1407 -- handled by the back end (using the N_Push/N_Pop mechanism).
1408
1409 -- Loop_Actions (List2-Sem)
1410 -- A list present in Component_Association nodes in array aggregates.
1411 -- Used to collect actions that must be executed within the loop because
1412 -- they may need to be evaluated anew each time through.
1413
1414 -- Limited_View_Installed (Flag18-Sem)
1415 -- Present in With_Clauses and in package specifications. If set on
1416 -- with_clause, it indicates that this clause has created the current
1417 -- limited view of the designated package. On a package specification, it
1418 -- indicates that the limited view has already been created because the
1419 -- package is mentioned in a limited_with_clause in the closure of the
1420 -- unit being compiled.
1421
1422 -- Local_Raise_Not_OK (Flag7-Sem)
1423 -- Present in N_Exception_Handler nodes. Set if the handler contains
1424 -- a construct (reraise statement, or call to subprogram in package
1425 -- GNAT.Current_Exception) that makes the handler unsuitable as a target
1426 -- for a local raise (one that could otherwise be converted to a goto).
1427
1428 -- Must_Be_Byte_Aligned (Flag14-Sem)
1429 -- This flag is present in N_Attribute_Reference nodes. It can be set
1430 -- only for the Address and Unrestricted_Access attributes. If set it
1431 -- means that the object for which the address/access is given must be on
1432 -- a byte (more accurately a storage unit) boundary. If necessary, a copy
1433 -- of the object is to be made before taking the address (this copy is in
1434 -- the current scope on the stack frame). This is used for certain cases
1435 -- of code generated by the expander that passes parameters by address.
1436 --
1437 -- The reason the copy is not made by the front end is that the back end
1438 -- has more information about type layout and may be able to (but is not
1439 -- guaranteed to) prevent making unnecessary copies.
1440
1441 -- Must_Not_Freeze (Flag8-Sem)
1442 -- A flag present in all expression nodes. Normally expressions cause
1443 -- freezing as described in the RM. If this flag is set, then this is
1444 -- inhibited. This is used by the analyzer and expander to label nodes
1445 -- that are created by semantic analysis or expansion and which must not
1446 -- cause freezing even though they normally would. This flag is also
1447 -- present in an N_Subtype_Indication node, since we also use these in
1448 -- calls to Freeze_Expression.
1449
1450 -- Next_Entity (Node2-Sem)
1451 -- Present in defining identifiers, defining character literals and
1452 -- defining operator symbols (i.e. in all entities). The entities of a
1453 -- scope are chained, and this field is used as the forward pointer for
1454 -- this list. See Einfo for further details.
1455
1456 -- Next_Exit_Statement (Node3-Sem)
1457 -- Present in N_Exit_Statement nodes. The exit statements for a loop are
1458 -- chained (in reverse order of appearence) from the First_Exit_Statement
1459 -- field of the E_Loop entity for the loop. Next_Exit_Statement points to
1460 -- the next entry on this chain (Empty = end of list).
1461
1462 -- Next_Implicit_With (Node3-Sem)
1463 -- Present in N_With_Clause. Part of a chain of with_clauses generated
1464 -- in rtsfind to indicate implicit dependencies on predefined units. Used
1465 -- to prevent multiple with_clauses for the same unit in a given context.
1466 -- A postorder traversal of the tree whose nodes are units and whose
1467 -- links are with_clauses defines the order in which Inspector must
1468 -- examine a compiled unit and its full context. This ordering ensures
1469 -- that any subprogram call is examined after the subprogram declartion
1470 -- has been seen.
1471
1472 -- Next_Named_Actual (Node4-Sem)
1473 -- Present in parameter association node. Set during semantic analysis to
1474 -- point to the next named parameter, where parameters are ordered by
1475 -- declaration order (as opposed to the actual order in the call, which
1476 -- may be different due to named associations). Not that this field
1477 -- points to the explicit actual parameter itself, not to the
1478 -- N_Parameter_Association node (its parent).
1479
1480 -- Next_Pragma (Node1-Sem)
1481 -- Present in N_Pragma nodes. Used to create a linked list of pragma
1482 -- nodes. Currently used for two purposes:
1483 --
1484 -- Create a list of linked Check_Policy pragmas. The head of this list
1485 -- is stored in Opt.Check_Policy_List (which has further details).
1486 --
1487 -- Used by processing for Pre/Postcondition pragmas to store a list of
1488 -- pragmas associated with the spec of a subprogram (see Sem_Prag for
1489 -- details).
1490
1491 -- Next_Rep_Item (Node5-Sem)
1492 -- Present in pragma nodes, attribute definition nodes, enumeration rep
1493 -- clauses, record rep clauses, aspect specification nodes. Used to link
1494 -- representation items that apply to an entity. See full description of
1495 -- First_Rep_Item field in Einfo for further details.
1496
1497 -- Next_Use_Clause (Node3-Sem)
1498 -- While use clauses are active during semantic processing, they are
1499 -- chained from the scope stack entry, using Next_Use_Clause as a link
1500 -- pointer, with Empty marking the end of the list. The head pointer is
1501 -- in the scope stack entry (First_Use_Clause). At the end of semantic
1502 -- processing (i.e. when Gigi sees the tree, the contents of this field
1503 -- is undefined and should not be read).
1504
1505 -- No_Ctrl_Actions (Flag7-Sem)
1506 -- Present in N_Assignment_Statement to indicate that no finalize nor
1507 -- adjust should take place on this assignment even though the rhs is
1508 -- controlled. This is used in init procs and aggregate expansions where
1509 -- the generated assignments are more initialisations than real
1510 -- assignments.
1511
1512 -- No_Elaboration_Check (Flag14-Sem)
1513 -- Present in N_Function_Call and N_Procedure_Call_Statement. Indicates
1514 -- that no elaboration check is needed on the call, because it appears in
1515 -- the context of a local Suppress pragma. This is used on calls within
1516 -- task bodies, where the actual elaboration checks are applied after
1517 -- analysis, when the local scope stack is not present.
1518
1519 -- No_Entities_Ref_In_Spec (Flag8-Sem)
1520 -- Present in N_With_Clause nodes. Set if the with clause is on the
1521 -- package or subprogram spec where the main unit is the corresponding
1522 -- body, and no entities of the with'ed unit are referenced by the spec
1523 -- (an entity may still be referenced in the body, so this flag is used
1524 -- to generate the proper message (see Sem_Util.Check_Unused_Withs for
1525 -- full details)
1526
1527 -- No_Initialization (Flag13-Sem)
1528 -- Present in N_Object_Declaration and N_Allocator to indicate that the
1529 -- object must not be initialized (by Initialize or call to an init
1530 -- proc). This is needed for controlled aggregates. When the Object
1531 -- declaration has an expression, this flag means that this expression
1532 -- should not be taken into account (needed for in place initialization
1533 -- with aggregates).
1534
1535 -- No_Truncation (Flag17-Sem)
1536 -- Present in N_Unchecked_Type_Conversion node. This flag has an effect
1537 -- only if the RM_Size of the source is greater than the RM_Size of the
1538 -- target for scalar operands. Normally in such a case we truncate some
1539 -- higher order bits of the source, and then sign/zero extend the result
1540 -- to form the output value. But if this flag is set, then we do not do
1541 -- any truncation, so for example, if an 8 bit input is converted to 5
1542 -- bit result which is in fact stored in 8 bits, then the high order
1543 -- three bits of the target result will be copied from the source. This
1544 -- is used for properly setting out of range values for use by pragmas
1545 -- Initialize_Scalars and Normalize_Scalars.
1546
1547 -- Of_Present (Flag16)
1548 -- Present in N_Iterastor_Specification nodes, to mark the Ada2012 iterator
1549 -- form over arrays and containers.
1550
1551 -- Original_Discriminant (Node2-Sem)
1552 -- Present in identifiers. Used in references to discriminants that
1553 -- appear in generic units. Because the names of the discriminants may be
1554 -- different in an instance, we use this field to recover the position of
1555 -- the discriminant in the original type, and replace it with the
1556 -- discriminant at the same position in the instantiated type.
1557
1558 -- Original_Entity (Node2-Sem)
1559 -- Present in numeric literals. Used to denote the named number that has
1560 -- been constant-folded into the given literal. If literal is from
1561 -- source, or the result of some other constant-folding operation, then
1562 -- Original_Entity is empty. This field is needed to handle properly
1563 -- named numbers in generic units, where the Associated_Node field
1564 -- interferes with the Entity field, making it impossible to preserve the
1565 -- original entity at the point of instantiation (ASIS problem).
1566
1567 -- Others_Discrete_Choices (List1-Sem)
1568 -- When a case statement or variant is analyzed, the semantic checks
1569 -- determine the actual list of choices that correspond to an others
1570 -- choice. This list is materialized for later use by the expander and
1571 -- the Others_Discrete_Choices field of an N_Others_Choice node points to
1572 -- this materialized list of choices, which is in standard format for a
1573 -- list of discrete choices, except that of course it cannot contain an
1574 -- N_Others_Choice entry.
1575
1576 -- Parameter_List_Truncated (Flag17-Sem)
1577 -- Present in N_Function_Call and N_Procedure_Call_Statement nodes. Set
1578 -- (for OpenVMS ports of GNAT only) if the parameter list is truncated as
1579 -- a result of a First_Optional_Parameter specification in an
1580 -- Import_Function, Import_Procedure, or Import_Valued_Procedure pragma.
1581 -- The truncation is done by the expander by removing trailing parameters
1582 -- from the argument list, in accordance with the set of rules allowing
1583 -- such parameter removal. In particular, parameters can be removed
1584 -- working from the end of the parameter list backwards up to and
1585 -- including the entry designated by First_Optional_Parameter in the
1586 -- Import pragma. Parameters can be removed if they are implicit and the
1587 -- default value is a known-at-compile-time value, including the use of
1588 -- the Null_Parameter attribute, or if explicit parameter values are
1589 -- present that match the corresponding defaults.
1590
1591 -- Parent_Spec (Node4-Sem)
1592 -- For a library unit that is a child unit spec (package or subprogram
1593 -- declaration, generic declaration or instantiation, or library level
1594 -- rename, this field points to the compilation unit node for the parent
1595 -- package specification. This field is Empty for library bodies (the
1596 -- parent spec in this case can be found from the corresponding spec).
1597
1598 -- Pragma_Enabled (Flag5-Sem)
1599 -- Present in N_Pragma nodes. This flag is relevant only for pragmas
1600 -- Assert, Check, Precondition, and Postcondition. It is true if the
1601 -- check corresponding to the pragma type is enabled at the point where
1602 -- the pragma appears.
1603
1604 -- Present_Expr (Uint3-Sem)
1605 -- Present in an N_Variant node. This has a meaningful value only after
1606 -- Gigi has back annotated the tree with representation information. At
1607 -- this point, it contains a reference to a gcc expression that depends
1608 -- on the values of one or more discriminants. Give a set of discriminant
1609 -- values, this expression evaluates to False (zero) if variant is not
1610 -- present, and True (non-zero) if it is present. See unit Repinfo for
1611 -- further details on gigi back annotation. This field is used during
1612 -- ASIS processing (data decomposition annex) to determine if a field is
1613 -- present or not.
1614
1615 -- Print_In_Hex (Flag13-Sem)
1616 -- Set on an N_Integer_Literal node to indicate that the value should be
1617 -- printed in hexadecimal in the sprint listing. Has no effect on
1618 -- legality or semantics of program, only on the displayed output. This
1619 -- is used to clarify output from the packed array cases.
1620
1621 -- Procedure_To_Call (Node2-Sem)
1622 -- Present in N_Allocator, N_Free_Statement, N_Simple_Return_Statement,
1623 -- and N_Extended_Return_Statement nodes. References the entity for the
1624 -- declaration of the procedure to be called to accomplish the required
1625 -- operation (i.e. for the Allocate procedure in the case of N_Allocator
1626 -- and N_Simple_Return_Statement and N_Extended_Return_Statement (for
1627 -- allocating the return value), and for the Deallocate procedure in the
1628 -- case of N_Free_Statement.
1629
1630 -- Raises_Constraint_Error (Flag7-Sem)
1631 -- Set on an expression whose evaluation will definitely fail constraint
1632 -- error check. In the case of static expressions, this flag must be set
1633 -- accurately (and if it is set, the expression is typically illegal
1634 -- unless it appears as a non-elaborated branch of a short-circuit form).
1635 -- For a non-static expression, this flag may be set whenever an
1636 -- expression (e.g. an aggregate) is known to raise constraint error. If
1637 -- set, the expression definitely will raise CE if elaborated at runtime.
1638 -- If not set, the expression may or may not raise CE. In other words, on
1639 -- static expressions, the flag is set accurately, on non-static
1640 -- expressions it is set conservatively.
1641
1642 -- Redundant_Use (Flag13-Sem)
1643 -- Present in nodes that can appear as an operand in a use clause or use
1644 -- type clause (identifiers, expanded names, attribute references). Set
1645 -- to indicate that a use is redundant (and therefore need not be undone
1646 -- on scope exit).
1647
1648 -- Renaming_Exception (Node2-Sem)
1649 -- Present in N_Exception_Declaration node. Used to point back to the
1650 -- exception renaming for an exception declared within a subprogram.
1651 -- What happens is that an exception declared in a subprogram is moved
1652 -- to the library level with a unique name, and the original exception
1653 -- becomes a renaming. This link from the library level exception to the
1654 -- renaming declaration allows registering of the proper exception name.
1655
1656 -- Return_Statement_Entity (Node5-Sem)
1657 -- Present in N_Simple_Return_Statement and N_Extended_Return_Statement.
1658 -- Points to an E_Return_Statement representing the return statement.
1659
1660 -- Return_Object_Declarations (List3)
1661 -- Present in N_Extended_Return_Statement.
1662 -- Points to a list initially containing a single
1663 -- N_Object_Declaration representing the return object.
1664 -- We use a list (instead of just a pointer to the object decl)
1665 -- because Analyze wants to insert extra actions on this list.
1666
1667 -- Rounded_Result (Flag18-Sem)
1668 -- Present in N_Type_Conversion, N_Op_Divide and N_Op_Multiply nodes.
1669 -- Used in the fixed-point cases to indicate that the result must be
1670 -- rounded as a result of the use of the 'Round attribute. Also used for
1671 -- integer N_Op_Divide nodes to indicate that the result should be
1672 -- rounded to the nearest integer (breaking ties away from zero), rather
1673 -- than truncated towards zero as usual. These rounded integer operations
1674 -- are the result of expansion of rounded fixed-point divide, conversion
1675 -- and multiplication operations.
1676
1677 -- SCIL_Entity (Node4-Sem)
1678 -- Present in SCIL nodes. Used to reference the tagged type associated
1679 -- with the SCIL node.
1680
1681 -- SCIL_Controlling_Tag (Node5-Sem)
1682 -- Present in N_SCIL_Dispatching_Call nodes. Used to reference the
1683 -- controlling tag of a dispatching call.
1684
1685 -- SCIL_Tag_Value (Node5-Sem)
1686 -- Present in N_SCIL_Membership_Test nodes. Used to reference the tag
1687 -- value that is being tested.
1688
1689 -- SCIL_Target_Prim (Node2-Sem)
1690 -- Present in N_SCIL_Dispatching_Call nodes. Used to reference the tagged
1691 -- type primitive associated with the SCIL node.
1692
1693 -- Scope (Node3-Sem)
1694 -- Present in defining identifiers, defining character literals and
1695 -- defining operator symbols (i.e. in all entities). The entities of a
1696 -- scope all use this field to reference the corresponding scope entity.
1697 -- See Einfo for further details.
1698
1699 -- Shift_Count_OK (Flag4-Sem)
1700 -- A flag present in shift nodes to indicate that the shift count is
1701 -- known to be in range, i.e. is in the range from zero to word length
1702 -- minus one. If this flag is not set, then the shift count may be
1703 -- outside this range, i.e. larger than the word length, and the code
1704 -- must ensure that such shift counts give the appropriate result.
1705
1706 -- Source_Type (Node1-Sem)
1707 -- Used in an N_Validate_Unchecked_Conversion node to point to the
1708 -- source type entity for the unchecked conversion instantiation
1709 -- which gigi must do size validation for.
1710
1711 -- Split_PPC (Flag17)
1712 -- When a Pre or Postaspect specification is processed, it is broken
1713 -- into AND THEN sections. The left most section has Split_PPC set to
1714 -- False, indicating that it is the original specification (e.g. for
1715 -- posting errors). For other sections, Split_PPC is set to True.
1716 -- This flag is set in both the N_Aspect_Specification node itself,
1717 -- and in the pragma which is generated from this node.
1718
1719 -- Static_Processing_OK (Flag4-Sem)
1720 -- Present in N_Aggregate nodes. When the Compile_Time_Known_Aggregate
1721 -- flag is set, the full value of the aggregate can be determined at
1722 -- compile time and the aggregate can be passed as is to the back-end.
1723 -- In this event it is irrelevant whether this flag is set or not.
1724 -- However, if the flag Compile_Time_Known_Aggregate is not set but
1725 -- Static_Processing_OK is set, the aggregate can (but need not) be
1726 -- converted into a compile time known aggregate by the expander. See
1727 -- Sem_Aggr for the specific conditions under which an aggregate has its
1728 -- Static_Processing_OK flag set.
1729
1730 -- Storage_Pool (Node1-Sem)
1731 -- Present in N_Allocator, N_Free_Statement, N_Simple_Return_Statement,
1732 -- and N_Extended_Return_Statement nodes. References the entity for the
1733 -- storage pool to be used for the allocate or free call or for the
1734 -- allocation of the returned value from function. Empty indicates that
1735 -- the global default pool is to be used. Note that in the case
1736 -- of a return statement, this field is set only if the function returns
1737 -- value of a type whose size is not known at compile time on the
1738 -- secondary stack.
1739
1740 -- Suppress_Loop_Warnings (Flag17-Sem)
1741 -- Used in N_Loop_Statement node to indicate that warnings within the
1742 -- body of the loop should be suppressed. This is set when the range
1743 -- of a FOR loop is known to be null, or is probably null (loop would
1744 -- only execute if invalid values are present).
1745
1746 -- Target_Type (Node2-Sem)
1747 -- Used in an N_Validate_Unchecked_Conversion node to point to the target
1748 -- type entity for the unchecked conversion instantiation which gigi must
1749 -- do size validation for.
1750
1751 -- Then_Actions (List3-Sem)
1752 -- This field is present in conditional expression nodes. During code
1753 -- expansion we use the Insert_Actions procedure (in Exp_Util) to insert
1754 -- actions at an appropriate place in the tree to get elaborated at the
1755 -- right time. For conditional expressions, we have to be sure that the
1756 -- actions for the Then branch are only elaborated if the condition is
1757 -- True. The Then_Actions field is used as a temporary parking place for
1758 -- these actions. The final tree is always rewritten to eliminate the
1759 -- need for this field, so in the tree passed to Gigi, this field is
1760 -- always set to No_List.
1761
1762 -- Treat_Fixed_As_Integer (Flag14-Sem)
1763 -- This flag appears in operator nodes for divide, multiply, mod and rem
1764 -- on fixed-point operands. It indicates that the operands are to be
1765 -- treated as integer values, ignoring small values. This flag is only
1766 -- set as a result of expansion of fixed-point operations. Typically a
1767 -- fixed-point multiplication in the source generates subsidiary
1768 -- multiplication and division operations that work with the underlying
1769 -- integer values and have this flag set. Note that this flag is not
1770 -- needed on other arithmetic operations (add, neg, subtract etc.) since
1771 -- in these cases it is always the case that fixed is treated as integer.
1772 -- The Etype field MUST be set if this flag is set. The analyzer knows to
1773 -- leave such nodes alone, and whoever makes them must set the correct
1774 -- Etype value.
1775
1776 -- TSS_Elist (Elist3-Sem)
1777 -- Present in N_Freeze_Entity nodes. Holds an element list containing
1778 -- entries for each TSS (type support subprogram) associated with the
1779 -- frozen type. The elements of the list are the entities for the
1780 -- subprograms (see package Exp_TSS for further details). Set to No_Elist
1781 -- if there are no type support subprograms for the type or if the freeze
1782 -- node is not for a type.
1783
1784 -- Unreferenced_In_Spec (Flag7-Sem)
1785 -- Present in N_With_Clause nodes. Set if the with clause is on the
1786 -- package or subprogram spec where the main unit is the corresponding
1787 -- body, and is not referenced by the spec (it may still be referenced by
1788 -- the body, so this flag is used to generate the proper message (see
1789 -- Sem_Util.Check_Unused_Withs for details)
1790
1791 -- Was_Originally_Stub (Flag13-Sem)
1792 -- This flag is set in the node for a proper body that replaces stub.
1793 -- During the analysis procedure, stubs in some situations get rewritten
1794 -- by the corresponding bodies, and we set this flag to remember that
1795 -- this happened. Note that it is not good enough to rely on the use of
1796 -- Original_Node here because of the case of nested instantiations where
1797 -- the substituted node can be copied.
1798
1799 -- Withed_Body (Node1-Sem)
1800 -- Present in N_With_Clause nodes. Set if the unit in whose context
1801 -- the with_clause appears instantiates a generic contained in the
1802 -- library unit of the with_clause and as a result loads its body.
1803 -- Used for a more precise unit traversal for CodePeer.
1804
1805 -- Zero_Cost_Handling (Flag5-Sem)
1806 -- This flag is set in all handled sequence of statement and exception
1807 -- handler nodes if exceptions are to be handled using the zero-cost
1808 -- mechanism (see Ada.Exceptions and System.Exceptions in files
1809 -- a-except.ads/adb and s-except.ads for full details). What gigi needs
1810 -- to do for such a handler is simply to put the code in the handler
1811 -- somewhere. The front end has generated all necessary labels.
1812
1813 --------------------------------------------------
1814 -- Note on Use of End_Label and End_Span Fields --
1815 --------------------------------------------------
1816
1817 -- Several constructs have end lines:
1818
1819 -- Loop Statement end loop [loop_IDENTIFIER];
1820 -- Package Specification end [[PARENT_UNIT_NAME .] IDENTIFIER]
1821 -- Task Definition end [task_IDENTIFIER]
1822 -- Protected Definition end [protected_IDENTIFIER]
1823 -- Protected Body end [protected_IDENTIFIER]
1824
1825 -- Block Statement end [block_IDENTIFIER];
1826 -- Subprogram Body end [DESIGNATOR];
1827 -- Package Body end [[PARENT_UNIT_NAME .] IDENTIFIER];
1828 -- Task Body end [task_IDENTIFIER];
1829 -- Accept Statement end [entry_IDENTIFIER]];
1830 -- Entry Body end [entry_IDENTIFIER];
1831
1832 -- If Statement end if;
1833 -- Case Statement end case;
1834
1835 -- Record Definition end record;
1836 -- Enumeration Definition );
1837
1838 -- The End_Label and End_Span fields are used to mark the locations of
1839 -- these lines, and also keep track of the label in the case where a label
1840 -- is present.
1841
1842 -- For the first group above, the End_Label field of the corresponding node
1843 -- is used to point to the label identifier. In the case where there is no
1844 -- label in the source, the parser supplies a dummy identifier (with
1845 -- Comes_From_Source set to False), and the Sloc of this dummy identifier
1846 -- marks the location of the token following the END token.
1847
1848 -- For the second group, the use of End_Label is similar, but the End_Label
1849 -- is found in the N_Handled_Sequence_Of_Statements node. This is done
1850 -- simply because in some cases there is no room in the parent node.
1851
1852 -- For the third group, there is never any label, and instead of using
1853 -- End_Label, we use the End_Span field which gives the location of the
1854 -- token following END, relative to the starting Sloc of the construct,
1855 -- i.e. add Sloc (Node) + End_Span (Node) to get the Sloc of the IF or CASE
1856 -- following the End_Label.
1857
1858 -- The record definition case is handled specially, we treat it as though
1859 -- it required an optional label which is never present, and so the parser
1860 -- always builds a dummy identifier with Comes From Source set False. The
1861 -- reason we do this, rather than using End_Span in this case, is that we
1862 -- want to generate a cross-ref entry for the end of a record, since it
1863 -- represents a scope for name declaration purposes.
1864
1865 -- The enumeration definition case is handled in an exactly similar manner,
1866 -- building a dummy identifier to get a cross-reference.
1867
1868 -- Note: the reason we store the difference as a Uint, instead of storing
1869 -- the Source_Ptr value directly, is that Source_Ptr values cannot be
1870 -- distinguished from other types of values, and we count on all general
1871 -- use fields being self describing. To make things easier for clients,
1872 -- note that we provide function End_Location, and procedure
1873 -- Set_End_Location to allow access to the logical value (which is the
1874 -- Source_Ptr value for the end token).
1875
1876 ---------------------
1877 -- Syntactic Nodes --
1878 ---------------------
1879
1880 ---------------------
1881 -- 2.3 Identifier --
1882 ---------------------
1883
1884 -- IDENTIFIER ::= IDENTIFIER_LETTER {[UNDERLINE] LETTER_OR_DIGIT}
1885 -- LETTER_OR_DIGIT ::= IDENTIFIER_LETTER | DIGIT
1886
1887 -- An IDENTIFIER shall not be a reserved word
1888
1889 -- In the Ada grammar identifiers are the bottom level tokens which have
1890 -- very few semantics. Actual program identifiers are direct names. If
1891 -- we were being 100% honest with the grammar, then we would have a node
1892 -- called N_Direct_Name which would point to an identifier. However,
1893 -- that's too many extra nodes, so we just use the N_Identifier node
1894 -- directly as a direct name, and it contains the expression fields and
1895 -- Entity field that correspond to its use as a direct name. In those
1896 -- few cases where identifiers appear in contexts where they are not
1897 -- direct names (pragmas, pragma argument associations, attribute
1898 -- references and attribute definition clauses), the Chars field of the
1899 -- node contains the Name_Id for the identifier name.
1900
1901 -- Note: in GNAT, a reserved word can be treated as an identifier in two
1902 -- cases. First, an incorrect use of a reserved word as an identifier is
1903 -- diagnosed and then treated as a normal identifier. Second, an
1904 -- attribute designator of the form of a reserved word (access, delta,
1905 -- digits, range) is treated as an identifier.
1906
1907 -- Note: The set of letters that is permitted in an identifier depends
1908 -- on the character set in use. See package Csets for full details.
1909
1910 -- N_Identifier
1911 -- Sloc points to identifier
1912 -- Chars (Name1) contains the Name_Id for the identifier
1913 -- Entity (Node4-Sem)
1914 -- Associated_Node (Node4-Sem)
1915 -- Original_Discriminant (Node2-Sem)
1916 -- Redundant_Use (Flag13-Sem)
1917 -- Has_Private_View (Flag11-Sem) (set in generic units)
1918 -- plus fields for expression
1919
1920 --------------------------
1921 -- 2.4 Numeric Literal --
1922 --------------------------
1923
1924 -- NUMERIC_LITERAL ::= DECIMAL_LITERAL | BASED_LITERAL
1925
1926 ----------------------------
1927 -- 2.4.1 Decimal Literal --
1928 ----------------------------
1929
1930 -- DECIMAL_LITERAL ::= NUMERAL [.NUMERAL] [EXPONENT]
1931
1932 -- NUMERAL ::= DIGIT {[UNDERLINE] DIGIT}
1933
1934 -- EXPONENT ::= E [+] NUMERAL | E - NUMERAL
1935
1936 -- Decimal literals appear in the tree as either integer literal nodes
1937 -- or real literal nodes, depending on whether a period is present.
1938
1939 -- Note: literal nodes appear as a result of direct use of literals
1940 -- in the source program, and also as the result of evaluating
1941 -- expressions at compile time. In the latter case, it is possible
1942 -- to construct real literals that have no syntactic representation
1943 -- using the standard literal format. Such literals are listed by
1944 -- Sprint using the notation [numerator / denominator].
1945
1946 -- Note: the value of an integer literal node created by the front end
1947 -- is never outside the range of values of the base type. However, it
1948 -- can be the case that the value is outside the range of the
1949 -- particular subtype. This happens in the case of integer overflows
1950 -- with checks suppressed.
1951
1952 -- N_Integer_Literal
1953 -- Sloc points to literal
1954 -- Original_Entity (Node2-Sem) If not Empty, holds Named_Number that
1955 -- has been constant-folded into its literal value.
1956 -- Intval (Uint3) contains integer value of literal
1957 -- plus fields for expression
1958 -- Print_In_Hex (Flag13-Sem)
1959
1960 -- N_Real_Literal
1961 -- Sloc points to literal
1962 -- Original_Entity (Node2-Sem) If not Empty, holds Named_Number that
1963 -- has been constant-folded into its literal value.
1964 -- Realval (Ureal3) contains real value of literal
1965 -- Corresponding_Integer_Value (Uint4-Sem)
1966 -- Is_Machine_Number (Flag11-Sem)
1967 -- plus fields for expression
1968
1969 --------------------------
1970 -- 2.4.2 Based Literal --
1971 --------------------------
1972
1973 -- BASED_LITERAL ::=
1974 -- BASE # BASED_NUMERAL [.BASED_NUMERAL] # [EXPONENT]
1975
1976 -- BASE ::= NUMERAL
1977
1978 -- BASED_NUMERAL ::=
1979 -- EXTENDED_DIGIT {[UNDERLINE] EXTENDED_DIGIT}
1980
1981 -- EXTENDED_DIGIT ::= DIGIT | A | B | C | D | E | F
1982
1983 -- Based literals appear in the tree as either integer literal nodes
1984 -- or real literal nodes, depending on whether a period is present.
1985
1986 ----------------------------
1987 -- 2.5 Character Literal --
1988 ----------------------------
1989
1990 -- CHARACTER_LITERAL ::= ' GRAPHIC_CHARACTER '
1991
1992 -- N_Character_Literal
1993 -- Sloc points to literal
1994 -- Chars (Name1) contains the Name_Id for the identifier
1995 -- Char_Literal_Value (Uint2) contains the literal value
1996 -- Entity (Node4-Sem)
1997 -- Associated_Node (Node4-Sem)
1998 -- Has_Private_View (Flag11-Sem) set in generic units.
1999 -- plus fields for expression
2000
2001 -- Note: the Entity field will be missing (set to Empty) for character
2002 -- literals whose type is Standard.Wide_Character or Standard.Character
2003 -- or a type derived from one of these two. In this case the character
2004 -- literal stands for its own coding. The reason we take this irregular
2005 -- short cut is to avoid the need to build lots of junk defining
2006 -- character literal nodes.
2007
2008 -------------------------
2009 -- 2.6 String Literal --
2010 -------------------------
2011
2012 -- STRING LITERAL ::= "{STRING_ELEMENT}"
2013
2014 -- A STRING_ELEMENT is either a pair of quotation marks ("), or a
2015 -- single GRAPHIC_CHARACTER other than a quotation mark.
2016 --
2017 -- Is_Folded_In_Parser is True if the parser created this literal by
2018 -- folding a sequence of "&" operators. For example, if the source code
2019 -- says "aaa" & "bbb" & "ccc", and this produces "aaabbbccc", the flag
2020 -- is set. This flag is needed because the parser doesn't know about
2021 -- visibility, so the folded result might be wrong, and semantic
2022 -- analysis needs to check for that.
2023
2024 -- N_String_Literal
2025 -- Sloc points to literal
2026 -- Strval (Str3) contains Id of string value
2027 -- Has_Wide_Character (Flag11-Sem)
2028 -- Has_Wide_Wide_Character (Flag13-Sem)
2029 -- Is_Folded_In_Parser (Flag4)
2030 -- plus fields for expression
2031
2032 ------------------
2033 -- 2.7 Comment --
2034 ------------------
2035
2036 -- A COMMENT starts with two adjacent hyphens and extends up to the
2037 -- end of the line. A COMMENT may appear on any line of a program.
2038
2039 -- Comments are skipped by the scanner and do not appear in the tree.
2040 -- It is possible to reconstruct the position of comments with respect
2041 -- to the elements of the tree by using the source position (Sloc)
2042 -- pointers that appear in every tree node.
2043
2044 -----------------
2045 -- 2.8 Pragma --
2046 -----------------
2047
2048 -- PRAGMA ::= pragma IDENTIFIER
2049 -- [(PRAGMA_ARGUMENT_ASSOCIATION {, PRAGMA_ARGUMENT_ASSOCIATION})];
2050
2051 -- Note that a pragma may appear in the tree anywhere a declaration
2052 -- or a statement may appear, as well as in some other situations
2053 -- which are explicitly documented.
2054
2055 -- N_Pragma
2056 -- Sloc points to PRAGMA
2057 -- Next_Pragma (Node1-Sem)
2058 -- Pragma_Argument_Associations (List2) (set to No_List if none)
2059 -- Debug_Statement (Node3) (set to Empty if not Debug)
2060 -- Pragma_Identifier (Node4)
2061 -- Next_Rep_Item (Node5-Sem)
2062 -- Pragma_Enabled (Flag5-Sem)
2063 -- From_Aspect_Specification (Flag13-Sem)
2064 -- Is_Delayed_Aspect (Flag14-Sem)
2065 -- Import_Interface_Present (Flag16-Sem)
2066 -- Aspect_Cancel (Flag11-Sem)
2067 -- Split_PPC (Flag17) set if corresponding aspect had Split_PPC set
2068 -- Class_Present (Flag6) set if from Aspect with 'Class
2069
2070 -- Note: we should have a section on what pragmas are passed on to
2071 -- the back end to be processed. This section should note that pragma
2072 -- Psect_Object is always converted to Common_Object, but there are
2073 -- undoubtedly many other similar notes required ???
2074
2075 -- Note: a utility function Pragma_Name may be applied to pragma nodes
2076 -- to conveniently obtain the Chars field of the Pragma_Identifier.
2077
2078 -- Note: if From_Aspect_Specification is set, then Sloc points to the
2079 -- aspect name, as does the Pragma_Identifier. In this case if the
2080 -- pragma has a local name argument (such as pragma Inline), it is
2081 -- resolved to point to the specific entity affected by the pragma.
2082
2083 --------------------------------------
2084 -- 2.8 Pragma Argument Association --
2085 --------------------------------------
2086
2087 -- PRAGMA_ARGUMENT_ASSOCIATION ::=
2088 -- [pragma_argument_IDENTIFIER =>] NAME
2089 -- | [pragma_argument_IDENTIFIER =>] EXPRESSION
2090
2091 -- N_Pragma_Argument_Association
2092 -- Sloc points to first token in association
2093 -- Chars (Name1) (set to No_Name if no pragma argument identifier)
2094 -- Expression (Node3)
2095
2096 ------------------------
2097 -- 2.9 Reserved Word --
2098 ------------------------
2099
2100 -- Reserved words are parsed by the scanner, and returned as the
2101 -- corresponding token types (e.g. PACKAGE is returned as Tok_Package)
2102
2103 ----------------------------
2104 -- 3.1 Basic Declaration --
2105 ----------------------------
2106
2107 -- BASIC_DECLARATION ::=
2108 -- TYPE_DECLARATION | SUBTYPE_DECLARATION
2109 -- | OBJECT_DECLARATION | NUMBER_DECLARATION
2110 -- | SUBPROGRAM_DECLARATION | ABSTRACT_SUBPROGRAM_DECLARATION
2111 -- | PACKAGE_DECLARATION | RENAMING_DECLARATION
2112 -- | EXCEPTION_DECLARATION | GENERIC_DECLARATION
2113 -- | GENERIC_INSTANTIATION
2114
2115 -- Basic declaration also includes IMPLICIT_LABEL_DECLARATION
2116 -- see further description in section on semantic nodes.
2117
2118 -- Also, in the tree that is constructed, a pragma may appear
2119 -- anywhere that a declaration may appear.
2120
2121 ------------------------------
2122 -- 3.1 Defining Identifier --
2123 ------------------------------
2124
2125 -- DEFINING_IDENTIFIER ::= IDENTIFIER
2126
2127 -- A defining identifier is an entity, which has additional fields
2128 -- depending on the setting of the Ekind field. These additional
2129 -- fields are defined (and access subprograms declared) in package
2130 -- Einfo.
2131
2132 -- Note: N_Defining_Identifier is an extended node whose fields are
2133 -- deliberate layed out to match the layout of fields in an ordinary
2134 -- N_Identifier node allowing for easy alteration of an identifier
2135 -- node into a defining identifier node. For details, see procedure
2136 -- Sinfo.CN.Change_Identifier_To_Defining_Identifier.
2137
2138 -- N_Defining_Identifier
2139 -- Sloc points to identifier
2140 -- Chars (Name1) contains the Name_Id for the identifier
2141 -- Next_Entity (Node2-Sem)
2142 -- Scope (Node3-Sem)
2143 -- Etype (Node5-Sem)
2144
2145 -----------------------------
2146 -- 3.2.1 Type Declaration --
2147 -----------------------------
2148
2149 -- TYPE_DECLARATION ::=
2150 -- FULL_TYPE_DECLARATION
2151 -- | INCOMPLETE_TYPE_DECLARATION
2152 -- | PRIVATE_TYPE_DECLARATION
2153 -- | PRIVATE_EXTENSION_DECLARATION
2154
2155 ----------------------------------
2156 -- 3.2.1 Full Type Declaration --
2157 ----------------------------------
2158
2159 -- FULL_TYPE_DECLARATION ::=
2160 -- type DEFINING_IDENTIFIER [KNOWN_DISCRIMINANT_PART]
2161 -- is TYPE_DEFINITION
2162 -- [ASPECT_SPECIFICATIONS];
2163
2164 -- | TASK_TYPE_DECLARATION
2165 -- | PROTECTED_TYPE_DECLARATION
2166
2167 -- The full type declaration node is used only for the first case. The
2168 -- second case (concurrent type declaration), is represented directly
2169 -- by a task type declaration or a protected type declaration.
2170
2171 -- N_Full_Type_Declaration
2172 -- Sloc points to TYPE
2173 -- Defining_Identifier (Node1)
2174 -- Discriminant_Specifications (List4) (set to No_List if none)
2175 -- Type_Definition (Node3)
2176 -- Discr_Check_Funcs_Built (Flag11-Sem)
2177
2178 ----------------------------
2179 -- 3.2.1 Type Definition --
2180 ----------------------------
2181
2182 -- TYPE_DEFINITION ::=
2183 -- ENUMERATION_TYPE_DEFINITION | INTEGER_TYPE_DEFINITION
2184 -- | REAL_TYPE_DEFINITION | ARRAY_TYPE_DEFINITION
2185 -- | RECORD_TYPE_DEFINITION | ACCESS_TYPE_DEFINITION
2186 -- | DERIVED_TYPE_DEFINITION | INTERFACE_TYPE_DEFINITION
2187
2188 --------------------------------
2189 -- 3.2.2 Subtype Declaration --
2190 --------------------------------
2191
2192 -- SUBTYPE_DECLARATION ::=
2193 -- subtype DEFINING_IDENTIFIER is [NULL_EXCLUSION] SUBTYPE_INDICATION;
2194
2195 -- The subtype indication field is set to Empty for subtypes
2196 -- declared in package Standard (Positive, Natural).
2197
2198 -- N_Subtype_Declaration
2199 -- Sloc points to SUBTYPE
2200 -- Defining_Identifier (Node1)
2201 -- Null_Exclusion_Present (Flag11)
2202 -- Subtype_Indication (Node5)
2203 -- Generic_Parent_Type (Node4-Sem) (set for an actual derived type).
2204 -- Exception_Junk (Flag8-Sem)
2205
2206 -------------------------------
2207 -- 3.2.2 Subtype Indication --
2208 -------------------------------
2209
2210 -- SUBTYPE_INDICATION ::= SUBTYPE_MARK [CONSTRAINT]
2211
2212 -- Note: if no constraint is present, the subtype indication appears
2213 -- directly in the tree as a subtype mark. The N_Subtype_Indication
2214 -- node is used only if a constraint is present.
2215
2216 -- Note: [For Ada 2005 (AI-231)]: Because Ada 2005 extends this rule
2217 -- with the null-exclusion part (see AI-231), we had to introduce a new
2218 -- attribute in all the parents of subtype_indication nodes to indicate
2219 -- if the null-exclusion is present.
2220
2221 -- Note: the reason that this node has expression fields is that a
2222 -- subtype indication can appear as an operand of a membership test.
2223
2224 -- N_Subtype_Indication
2225 -- Sloc points to first token of subtype mark
2226 -- Subtype_Mark (Node4)
2227 -- Constraint (Node3)
2228 -- Etype (Node5-Sem)
2229 -- Must_Not_Freeze (Flag8-Sem)
2230
2231 -- Note: Etype is a copy of the Etype field of the Subtype_Mark. The
2232 -- reason for this redundancy is so that in a list of array index types,
2233 -- the Etype can be uniformly accessed to determine the subscript type.
2234 -- This means that no Itype is constructed for the actual subtype that
2235 -- is created by the subtype indication. If such an Itype is required,
2236 -- it is constructed in the context in which the indication appears.
2237
2238 -------------------------
2239 -- 3.2.2 Subtype Mark --
2240 -------------------------
2241
2242 -- SUBTYPE_MARK ::= subtype_NAME
2243
2244 -----------------------
2245 -- 3.2.2 Constraint --
2246 -----------------------
2247
2248 -- CONSTRAINT ::= SCALAR_CONSTRAINT | COMPOSITE_CONSTRAINT
2249
2250 ------------------------------
2251 -- 3.2.2 Scalar Constraint --
2252 ------------------------------
2253
2254 -- SCALAR_CONSTRAINT ::=
2255 -- RANGE_CONSTRAINT | DIGITS_CONSTRAINT | DELTA_CONSTRAINT
2256
2257 ---------------------------------
2258 -- 3.2.2 Composite Constraint --
2259 ---------------------------------
2260
2261 -- COMPOSITE_CONSTRAINT ::=
2262 -- INDEX_CONSTRAINT | DISCRIMINANT_CONSTRAINT
2263
2264 -------------------------------
2265 -- 3.3.1 Object Declaration --
2266 -------------------------------
2267
2268 -- OBJECT_DECLARATION ::=
2269 -- DEFINING_IDENTIFIER_LIST : [aliased] [constant]
2270 -- [NULL_EXCLUSION] SUBTYPE_INDICATION [:= EXPRESSION]
2271 -- [ASPECT_SPECIFICATIONS];
2272 -- | DEFINING_IDENTIFIER_LIST : [aliased] [constant]
2273 -- ACCESS_DEFINITION [:= EXPRESSION]
2274 -- [ASPECT_SPECIFICATIONS];
2275 -- | DEFINING_IDENTIFIER_LIST : [aliased] [constant]
2276 -- ARRAY_TYPE_DEFINITION [:= EXPRESSION]
2277 -- [ASPECT_SPECIFICATIONS];
2278 -- | SINGLE_TASK_DECLARATION
2279 -- | SINGLE_PROTECTED_DECLARATION
2280
2281 -- Note: aliased is not permitted in Ada 83 mode
2282
2283 -- The N_Object_Declaration node is only for the first two cases.
2284 -- Single task declaration is handled by P_Task (9.1)
2285 -- Single protected declaration is handled by P_protected (9.5)
2286
2287 -- Although the syntax allows multiple identifiers in the list, the
2288 -- semantics is as though successive declarations were given with
2289 -- identical type definition and expression components. To simplify
2290 -- semantic processing, the parser represents a multiple declaration
2291 -- case as a sequence of single declarations, using the More_Ids and
2292 -- Prev_Ids flags to preserve the original source form as described
2293 -- in the section on "Handling of Defining Identifier Lists".
2294
2295 -- The flag Has_Init_Expression is set if an initializing expression
2296 -- is present. Normally it is set if and only if Expression contains
2297 -- a non-empty value, but there is an exception to this. When the
2298 -- initializing expression is an aggregate which requires explicit
2299 -- assignments, the Expression field gets set to Empty, but this flag
2300 -- is still set, so we don't forget we had an initializing expression.
2301
2302 -- Note: if a range check is required for the initialization
2303 -- expression then the Do_Range_Check flag is set in the Expression,
2304 -- with the check being done against the type given by the object
2305 -- definition, which is also the Etype of the defining identifier.
2306
2307 -- Note: the contents of the Expression field must be ignored (i.e.
2308 -- treated as though it were Empty) if No_Initialization is set True.
2309
2310 -- Note: the back end places some restrictions on the form of the
2311 -- Expression field. If the object being declared is Atomic, then
2312 -- the Expression may not have the form of an aggregate (since this
2313 -- might cause the back end to generate separate assignments). In this
2314 -- case the front end must generate an extra temporary and initialize
2315 -- this temporary as required (the temporary itself is not atomic).
2316
2317 -- Note: there is not node kind for object definition. Instead, the
2318 -- corresponding field holds a subtype indication, an array type
2319 -- definition, or (Ada 2005, AI-406) an access definition.
2320
2321 -- N_Object_Declaration
2322 -- Sloc points to first identifier
2323 -- Defining_Identifier (Node1)
2324 -- Aliased_Present (Flag4) set if ALIASED appears
2325 -- Constant_Present (Flag17) set if CONSTANT appears
2326 -- Null_Exclusion_Present (Flag11)
2327 -- Object_Definition (Node4) subtype indic./array type def./access def.
2328 -- Expression (Node3) (set to Empty if not present)
2329 -- Handler_List_Entry (Node2-Sem)
2330 -- Corresponding_Generic_Association (Node5-Sem)
2331 -- More_Ids (Flag5) (set to False if no more identifiers in list)
2332 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
2333 -- No_Initialization (Flag13-Sem)
2334 -- Assignment_OK (Flag15-Sem)
2335 -- Exception_Junk (Flag8-Sem)
2336 -- Is_Subprogram_Descriptor (Flag16-Sem)
2337 -- Has_Init_Expression (Flag14)
2338
2339 -------------------------------------
2340 -- 3.3.1 Defining Identifier List --
2341 -------------------------------------
2342
2343 -- DEFINING_IDENTIFIER_LIST ::=
2344 -- DEFINING_IDENTIFIER {, DEFINING_IDENTIFIER}
2345
2346 -------------------------------
2347 -- 3.3.2 Number Declaration --
2348 -------------------------------
2349
2350 -- NUMBER_DECLARATION ::=
2351 -- DEFINING_IDENTIFIER_LIST : constant := static_EXPRESSION;
2352
2353 -- Although the syntax allows multiple identifiers in the list, the
2354 -- semantics is as though successive declarations were given with
2355 -- identical expressions. To simplify semantic processing, the parser
2356 -- represents a multiple declaration case as a sequence of single
2357 -- declarations, using the More_Ids and Prev_Ids flags to preserve
2358 -- the original source form as described in the section on "Handling
2359 -- of Defining Identifier Lists".
2360
2361 -- N_Number_Declaration
2362 -- Sloc points to first identifier
2363 -- Defining_Identifier (Node1)
2364 -- Expression (Node3)
2365 -- More_Ids (Flag5) (set to False if no more identifiers in list)
2366 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
2367
2368 ----------------------------------
2369 -- 3.4 Derived Type Definition --
2370 ----------------------------------
2371
2372 -- DERIVED_TYPE_DEFINITION ::=
2373 -- [abstract] [limited] new [NULL_EXCLUSION] parent_SUBTYPE_INDICATION
2374 -- [[and INTERFACE_LIST] RECORD_EXTENSION_PART]
2375
2376 -- Note: ABSTRACT, LIMITED and record extension part are not permitted
2377 -- in Ada 83 mode
2378
2379 -- Note: a record extension part is required if ABSTRACT is present
2380
2381 -- N_Derived_Type_Definition
2382 -- Sloc points to NEW
2383 -- Abstract_Present (Flag4)
2384 -- Null_Exclusion_Present (Flag11) (set to False if not present)
2385 -- Subtype_Indication (Node5)
2386 -- Record_Extension_Part (Node3) (set to Empty if not present)
2387 -- Limited_Present (Flag17)
2388 -- Task_Present (Flag5) set in task interfaces
2389 -- Protected_Present (Flag6) set in protected interfaces
2390 -- Synchronized_Present (Flag7) set in interfaces
2391 -- Interface_List (List2) (set to No_List if none)
2392 -- Interface_Present (Flag16) set in abstract interfaces
2393
2394 -- Note: Task_Present, Protected_Present, Synchronized_Present,
2395 -- Interface_List, and Interface_Present are used for abstract
2396 -- interfaces (see comments for INTERFACE_TYPE_DEFINITION).
2397
2398 ---------------------------
2399 -- 3.5 Range Constraint --
2400 ---------------------------
2401
2402 -- RANGE_CONSTRAINT ::= range RANGE
2403
2404 -- N_Range_Constraint
2405 -- Sloc points to RANGE
2406 -- Range_Expression (Node4)
2407
2408 ----------------
2409 -- 3.5 Range --
2410 ----------------
2411
2412 -- RANGE ::=
2413 -- RANGE_ATTRIBUTE_REFERENCE
2414 -- | SIMPLE_EXPRESSION .. SIMPLE_EXPRESSION
2415
2416 -- Note: the case of a range given as a range attribute reference
2417 -- appears directly in the tree as an attribute reference.
2418
2419 -- Note: the field name for a reference to a range is Range_Expression
2420 -- rather than Range, because range is a reserved keyword in Ada!
2421
2422 -- Note: the reason that this node has expression fields is that a
2423 -- range can appear as an operand of a membership test. The Etype
2424 -- field is the type of the range (we do NOT construct an implicit
2425 -- subtype to represent the range exactly).
2426
2427 -- N_Range
2428 -- Sloc points to ..
2429 -- Low_Bound (Node1)
2430 -- High_Bound (Node2)
2431 -- Includes_Infinities (Flag11)
2432 -- plus fields for expression
2433
2434 -- Note: if the range appears in a context, such as a subtype
2435 -- declaration, where range checks are required on one or both of
2436 -- the expression fields, then type conversion nodes are inserted
2437 -- to represent the required checks.
2438
2439 ----------------------------------------
2440 -- 3.5.1 Enumeration Type Definition --
2441 ----------------------------------------
2442
2443 -- ENUMERATION_TYPE_DEFINITION ::=
2444 -- (ENUMERATION_LITERAL_SPECIFICATION
2445 -- {, ENUMERATION_LITERAL_SPECIFICATION})
2446
2447 -- Note: the Literals field in the node described below is null for
2448 -- the case of the standard types CHARACTER and WIDE_CHARACTER, for
2449 -- which special processing handles these types as special cases.
2450
2451 -- N_Enumeration_Type_Definition
2452 -- Sloc points to left parenthesis
2453 -- Literals (List1) (Empty for CHARACTER or WIDE_CHARACTER)
2454 -- End_Label (Node4) (set to Empty if internally generated record)
2455
2456 ----------------------------------------------
2457 -- 3.5.1 Enumeration Literal Specification --
2458 ----------------------------------------------
2459
2460 -- ENUMERATION_LITERAL_SPECIFICATION ::=
2461 -- DEFINING_IDENTIFIER | DEFINING_CHARACTER_LITERAL
2462
2463 ---------------------------------------
2464 -- 3.5.1 Defining Character Literal --
2465 ---------------------------------------
2466
2467 -- DEFINING_CHARACTER_LITERAL ::= CHARACTER_LITERAL
2468
2469 -- A defining character literal is an entity, which has additional
2470 -- fields depending on the setting of the Ekind field. These
2471 -- additional fields are defined (and access subprograms declared)
2472 -- in package Einfo.
2473
2474 -- Note: N_Defining_Character_Literal is an extended node whose fields
2475 -- are deliberate layed out to match the layout of fields in an ordinary
2476 -- N_Character_Literal node allowing for easy alteration of a character
2477 -- literal node into a defining character literal node. For details, see
2478 -- Sinfo.CN.Change_Character_Literal_To_Defining_Character_Literal.
2479
2480 -- N_Defining_Character_Literal
2481 -- Sloc points to literal
2482 -- Chars (Name1) contains the Name_Id for the identifier
2483 -- Next_Entity (Node2-Sem)
2484 -- Scope (Node3-Sem)
2485 -- Etype (Node5-Sem)
2486
2487 ------------------------------------
2488 -- 3.5.4 Integer Type Definition --
2489 ------------------------------------
2490
2491 -- Note: there is an error in this rule in the latest version of the
2492 -- grammar, so we have retained the old rule pending clarification.
2493
2494 -- INTEGER_TYPE_DEFINITION ::=
2495 -- SIGNED_INTEGER_TYPE_DEFINITION
2496 -- | MODULAR_TYPE_DEFINITION
2497
2498 -------------------------------------------
2499 -- 3.5.4 Signed Integer Type Definition --
2500 -------------------------------------------
2501
2502 -- SIGNED_INTEGER_TYPE_DEFINITION ::=
2503 -- range static_SIMPLE_EXPRESSION .. static_SIMPLE_EXPRESSION
2504
2505 -- Note: the Low_Bound and High_Bound fields are set to Empty
2506 -- for integer types defined in package Standard.
2507
2508 -- N_Signed_Integer_Type_Definition
2509 -- Sloc points to RANGE
2510 -- Low_Bound (Node1)
2511 -- High_Bound (Node2)
2512
2513 ------------------------------------
2514 -- 3.5.4 Modular Type Definition --
2515 ------------------------------------
2516
2517 -- MODULAR_TYPE_DEFINITION ::= mod static_EXPRESSION
2518
2519 -- N_Modular_Type_Definition
2520 -- Sloc points to MOD
2521 -- Expression (Node3)
2522
2523 ---------------------------------
2524 -- 3.5.6 Real Type Definition --
2525 ---------------------------------
2526
2527 -- REAL_TYPE_DEFINITION ::=
2528 -- FLOATING_POINT_DEFINITION | FIXED_POINT_DEFINITION
2529
2530 --------------------------------------
2531 -- 3.5.7 Floating Point Definition --
2532 --------------------------------------
2533
2534 -- FLOATING_POINT_DEFINITION ::=
2535 -- digits static_SIMPLE_EXPRESSION [REAL_RANGE_SPECIFICATION]
2536
2537 -- Note: The Digits_Expression and Real_Range_Specifications fields
2538 -- are set to Empty for floating-point types declared in Standard.
2539
2540 -- N_Floating_Point_Definition
2541 -- Sloc points to DIGITS
2542 -- Digits_Expression (Node2)
2543 -- Real_Range_Specification (Node4) (set to Empty if not present)
2544
2545 -------------------------------------
2546 -- 3.5.7 Real Range Specification --
2547 -------------------------------------
2548
2549 -- REAL_RANGE_SPECIFICATION ::=
2550 -- range static_SIMPLE_EXPRESSION .. static_SIMPLE_EXPRESSION
2551
2552 -- N_Real_Range_Specification
2553 -- Sloc points to RANGE
2554 -- Low_Bound (Node1)
2555 -- High_Bound (Node2)
2556
2557 -----------------------------------
2558 -- 3.5.9 Fixed Point Definition --
2559 -----------------------------------
2560
2561 -- FIXED_POINT_DEFINITION ::=
2562 -- ORDINARY_FIXED_POINT_DEFINITION | DECIMAL_FIXED_POINT_DEFINITION
2563
2564 --------------------------------------------
2565 -- 3.5.9 Ordinary Fixed Point Definition --
2566 --------------------------------------------
2567
2568 -- ORDINARY_FIXED_POINT_DEFINITION ::=
2569 -- delta static_EXPRESSION REAL_RANGE_SPECIFICATION
2570
2571 -- Note: In Ada 83, the EXPRESSION must be a SIMPLE_EXPRESSION
2572
2573 -- N_Ordinary_Fixed_Point_Definition
2574 -- Sloc points to DELTA
2575 -- Delta_Expression (Node3)
2576 -- Real_Range_Specification (Node4)
2577
2578 -------------------------------------------
2579 -- 3.5.9 Decimal Fixed Point Definition --
2580 -------------------------------------------
2581
2582 -- DECIMAL_FIXED_POINT_DEFINITION ::=
2583 -- delta static_EXPRESSION
2584 -- digits static_EXPRESSION [REAL_RANGE_SPECIFICATION]
2585
2586 -- Note: decimal types are not permitted in Ada 83 mode
2587
2588 -- N_Decimal_Fixed_Point_Definition
2589 -- Sloc points to DELTA
2590 -- Delta_Expression (Node3)
2591 -- Digits_Expression (Node2)
2592 -- Real_Range_Specification (Node4) (set to Empty if not present)
2593
2594 ------------------------------
2595 -- 3.5.9 Digits Constraint --
2596 ------------------------------
2597
2598 -- DIGITS_CONSTRAINT ::=
2599 -- digits static_EXPRESSION [RANGE_CONSTRAINT]
2600
2601 -- Note: in Ada 83, the EXPRESSION must be a SIMPLE_EXPRESSION
2602 -- Note: in Ada 95, reduced accuracy subtypes are obsolescent
2603
2604 -- N_Digits_Constraint
2605 -- Sloc points to DIGITS
2606 -- Digits_Expression (Node2)
2607 -- Range_Constraint (Node4) (set to Empty if not present)
2608
2609 --------------------------------
2610 -- 3.6 Array Type Definition --
2611 --------------------------------
2612
2613 -- ARRAY_TYPE_DEFINITION ::=
2614 -- UNCONSTRAINED_ARRAY_DEFINITION | CONSTRAINED_ARRAY_DEFINITION
2615
2616 -----------------------------------------
2617 -- 3.6 Unconstrained Array Definition --
2618 -----------------------------------------
2619
2620 -- UNCONSTRAINED_ARRAY_DEFINITION ::=
2621 -- array (INDEX_SUBTYPE_DEFINITION {, INDEX_SUBTYPE_DEFINITION}) of
2622 -- COMPONENT_DEFINITION
2623
2624 -- Note: dimensionality of array is indicated by number of entries in
2625 -- the Subtype_Marks list, which has one entry for each dimension.
2626
2627 -- N_Unconstrained_Array_Definition
2628 -- Sloc points to ARRAY
2629 -- Subtype_Marks (List2)
2630 -- Component_Definition (Node4)
2631
2632 -----------------------------------
2633 -- 3.6 Index Subtype Definition --
2634 -----------------------------------
2635
2636 -- INDEX_SUBTYPE_DEFINITION ::= SUBTYPE_MARK range <>
2637
2638 -- There is no explicit node in the tree for an index subtype
2639 -- definition since the N_Unconstrained_Array_Definition node
2640 -- incorporates the type marks which appear in this context.
2641
2642 ---------------------------------------
2643 -- 3.6 Constrained Array Definition --
2644 ---------------------------------------
2645
2646 -- CONSTRAINED_ARRAY_DEFINITION ::=
2647 -- array (DISCRETE_SUBTYPE_DEFINITION
2648 -- {, DISCRETE_SUBTYPE_DEFINITION})
2649 -- of COMPONENT_DEFINITION
2650
2651 -- Note: dimensionality of array is indicated by number of entries
2652 -- in the Discrete_Subtype_Definitions list, which has one entry
2653 -- for each dimension.
2654
2655 -- N_Constrained_Array_Definition
2656 -- Sloc points to ARRAY
2657 -- Discrete_Subtype_Definitions (List2)
2658 -- Component_Definition (Node4)
2659
2660 --------------------------------------
2661 -- 3.6 Discrete Subtype Definition --
2662 --------------------------------------
2663
2664 -- DISCRETE_SUBTYPE_DEFINITION ::=
2665 -- discrete_SUBTYPE_INDICATION | RANGE
2666
2667 -------------------------------
2668 -- 3.6 Component Definition --
2669 -------------------------------
2670
2671 -- COMPONENT_DEFINITION ::=
2672 -- [aliased] [NULL_EXCLUSION] SUBTYPE_INDICATION | ACCESS_DEFINITION
2673
2674 -- Note: although the syntax does not permit a component definition to
2675 -- be an anonymous array (and the parser will diagnose such an attempt
2676 -- with an appropriate message), it is possible for anonymous arrays
2677 -- to appear as component definitions. The semantics and back end handle
2678 -- this case properly, and the expander in fact generates such cases.
2679 -- Access_Definition is an optional field that gives support to
2680 -- Ada 2005 (AI-230). The parser generates nodes that have either the
2681 -- Subtype_Indication field or else the Access_Definition field.
2682
2683 -- N_Component_Definition
2684 -- Sloc points to ALIASED, ACCESS or to first token of subtype mark
2685 -- Aliased_Present (Flag4)
2686 -- Null_Exclusion_Present (Flag11)
2687 -- Subtype_Indication (Node5) (set to Empty if not present)
2688 -- Access_Definition (Node3) (set to Empty if not present)
2689
2690 -----------------------------
2691 -- 3.6.1 Index Constraint --
2692 -----------------------------
2693
2694 -- INDEX_CONSTRAINT ::= (DISCRETE_RANGE {, DISCRETE_RANGE})
2695
2696 -- It is not in general possible to distinguish between discriminant
2697 -- constraints and index constraints at parse time, since a simple
2698 -- name could be either the subtype mark of a discrete range, or an
2699 -- expression in a discriminant association with no name. Either
2700 -- entry appears simply as the name, and the semantic parse must
2701 -- distinguish between the two cases. Thus we use a common tree
2702 -- node format for both of these constraint types.
2703
2704 -- See Discriminant_Constraint for format of node
2705
2706 ---------------------------
2707 -- 3.6.1 Discrete Range --
2708 ---------------------------
2709
2710 -- DISCRETE_RANGE ::= discrete_SUBTYPE_INDICATION | RANGE
2711
2712 ----------------------------
2713 -- 3.7 Discriminant Part --
2714 ----------------------------
2715
2716 -- DISCRIMINANT_PART ::=
2717 -- UNKNOWN_DISCRIMINANT_PART | KNOWN_DISCRIMINANT_PART
2718
2719 ------------------------------------
2720 -- 3.7 Unknown Discriminant Part --
2721 ------------------------------------
2722
2723 -- UNKNOWN_DISCRIMINANT_PART ::= (<>)
2724
2725 -- Note: unknown discriminant parts are not permitted in Ada 83 mode
2726
2727 -- There is no explicit node in the tree for an unknown discriminant
2728 -- part. Instead the Unknown_Discriminants_Present flag is set in the
2729 -- parent node.
2730
2731 ----------------------------------
2732 -- 3.7 Known Discriminant Part --
2733 ----------------------------------
2734
2735 -- KNOWN_DISCRIMINANT_PART ::=
2736 -- (DISCRIMINANT_SPECIFICATION {; DISCRIMINANT_SPECIFICATION})
2737
2738 -------------------------------------
2739 -- 3.7 Discriminant Specification --
2740 -------------------------------------
2741
2742 -- DISCRIMINANT_SPECIFICATION ::=
2743 -- DEFINING_IDENTIFIER_LIST : [NULL_EXCLUSION] SUBTYPE_MARK
2744 -- [:= DEFAULT_EXPRESSION]
2745 -- | DEFINING_IDENTIFIER_LIST : ACCESS_DEFINITION
2746 -- [:= DEFAULT_EXPRESSION]
2747
2748 -- Although the syntax allows multiple identifiers in the list, the
2749 -- semantics is as though successive specifications were given with
2750 -- identical type definition and expression components. To simplify
2751 -- semantic processing, the parser represents a multiple declaration
2752 -- case as a sequence of single specifications, using the More_Ids and
2753 -- Prev_Ids flags to preserve the original source form as described
2754 -- in the section on "Handling of Defining Identifier Lists".
2755
2756 -- N_Discriminant_Specification
2757 -- Sloc points to first identifier
2758 -- Defining_Identifier (Node1)
2759 -- Null_Exclusion_Present (Flag11)
2760 -- Discriminant_Type (Node5) subtype mark or access parameter definition
2761 -- Expression (Node3) (set to Empty if no default expression)
2762 -- More_Ids (Flag5) (set to False if no more identifiers in list)
2763 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
2764
2765 -----------------------------
2766 -- 3.7 Default Expression --
2767 -----------------------------
2768
2769 -- DEFAULT_EXPRESSION ::= EXPRESSION
2770
2771 ------------------------------------
2772 -- 3.7.1 Discriminant Constraint --
2773 ------------------------------------
2774
2775 -- DISCRIMINANT_CONSTRAINT ::=
2776 -- (DISCRIMINANT_ASSOCIATION {, DISCRIMINANT_ASSOCIATION})
2777
2778 -- It is not in general possible to distinguish between discriminant
2779 -- constraints and index constraints at parse time, since a simple
2780 -- name could be either the subtype mark of a discrete range, or an
2781 -- expression in a discriminant association with no name. Either
2782 -- entry appears simply as the name, and the semantic parse must
2783 -- distinguish between the two cases. Thus we use a common tree
2784 -- node format for both of these constraint types.
2785
2786 -- N_Index_Or_Discriminant_Constraint
2787 -- Sloc points to left paren
2788 -- Constraints (List1) points to list of discrete ranges or
2789 -- discriminant associations
2790
2791 -------------------------------------
2792 -- 3.7.1 Discriminant Association --
2793 -------------------------------------
2794
2795 -- DISCRIMINANT_ASSOCIATION ::=
2796 -- [discriminant_SELECTOR_NAME
2797 -- {| discriminant_SELECTOR_NAME} =>] EXPRESSION
2798
2799 -- Note: a discriminant association that has no selector name list
2800 -- appears directly as an expression in the tree.
2801
2802 -- N_Discriminant_Association
2803 -- Sloc points to first token of discriminant association
2804 -- Selector_Names (List1) (always non-empty, since if no selector
2805 -- names are present, this node is not used, see comment above)
2806 -- Expression (Node3)
2807
2808 ---------------------------------
2809 -- 3.8 Record Type Definition --
2810 ---------------------------------
2811
2812 -- RECORD_TYPE_DEFINITION ::=
2813 -- [[abstract] tagged] [limited] RECORD_DEFINITION
2814
2815 -- Note: ABSTRACT, TAGGED, LIMITED are not permitted in Ada 83 mode
2816
2817 -- There is no explicit node in the tree for a record type definition.
2818 -- Instead the flags for Tagged_Present and Limited_Present appear in
2819 -- the N_Record_Definition node for a record definition appearing in
2820 -- the context of a record type definition.
2821
2822 ----------------------------
2823 -- 3.8 Record Definition --
2824 ----------------------------
2825
2826 -- RECORD_DEFINITION ::=
2827 -- record
2828 -- COMPONENT_LIST
2829 -- end record
2830 -- | null record
2831
2832 -- Note: the Abstract_Present, Tagged_Present and Limited_Present
2833 -- flags appear only for a record definition appearing in a record
2834 -- type definition.
2835
2836 -- Note: the NULL RECORD case is not permitted in Ada 83
2837
2838 -- N_Record_Definition
2839 -- Sloc points to RECORD or NULL
2840 -- End_Label (Node4) (set to Empty if internally generated record)
2841 -- Abstract_Present (Flag4)
2842 -- Tagged_Present (Flag15)
2843 -- Limited_Present (Flag17)
2844 -- Component_List (Node1) empty in null record case
2845 -- Null_Present (Flag13) set in null record case
2846 -- Task_Present (Flag5) set in task interfaces
2847 -- Protected_Present (Flag6) set in protected interfaces
2848 -- Synchronized_Present (Flag7) set in interfaces
2849 -- Interface_Present (Flag16) set in abstract interfaces
2850 -- Interface_List (List2) (set to No_List if none)
2851
2852 -- Note: Task_Present, Protected_Present, Synchronized _Present,
2853 -- Interface_List and Interface_Present are used for abstract
2854 -- interfaces (see comments for INTERFACE_TYPE_DEFINITION).
2855
2856 -------------------------
2857 -- 3.8 Component List --
2858 -------------------------
2859
2860 -- COMPONENT_LIST ::=
2861 -- COMPONENT_ITEM {COMPONENT_ITEM}
2862 -- | {COMPONENT_ITEM} VARIANT_PART
2863 -- | null;
2864
2865 -- N_Component_List
2866 -- Sloc points to first token of component list
2867 -- Component_Items (List3)
2868 -- Variant_Part (Node4) (set to Empty if no variant part)
2869 -- Null_Present (Flag13)
2870
2871 -------------------------
2872 -- 3.8 Component Item --
2873 -------------------------
2874
2875 -- COMPONENT_ITEM ::= COMPONENT_DECLARATION | REPRESENTATION_CLAUSE
2876
2877 -- Note: A component item can also be a pragma, and in the tree
2878 -- that is obtained after semantic processing, a component item
2879 -- can be an N_Null node resulting from a non-recognized pragma.
2880
2881 --------------------------------
2882 -- 3.8 Component Declaration --
2883 --------------------------------
2884
2885 -- COMPONENT_DECLARATION ::=
2886 -- DEFINING_IDENTIFIER_LIST : COMPONENT_DEFINITION
2887 -- [:= DEFAULT_EXPRESSION]
2888 -- [ASPECT_SPECIFICATIONS];
2889
2890 -- Note: although the syntax does not permit a component definition to
2891 -- be an anonymous array (and the parser will diagnose such an attempt
2892 -- with an appropriate message), it is possible for anonymous arrays
2893 -- to appear as component definitions. The semantics and back end handle
2894 -- this case properly, and the expander in fact generates such cases.
2895
2896 -- Although the syntax allows multiple identifiers in the list, the
2897 -- semantics is as though successive declarations were given with the
2898 -- same component definition and expression components. To simplify
2899 -- semantic processing, the parser represents a multiple declaration
2900 -- case as a sequence of single declarations, using the More_Ids and
2901 -- Prev_Ids flags to preserve the original source form as described
2902 -- in the section on "Handling of Defining Identifier Lists".
2903
2904 -- N_Component_Declaration
2905 -- Sloc points to first identifier
2906 -- Defining_Identifier (Node1)
2907 -- Component_Definition (Node4)
2908 -- Expression (Node3) (set to Empty if no default expression)
2909 -- More_Ids (Flag5) (set to False if no more identifiers in list)
2910 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
2911
2912 -------------------------
2913 -- 3.8.1 Variant Part --
2914 -------------------------
2915
2916 -- VARIANT_PART ::=
2917 -- case discriminant_DIRECT_NAME is
2918 -- VARIANT
2919 -- {VARIANT}
2920 -- end case;
2921
2922 -- Note: the variants list can contain pragmas as well as variants.
2923 -- In a properly formed program there is at least one variant.
2924
2925 -- N_Variant_Part
2926 -- Sloc points to CASE
2927 -- Name (Node2)
2928 -- Variants (List1)
2929
2930 --------------------
2931 -- 3.8.1 Variant --
2932 --------------------
2933
2934 -- VARIANT ::=
2935 -- when DISCRETE_CHOICE_LIST =>
2936 -- COMPONENT_LIST
2937
2938 -- N_Variant
2939 -- Sloc points to WHEN
2940 -- Discrete_Choices (List4)
2941 -- Component_List (Node1)
2942 -- Enclosing_Variant (Node2-Sem)
2943 -- Present_Expr (Uint3-Sem)
2944 -- Dcheck_Function (Node5-Sem)
2945
2946 ---------------------------------
2947 -- 3.8.1 Discrete Choice List --
2948 ---------------------------------
2949
2950 -- DISCRETE_CHOICE_LIST ::= DISCRETE_CHOICE {| DISCRETE_CHOICE}
2951
2952 ----------------------------
2953 -- 3.8.1 Discrete Choice --
2954 ----------------------------
2955
2956 -- DISCRETE_CHOICE ::= EXPRESSION | DISCRETE_RANGE | others
2957
2958 -- Note: in Ada 83 mode, the expression must be a simple expression
2959
2960 -- The only choice that appears explicitly is the OTHERS choice, as
2961 -- defined here. Other cases of discrete choice (expression and
2962 -- discrete range) appear directly. This production is also used
2963 -- for the OTHERS possibility of an exception choice.
2964
2965 -- Note: in accordance with the syntax, the parser does not check that
2966 -- OTHERS appears at the end on its own in a choice list context. This
2967 -- is a semantic check.
2968
2969 -- N_Others_Choice
2970 -- Sloc points to OTHERS
2971 -- Others_Discrete_Choices (List1-Sem)
2972 -- All_Others (Flag11-Sem)
2973
2974 ----------------------------------
2975 -- 3.9.1 Record Extension Part --
2976 ----------------------------------
2977
2978 -- RECORD_EXTENSION_PART ::= with RECORD_DEFINITION
2979
2980 -- Note: record extension parts are not permitted in Ada 83 mode
2981
2982 --------------------------------------
2983 -- 3.9.4 Interface Type Definition --
2984 --------------------------------------
2985
2986 -- INTERFACE_TYPE_DEFINITION ::=
2987 -- [limited | task | protected | synchronized]
2988 -- interface [interface_list]
2989
2990 -- Note: Interfaces are implemented with N_Record_Definition and
2991 -- N_Derived_Type_Definition nodes because most of the support
2992 -- for the analysis of abstract types has been reused to
2993 -- analyze abstract interfaces.
2994
2995 ----------------------------------
2996 -- 3.10 Access Type Definition --
2997 ----------------------------------
2998
2999 -- ACCESS_TYPE_DEFINITION ::=
3000 -- ACCESS_TO_OBJECT_DEFINITION
3001 -- | ACCESS_TO_SUBPROGRAM_DEFINITION
3002
3003 --------------------------
3004 -- 3.10 Null Exclusion --
3005 --------------------------
3006
3007 -- NULL_EXCLUSION ::= not null
3008
3009 ---------------------------------------
3010 -- 3.10 Access To Object Definition --
3011 ---------------------------------------
3012
3013 -- ACCESS_TO_OBJECT_DEFINITION ::=
3014 -- [NULL_EXCLUSION] access [GENERAL_ACCESS_MODIFIER]
3015 -- SUBTYPE_INDICATION
3016
3017 -- N_Access_To_Object_Definition
3018 -- Sloc points to ACCESS
3019 -- All_Present (Flag15)
3020 -- Null_Exclusion_Present (Flag11)
3021 -- Subtype_Indication (Node5)
3022 -- Constant_Present (Flag17)
3023
3024 -----------------------------------
3025 -- 3.10 General Access Modifier --
3026 -----------------------------------
3027
3028 -- GENERAL_ACCESS_MODIFIER ::= all | constant
3029
3030 -- Note: general access modifiers are not permitted in Ada 83 mode
3031
3032 -- There is no explicit node in the tree for general access modifier.
3033 -- Instead the All_Present or Constant_Present flags are set in the
3034 -- parent node.
3035
3036 -------------------------------------------
3037 -- 3.10 Access To Subprogram Definition --
3038 -------------------------------------------
3039
3040 -- ACCESS_TO_SUBPROGRAM_DEFINITION
3041 -- [NULL_EXCLUSION] access [protected] procedure PARAMETER_PROFILE
3042 -- | [NULL_EXCLUSION] access [protected] function
3043 -- PARAMETER_AND_RESULT_PROFILE
3044
3045 -- Note: access to subprograms are not permitted in Ada 83 mode
3046
3047 -- N_Access_Function_Definition
3048 -- Sloc points to ACCESS
3049 -- Null_Exclusion_Present (Flag11)
3050 -- Null_Exclusion_In_Return_Present (Flag14)
3051 -- Protected_Present (Flag6)
3052 -- Parameter_Specifications (List3) (set to No_List if no formal part)
3053 -- Result_Definition (Node4) result subtype (subtype mark or access def)
3054
3055 -- N_Access_Procedure_Definition
3056 -- Sloc points to ACCESS
3057 -- Null_Exclusion_Present (Flag11)
3058 -- Protected_Present (Flag6)
3059 -- Parameter_Specifications (List3) (set to No_List if no formal part)
3060
3061 -----------------------------
3062 -- 3.10 Access Definition --
3063 -----------------------------
3064
3065 -- ACCESS_DEFINITION ::=
3066 -- [NULL_EXCLUSION] access [GENERAL_ACCESS_MODIFIER] SUBTYPE_MARK
3067 -- | ACCESS_TO_SUBPROGRAM_DEFINITION
3068
3069 -- Note: access to subprograms are an Ada 2005 (AI-254) extension
3070
3071 -- N_Access_Definition
3072 -- Sloc points to ACCESS
3073 -- Null_Exclusion_Present (Flag11)
3074 -- All_Present (Flag15)
3075 -- Constant_Present (Flag17)
3076 -- Subtype_Mark (Node4)
3077 -- Access_To_Subprogram_Definition (Node3) (set to Empty if not present)
3078
3079 -----------------------------------------
3080 -- 3.10.1 Incomplete Type Declaration --
3081 -----------------------------------------
3082
3083 -- INCOMPLETE_TYPE_DECLARATION ::=
3084 -- type DEFINING_IDENTIFIER [DISCRIMINANT_PART] [IS TAGGED];
3085
3086 -- N_Incomplete_Type_Declaration
3087 -- Sloc points to TYPE
3088 -- Defining_Identifier (Node1)
3089 -- Discriminant_Specifications (List4) (set to No_List if no
3090 -- discriminant part, or if the discriminant part is an
3091 -- unknown discriminant part)
3092 -- Unknown_Discriminants_Present (Flag13) set if (<>) discriminant
3093 -- Tagged_Present (Flag15)
3094
3095 ----------------------------
3096 -- 3.11 Declarative Part --
3097 ----------------------------
3098
3099 -- DECLARATIVE_PART ::= {DECLARATIVE_ITEM}
3100
3101 -- Note: although the parser enforces the syntactic requirement that
3102 -- a declarative part can contain only declarations, the semantic
3103 -- processing may add statements to the list of actions in a
3104 -- declarative part, so the code generator should be prepared
3105 -- to accept a statement in this position.
3106
3107 ----------------------------
3108 -- 3.11 Declarative Item --
3109 ----------------------------
3110
3111 -- DECLARATIVE_ITEM ::= BASIC_DECLARATIVE_ITEM | BODY
3112
3113 ----------------------------------
3114 -- 3.11 Basic Declarative Item --
3115 ----------------------------------
3116
3117 -- BASIC_DECLARATIVE_ITEM ::=
3118 -- BASIC_DECLARATION | REPRESENTATION_CLAUSE | USE_CLAUSE
3119
3120 ----------------
3121 -- 3.11 Body --
3122 ----------------
3123
3124 -- BODY ::= PROPER_BODY | BODY_STUB
3125
3126 -----------------------
3127 -- 3.11 Proper Body --
3128 -----------------------
3129
3130 -- PROPER_BODY ::=
3131 -- SUBPROGRAM_BODY | PACKAGE_BODY | TASK_BODY | PROTECTED_BODY
3132
3133 ---------------
3134 -- 4.1 Name --
3135 ---------------
3136
3137 -- NAME ::=
3138 -- DIRECT_NAME | EXPLICIT_DEREFERENCE
3139 -- | INDEXED_COMPONENT | SLICE
3140 -- | SELECTED_COMPONENT | ATTRIBUTE_REFERENCE
3141 -- | TYPE_CONVERSION | FUNCTION_CALL
3142 -- | CHARACTER_LITERAL
3143
3144 ----------------------
3145 -- 4.1 Direct Name --
3146 ----------------------
3147
3148 -- DIRECT_NAME ::= IDENTIFIER | OPERATOR_SYMBOL
3149
3150 -----------------
3151 -- 4.1 Prefix --
3152 -----------------
3153
3154 -- PREFIX ::= NAME | IMPLICIT_DEREFERENCE
3155
3156 -------------------------------
3157 -- 4.1 Explicit Dereference --
3158 -------------------------------
3159
3160 -- EXPLICIT_DEREFERENCE ::= NAME . all
3161
3162 -- N_Explicit_Dereference
3163 -- Sloc points to ALL
3164 -- Prefix (Node3)
3165 -- Actual_Designated_Subtype (Node4-Sem)
3166 -- plus fields for expression
3167
3168 -------------------------------
3169 -- 4.1 Implicit Dereference --
3170 -------------------------------
3171
3172 -- IMPLICIT_DEREFERENCE ::= NAME
3173
3174 ------------------------------
3175 -- 4.1.1 Indexed Component --
3176 ------------------------------
3177
3178 -- INDEXED_COMPONENT ::= PREFIX (EXPRESSION {, EXPRESSION})
3179
3180 -- Note: the parser may generate this node in some situations where it
3181 -- should be a function call. The semantic pass must correct this
3182 -- misidentification (which is inevitable at the parser level).
3183
3184 -- N_Indexed_Component
3185 -- Sloc contains a copy of the Sloc value of the Prefix
3186 -- Prefix (Node3)
3187 -- Expressions (List1)
3188 -- plus fields for expression
3189
3190 -- Note: if any of the subscripts requires a range check, then the
3191 -- Do_Range_Check flag is set on the corresponding expression, with
3192 -- the index type being determined from the type of the Prefix, which
3193 -- references the array being indexed.
3194
3195 -- Note: in a fully analyzed and expanded indexed component node, and
3196 -- hence in any such node that gigi sees, if the prefix is an access
3197 -- type, then an explicit dereference operation has been inserted.
3198
3199 ------------------
3200 -- 4.1.2 Slice --
3201 ------------------
3202
3203 -- SLICE ::= PREFIX (DISCRETE_RANGE)
3204
3205 -- Note: an implicit subtype is created to describe the resulting
3206 -- type, so that the bounds of this type are the bounds of the slice.
3207
3208 -- N_Slice
3209 -- Sloc points to first token of prefix
3210 -- Prefix (Node3)
3211 -- Discrete_Range (Node4)
3212 -- plus fields for expression
3213
3214 -------------------------------
3215 -- 4.1.3 Selected Component --
3216 -------------------------------
3217
3218 -- SELECTED_COMPONENT ::= PREFIX . SELECTOR_NAME
3219
3220 -- Note: selected components that are semantically expanded names get
3221 -- changed during semantic processing into the separate N_Expanded_Name
3222 -- node. See description of this node in the section on semantic nodes.
3223
3224 -- N_Selected_Component
3225 -- Sloc points to period
3226 -- Prefix (Node3)
3227 -- Selector_Name (Node2)
3228 -- Associated_Node (Node4-Sem)
3229 -- Do_Discriminant_Check (Flag13-Sem)
3230 -- Is_In_Discriminant_Check (Flag11-Sem)
3231 -- plus fields for expression
3232
3233 --------------------------
3234 -- 4.1.3 Selector Name --
3235 --------------------------
3236
3237 -- SELECTOR_NAME ::= IDENTIFIER | CHARACTER_LITERAL | OPERATOR_SYMBOL
3238
3239 --------------------------------
3240 -- 4.1.4 Attribute Reference --
3241 --------------------------------
3242
3243 -- ATTRIBUTE_REFERENCE ::= PREFIX ' ATTRIBUTE_DESIGNATOR
3244
3245 -- Note: the syntax is quite ambiguous at this point. Consider:
3246
3247 -- A'Length (X) X is part of the attribute designator
3248 -- A'Pos (X) X is an explicit actual parameter of function A'Pos
3249 -- A'Class (X) X is the expression of a type conversion
3250
3251 -- It would be possible for the parser to distinguish these cases
3252 -- by looking at the attribute identifier. However, that would mean
3253 -- more work in introducing new implementation defined attributes,
3254 -- and also it would mean that special processing for attributes
3255 -- would be scattered around, instead of being centralized in the
3256 -- semantic routine that handles an N_Attribute_Reference node.
3257 -- Consequently, the parser in all the above cases stores the
3258 -- expression (X in these examples) as a single element list in
3259 -- in the Expressions field of the N_Attribute_Reference node.
3260
3261 -- Similarly, for attributes like Max which take two arguments,
3262 -- we store the two arguments as a two element list in the
3263 -- Expressions field. Of course it is clear at parse time that
3264 -- this case is really a function call with an attribute as the
3265 -- prefix, but it turns out to be convenient to handle the two
3266 -- argument case in a similar manner to the one argument case,
3267 -- and indeed in general the parser will accept any number of
3268 -- expressions in this position and store them as a list in the
3269 -- attribute reference node. This allows for future addition of
3270 -- attributes that take more than two arguments.
3271
3272 -- Note: named associates are not permitted in function calls where
3273 -- the function is an attribute (see RM 6.4(3)) so it is legitimate
3274 -- to skip the normal subprogram argument processing.
3275
3276 -- Note: for the attributes whose designators are technically keywords,
3277 -- i.e. digits, access, delta, range, the Attribute_Name field contains
3278 -- the corresponding name, even though no identifier is involved.
3279
3280 -- Note: the generated code may contain stream attributes applied to
3281 -- limited types for which no stream routines exist officially. In such
3282 -- case, the result is to use the stream attribute for the underlying
3283 -- full type, or in the case of a protected type, the components
3284 -- (including any discriminants) are merely streamed in order.
3285
3286 -- See Exp_Attr for a complete description of which attributes are
3287 -- passed onto Gigi, and which are handled entirely by the front end.
3288
3289 -- Gigi restriction: For the Pos attribute, the prefix cannot be
3290 -- a non-standard enumeration type or a nonzero/zero semantics
3291 -- boolean type, so the value is simply the stored representation.
3292
3293 -- Gigi requirement: For the Mechanism_Code attribute, if the prefix
3294 -- references a subprogram that is a renaming, then the front end must
3295 -- rewrite the attribute to refer directly to the renamed entity.
3296
3297 -- Note: In generated code, the Address and Unrestricted_Access
3298 -- attributes can be applied to any expression, and the meaning is
3299 -- to create an object containing the value (the object is in the
3300 -- current stack frame), and pass the address of this value. If the
3301 -- Must_Be_Byte_Aligned flag is set, then the object whose address
3302 -- is taken must be on a byte (storage unit) boundary, and if it is
3303 -- not (or may not be), then the generated code must create a copy
3304 -- that is byte aligned, and pass the address of this copy.
3305
3306 -- N_Attribute_Reference
3307 -- Sloc points to apostrophe
3308 -- Prefix (Node3)
3309 -- Attribute_Name (Name2) identifier name from attribute designator
3310 -- Expressions (List1) (set to No_List if no associated expressions)
3311 -- Entity (Node4-Sem) used if the attribute yields a type
3312 -- Associated_Node (Node4-Sem)
3313 -- Do_Overflow_Check (Flag17-Sem)
3314 -- Redundant_Use (Flag13-Sem)
3315 -- Must_Be_Byte_Aligned (Flag14)
3316 -- plus fields for expression
3317
3318 ---------------------------------
3319 -- 4.1.4 Attribute Designator --
3320 ---------------------------------
3321
3322 -- ATTRIBUTE_DESIGNATOR ::=
3323 -- IDENTIFIER [(static_EXPRESSION)]
3324 -- | access | delta | digits
3325
3326 -- There is no explicit node in the tree for an attribute designator.
3327 -- Instead the Attribute_Name and Expressions fields of the parent
3328 -- node (N_Attribute_Reference node) hold the information.
3329
3330 -- Note: if ACCESS, DELTA or DIGITS appears in an attribute
3331 -- designator, then they are treated as identifiers internally
3332 -- rather than the keywords of the same name.
3333
3334 --------------------------------------
3335 -- 4.1.4 Range Attribute Reference --
3336 --------------------------------------
3337
3338 -- RANGE_ATTRIBUTE_REFERENCE ::= PREFIX ' RANGE_ATTRIBUTE_DESIGNATOR
3339
3340 -- A range attribute reference is represented in the tree using the
3341 -- normal N_Attribute_Reference node.
3342
3343 ---------------------------------------
3344 -- 4.1.4 Range Attribute Designator --
3345 ---------------------------------------
3346
3347 -- RANGE_ATTRIBUTE_DESIGNATOR ::= Range [(static_EXPRESSION)]
3348
3349 -- A range attribute designator is represented in the tree using the
3350 -- normal N_Attribute_Reference node.
3351
3352 --------------------
3353 -- 4.3 Aggregate --
3354 --------------------
3355
3356 -- AGGREGATE ::=
3357 -- RECORD_AGGREGATE | EXTENSION_AGGREGATE | ARRAY_AGGREGATE
3358
3359 -----------------------------
3360 -- 4.3.1 Record Aggregate --
3361 -----------------------------
3362
3363 -- RECORD_AGGREGATE ::= (RECORD_COMPONENT_ASSOCIATION_LIST)
3364
3365 -- N_Aggregate
3366 -- Sloc points to left parenthesis
3367 -- Expressions (List1) (set to No_List if none or null record case)
3368 -- Component_Associations (List2) (set to No_List if none)
3369 -- Null_Record_Present (Flag17)
3370 -- Aggregate_Bounds (Node3-Sem)
3371 -- Associated_Node (Node4-Sem)
3372 -- Static_Processing_OK (Flag4-Sem)
3373 -- Compile_Time_Known_Aggregate (Flag18-Sem)
3374 -- Expansion_Delayed (Flag11-Sem)
3375 -- Has_Self_Reference (Flag13-Sem)
3376 -- plus fields for expression
3377
3378 -- Note: this structure is used for both record and array aggregates
3379 -- since the two cases are not separable by the parser. The parser
3380 -- makes no attempt to enforce consistency here, so it is up to the
3381 -- semantic phase to make sure that the aggregate is consistent (i.e.
3382 -- that it is not a "half-and-half" case that mixes record and array
3383 -- syntax. In particular, for a record aggregate, the expressions
3384 -- field will be set if there are positional associations.
3385
3386 -- Note: N_Aggregate is not used for all aggregates; in particular,
3387 -- there is a separate node kind for extension aggregates.
3388
3389 -- Note: gigi/gcc can handle array aggregates correctly providing that
3390 -- they are entirely positional, and the array subtype involved has a
3391 -- known at compile time length and is not bit packed, or a convention
3392 -- Fortran array with more than one dimension. If these conditions
3393 -- are not met, then the front end must translate the aggregate into
3394 -- an appropriate set of assignments into a temporary.
3395
3396 -- Note: for the record aggregate case, gigi/gcc can handle all cases of
3397 -- record aggregates, including those for packed, and rep-claused
3398 -- records, and also variant records, providing that there are no
3399 -- variable length fields whose size is not known at compile time, and
3400 -- providing that the aggregate is presented in fully named form.
3401
3402 ----------------------------------------------
3403 -- 4.3.1 Record Component Association List --
3404 ----------------------------------------------
3405
3406 -- RECORD_COMPONENT_ASSOCIATION_LIST ::=
3407 -- RECORD_COMPONENT_ASSOCIATION {, RECORD_COMPONENT_ASSOCIATION}
3408 -- | null record
3409
3410 -- There is no explicit node in the tree for a record component
3411 -- association list. Instead the Null_Record_Present flag is set in
3412 -- the parent node for the NULL RECORD case.
3413
3414 ------------------------------------------------------
3415 -- 4.3.1 Record Component Association (also 4.3.3) --
3416 ------------------------------------------------------
3417
3418 -- RECORD_COMPONENT_ASSOCIATION ::=
3419 -- [COMPONENT_CHOICE_LIST =>] EXPRESSION
3420
3421 -- N_Component_Association
3422 -- Sloc points to first selector name
3423 -- Choices (List1)
3424 -- Loop_Actions (List2-Sem)
3425 -- Expression (Node3)
3426 -- Box_Present (Flag15)
3427 -- Inherited_Discriminant (Flag13)
3428
3429 -- Note: this structure is used for both record component associations
3430 -- and array component associations, since the two cases aren't always
3431 -- separable by the parser. The choices list may represent either a
3432 -- list of selector names in the record aggregate case, or a list of
3433 -- discrete choices in the array aggregate case or an N_Others_Choice
3434 -- node (which appears as a singleton list). Box_Present gives support
3435 -- to Ada 2005 (AI-287).
3436
3437 ----------------------------------
3438 -- 4.3.1 Component Choice List --
3439 ----------------------------------
3440
3441 -- COMPONENT_CHOICE_LIST ::=
3442 -- component_SELECTOR_NAME {| component_SELECTOR_NAME}
3443 -- | others
3444
3445 -- The entries of a component choice list appear in the Choices list of
3446 -- the associated N_Component_Association, as either selector names, or
3447 -- as an N_Others_Choice node.
3448
3449 --------------------------------
3450 -- 4.3.2 Extension Aggregate --
3451 --------------------------------
3452
3453 -- EXTENSION_AGGREGATE ::=
3454 -- (ANCESTOR_PART with RECORD_COMPONENT_ASSOCIATION_LIST)
3455
3456 -- Note: extension aggregates are not permitted in Ada 83 mode
3457
3458 -- N_Extension_Aggregate
3459 -- Sloc points to left parenthesis
3460 -- Ancestor_Part (Node3)
3461 -- Associated_Node (Node4-Sem)
3462 -- Expressions (List1) (set to No_List if none or null record case)
3463 -- Component_Associations (List2) (set to No_List if none)
3464 -- Null_Record_Present (Flag17)
3465 -- Expansion_Delayed (Flag11-Sem)
3466 -- Has_Self_Reference (Flag13-Sem)
3467 -- plus fields for expression
3468
3469 --------------------------
3470 -- 4.3.2 Ancestor Part --
3471 --------------------------
3472
3473 -- ANCESTOR_PART ::= EXPRESSION | SUBTYPE_MARK
3474
3475 ----------------------------
3476 -- 4.3.3 Array Aggregate --
3477 ----------------------------
3478
3479 -- ARRAY_AGGREGATE ::=
3480 -- POSITIONAL_ARRAY_AGGREGATE | NAMED_ARRAY_AGGREGATE
3481
3482 ---------------------------------------
3483 -- 4.3.3 Positional Array Aggregate --
3484 ---------------------------------------
3485
3486 -- POSITIONAL_ARRAY_AGGREGATE ::=
3487 -- (EXPRESSION, EXPRESSION {, EXPRESSION})
3488 -- | (EXPRESSION {, EXPRESSION}, others => EXPRESSION)
3489
3490 -- See Record_Aggregate (4.3.1) for node structure
3491
3492 ----------------------------------
3493 -- 4.3.3 Named Array Aggregate --
3494 ----------------------------------
3495
3496 -- NAMED_ARRAY_AGGREGATE ::=
3497 -- | (ARRAY_COMPONENT_ASSOCIATION {, ARRAY_COMPONENT_ASSOCIATION})
3498
3499 -- See Record_Aggregate (4.3.1) for node structure
3500
3501 ----------------------------------------
3502 -- 4.3.3 Array Component Association --
3503 ----------------------------------------
3504
3505 -- ARRAY_COMPONENT_ASSOCIATION ::=
3506 -- DISCRETE_CHOICE_LIST => EXPRESSION
3507
3508 -- See Record_Component_Association (4.3.1) for node structure
3509
3510 --------------------------------------------------
3511 -- 4.4 Expression/Relation/Term/Factor/Primary --
3512 --------------------------------------------------
3513
3514 -- EXPRESSION ::=
3515 -- RELATION {and RELATION} | RELATION {and then RELATION}
3516 -- | RELATION {or RELATION} | RELATION {or else RELATION}
3517 -- | RELATION {xor RELATION}
3518
3519 -- RELATION ::=
3520 -- SIMPLE_EXPRESSION [RELATIONAL_OPERATOR SIMPLE_EXPRESSION]
3521 -- | SIMPLE_EXPRESSION [not] in RANGE
3522 -- | SIMPLE_EXPRESSION [not] in SUBTYPE_MARK
3523
3524 -- SIMPLE_EXPRESSION ::=
3525 -- [UNARY_ADDING_OPERATOR] TERM {BINARY_ADDING_OPERATOR TERM}
3526
3527 -- TERM ::= FACTOR {MULTIPLYING_OPERATOR FACTOR}
3528
3529 -- FACTOR ::= PRIMARY [** PRIMARY] | abs PRIMARY | not PRIMARY
3530
3531 -- No nodes are generated for any of these constructs. Instead, the
3532 -- node for the operator appears directly. When we refer to an
3533 -- expression in this description, we mean any of the possible
3534 -- constituent components of an expression (e.g. identifier is
3535 -- an example of an expression).
3536
3537 ------------------
3538 -- 4.4 Primary --
3539 ------------------
3540
3541 -- PRIMARY ::=
3542 -- NUMERIC_LITERAL | null
3543 -- | STRING_LITERAL | AGGREGATE
3544 -- | NAME | QUALIFIED_EXPRESSION
3545 -- | ALLOCATOR | (EXPRESSION)
3546
3547 -- Usually there is no explicit node in the tree for primary. Instead
3548 -- the constituent (e.g. AGGREGATE) appears directly. There are two
3549 -- exceptions. First, there is an explicit node for a null primary.
3550
3551 -- N_Null
3552 -- Sloc points to NULL
3553 -- plus fields for expression
3554
3555 -- Second, the case of (EXPRESSION) is handled specially. Ada requires
3556 -- that the parser keep track of which subexpressions are enclosed
3557 -- in parentheses, and how many levels of parentheses are used. This
3558 -- information is required for optimization purposes, and also for
3559 -- some semantic checks (e.g. (((1))) in a procedure spec does not
3560 -- conform with ((((1)))) in the body).
3561
3562 -- The parentheses are recorded by keeping a Paren_Count field in every
3563 -- subexpression node (it is actually present in all nodes, but only
3564 -- used in subexpression nodes). This count records the number of
3565 -- levels of parentheses. If the number of levels in the source exceeds
3566 -- the maximum accommodated by this count, then the count is simply left
3567 -- at the maximum value. This means that there are some pathological
3568 -- cases of failure to detect conformance failures (e.g. an expression
3569 -- with 500 levels of parens will conform with one with 501 levels),
3570 -- but we do not need to lose sleep over this.
3571
3572 -- Historical note: in versions of GNAT prior to 1.75, there was a node
3573 -- type N_Parenthesized_Expression used to accurately record unlimited
3574 -- numbers of levels of parentheses. However, it turned out to be a
3575 -- real nuisance to have to take into account the possible presence of
3576 -- this node during semantic analysis, since basically parentheses have
3577 -- zero relevance to semantic analysis.
3578
3579 -- Note: the level of parentheses always present in things like
3580 -- aggregates does not count, only the parentheses in the primary
3581 -- (EXPRESSION) affect the setting of the Paren_Count field.
3582
3583 -- 2nd Note: the contents of the Expression field must be ignored (i.e.
3584 -- treated as though it were Empty) if No_Initialization is set True.
3585
3586 --------------------------------------
3587 -- 4.5 Short Circuit Control Forms --
3588 --------------------------------------
3589
3590 -- EXPRESSION ::=
3591 -- RELATION {and then RELATION} | RELATION {or else RELATION}
3592
3593 -- Gigi restriction: For both these control forms, the operand and
3594 -- result types are always Standard.Boolean. The expander inserts the
3595 -- required conversion operations where needed to ensure this is the
3596 -- case.
3597
3598 -- N_And_Then
3599 -- Sloc points to AND of AND THEN
3600 -- Left_Opnd (Node2)
3601 -- Right_Opnd (Node3)
3602 -- Actions (List1-Sem)
3603 -- plus fields for expression
3604
3605 -- N_Or_Else
3606 -- Sloc points to OR of OR ELSE
3607 -- Left_Opnd (Node2)
3608 -- Right_Opnd (Node3)
3609 -- Actions (List1-Sem)
3610 -- plus fields for expression
3611
3612 -- Note: The Actions field is used to hold actions associated with
3613 -- the right hand operand. These have to be treated specially since
3614 -- they are not unconditionally executed. See Insert_Actions for a
3615 -- more detailed description of how these actions are handled.
3616
3617 ---------------------------
3618 -- 4.5 Membership Tests --
3619 ---------------------------
3620
3621 -- RELATION ::=
3622 -- SIMPLE_EXPRESSION [not] in RANGE
3623 -- | SIMPLE_EXPRESSION [not] in SUBTYPE_MARK
3624
3625 -- Note: although the grammar above allows only a range or a subtype
3626 -- mark, the parser in fact will accept any simple expression in place
3627 -- of a subtype mark. This means that the semantic analyzer must be able
3628 -- to deal with, and diagnose a simple expression other than a name for
3629 -- the right operand. This simplifies error recovery in the parser.
3630
3631 -- If extensions are enabled, the grammar is as follows:
3632
3633 -- RELATION ::=
3634 -- SIMPLE_EXPRESSION [not] in SET_ALTERNATIVE {| SET_ALTERNATIVE}
3635
3636 -- SET_ALTERNATIVE ::= RANGE | SUBTYPE_MARK
3637
3638 -- The Alternatives field below is present only if there is more than
3639 -- one Set_Alternative present, in which case Right_Opnd is set to
3640 -- Empty, and Alternatives contains the list of alternatives. In the
3641 -- tree passed to the back end, Alternatives is always No_List, and
3642 -- Right_Opnd is set (i.e. the expansion circuitry expands out the
3643 -- complex set membership case using simple membership operations).
3644
3645 -- N_In
3646 -- Sloc points to IN
3647 -- Left_Opnd (Node2)
3648 -- Right_Opnd (Node3)
3649 -- Alternatives (List4) (set to No_List if only one set alternative)
3650 -- plus fields for expression
3651
3652 -- N_Not_In
3653 -- Sloc points to NOT of NOT IN
3654 -- Left_Opnd (Node2)
3655 -- Right_Opnd (Node3)
3656 -- Alternatives (List4) (set to No_List if only one set alternative)
3657 -- plus fields for expression
3658
3659 --------------------
3660 -- 4.5 Operators --
3661 --------------------
3662
3663 -- LOGICAL_OPERATOR ::= and | or | xor
3664
3665 -- RELATIONAL_OPERATOR ::= = | /= | < | <= | > | >=
3666
3667 -- BINARY_ADDING_OPERATOR ::= + | - | &
3668
3669 -- UNARY_ADDING_OPERATOR ::= + | -
3670
3671 -- MULTIPLYING_OPERATOR ::= * | / | mod | rem
3672
3673 -- HIGHEST_PRECEDENCE_OPERATOR ::= ** | abs | not
3674
3675 -- Sprint syntax if Treat_Fixed_As_Integer is set:
3676
3677 -- x #* y
3678 -- x #/ y
3679 -- x #mod y
3680 -- x #rem y
3681
3682 -- Gigi restriction: For * / mod rem with fixed-point operands, Gigi
3683 -- will only be given nodes with the Treat_Fixed_As_Integer flag set.
3684 -- All handling of smalls for multiplication and division is handled
3685 -- by the front end (mod and rem result only from expansion). Gigi
3686 -- thus never needs to worry about small values (for other operators
3687 -- operating on fixed-point, e.g. addition, the small value does not
3688 -- have any semantic effect anyway, these are always integer operations.
3689
3690 -- Gigi restriction: For all operators taking Boolean operands, the
3691 -- type is always Standard.Boolean. The expander inserts the required
3692 -- conversion operations where needed to ensure this is the case.
3693
3694 -- N_Op_And
3695 -- Sloc points to AND
3696 -- Do_Length_Check (Flag4-Sem)
3697 -- plus fields for binary operator
3698 -- plus fields for expression
3699
3700 -- N_Op_Or
3701 -- Sloc points to OR
3702 -- Do_Length_Check (Flag4-Sem)
3703 -- plus fields for binary operator
3704 -- plus fields for expression
3705
3706 -- N_Op_Xor
3707 -- Sloc points to XOR
3708 -- Do_Length_Check (Flag4-Sem)
3709 -- plus fields for binary operator
3710 -- plus fields for expression
3711
3712 -- N_Op_Eq
3713 -- Sloc points to =
3714 -- plus fields for binary operator
3715 -- plus fields for expression
3716
3717 -- N_Op_Ne
3718 -- Sloc points to /=
3719 -- plus fields for binary operator
3720 -- plus fields for expression
3721
3722 -- N_Op_Lt
3723 -- Sloc points to <
3724 -- plus fields for binary operator
3725 -- plus fields for expression
3726
3727 -- N_Op_Le
3728 -- Sloc points to <=
3729 -- plus fields for binary operator
3730 -- plus fields for expression
3731
3732 -- N_Op_Gt
3733 -- Sloc points to >
3734 -- plus fields for binary operator
3735 -- plus fields for expression
3736
3737 -- N_Op_Ge
3738 -- Sloc points to >=
3739 -- plus fields for binary operator
3740 -- plus fields for expression
3741
3742 -- N_Op_Add
3743 -- Sloc points to + (binary)
3744 -- plus fields for binary operator
3745 -- plus fields for expression
3746
3747 -- N_Op_Subtract
3748 -- Sloc points to - (binary)
3749 -- plus fields for binary operator
3750 -- plus fields for expression
3751
3752 -- N_Op_Concat
3753 -- Sloc points to &
3754 -- Is_Component_Left_Opnd (Flag13-Sem)
3755 -- Is_Component_Right_Opnd (Flag14-Sem)
3756 -- plus fields for binary operator
3757 -- plus fields for expression
3758
3759 -- N_Op_Multiply
3760 -- Sloc points to *
3761 -- Treat_Fixed_As_Integer (Flag14-Sem)
3762 -- Rounded_Result (Flag18-Sem)
3763 -- plus fields for binary operator
3764 -- plus fields for expression
3765
3766 -- N_Op_Divide
3767 -- Sloc points to /
3768 -- Treat_Fixed_As_Integer (Flag14-Sem)
3769 -- Do_Division_Check (Flag13-Sem)
3770 -- Rounded_Result (Flag18-Sem)
3771 -- plus fields for binary operator
3772 -- plus fields for expression
3773
3774 -- N_Op_Mod
3775 -- Sloc points to MOD
3776 -- Treat_Fixed_As_Integer (Flag14-Sem)
3777 -- Do_Division_Check (Flag13-Sem)
3778 -- plus fields for binary operator
3779 -- plus fields for expression
3780
3781 -- N_Op_Rem
3782 -- Sloc points to REM
3783 -- Treat_Fixed_As_Integer (Flag14-Sem)
3784 -- Do_Division_Check (Flag13-Sem)
3785 -- plus fields for binary operator
3786 -- plus fields for expression
3787
3788 -- N_Op_Expon
3789 -- Is_Power_Of_2_For_Shift (Flag13-Sem)
3790 -- Sloc points to **
3791 -- plus fields for binary operator
3792 -- plus fields for expression
3793
3794 -- N_Op_Plus
3795 -- Sloc points to + (unary)
3796 -- plus fields for unary operator
3797 -- plus fields for expression
3798
3799 -- N_Op_Minus
3800 -- Sloc points to - (unary)
3801 -- plus fields for unary operator
3802 -- plus fields for expression
3803
3804 -- N_Op_Abs
3805 -- Sloc points to ABS
3806 -- plus fields for unary operator
3807 -- plus fields for expression
3808
3809 -- N_Op_Not
3810 -- Sloc points to NOT
3811 -- plus fields for unary operator
3812 -- plus fields for expression
3813
3814 -- See also shift operators in section B.2
3815
3816 -- Note on fixed-point operations passed to Gigi: For adding operators,
3817 -- the semantics is to treat these simply as integer operations, with
3818 -- the small values being ignored (the bounds are already stored in
3819 -- units of small, so that constraint checking works as usual). For the
3820 -- case of multiply/divide/rem/mod operations, Gigi will only see fixed
3821 -- point operands if the Treat_Fixed_As_Integer flag is set and will
3822 -- thus treat these nodes in identical manner, ignoring small values.
3823
3824 ---------------------------------
3825 -- 4.5.9 Quantified Expression --
3826 ---------------------------------
3827
3828 -- QUANTIFIED_EXPRESSION ::=
3829 -- for QUANTIFIER LOOP_PARAMETER_SPECIFICATION => PREDICATE |
3830 -- for QUANTIFIER ITERATOR_SPECIFICATION => PREDICATE
3831 --
3832 -- QUANTIFIER ::= all | some
3833
3834 -- N_Quantified_Expression
3835 -- Sloc points to FOR
3836 -- Iterator_Specification (Node2) (set to Empty if not Present)
3837 -- Loop_Parameter_Specification (Node4)
3838 -- Condition (Node1)
3839 -- All_Present (Flag15)
3840
3841 --------------------------
3842 -- 4.6 Type Conversion --
3843 --------------------------
3844
3845 -- TYPE_CONVERSION ::=
3846 -- SUBTYPE_MARK (EXPRESSION) | SUBTYPE_MARK (NAME)
3847
3848 -- In the (NAME) case, the name is stored as the expression
3849
3850 -- Note: the parser never generates a type conversion node, since it
3851 -- looks like an indexed component which is generated by preference.
3852 -- The semantic pass must correct this misidentification.
3853
3854 -- Gigi handles conversions that involve no change in the root type,
3855 -- and also all conversions from integer to floating-point types.
3856 -- Conversions from floating-point to integer are only handled in
3857 -- the case where Float_Truncate flag set. Other conversions from
3858 -- floating-point to integer (involving rounding) and all conversions
3859 -- involving fixed-point types are handled by the expander.
3860
3861 -- Sprint syntax if Float_Truncate set: X^(Y)
3862 -- Sprint syntax if Conversion_OK set X?(Y)
3863 -- Sprint syntax if both flags set X?^(Y)
3864
3865 -- Note: If either the operand or result type is fixed-point, Gigi will
3866 -- only see a type conversion node with Conversion_OK set. The front end
3867 -- takes care of all handling of small's for fixed-point conversions.
3868
3869 -- N_Type_Conversion
3870 -- Sloc points to first token of subtype mark
3871 -- Subtype_Mark (Node4)
3872 -- Expression (Node3)
3873 -- Do_Tag_Check (Flag13-Sem)
3874 -- Do_Length_Check (Flag4-Sem)
3875 -- Do_Overflow_Check (Flag17-Sem)
3876 -- Float_Truncate (Flag11-Sem)
3877 -- Rounded_Result (Flag18-Sem)
3878 -- Conversion_OK (Flag14-Sem)
3879 -- plus fields for expression
3880
3881 -- Note: if a range check is required, then the Do_Range_Check flag
3882 -- is set in the Expression with the check being done against the
3883 -- target type range (after the base type conversion, if any).
3884
3885 -------------------------------
3886 -- 4.7 Qualified Expression --
3887 -------------------------------
3888
3889 -- QUALIFIED_EXPRESSION ::=
3890 -- SUBTYPE_MARK ' (EXPRESSION) | SUBTYPE_MARK ' AGGREGATE
3891
3892 -- Note: the parentheses in the (EXPRESSION) case are deemed to enclose
3893 -- the expression, so the Expression field of this node always points
3894 -- to a parenthesized expression in this case (i.e. Paren_Count will
3895 -- always be non-zero for the referenced expression if it is not an
3896 -- aggregate).
3897
3898 -- N_Qualified_Expression
3899 -- Sloc points to apostrophe
3900 -- Subtype_Mark (Node4)
3901 -- Expression (Node3) expression or aggregate
3902 -- plus fields for expression
3903
3904 --------------------
3905 -- 4.8 Allocator --
3906 --------------------
3907
3908 -- ALLOCATOR ::=
3909 -- new [NULL_EXCLUSION] SUBTYPE_INDICATION | new QUALIFIED_EXPRESSION
3910
3911 -- Sprint syntax (when storage pool present)
3912 -- new xxx (storage_pool = pool)
3913
3914 -- N_Allocator
3915 -- Sloc points to NEW
3916 -- Expression (Node3) subtype indication or qualified expression
3917 -- Storage_Pool (Node1-Sem)
3918 -- Procedure_To_Call (Node2-Sem)
3919 -- Coextensions (Elist4-Sem)
3920 -- Null_Exclusion_Present (Flag11)
3921 -- No_Initialization (Flag13-Sem)
3922 -- Is_Static_Coextension (Flag14-Sem)
3923 -- Do_Storage_Check (Flag17-Sem)
3924 -- Is_Dynamic_Coextension (Flag18-Sem)
3925 -- plus fields for expression
3926
3927 -- Note: like all nodes, the N_Allocator has the Comes_From_Source flag.
3928 -- This flag has a special function in conjunction with the restriction
3929 -- No_Implicit_Heap_Allocations, which will be triggered if this flag
3930 -- is not set. This means that if a source allocator is replaced with
3931 -- a constructed allocator, the Comes_From_Source flag should be copied
3932 -- to the newly created allocator.
3933
3934 ---------------------------------
3935 -- 5.1 Sequence Of Statements --
3936 ---------------------------------
3937
3938 -- SEQUENCE_OF_STATEMENTS ::= STATEMENT {STATEMENT}
3939
3940 -- Note: Although the parser will not accept a declaration as a
3941 -- statement, the semantic analyzer may insert declarations (e.g.
3942 -- declarations of implicit types needed for execution of other
3943 -- statements) into a sequence of statements, so the code generator
3944 -- should be prepared to accept a declaration where a statement is
3945 -- expected. Note also that pragmas can appear as statements.
3946
3947 --------------------
3948 -- 5.1 Statement --
3949 --------------------
3950
3951 -- STATEMENT ::=
3952 -- {LABEL} SIMPLE_STATEMENT | {LABEL} COMPOUND_STATEMENT
3953
3954 -- There is no explicit node in the tree for a statement. Instead, the
3955 -- individual statement appears directly. Labels are treated as a
3956 -- kind of statement, i.e. they are linked into a statement list at
3957 -- the point they appear, so the labeled statement appears following
3958 -- the label or labels in the statement list.
3959
3960 ---------------------------
3961 -- 5.1 Simple Statement --
3962 ---------------------------
3963
3964 -- SIMPLE_STATEMENT ::= NULL_STATEMENT
3965 -- | ASSIGNMENT_STATEMENT | EXIT_STATEMENT
3966 -- | GOTO_STATEMENT | PROCEDURE_CALL_STATEMENT
3967 -- | SIMPLE_RETURN_STATEMENT | ENTRY_CALL_STATEMENT
3968 -- | REQUEUE_STATEMENT | DELAY_STATEMENT
3969 -- | ABORT_STATEMENT | RAISE_STATEMENT
3970 -- | CODE_STATEMENT
3971
3972 -----------------------------
3973 -- 5.1 Compound Statement --
3974 -----------------------------
3975
3976 -- COMPOUND_STATEMENT ::=
3977 -- IF_STATEMENT | CASE_STATEMENT
3978 -- | LOOP_STATEMENT | BLOCK_STATEMENT
3979 -- | EXTENDED_RETURN_STATEMENT
3980 -- | ACCEPT_STATEMENT | SELECT_STATEMENT
3981
3982 -------------------------
3983 -- 5.1 Null Statement --
3984 -------------------------
3985
3986 -- NULL_STATEMENT ::= null;
3987
3988 -- N_Null_Statement
3989 -- Sloc points to NULL
3990
3991 ----------------
3992 -- 5.1 Label --
3993 ----------------
3994
3995 -- LABEL ::= <<label_STATEMENT_IDENTIFIER>>
3996
3997 -- Note that the occurrence of a label is not a defining identifier,
3998 -- but rather a referencing occurrence. The defining occurrence is
3999 -- in the implicit label declaration which occurs in the innermost
4000 -- enclosing block.
4001
4002 -- N_Label
4003 -- Sloc points to <<
4004 -- Identifier (Node1) direct name of statement identifier
4005 -- Exception_Junk (Flag8-Sem)
4006
4007 -- Note: Before Ada 2012, a label is always followed by a statement,
4008 -- and this is true in the tree even in Ada 2012 mode (the parser
4009 -- inserts a null statement marked with Comes_From_Source False).
4010
4011 -------------------------------
4012 -- 5.1 Statement Identifier --
4013 -------------------------------
4014
4015 -- STATEMENT_IDENTIFIER ::= DIRECT_NAME
4016
4017 -- The IDENTIFIER of a STATEMENT_IDENTIFIER shall be an identifier
4018 -- (not an OPERATOR_SYMBOL)
4019
4020 -------------------------------
4021 -- 5.2 Assignment Statement --
4022 -------------------------------
4023
4024 -- ASSIGNMENT_STATEMENT ::=
4025 -- variable_NAME := EXPRESSION;
4026
4027 -- N_Assignment_Statement
4028 -- Sloc points to :=
4029 -- Name (Node2)
4030 -- Expression (Node3)
4031 -- Do_Tag_Check (Flag13-Sem)
4032 -- Do_Length_Check (Flag4-Sem)
4033 -- Forwards_OK (Flag5-Sem)
4034 -- Backwards_OK (Flag6-Sem)
4035 -- No_Ctrl_Actions (Flag7-Sem)
4036 -- Componentwise_Assignment (Flag14-Sem)
4037
4038 -- Note: if a range check is required, then the Do_Range_Check flag
4039 -- is set in the Expression (right hand side), with the check being
4040 -- done against the type of the Name (left hand side).
4041
4042 -- Note: the back end places some restrictions on the form of the
4043 -- Expression field. If the object being assigned to is Atomic, then
4044 -- the Expression may not have the form of an aggregate (since this
4045 -- might cause the back end to generate separate assignments). In this
4046 -- case the front end must generate an extra temporary and initialize
4047 -- this temporary as required (the temporary itself is not atomic).
4048
4049 -----------------------
4050 -- 5.3 If Statement --
4051 -----------------------
4052
4053 -- IF_STATEMENT ::=
4054 -- if CONDITION then
4055 -- SEQUENCE_OF_STATEMENTS
4056 -- {elsif CONDITION then
4057 -- SEQUENCE_OF_STATEMENTS}
4058 -- [else
4059 -- SEQUENCE_OF_STATEMENTS]
4060 -- end if;
4061
4062 -- Gigi restriction: This expander ensures that the type of the
4063 -- Condition fields is always Standard.Boolean, even if the type
4064 -- in the source is some non-standard boolean type.
4065
4066 -- N_If_Statement
4067 -- Sloc points to IF
4068 -- Condition (Node1)
4069 -- Then_Statements (List2)
4070 -- Elsif_Parts (List3) (set to No_List if none present)
4071 -- Else_Statements (List4) (set to No_List if no else part present)
4072 -- End_Span (Uint5) (set to No_Uint if expander generated)
4073
4074 -- N_Elsif_Part
4075 -- Sloc points to ELSIF
4076 -- Condition (Node1)
4077 -- Then_Statements (List2)
4078 -- Condition_Actions (List3-Sem)
4079
4080 --------------------
4081 -- 5.3 Condition --
4082 --------------------
4083
4084 -- CONDITION ::= boolean_EXPRESSION
4085
4086 -------------------------
4087 -- 5.4 Case Statement --
4088 -------------------------
4089
4090 -- CASE_STATEMENT ::=
4091 -- case EXPRESSION is
4092 -- CASE_STATEMENT_ALTERNATIVE
4093 -- {CASE_STATEMENT_ALTERNATIVE}
4094 -- end case;
4095
4096 -- Note: the Alternatives can contain pragmas. These only occur at
4097 -- the start of the list, since any pragmas occurring after the first
4098 -- alternative are absorbed into the corresponding statement sequence.
4099
4100 -- N_Case_Statement
4101 -- Sloc points to CASE
4102 -- Expression (Node3)
4103 -- Alternatives (List4)
4104 -- End_Span (Uint5) (set to No_Uint if expander generated)
4105
4106 -- Note: Before Ada 2012, a pragma in a statement sequence is always
4107 -- followed by a statement, and this is true in the tree even in Ada
4108 -- 2012 mode (the parser inserts a null statement marked with the flag
4109 -- Comes_From_Source False).
4110
4111 -------------------------------------
4112 -- 5.4 Case Statement Alternative --
4113 -------------------------------------
4114
4115 -- CASE_STATEMENT_ALTERNATIVE ::=
4116 -- when DISCRETE_CHOICE_LIST =>
4117 -- SEQUENCE_OF_STATEMENTS
4118
4119 -- N_Case_Statement_Alternative
4120 -- Sloc points to WHEN
4121 -- Discrete_Choices (List4)
4122 -- Statements (List3)
4123
4124 -------------------------
4125 -- 5.5 Loop Statement --
4126 -------------------------
4127
4128 -- LOOP_STATEMENT ::=
4129 -- [loop_STATEMENT_IDENTIFIER :]
4130 -- [ITERATION_SCHEME] loop
4131 -- SEQUENCE_OF_STATEMENTS
4132 -- end loop [loop_IDENTIFIER];
4133
4134 -- Note: The occurrence of a loop label is not a defining identifier
4135 -- but rather a referencing occurrence. The defining occurrence is in
4136 -- the implicit label declaration which occurs in the innermost
4137 -- enclosing block.
4138
4139 -- Note: there is always a loop statement identifier present in
4140 -- the tree, even if none was given in the source. In the case where
4141 -- no loop identifier is given in the source, the parser creates
4142 -- a name of the form _Loop_n, where n is a decimal integer (the
4143 -- two underlines ensure that the loop names created in this manner
4144 -- do not conflict with any user defined identifiers), and the flag
4145 -- Has_Created_Identifier is set to True. The only exception to the
4146 -- rule that all loop statement nodes have identifiers occurs for
4147 -- loops constructed by the expander, and the semantic analyzer will
4148 -- create and supply dummy loop identifiers in these cases.
4149
4150 -- N_Loop_Statement
4151 -- Sloc points to LOOP
4152 -- Identifier (Node1) loop identifier (set to Empty if no identifier)
4153 -- Iteration_Scheme (Node2) (set to Empty if no iteration scheme)
4154 -- Statements (List3)
4155 -- End_Label (Node4)
4156 -- Has_Created_Identifier (Flag15)
4157 -- Is_Null_Loop (Flag16)
4158 -- Suppress_Loop_Warnings (Flag17)
4159
4160 -- Note: the parser fills in the Identifier field if there is an
4161 -- explicit loop identifier. Otherwise the parser leaves this field
4162 -- set to Empty, and then the semantic processing for a loop statement
4163 -- creates an identifier, setting the Has_Created_Identifier flag to
4164 -- True. So after semantic anlaysis, the Identifier is always set,
4165 -- referencing an identifier whose entity has an Ekind of E_Loop.
4166
4167 --------------------------
4168 -- 5.5 Iteration Scheme --
4169 --------------------------
4170
4171 -- ITERATION_SCHEME ::=
4172 -- while CONDITION | for LOOP_PARAMETER_SPECIFICATION |
4173 -- for ITERATOR_SPECIFICATION
4174
4175 -- Only one of (Iterator_Specification, Loop_Parameter_Specification)
4176 -- is present at a time, the other one is empty.
4177
4178 -- Gigi restriction: This expander ensures that the type of the
4179 -- Condition field is always Standard.Boolean, even if the type
4180 -- in the source is some non-standard boolean type.
4181
4182 -- N_Iteration_Scheme
4183 -- Sloc points to WHILE or FOR
4184 -- Condition (Node1) (set to Empty if FOR case)
4185 -- Condition_Actions (List3-Sem)
4186 -- Iterator_Specification (Node2) (set to Empty if not Present)
4187 -- Loop_Parameter_Specification (Node4) (set to Empty if WHILE case)
4188
4189 ---------------------------------------
4190 -- 5.5 Loop parameter specification --
4191 ---------------------------------------
4192
4193 -- LOOP_PARAMETER_SPECIFICATION ::=
4194 -- DEFINING_IDENTIFIER in [reverse] DISCRETE_SUBTYPE_DEFINITION
4195
4196 -- N_Loop_Parameter_Specification
4197 -- Sloc points to first identifier
4198 -- Defining_Identifier (Node1)
4199 -- Reverse_Present (Flag15)
4200 -- Discrete_Subtype_Definition (Node4)
4201
4202 ----------------------------------
4203 -- 5.5.1 Iterator specification --
4204 ----------------------------------
4205
4206 -- ITERATOR_SPECIFICATION ::=
4207 -- DEFINING_IDENTIFIER in [reverse] NAME
4208 -- DEFINING_IDENTIFIER [: SUBTYPE_INDICATION] of [reverse] NAME
4209
4210 -- N_Iterator_Specification
4211 -- Sloc points to defining identifier
4212 -- Defining_Identifier (Node1)
4213 -- Name (Node2)
4214 -- Reverse_Present (Flag15)
4215 -- Of_Present (Flag16)
4216 -- Subtype_Indication (Node5)
4217
4218 --------------------------
4219 -- 5.6 Block Statement --
4220 --------------------------
4221
4222 -- BLOCK_STATEMENT ::=
4223 -- [block_STATEMENT_IDENTIFIER:]
4224 -- [declare
4225 -- DECLARATIVE_PART]
4226 -- begin
4227 -- HANDLED_SEQUENCE_OF_STATEMENTS
4228 -- end [block_IDENTIFIER];
4229
4230 -- Note that the occurrence of a block identifier is not a defining
4231 -- identifier, but rather a referencing occurrence. The defining
4232 -- occurrence is an E_Block entity declared by the implicit label
4233 -- declaration which occurs in the innermost enclosing block statement
4234 -- or body; the block identifier denotes that E_Block.
4235
4236 -- For block statements that come from source code, there is always a
4237 -- block statement identifier present in the tree, denoting an
4238 -- E_Block. In the case where no block identifier is given in the
4239 -- source, the parser creates a name of the form B_n, where n is a
4240 -- decimal integer, and the flag Has_Created_Identifier is set to
4241 -- True. Blocks constructed by the expander usually have no identifier,
4242 -- and no corresponding entity.
4243
4244 -- Note: the block statement created for an extended return statement
4245 -- has an entity, and this entity is an E_Return_Statement, rather than
4246 -- the usual E_Block.
4247
4248 -- Note: Exception_Junk is set for the wrapping blocks created during
4249 -- local raise optimization (Exp_Ch11.Expand_Local_Exception_Handlers).
4250
4251 -- N_Block_Statement
4252 -- Sloc points to DECLARE or BEGIN
4253 -- Identifier (Node1) block direct name (set to Empty if not present)
4254 -- Declarations (List2) (set to No_List if no DECLARE part)
4255 -- Handled_Statement_Sequence (Node4)
4256 -- Is_Task_Master (Flag5-Sem)
4257 -- Activation_Chain_Entity (Node3-Sem)
4258 -- Has_Created_Identifier (Flag15)
4259 -- Is_Task_Allocation_Block (Flag6)
4260 -- Is_Asynchronous_Call_Block (Flag7)
4261 -- Exception_Junk (Flag8-Sem)
4262
4263 -------------------------
4264 -- 5.7 Exit Statement --
4265 -------------------------
4266
4267 -- EXIT_STATEMENT ::= exit [loop_NAME] [when CONDITION];
4268
4269 -- Gigi restriction: This expander ensures that the type of the
4270 -- Condition field is always Standard.Boolean, even if the type
4271 -- in the source is some non-standard boolean type.
4272
4273 -- N_Exit_Statement
4274 -- Sloc points to EXIT
4275 -- Name (Node2) (set to Empty if no loop name present)
4276 -- Condition (Node1) (set to Empty if no WHEN part present)
4277 -- Next_Exit_Statement (Node3-Sem): Next exit on chain
4278
4279 -------------------------
4280 -- 5.9 Goto Statement --
4281 -------------------------
4282
4283 -- GOTO_STATEMENT ::= goto label_NAME;
4284
4285 -- N_Goto_Statement
4286 -- Sloc points to GOTO
4287 -- Name (Node2)
4288 -- Exception_Junk (Flag8-Sem)
4289
4290 ---------------------------------
4291 -- 6.1 Subprogram Declaration --
4292 ---------------------------------
4293
4294 -- SUBPROGRAM_DECLARATION ::=
4295 -- SUBPROGRAM_SPECIFICATION
4296 -- [ASPECT_SPECIFICATIONS];
4297
4298 -- N_Subprogram_Declaration
4299 -- Sloc points to FUNCTION or PROCEDURE
4300 -- Specification (Node1)
4301 -- Body_To_Inline (Node3-Sem)
4302 -- Corresponding_Body (Node5-Sem)
4303 -- Parent_Spec (Node4-Sem)
4304
4305 ------------------------------------------
4306 -- 6.1 Abstract Subprogram Declaration --
4307 ------------------------------------------
4308
4309 -- ABSTRACT_SUBPROGRAM_DECLARATION ::=
4310 -- SUBPROGRAM_SPECIFICATION is abstract
4311 -- [ASPECT_SPECIFICATIONS];
4312
4313 -- N_Abstract_Subprogram_Declaration
4314 -- Sloc points to ABSTRACT
4315 -- Specification (Node1)
4316
4317 -----------------------------------
4318 -- 6.1 Subprogram Specification --
4319 -----------------------------------
4320
4321 -- SUBPROGRAM_SPECIFICATION ::=
4322 -- [[not] overriding]
4323 -- procedure DEFINING_PROGRAM_UNIT_NAME PARAMETER_PROFILE
4324 -- | [[not] overriding]
4325 -- function DEFINING_DESIGNATOR PARAMETER_AND_RESULT_PROFILE
4326
4327 -- Note: there are no separate nodes for the profiles, instead the
4328 -- information appears directly in the following nodes.
4329
4330 -- N_Function_Specification
4331 -- Sloc points to FUNCTION
4332 -- Defining_Unit_Name (Node1) (the designator)
4333 -- Elaboration_Boolean (Node2-Sem)
4334 -- Parameter_Specifications (List3) (set to No_List if no formal part)
4335 -- Null_Exclusion_Present (Flag11)
4336 -- Result_Definition (Node4) for result subtype
4337 -- Generic_Parent (Node5-Sem)
4338 -- Must_Override (Flag14) set if overriding indicator present
4339 -- Must_Not_Override (Flag15) set if not_overriding indicator present
4340
4341 -- N_Procedure_Specification
4342 -- Sloc points to PROCEDURE
4343 -- Defining_Unit_Name (Node1)
4344 -- Elaboration_Boolean (Node2-Sem)
4345 -- Parameter_Specifications (List3) (set to No_List if no formal part)
4346 -- Generic_Parent (Node5-Sem)
4347 -- Null_Present (Flag13) set for null procedure case (Ada 2005 feature)
4348 -- Must_Override (Flag14) set if overriding indicator present
4349 -- Must_Not_Override (Flag15) set if not_overriding indicator present
4350
4351 -- Note: overriding indicator is an Ada 2005 feature
4352
4353 ---------------------
4354 -- 6.1 Designator --
4355 ---------------------
4356
4357 -- DESIGNATOR ::=
4358 -- [PARENT_UNIT_NAME .] IDENTIFIER | OPERATOR_SYMBOL
4359
4360 -- Designators that are simply identifiers or operator symbols appear
4361 -- directly in the tree in this form. The following node is used only
4362 -- in the case where the designator has a parent unit name component.
4363
4364 -- N_Designator
4365 -- Sloc points to period
4366 -- Name (Node2) holds the parent unit name. Note that this is always
4367 -- non-Empty, since this node is only used for the case where a
4368 -- parent library unit package name is present.
4369 -- Identifier (Node1)
4370
4371 -- Note that the identifier can also be an operator symbol here
4372
4373 ------------------------------
4374 -- 6.1 Defining Designator --
4375 ------------------------------
4376
4377 -- DEFINING_DESIGNATOR ::=
4378 -- DEFINING_PROGRAM_UNIT_NAME | DEFINING_OPERATOR_SYMBOL
4379
4380 -------------------------------------
4381 -- 6.1 Defining Program Unit Name --
4382 -------------------------------------
4383
4384 -- DEFINING_PROGRAM_UNIT_NAME ::=
4385 -- [PARENT_UNIT_NAME .] DEFINING_IDENTIFIER
4386
4387 -- The parent unit name is present only in the case of a child unit
4388 -- name (permissible only for Ada 95 for a library level unit, i.e.
4389 -- a unit at scope level one). If no such name is present, the defining
4390 -- program unit name is represented simply as the defining identifier.
4391 -- In the child unit case, the following node is used to represent the
4392 -- child unit name.
4393
4394 -- N_Defining_Program_Unit_Name
4395 -- Sloc points to period
4396 -- Name (Node2) holds the parent unit name. Note that this is always
4397 -- non-Empty, since this node is only used for the case where a
4398 -- parent unit name is present.
4399 -- Defining_Identifier (Node1)
4400
4401 --------------------------
4402 -- 6.1 Operator Symbol --
4403 --------------------------
4404
4405 -- OPERATOR_SYMBOL ::= STRING_LITERAL
4406
4407 -- Note: the fields of the N_Operator_Symbol node are laid out to
4408 -- match the corresponding fields of an N_Character_Literal node. This
4409 -- allows easy conversion of the operator symbol node into a character
4410 -- literal node in the case where a string constant of the form of an
4411 -- operator symbol is scanned out as such, but turns out semantically
4412 -- to be a string literal that is not an operator. For details see
4413 -- Sinfo.CN.Change_Operator_Symbol_To_String_Literal.
4414
4415 -- N_Operator_Symbol
4416 -- Sloc points to literal
4417 -- Chars (Name1) contains the Name_Id for the operator symbol
4418 -- Strval (Str3) Id of string value. This is used if the operator
4419 -- symbol turns out to be a normal string after all.
4420 -- Entity (Node4-Sem)
4421 -- Associated_Node (Node4-Sem)
4422 -- Has_Private_View (Flag11-Sem) set in generic units.
4423 -- Etype (Node5-Sem)
4424
4425 -- Note: the Strval field may be set to No_String for generated
4426 -- operator symbols that are known not to be string literals
4427 -- semantically.
4428
4429 -----------------------------------
4430 -- 6.1 Defining Operator Symbol --
4431 -----------------------------------
4432
4433 -- DEFINING_OPERATOR_SYMBOL ::= OPERATOR_SYMBOL
4434
4435 -- A defining operator symbol is an entity, which has additional
4436 -- fields depending on the setting of the Ekind field. These
4437 -- additional fields are defined (and access subprograms declared)
4438 -- in package Einfo.
4439
4440 -- Note: N_Defining_Operator_Symbol is an extended node whose fields
4441 -- are deliberately layed out to match the layout of fields in an
4442 -- ordinary N_Operator_Symbol node allowing for easy alteration of
4443 -- an operator symbol node into a defining operator symbol node.
4444 -- See Sinfo.CN.Change_Operator_Symbol_To_Defining_Operator_Symbol
4445 -- for further details.
4446
4447 -- N_Defining_Operator_Symbol
4448 -- Sloc points to literal
4449 -- Chars (Name1) contains the Name_Id for the operator symbol
4450 -- Next_Entity (Node2-Sem)
4451 -- Scope (Node3-Sem)
4452 -- Etype (Node5-Sem)
4453
4454 ----------------------------
4455 -- 6.1 Parameter Profile --
4456 ----------------------------
4457
4458 -- PARAMETER_PROFILE ::= [FORMAL_PART]
4459
4460 ---------------------------------------
4461 -- 6.1 Parameter and Result Profile --
4462 ---------------------------------------
4463
4464 -- PARAMETER_AND_RESULT_PROFILE ::=
4465 -- [FORMAL_PART] return [NULL_EXCLUSION] SUBTYPE_MARK
4466 -- | [FORMAL_PART] return ACCESS_DEFINITION
4467
4468 -- There is no explicit node in the tree for a parameter and result
4469 -- profile. Instead the information appears directly in the parent.
4470
4471 ----------------------
4472 -- 6.1 Formal part --
4473 ----------------------
4474
4475 -- FORMAL_PART ::=
4476 -- (PARAMETER_SPECIFICATION {; PARAMETER_SPECIFICATION})
4477
4478 ----------------------------------
4479 -- 6.1 Parameter specification --
4480 ----------------------------------
4481
4482 -- PARAMETER_SPECIFICATION ::=
4483 -- DEFINING_IDENTIFIER_LIST : MODE [NULL_EXCLUSION] SUBTYPE_MARK
4484 -- [:= DEFAULT_EXPRESSION]
4485 -- | DEFINING_IDENTIFIER_LIST : ACCESS_DEFINITION
4486 -- [:= DEFAULT_EXPRESSION]
4487
4488 -- Although the syntax allows multiple identifiers in the list, the
4489 -- semantics is as though successive specifications were given with
4490 -- identical type definition and expression components. To simplify
4491 -- semantic processing, the parser represents a multiple declaration
4492 -- case as a sequence of single Specifications, using the More_Ids and
4493 -- Prev_Ids flags to preserve the original source form as described
4494 -- in the section on "Handling of Defining Identifier Lists".
4495
4496 -- N_Parameter_Specification
4497 -- Sloc points to first identifier
4498 -- Defining_Identifier (Node1)
4499 -- In_Present (Flag15)
4500 -- Out_Present (Flag17)
4501 -- Null_Exclusion_Present (Flag11)
4502 -- Parameter_Type (Node2) subtype mark or access definition
4503 -- Expression (Node3) (set to Empty if no default expression present)
4504 -- Do_Accessibility_Check (Flag13-Sem)
4505 -- More_Ids (Flag5) (set to False if no more identifiers in list)
4506 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
4507 -- Default_Expression (Node5-Sem)
4508
4509 ---------------
4510 -- 6.1 Mode --
4511 ---------------
4512
4513 -- MODE ::= [in] | in out | out
4514
4515 -- There is no explicit node in the tree for the Mode. Instead the
4516 -- In_Present and Out_Present flags are set in the parent node to
4517 -- record the presence of keywords specifying the mode.
4518
4519 --------------------------
4520 -- 6.3 Subprogram Body --
4521 --------------------------
4522
4523 -- SUBPROGRAM_BODY ::=
4524 -- SUBPROGRAM_SPECIFICATION is
4525 -- DECLARATIVE_PART
4526 -- begin
4527 -- HANDLED_SEQUENCE_OF_STATEMENTS
4528 -- end [DESIGNATOR];
4529
4530 -- N_Subprogram_Body
4531 -- Sloc points to FUNCTION or PROCEDURE
4532 -- Specification (Node1)
4533 -- Declarations (List2)
4534 -- Handled_Statement_Sequence (Node4)
4535 -- Activation_Chain_Entity (Node3-Sem)
4536 -- Corresponding_Spec (Node5-Sem)
4537 -- Acts_As_Spec (Flag4-Sem)
4538 -- Bad_Is_Detected (Flag15) used only by parser
4539 -- Do_Storage_Check (Flag17-Sem)
4540 -- Has_Pragma_Priority (Flag6-Sem)
4541 -- Is_Protected_Subprogram_Body (Flag7-Sem)
4542 -- Is_Entry_Barrier_Function (Flag8-Sem)
4543 -- Is_Task_Master (Flag5-Sem)
4544 -- Was_Originally_Stub (Flag13-Sem)
4545 -- Has_Relative_Deadline_Pragma (Flag9-Sem)
4546 -- Has_Pragma_CPU (Flag14-Sem)
4547
4548 ------------------------------
4549 -- Parameterized Expression --
4550 ------------------------------
4551
4552 -- This is an Ada 2012 extension, we put it here for now, to be labeled
4553 -- and put in its proper section when we know exactly where that is!
4554
4555 -- PARAMETERIZED_EXPRESSION ::=
4556 -- FUNCTION SPECIFICATION IS (EXPRESSION);
4557
4558 -- N_Parameterized_Expression
4559 -- Sloc points to FUNCTION
4560 -- Specification (Node1)
4561 -- Expression (Node3)
4562
4563 -----------------------------------
4564 -- 6.4 Procedure Call Statement --
4565 -----------------------------------
4566
4567 -- PROCEDURE_CALL_STATEMENT ::=
4568 -- procedure_NAME; | procedure_PREFIX ACTUAL_PARAMETER_PART;
4569
4570 -- Note: the reason that a procedure call has expression fields is
4571 -- that it semantically resembles an expression, e.g. overloading is
4572 -- allowed and a type is concocted for semantic processing purposes.
4573 -- Certain of these fields, such as Parens are not relevant, but it
4574 -- is easier to just supply all of them together!
4575
4576 -- N_Procedure_Call_Statement
4577 -- Sloc points to first token of name or prefix
4578 -- Name (Node2) stores name or prefix
4579 -- Parameter_Associations (List3) (set to No_List if no
4580 -- actual parameter part)
4581 -- First_Named_Actual (Node4-Sem)
4582 -- Controlling_Argument (Node1-Sem) (set to Empty if not dispatching)
4583 -- Do_Tag_Check (Flag13-Sem)
4584 -- No_Elaboration_Check (Flag14-Sem)
4585 -- Parameter_List_Truncated (Flag17-Sem)
4586 -- ABE_Is_Certain (Flag18-Sem)
4587 -- plus fields for expression
4588
4589 -- If any IN parameter requires a range check, then the corresponding
4590 -- argument expression has the Do_Range_Check flag set, and the range
4591 -- check is done against the formal type. Note that this argument
4592 -- expression may appear directly in the Parameter_Associations list,
4593 -- or may be a descendent of an N_Parameter_Association node that
4594 -- appears in this list.
4595
4596 ------------------------
4597 -- 6.4 Function Call --
4598 ------------------------
4599
4600 -- FUNCTION_CALL ::=
4601 -- function_NAME | function_PREFIX ACTUAL_PARAMETER_PART
4602
4603 -- Note: the parser may generate an indexed component node or simply
4604 -- a name node instead of a function call node. The semantic pass must
4605 -- correct this misidentification.
4606
4607 -- N_Function_Call
4608 -- Sloc points to first token of name or prefix
4609 -- Name (Node2) stores name or prefix
4610 -- Parameter_Associations (List3) (set to No_List if no
4611 -- actual parameter part)
4612 -- First_Named_Actual (Node4-Sem)
4613 -- Controlling_Argument (Node1-Sem) (set to Empty if not dispatching)
4614 -- Is_Expanded_Build_In_Place_Call (Flag11-Sem)
4615 -- Do_Tag_Check (Flag13-Sem)
4616 -- No_Elaboration_Check (Flag14-Sem)
4617 -- Parameter_List_Truncated (Flag17-Sem)
4618 -- ABE_Is_Certain (Flag18-Sem)
4619 -- plus fields for expression
4620
4621 --------------------------------
4622 -- 6.4 Actual Parameter Part --
4623 --------------------------------
4624
4625 -- ACTUAL_PARAMETER_PART ::=
4626 -- (PARAMETER_ASSOCIATION {,PARAMETER_ASSOCIATION})
4627
4628 --------------------------------
4629 -- 6.4 Parameter Association --
4630 --------------------------------
4631
4632 -- PARAMETER_ASSOCIATION ::=
4633 -- [formal_parameter_SELECTOR_NAME =>] EXPLICIT_ACTUAL_PARAMETER
4634
4635 -- Note: the N_Parameter_Association node is built only if a formal
4636 -- parameter selector name is present, otherwise the parameter
4637 -- association appears in the tree simply as the node for the
4638 -- explicit actual parameter.
4639
4640 -- N_Parameter_Association
4641 -- Sloc points to formal parameter
4642 -- Selector_Name (Node2) (always non-Empty)
4643 -- Explicit_Actual_Parameter (Node3)
4644 -- Next_Named_Actual (Node4-Sem)
4645 -- Is_Accessibility_Actual (Flag13-Sem)
4646
4647 ---------------------------
4648 -- 6.4 Actual Parameter --
4649 ---------------------------
4650
4651 -- EXPLICIT_ACTUAL_PARAMETER ::= EXPRESSION | variable_NAME
4652
4653 ---------------------------
4654 -- 6.5 Return Statement --
4655 ---------------------------
4656
4657 -- RETURN_STATEMENT ::= return [EXPRESSION]; -- Ada 95
4658
4659 -- In Ada 2005, we have:
4660
4661 -- SIMPLE_RETURN_STATEMENT ::= return [EXPRESSION];
4662
4663 -- EXTENDED_RETURN_STATEMENT ::=
4664 -- return DEFINING_IDENTIFIER : [aliased] RETURN_SUBTYPE_INDICATION
4665 -- [:= EXPRESSION] [do
4666 -- HANDLED_SEQUENCE_OF_STATEMENTS
4667 -- end return];
4668
4669 -- RETURN_SUBTYPE_INDICATION ::= SUBTYPE_INDICATION | ACCESS_DEFINITION
4670
4671 -- So in Ada 2005, RETURN_STATEMENT is no longer a nonterminal, but
4672 -- "return statement" is defined in 6.5 to mean a
4673 -- SIMPLE_RETURN_STATEMENT or an EXTENDED_RETURN_STATEMENT.
4674
4675 -- N_Return_Statement
4676 -- Sloc points to RETURN
4677 -- Return_Statement_Entity (Node5-Sem)
4678 -- Expression (Node3) (set to Empty if no expression present)
4679 -- Storage_Pool (Node1-Sem)
4680 -- Procedure_To_Call (Node2-Sem)
4681 -- Do_Tag_Check (Flag13-Sem)
4682 -- By_Ref (Flag5-Sem)
4683 -- Comes_From_Extended_Return_Statement (Flag18-Sem)
4684
4685 -- N_Return_Statement represents a simple_return_statement, and is
4686 -- renamed to be N_Simple_Return_Statement below. Clients should refer
4687 -- to N_Simple_Return_Statement. We retain N_Return_Statement because
4688 -- that's how gigi knows it. See also renaming of Make_Return_Statement
4689 -- as Make_Simple_Return_Statement in Sem_Util.
4690
4691 -- Note: Return_Statement_Entity points to an E_Return_Statement
4692
4693 -- If a range check is required, then Do_Range_Check is set on the
4694 -- Expression. The check is against the return subtype of the function.
4695
4696 -- N_Extended_Return_Statement
4697 -- Sloc points to RETURN
4698 -- Return_Statement_Entity (Node5-Sem)
4699 -- Return_Object_Declarations (List3)
4700 -- Handled_Statement_Sequence (Node4) (set to Empty if not present)
4701 -- Storage_Pool (Node1-Sem)
4702 -- Procedure_To_Call (Node2-Sem)
4703 -- Do_Tag_Check (Flag13-Sem)
4704 -- By_Ref (Flag5-Sem)
4705
4706 -- Note: Return_Statement_Entity points to an E_Return_Statement.
4707
4708 -- Note that Return_Object_Declarations is a list containing the
4709 -- N_Object_Declaration -- see comment on this field above.
4710
4711 -- The declared object will have Is_Return_Object = True.
4712
4713 -- There is no such syntactic category as return_object_declaration
4714 -- in the RM. Return_Object_Declarations represents this portion of
4715 -- the syntax for EXTENDED_RETURN_STATEMENT:
4716 -- DEFINING_IDENTIFIER : [aliased] RETURN_SUBTYPE_INDICATION
4717 -- [:= EXPRESSION]
4718
4719 -- There are two entities associated with an extended_return_statement:
4720 -- the Return_Statement_Entity represents the statement itself, and the
4721 -- Defining_Identifier of the Object_Declaration in
4722 -- Return_Object_Declarations represents the object being
4723 -- returned. N_Simple_Return_Statement has only the former.
4724
4725 ------------------------------
4726 -- 7.1 Package Declaration --
4727 ------------------------------
4728
4729 -- PACKAGE_DECLARATION ::=
4730 -- PACKAGE_SPECIFICATION
4731 -- [ASPECT_SPECIFICATIONS];
4732
4733 -- Note: the activation chain entity for a package spec is used for
4734 -- all tasks declared in the package spec, or in the package body.
4735
4736 -- N_Package_Declaration
4737 -- Sloc points to PACKAGE
4738 -- Specification (Node1)
4739 -- Corresponding_Body (Node5-Sem)
4740 -- Parent_Spec (Node4-Sem)
4741 -- Activation_Chain_Entity (Node3-Sem)
4742
4743 --------------------------------
4744 -- 7.1 Package Specification --
4745 --------------------------------
4746
4747 -- PACKAGE_SPECIFICATION ::=
4748 -- package DEFINING_PROGRAM_UNIT_NAME is
4749 -- {BASIC_DECLARATIVE_ITEM}
4750 -- [private
4751 -- {BASIC_DECLARATIVE_ITEM}]
4752 -- end [[PARENT_UNIT_NAME .] IDENTIFIER]
4753
4754 -- N_Package_Specification
4755 -- Sloc points to PACKAGE
4756 -- Defining_Unit_Name (Node1)
4757 -- Visible_Declarations (List2)
4758 -- Private_Declarations (List3) (set to No_List if no private
4759 -- part present)
4760 -- End_Label (Node4)
4761 -- Generic_Parent (Node5-Sem)
4762 -- Limited_View_Installed (Flag18-Sem)
4763
4764 -----------------------
4765 -- 7.1 Package Body --
4766 -----------------------
4767
4768 -- PACKAGE_BODY ::=
4769 -- package body DEFINING_PROGRAM_UNIT_NAME is
4770 -- DECLARATIVE_PART
4771 -- [begin
4772 -- HANDLED_SEQUENCE_OF_STATEMENTS]
4773 -- end [[PARENT_UNIT_NAME .] IDENTIFIER];
4774
4775 -- N_Package_Body
4776 -- Sloc points to PACKAGE
4777 -- Defining_Unit_Name (Node1)
4778 -- Declarations (List2)
4779 -- Handled_Statement_Sequence (Node4) (set to Empty if no HSS present)
4780 -- Corresponding_Spec (Node5-Sem)
4781 -- Was_Originally_Stub (Flag13-Sem)
4782
4783 -- Note: if a source level package does not contain a handled sequence
4784 -- of statements, then the parser supplies a dummy one with a null
4785 -- sequence of statements. Comes_From_Source will be False in this
4786 -- constructed sequence. The reason we need this is for the End_Label
4787 -- field in the HSS.
4788
4789 -----------------------------------
4790 -- 7.4 Private Type Declaration --
4791 -----------------------------------
4792
4793 -- PRIVATE_TYPE_DECLARATION ::=
4794 -- type DEFINING_IDENTIFIER [DISCRIMINANT_PART]
4795 -- is [[abstract] tagged] [limited] private;
4796
4797 -- Note: TAGGED is not permitted in Ada 83 mode
4798
4799 -- N_Private_Type_Declaration
4800 -- Sloc points to TYPE
4801 -- Defining_Identifier (Node1)
4802 -- Discriminant_Specifications (List4) (set to No_List if no
4803 -- discriminant part)
4804 -- Unknown_Discriminants_Present (Flag13) set if (<>) discriminant
4805 -- Abstract_Present (Flag4)
4806 -- Tagged_Present (Flag15)
4807 -- Limited_Present (Flag17)
4808
4809 ----------------------------------------
4810 -- 7.4 Private Extension Declaration --
4811 ----------------------------------------
4812
4813 -- PRIVATE_EXTENSION_DECLARATION ::=
4814 -- type DEFINING_IDENTIFIER [DISCRIMINANT_PART] is
4815 -- [abstract] [limited | synchronized]
4816 -- new ancestor_SUBTYPE_INDICATION [and INTERFACE_LIST]
4817 -- with private;
4818
4819 -- Note: LIMITED, and private extension declarations are not allowed
4820 -- in Ada 83 mode.
4821
4822 -- N_Private_Extension_Declaration
4823 -- Sloc points to TYPE
4824 -- Defining_Identifier (Node1)
4825 -- Discriminant_Specifications (List4) (set to No_List if no
4826 -- discriminant part)
4827 -- Unknown_Discriminants_Present (Flag13) set if (<>) discriminant
4828 -- Abstract_Present (Flag4)
4829 -- Limited_Present (Flag17)
4830 -- Synchronized_Present (Flag7)
4831 -- Subtype_Indication (Node5)
4832 -- Interface_List (List2) (set to No_List if none)
4833
4834 ---------------------
4835 -- 8.4 Use Clause --
4836 ---------------------
4837
4838 -- USE_CLAUSE ::= USE_PACKAGE_CLAUSE | USE_TYPE_CLAUSE
4839
4840 -----------------------------
4841 -- 8.4 Use Package Clause --
4842 -----------------------------
4843
4844 -- USE_PACKAGE_CLAUSE ::= use package_NAME {, package_NAME};
4845
4846 -- N_Use_Package_Clause
4847 -- Sloc points to USE
4848 -- Names (List2)
4849 -- Next_Use_Clause (Node3-Sem)
4850 -- Hidden_By_Use_Clause (Elist4-Sem)
4851
4852 --------------------------
4853 -- 8.4 Use Type Clause --
4854 --------------------------
4855
4856 -- USE_TYPE_CLAUSE ::= use [ALL] type SUBTYPE_MARK {, SUBTYPE_MARK};
4857
4858 -- Note: use type clause is not permitted in Ada 83 mode
4859
4860 -- Note: the ALL keyword can appear only in Ada 2012 mode
4861
4862 -- N_Use_Type_Clause
4863 -- Sloc points to USE
4864 -- Subtype_Marks (List2)
4865 -- Next_Use_Clause (Node3-Sem)
4866 -- Hidden_By_Use_Clause (Elist4-Sem)
4867 -- All_Present (Flag15)
4868
4869 -------------------------------
4870 -- 8.5 Renaming Declaration --
4871 -------------------------------
4872
4873 -- RENAMING_DECLARATION ::=
4874 -- OBJECT_RENAMING_DECLARATION
4875 -- | EXCEPTION_RENAMING_DECLARATION
4876 -- | PACKAGE_RENAMING_DECLARATION
4877 -- | SUBPROGRAM_RENAMING_DECLARATION
4878 -- | GENERIC_RENAMING_DECLARATION
4879
4880 --------------------------------------
4881 -- 8.5 Object Renaming Declaration --
4882 --------------------------------------
4883
4884 -- OBJECT_RENAMING_DECLARATION ::=
4885 -- DEFINING_IDENTIFIER :
4886 -- [NULL_EXCLUSION] SUBTYPE_MARK renames object_NAME;
4887 -- | DEFINING_IDENTIFIER :
4888 -- ACCESS_DEFINITION renames object_NAME;
4889
4890 -- Note: Access_Definition is an optional field that gives support to
4891 -- Ada 2005 (AI-230). The parser generates nodes that have either the
4892 -- Subtype_Indication field or else the Access_Definition field.
4893
4894 -- N_Object_Renaming_Declaration
4895 -- Sloc points to first identifier
4896 -- Defining_Identifier (Node1)
4897 -- Null_Exclusion_Present (Flag11) (set to False if not present)
4898 -- Subtype_Mark (Node4) (set to Empty if not present)
4899 -- Access_Definition (Node3) (set to Empty if not present)
4900 -- Name (Node2)
4901 -- Corresponding_Generic_Association (Node5-Sem)
4902
4903 -----------------------------------------
4904 -- 8.5 Exception Renaming Declaration --
4905 -----------------------------------------
4906
4907 -- EXCEPTION_RENAMING_DECLARATION ::=
4908 -- DEFINING_IDENTIFIER : exception renames exception_NAME;
4909
4910 -- N_Exception_Renaming_Declaration
4911 -- Sloc points to first identifier
4912 -- Defining_Identifier (Node1)
4913 -- Name (Node2)
4914
4915 ---------------------------------------
4916 -- 8.5 Package Renaming Declaration --
4917 ---------------------------------------
4918
4919 -- PACKAGE_RENAMING_DECLARATION ::=
4920 -- package DEFINING_PROGRAM_UNIT_NAME renames package_NAME;
4921
4922 -- N_Package_Renaming_Declaration
4923 -- Sloc points to PACKAGE
4924 -- Defining_Unit_Name (Node1)
4925 -- Name (Node2)
4926 -- Parent_Spec (Node4-Sem)
4927
4928 ------------------------------------------
4929 -- 8.5 Subprogram Renaming Declaration --
4930 ------------------------------------------
4931
4932 -- SUBPROGRAM_RENAMING_DECLARATION ::=
4933 -- SUBPROGRAM_SPECIFICATION renames callable_entity_NAME;
4934
4935 -- N_Subprogram_Renaming_Declaration
4936 -- Sloc points to RENAMES
4937 -- Specification (Node1)
4938 -- Name (Node2)
4939 -- Parent_Spec (Node4-Sem)
4940 -- Corresponding_Spec (Node5-Sem)
4941 -- Corresponding_Formal_Spec (Node3-Sem)
4942 -- From_Default (Flag6-Sem)
4943
4944 -----------------------------------------
4945 -- 8.5.5 Generic Renaming Declaration --
4946 -----------------------------------------
4947
4948 -- GENERIC_RENAMING_DECLARATION ::=
4949 -- generic package DEFINING_PROGRAM_UNIT_NAME
4950 -- renames generic_package_NAME
4951 -- | generic procedure DEFINING_PROGRAM_UNIT_NAME
4952 -- renames generic_procedure_NAME
4953 -- | generic function DEFINING_PROGRAM_UNIT_NAME
4954 -- renames generic_function_NAME
4955
4956 -- N_Generic_Package_Renaming_Declaration
4957 -- Sloc points to GENERIC
4958 -- Defining_Unit_Name (Node1)
4959 -- Name (Node2)
4960 -- Parent_Spec (Node4-Sem)
4961
4962 -- N_Generic_Procedure_Renaming_Declaration
4963 -- Sloc points to GENERIC
4964 -- Defining_Unit_Name (Node1)
4965 -- Name (Node2)
4966 -- Parent_Spec (Node4-Sem)
4967
4968 -- N_Generic_Function_Renaming_Declaration
4969 -- Sloc points to GENERIC
4970 -- Defining_Unit_Name (Node1)
4971 -- Name (Node2)
4972 -- Parent_Spec (Node4-Sem)
4973
4974 --------------------------------
4975 -- 9.1 Task Type Declaration --
4976 --------------------------------
4977
4978 -- TASK_TYPE_DECLARATION ::=
4979 -- task type DEFINING_IDENTIFIER [KNOWN_DISCRIMINANT_PART]
4980 -- [is [new INTERFACE_LIST with] TASK_DEFINITION]
4981 -- [ASPECT_SPECIFICATIONS];
4982
4983 -- N_Task_Type_Declaration
4984 -- Sloc points to TASK
4985 -- Defining_Identifier (Node1)
4986 -- Discriminant_Specifications (List4) (set to No_List if no
4987 -- discriminant part)
4988 -- Interface_List (List2) (set to No_List if none)
4989 -- Task_Definition (Node3) (set to Empty if not present)
4990 -- Corresponding_Body (Node5-Sem)
4991
4992 ----------------------------------
4993 -- 9.1 Single Task Declaration --
4994 ----------------------------------
4995
4996 -- SINGLE_TASK_DECLARATION ::=
4997 -- task DEFINING_IDENTIFIER
4998 -- [is [new INTERFACE_LIST with] TASK_DEFINITION]
4999 -- [ASPECT_SPECIFICATIONS];
5000
5001 -- N_Single_Task_Declaration
5002 -- Sloc points to TASK
5003 -- Defining_Identifier (Node1)
5004 -- Interface_List (List2) (set to No_List if none)
5005 -- Task_Definition (Node3) (set to Empty if not present)
5006
5007 --------------------------
5008 -- 9.1 Task Definition --
5009 --------------------------
5010
5011 -- TASK_DEFINITION ::=
5012 -- {TASK_ITEM}
5013 -- [private
5014 -- {TASK_ITEM}]
5015 -- end [task_IDENTIFIER]
5016
5017 -- Note: as a result of semantic analysis, the list of task items can
5018 -- include implicit type declarations resulting from entry families.
5019
5020 -- N_Task_Definition
5021 -- Sloc points to first token of task definition
5022 -- Visible_Declarations (List2)
5023 -- Private_Declarations (List3) (set to No_List if no private part)
5024 -- End_Label (Node4)
5025 -- Has_Pragma_Priority (Flag6-Sem)
5026 -- Has_Storage_Size_Pragma (Flag5-Sem)
5027 -- Has_Task_Info_Pragma (Flag7-Sem)
5028 -- Has_Task_Name_Pragma (Flag8-Sem)
5029 -- Has_Relative_Deadline_Pragma (Flag9-Sem)
5030 -- Has_Pragma_CPU (Flag14-Sem)
5031
5032 --------------------
5033 -- 9.1 Task Item --
5034 --------------------
5035
5036 -- TASK_ITEM ::= ENTRY_DECLARATION | REPRESENTATION_CLAUSE
5037
5038 --------------------
5039 -- 9.1 Task Body --
5040 --------------------
5041
5042 -- TASK_BODY ::=
5043 -- task body task_DEFINING_IDENTIFIER is
5044 -- DECLARATIVE_PART
5045 -- begin
5046 -- HANDLED_SEQUENCE_OF_STATEMENTS
5047 -- end [task_IDENTIFIER];
5048
5049 -- Gigi restriction: This node never appears
5050
5051 -- N_Task_Body
5052 -- Sloc points to TASK
5053 -- Defining_Identifier (Node1)
5054 -- Declarations (List2)
5055 -- Handled_Statement_Sequence (Node4)
5056 -- Is_Task_Master (Flag5-Sem)
5057 -- Activation_Chain_Entity (Node3-Sem)
5058 -- Corresponding_Spec (Node5-Sem)
5059 -- Was_Originally_Stub (Flag13-Sem)
5060
5061 -------------------------------------
5062 -- 9.4 Protected Type Declaration --
5063 -------------------------------------
5064
5065 -- PROTECTED_TYPE_DECLARATION ::=
5066 -- protected type DEFINING_IDENTIFIER [KNOWN_DISCRIMINANT_PART]
5067 -- is [new INTERFACE_LIST with] PROTECTED_DEFINITION
5068 -- {ASPECT_SPECIFICATIONS];
5069
5070 -- Note: protected type declarations are not permitted in Ada 83 mode
5071
5072 -- N_Protected_Type_Declaration
5073 -- Sloc points to PROTECTED
5074 -- Defining_Identifier (Node1)
5075 -- Discriminant_Specifications (List4) (set to No_List if no
5076 -- discriminant part)
5077 -- Interface_List (List2) (set to No_List if none)
5078 -- Protected_Definition (Node3)
5079 -- Corresponding_Body (Node5-Sem)
5080
5081 ---------------------------------------
5082 -- 9.4 Single Protected Declaration --
5083 ---------------------------------------
5084
5085 -- SINGLE_PROTECTED_DECLARATION ::=
5086 -- protected DEFINING_IDENTIFIER
5087 -- is [new INTERFACE_LIST with] PROTECTED_DEFINITION
5088 -- [ASPECT_SPECIFICATIONS];
5089
5090 -- Note: single protected declarations are not allowed in Ada 83 mode
5091
5092 -- N_Single_Protected_Declaration
5093 -- Sloc points to PROTECTED
5094 -- Defining_Identifier (Node1)
5095 -- Interface_List (List2) (set to No_List if none)
5096 -- Protected_Definition (Node3)
5097
5098 -------------------------------
5099 -- 9.4 Protected Definition --
5100 -------------------------------
5101
5102 -- PROTECTED_DEFINITION ::=
5103 -- {PROTECTED_OPERATION_DECLARATION}
5104 -- [private
5105 -- {PROTECTED_ELEMENT_DECLARATION}]
5106 -- end [protected_IDENTIFIER]
5107
5108 -- N_Protected_Definition
5109 -- Sloc points to first token of protected definition
5110 -- Visible_Declarations (List2)
5111 -- Private_Declarations (List3) (set to No_List if no private part)
5112 -- End_Label (Node4)
5113 -- Has_Pragma_Priority (Flag6-Sem)
5114
5115 ------------------------------------------
5116 -- 9.4 Protected Operation Declaration --
5117 ------------------------------------------
5118
5119 -- PROTECTED_OPERATION_DECLARATION ::=
5120 -- SUBPROGRAM_DECLARATION
5121 -- | ENTRY_DECLARATION
5122 -- | REPRESENTATION_CLAUSE
5123
5124 ----------------------------------------
5125 -- 9.4 Protected Element Declaration --
5126 ----------------------------------------
5127
5128 -- PROTECTED_ELEMENT_DECLARATION ::=
5129 -- PROTECTED_OPERATION_DECLARATION | COMPONENT_DECLARATION
5130
5131 -------------------------
5132 -- 9.4 Protected Body --
5133 -------------------------
5134
5135 -- PROTECTED_BODY ::=
5136 -- protected body DEFINING_IDENTIFIER is
5137 -- {PROTECTED_OPERATION_ITEM}
5138 -- end [protected_IDENTIFIER];
5139
5140 -- Note: protected bodies are not allowed in Ada 83 mode
5141
5142 -- Gigi restriction: This node never appears
5143
5144 -- N_Protected_Body
5145 -- Sloc points to PROTECTED
5146 -- Defining_Identifier (Node1)
5147 -- Declarations (List2) protected operation items (and pragmas)
5148 -- End_Label (Node4)
5149 -- Corresponding_Spec (Node5-Sem)
5150 -- Was_Originally_Stub (Flag13-Sem)
5151
5152 -----------------------------------
5153 -- 9.4 Protected Operation Item --
5154 -----------------------------------
5155
5156 -- PROTECTED_OPERATION_ITEM ::=
5157 -- SUBPROGRAM_DECLARATION
5158 -- | SUBPROGRAM_BODY
5159 -- | ENTRY_BODY
5160 -- | REPRESENTATION_CLAUSE
5161
5162 ------------------------------
5163 -- 9.5.2 Entry Declaration --
5164 ------------------------------
5165
5166 -- ENTRY_DECLARATION ::=
5167 -- [[not] overriding]
5168 -- entry DEFINING_IDENTIFIER
5169 -- [(DISCRETE_SUBTYPE_DEFINITION)] PARAMETER_PROFILE;
5170
5171 -- N_Entry_Declaration
5172 -- Sloc points to ENTRY
5173 -- Defining_Identifier (Node1)
5174 -- Discrete_Subtype_Definition (Node4) (set to Empty if not present)
5175 -- Parameter_Specifications (List3) (set to No_List if no formal part)
5176 -- Corresponding_Body (Node5-Sem)
5177 -- Must_Override (Flag14) set if overriding indicator present
5178 -- Must_Not_Override (Flag15) set if not_overriding indicator present
5179
5180 -- Note: overriding indicator is an Ada 2005 feature
5181
5182 -----------------------------
5183 -- 9.5.2 Accept statement --
5184 -----------------------------
5185
5186 -- ACCEPT_STATEMENT ::=
5187 -- accept entry_DIRECT_NAME
5188 -- [(ENTRY_INDEX)] PARAMETER_PROFILE [do
5189 -- HANDLED_SEQUENCE_OF_STATEMENTS
5190 -- end [entry_IDENTIFIER]];
5191
5192 -- Gigi restriction: This node never appears
5193
5194 -- Note: there are no explicit declarations allowed in an accept
5195 -- statement. However, the implicit declarations for any statement
5196 -- identifiers (labels and block/loop identifiers) are declarations
5197 -- that belong logically to the accept statement, and that is why
5198 -- there is a Declarations field in this node.
5199
5200 -- N_Accept_Statement
5201 -- Sloc points to ACCEPT
5202 -- Entry_Direct_Name (Node1)
5203 -- Entry_Index (Node5) (set to Empty if not present)
5204 -- Parameter_Specifications (List3) (set to No_List if no formal part)
5205 -- Handled_Statement_Sequence (Node4)
5206 -- Declarations (List2) (set to No_List if no declarations)
5207
5208 ------------------------
5209 -- 9.5.2 Entry Index --
5210 ------------------------
5211
5212 -- ENTRY_INDEX ::= EXPRESSION
5213
5214 -----------------------
5215 -- 9.5.2 Entry Body --
5216 -----------------------
5217
5218 -- ENTRY_BODY ::=
5219 -- entry DEFINING_IDENTIFIER ENTRY_BODY_FORMAL_PART ENTRY_BARRIER is
5220 -- DECLARATIVE_PART
5221 -- begin
5222 -- HANDLED_SEQUENCE_OF_STATEMENTS
5223 -- end [entry_IDENTIFIER];
5224
5225 -- ENTRY_BARRIER ::= when CONDITION
5226
5227 -- Note: we store the CONDITION of the ENTRY_BARRIER in the node for
5228 -- the ENTRY_BODY_FORMAL_PART to avoid the N_Entry_Body node getting
5229 -- too full (it would otherwise have too many fields)
5230
5231 -- Gigi restriction: This node never appears
5232
5233 -- N_Entry_Body
5234 -- Sloc points to ENTRY
5235 -- Defining_Identifier (Node1)
5236 -- Entry_Body_Formal_Part (Node5)
5237 -- Declarations (List2)
5238 -- Handled_Statement_Sequence (Node4)
5239 -- Activation_Chain_Entity (Node3-Sem)
5240
5241 -----------------------------------
5242 -- 9.5.2 Entry Body Formal Part --
5243 -----------------------------------
5244
5245 -- ENTRY_BODY_FORMAL_PART ::=
5246 -- [(ENTRY_INDEX_SPECIFICATION)] PARAMETER_PROFILE
5247
5248 -- Note that an entry body formal part node is present even if it is
5249 -- empty. This reflects the grammar, in which it is the components of
5250 -- the entry body formal part that are optional, not the entry body
5251 -- formal part itself. Also this means that the barrier condition
5252 -- always has somewhere to be stored.
5253
5254 -- Gigi restriction: This node never appears
5255
5256 -- N_Entry_Body_Formal_Part
5257 -- Sloc points to first token
5258 -- Entry_Index_Specification (Node4) (set to Empty if not present)
5259 -- Parameter_Specifications (List3) (set to No_List if no formal part)
5260 -- Condition (Node1) from entry barrier of entry body
5261
5262 --------------------------
5263 -- 9.5.2 Entry Barrier --
5264 --------------------------
5265
5266 -- ENTRY_BARRIER ::= when CONDITION
5267
5268 --------------------------------------
5269 -- 9.5.2 Entry Index Specification --
5270 --------------------------------------
5271
5272 -- ENTRY_INDEX_SPECIFICATION ::=
5273 -- for DEFINING_IDENTIFIER in DISCRETE_SUBTYPE_DEFINITION
5274
5275 -- Gigi restriction: This node never appears
5276
5277 -- N_Entry_Index_Specification
5278 -- Sloc points to FOR
5279 -- Defining_Identifier (Node1)
5280 -- Discrete_Subtype_Definition (Node4)
5281
5282 ---------------------------------
5283 -- 9.5.3 Entry Call Statement --
5284 ---------------------------------
5285
5286 -- ENTRY_CALL_STATEMENT ::= entry_NAME [ACTUAL_PARAMETER_PART];
5287
5288 -- The parser may generate a procedure call for this construct. The
5289 -- semantic pass must correct this misidentification where needed.
5290
5291 -- Gigi restriction: This node never appears
5292
5293 -- N_Entry_Call_Statement
5294 -- Sloc points to first token of name
5295 -- Name (Node2)
5296 -- Parameter_Associations (List3) (set to No_List if no
5297 -- actual parameter part)
5298 -- First_Named_Actual (Node4-Sem)
5299
5300 ------------------------------
5301 -- 9.5.4 Requeue Statement --
5302 ------------------------------
5303
5304 -- REQUEUE_STATEMENT ::= requeue entry_NAME [with abort];
5305
5306 -- Note: requeue statements are not permitted in Ada 83 mode
5307
5308 -- Gigi restriction: This node never appears
5309
5310 -- N_Requeue_Statement
5311 -- Sloc points to REQUEUE
5312 -- Name (Node2)
5313 -- Abort_Present (Flag15)
5314
5315 --------------------------
5316 -- 9.6 Delay Statement --
5317 --------------------------
5318
5319 -- DELAY_STATEMENT ::=
5320 -- DELAY_UNTIL_STATEMENT
5321 -- | DELAY_RELATIVE_STATEMENT
5322
5323 --------------------------------
5324 -- 9.6 Delay Until Statement --
5325 --------------------------------
5326
5327 -- DELAY_UNTIL_STATEMENT ::= delay until delay_EXPRESSION;
5328
5329 -- Note: delay until statements are not permitted in Ada 83 mode
5330
5331 -- Gigi restriction: This node never appears
5332
5333 -- N_Delay_Until_Statement
5334 -- Sloc points to DELAY
5335 -- Expression (Node3)
5336
5337 -----------------------------------
5338 -- 9.6 Delay Relative Statement --
5339 -----------------------------------
5340
5341 -- DELAY_RELATIVE_STATEMENT ::= delay delay_EXPRESSION;
5342
5343 -- Gigi restriction: This node never appears
5344
5345 -- N_Delay_Relative_Statement
5346 -- Sloc points to DELAY
5347 -- Expression (Node3)
5348
5349 ---------------------------
5350 -- 9.7 Select Statement --
5351 ---------------------------
5352
5353 -- SELECT_STATEMENT ::=
5354 -- SELECTIVE_ACCEPT
5355 -- | TIMED_ENTRY_CALL
5356 -- | CONDITIONAL_ENTRY_CALL
5357 -- | ASYNCHRONOUS_SELECT
5358
5359 -----------------------------
5360 -- 9.7.1 Selective Accept --
5361 -----------------------------
5362
5363 -- SELECTIVE_ACCEPT ::=
5364 -- select
5365 -- [GUARD]
5366 -- SELECT_ALTERNATIVE
5367 -- {or
5368 -- [GUARD]
5369 -- SELECT_ALTERNATIVE}
5370 -- [else
5371 -- SEQUENCE_OF_STATEMENTS]
5372 -- end select;
5373
5374 -- Gigi restriction: This node never appears
5375
5376 -- Note: the guard expression, if present, appears in the node for
5377 -- the select alternative.
5378
5379 -- N_Selective_Accept
5380 -- Sloc points to SELECT
5381 -- Select_Alternatives (List1)
5382 -- Else_Statements (List4) (set to No_List if no else part)
5383
5384 ------------------
5385 -- 9.7.1 Guard --
5386 ------------------
5387
5388 -- GUARD ::= when CONDITION =>
5389
5390 -- As noted above, the CONDITION that is part of a GUARD is included
5391 -- in the node for the select alternative for convenience.
5392
5393 -------------------------------
5394 -- 9.7.1 Select Alternative --
5395 -------------------------------
5396
5397 -- SELECT_ALTERNATIVE ::=
5398 -- ACCEPT_ALTERNATIVE
5399 -- | DELAY_ALTERNATIVE
5400 -- | TERMINATE_ALTERNATIVE
5401
5402 -------------------------------
5403 -- 9.7.1 Accept Alternative --
5404 -------------------------------
5405
5406 -- ACCEPT_ALTERNATIVE ::=
5407 -- ACCEPT_STATEMENT [SEQUENCE_OF_STATEMENTS]
5408
5409 -- Gigi restriction: This node never appears
5410
5411 -- N_Accept_Alternative
5412 -- Sloc points to ACCEPT
5413 -- Accept_Statement (Node2)
5414 -- Condition (Node1) from the guard (set to Empty if no guard present)
5415 -- Statements (List3) (set to Empty_List if no statements)
5416 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
5417 -- Accept_Handler_Records (List5-Sem)
5418
5419 ------------------------------
5420 -- 9.7.1 Delay Alternative --
5421 ------------------------------
5422
5423 -- DELAY_ALTERNATIVE ::=
5424 -- DELAY_STATEMENT [SEQUENCE_OF_STATEMENTS]
5425
5426 -- Gigi restriction: This node never appears
5427
5428 -- N_Delay_Alternative
5429 -- Sloc points to DELAY
5430 -- Delay_Statement (Node2)
5431 -- Condition (Node1) from the guard (set to Empty if no guard present)
5432 -- Statements (List3) (set to Empty_List if no statements)
5433 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
5434
5435 ----------------------------------
5436 -- 9.7.1 Terminate Alternative --
5437 ----------------------------------
5438
5439 -- TERMINATE_ALTERNATIVE ::= terminate;
5440
5441 -- Gigi restriction: This node never appears
5442
5443 -- N_Terminate_Alternative
5444 -- Sloc points to TERMINATE
5445 -- Condition (Node1) from the guard (set to Empty if no guard present)
5446 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
5447 -- Pragmas_After (List5) pragmas after alt (set to No_List if none)
5448
5449 -----------------------------
5450 -- 9.7.2 Timed Entry Call --
5451 -----------------------------
5452
5453 -- TIMED_ENTRY_CALL ::=
5454 -- select
5455 -- ENTRY_CALL_ALTERNATIVE
5456 -- or
5457 -- DELAY_ALTERNATIVE
5458 -- end select;
5459
5460 -- Gigi restriction: This node never appears
5461
5462 -- N_Timed_Entry_Call
5463 -- Sloc points to SELECT
5464 -- Entry_Call_Alternative (Node1)
5465 -- Delay_Alternative (Node4)
5466
5467 -----------------------------------
5468 -- 9.7.2 Entry Call Alternative --
5469 -----------------------------------
5470
5471 -- ENTRY_CALL_ALTERNATIVE ::=
5472 -- PROCEDURE_OR_ENTRY_CALL [SEQUENCE_OF_STATEMENTS]
5473
5474 -- PROCEDURE_OR_ENTRY_CALL ::=
5475 -- PROCEDURE_CALL_STATEMENT | ENTRY_CALL_STATEMENT
5476
5477 -- Gigi restriction: This node never appears
5478
5479 -- N_Entry_Call_Alternative
5480 -- Sloc points to first token of entry call statement
5481 -- Entry_Call_Statement (Node1)
5482 -- Statements (List3) (set to Empty_List if no statements)
5483 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
5484
5485 -----------------------------------
5486 -- 9.7.3 Conditional Entry Call --
5487 -----------------------------------
5488
5489 -- CONDITIONAL_ENTRY_CALL ::=
5490 -- select
5491 -- ENTRY_CALL_ALTERNATIVE
5492 -- else
5493 -- SEQUENCE_OF_STATEMENTS
5494 -- end select;
5495
5496 -- Gigi restriction: This node never appears
5497
5498 -- N_Conditional_Entry_Call
5499 -- Sloc points to SELECT
5500 -- Entry_Call_Alternative (Node1)
5501 -- Else_Statements (List4)
5502
5503 --------------------------------
5504 -- 9.7.4 Asynchronous Select --
5505 --------------------------------
5506
5507 -- ASYNCHRONOUS_SELECT ::=
5508 -- select
5509 -- TRIGGERING_ALTERNATIVE
5510 -- then abort
5511 -- ABORTABLE_PART
5512 -- end select;
5513
5514 -- Note: asynchronous select is not permitted in Ada 83 mode
5515
5516 -- Gigi restriction: This node never appears
5517
5518 -- N_Asynchronous_Select
5519 -- Sloc points to SELECT
5520 -- Triggering_Alternative (Node1)
5521 -- Abortable_Part (Node2)
5522
5523 -----------------------------------
5524 -- 9.7.4 Triggering Alternative --
5525 -----------------------------------
5526
5527 -- TRIGGERING_ALTERNATIVE ::=
5528 -- TRIGGERING_STATEMENT [SEQUENCE_OF_STATEMENTS]
5529
5530 -- Gigi restriction: This node never appears
5531
5532 -- N_Triggering_Alternative
5533 -- Sloc points to first token of triggering statement
5534 -- Triggering_Statement (Node1)
5535 -- Statements (List3) (set to Empty_List if no statements)
5536 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
5537
5538 ---------------------------------
5539 -- 9.7.4 Triggering Statement --
5540 ---------------------------------
5541
5542 -- TRIGGERING_STATEMENT ::= PROCEDURE_OR_ENTRY_CALL | DELAY_STATEMENT
5543
5544 ---------------------------
5545 -- 9.7.4 Abortable Part --
5546 ---------------------------
5547
5548 -- ABORTABLE_PART ::= SEQUENCE_OF_STATEMENTS
5549
5550 -- Gigi restriction: This node never appears
5551
5552 -- N_Abortable_Part
5553 -- Sloc points to ABORT
5554 -- Statements (List3)
5555
5556 --------------------------
5557 -- 9.8 Abort Statement --
5558 --------------------------
5559
5560 -- ABORT_STATEMENT ::= abort task_NAME {, task_NAME};
5561
5562 -- Gigi restriction: This node never appears
5563
5564 -- N_Abort_Statement
5565 -- Sloc points to ABORT
5566 -- Names (List2)
5567
5568 -------------------------
5569 -- 10.1.1 Compilation --
5570 -------------------------
5571
5572 -- COMPILATION ::= {COMPILATION_UNIT}
5573
5574 -- There is no explicit node in the tree for a compilation, since in
5575 -- general the compiler is processing only a single compilation unit
5576 -- at a time. It is possible to parse multiple units in syntax check
5577 -- only mode, but the trees are discarded in that case.
5578
5579 ------------------------------
5580 -- 10.1.1 Compilation Unit --
5581 ------------------------------
5582
5583 -- COMPILATION_UNIT ::=
5584 -- CONTEXT_CLAUSE LIBRARY_ITEM
5585 -- | CONTEXT_CLAUSE SUBUNIT
5586
5587 -- The N_Compilation_Unit node itself represents the above syntax.
5588 -- However, there are two additional items not reflected in the above
5589 -- syntax. First we have the global declarations that are added by the
5590 -- code generator. These are outer level declarations (so they cannot
5591 -- be represented as being inside the units). An example is the wrapper
5592 -- subprograms that are created to do ABE checking. As always a list of
5593 -- declarations can contain actions as well (i.e. statements), and such
5594 -- statements are executed as part of the elaboration of the unit. Note
5595 -- that all such declarations are elaborated before the library unit.
5596
5597 -- Similarly, certain actions need to be elaborated at the completion
5598 -- of elaboration of the library unit (notably the statement that sets
5599 -- the Boolean flag indicating that elaboration is complete).
5600
5601 -- The third item not reflected in the syntax is pragmas that appear
5602 -- after the compilation unit. As always pragmas are a problem since
5603 -- they are not part of the formal syntax, but can be stuck into the
5604 -- source following a set of ad hoc rules, and we have to find an ad
5605 -- hoc way of sticking them into the tree. For pragmas that appear
5606 -- before the library unit, we just consider them to be part of the
5607 -- context clause, and pragmas can appear in the Context_Items list
5608 -- of the compilation unit. However, pragmas can also appear after
5609 -- the library item.
5610
5611 -- To deal with all these problems, we create an auxiliary node for
5612 -- a compilation unit, referenced from the N_Compilation_Unit node,
5613 -- that contains these items.
5614
5615 -- N_Compilation_Unit
5616 -- Sloc points to first token of defining unit name
5617 -- Library_Unit (Node4-Sem) corresponding/parent spec/body
5618 -- Context_Items (List1) context items and pragmas preceding unit
5619 -- Private_Present (Flag15) set if library unit has private keyword
5620 -- Unit (Node2) library item or subunit
5621 -- Aux_Decls_Node (Node5) points to the N_Compilation_Unit_Aux node
5622 -- Has_No_Elaboration_Code (Flag17-Sem)
5623 -- Body_Required (Flag13-Sem) set for spec if body is required
5624 -- Acts_As_Spec (Flag4-Sem) flag for subprogram body with no spec
5625 -- Context_Pending (Flag16-Sem)
5626 -- First_Inlined_Subprogram (Node3-Sem)
5627 -- Has_Pragma_Suppress_All (Flag14-Sem)
5628
5629 -- N_Compilation_Unit_Aux
5630 -- Sloc is a copy of the Sloc from the N_Compilation_Unit node
5631 -- Declarations (List2) (set to No_List if no global declarations)
5632 -- Actions (List1) (set to No_List if no actions)
5633 -- Pragmas_After (List5) pragmas after unit (set to No_List if none)
5634 -- Config_Pragmas (List4) config pragmas (set to Empty_List if none)
5635 -- Default_Storage_Pool (Node3-Sem)
5636
5637 --------------------------
5638 -- 10.1.1 Library Item --
5639 --------------------------
5640
5641 -- LIBRARY_ITEM ::=
5642 -- [private] LIBRARY_UNIT_DECLARATION
5643 -- | LIBRARY_UNIT_BODY
5644 -- | [private] LIBRARY_UNIT_RENAMING_DECLARATION
5645
5646 -- Note: PRIVATE is not allowed in Ada 83 mode
5647
5648 -- There is no explicit node in the tree for library item, instead
5649 -- the declaration or body, and the flag for private if present,
5650 -- appear in the N_Compilation_Unit node.
5651
5652 --------------------------------------
5653 -- 10.1.1 Library Unit Declaration --
5654 --------------------------------------
5655
5656 -- LIBRARY_UNIT_DECLARATION ::=
5657 -- SUBPROGRAM_DECLARATION | PACKAGE_DECLARATION
5658 -- | GENERIC_DECLARATION | GENERIC_INSTANTIATION
5659
5660 -----------------------------------------------
5661 -- 10.1.1 Library Unit Renaming Declaration --
5662 -----------------------------------------------
5663
5664 -- LIBRARY_UNIT_RENAMING_DECLARATION ::=
5665 -- PACKAGE_RENAMING_DECLARATION
5666 -- | GENERIC_RENAMING_DECLARATION
5667 -- | SUBPROGRAM_RENAMING_DECLARATION
5668
5669 -------------------------------
5670 -- 10.1.1 Library unit body --
5671 -------------------------------
5672
5673 -- LIBRARY_UNIT_BODY ::= SUBPROGRAM_BODY | PACKAGE_BODY
5674
5675 ------------------------------
5676 -- 10.1.1 Parent Unit Name --
5677 ------------------------------
5678
5679 -- PARENT_UNIT_NAME ::= NAME
5680
5681 ----------------------------
5682 -- 10.1.2 Context clause --
5683 ----------------------------
5684
5685 -- CONTEXT_CLAUSE ::= {CONTEXT_ITEM}
5686
5687 -- The context clause can include pragmas, and any pragmas that appear
5688 -- before the context clause proper (i.e. all configuration pragmas,
5689 -- also appear at the front of this list).
5690
5691 --------------------------
5692 -- 10.1.2 Context_Item --
5693 --------------------------
5694
5695 -- CONTEXT_ITEM ::= WITH_CLAUSE | USE_CLAUSE | WITH_TYPE_CLAUSE
5696
5697 -------------------------
5698 -- 10.1.2 With clause --
5699 -------------------------
5700
5701 -- WITH_CLAUSE ::=
5702 -- with library_unit_NAME {,library_unit_NAME};
5703
5704 -- A separate With clause is built for each name, so that we have
5705 -- a Corresponding_Spec field for each with'ed spec. The flags
5706 -- First_Name and Last_Name are used to reconstruct the exact
5707 -- source form. When a list of names appears in one with clause,
5708 -- the first name in the list has First_Name set, and the last
5709 -- has Last_Name set. If the with clause has only one name, then
5710 -- both of the flags First_Name and Last_Name are set in this name.
5711
5712 -- Note: in the case of implicit with's that are installed by the
5713 -- Rtsfind routine, Implicit_With is set, and the Sloc is typically
5714 -- set to Standard_Location, but it is incorrect to test the Sloc
5715 -- to find out if a with clause is implicit, test the flag instead.
5716
5717 -- N_With_Clause
5718 -- Sloc points to first token of library unit name
5719 -- Withed_Body (Node1-Sem)
5720 -- Name (Node2)
5721 -- Next_Implicit_With (Node3-Sem)
5722 -- Library_Unit (Node4-Sem)
5723 -- Corresponding_Spec (Node5-Sem)
5724 -- First_Name (Flag5) (set to True if first name or only one name)
5725 -- Last_Name (Flag6) (set to True if last name or only one name)
5726 -- Context_Installed (Flag13-Sem)
5727 -- Elaborate_Present (Flag4-Sem)
5728 -- Elaborate_All_Present (Flag14-Sem)
5729 -- Elaborate_All_Desirable (Flag9-Sem)
5730 -- Elaborate_Desirable (Flag11-Sem)
5731 -- Private_Present (Flag15) set if with_clause has private keyword
5732 -- Implicit_With (Flag16-Sem)
5733 -- Limited_Present (Flag17) set if LIMITED is present
5734 -- Limited_View_Installed (Flag18-Sem)
5735 -- Unreferenced_In_Spec (Flag7-Sem)
5736 -- No_Entities_Ref_In_Spec (Flag8-Sem)
5737
5738 -- Note: Limited_Present and Limited_View_Installed give support to
5739 -- Ada 2005 (AI-50217).
5740 -- Similarly, Private_Present gives support to AI-50262.
5741
5742 ----------------------
5743 -- With_Type clause --
5744 ----------------------
5745
5746 -- This is a GNAT extension, used to implement mutually recursive
5747 -- types declared in different packages.
5748 -- Note: this is now obsolete. The functionality of this construct
5749 -- is now implemented by the Ada 2005 Limited_with_Clause.
5750
5751 ---------------------
5752 -- 10.2 Body stub --
5753 ---------------------
5754
5755 -- BODY_STUB ::=
5756 -- SUBPROGRAM_BODY_STUB
5757 -- | PACKAGE_BODY_STUB
5758 -- | TASK_BODY_STUB
5759 -- | PROTECTED_BODY_STUB
5760
5761 ----------------------------------
5762 -- 10.1.3 Subprogram Body Stub --
5763 ----------------------------------
5764
5765 -- SUBPROGRAM_BODY_STUB ::=
5766 -- SUBPROGRAM_SPECIFICATION is separate;
5767
5768 -- N_Subprogram_Body_Stub
5769 -- Sloc points to FUNCTION or PROCEDURE
5770 -- Specification (Node1)
5771 -- Library_Unit (Node4-Sem) points to the subunit
5772 -- Corresponding_Body (Node5-Sem)
5773
5774 -------------------------------
5775 -- 10.1.3 Package Body Stub --
5776 -------------------------------
5777
5778 -- PACKAGE_BODY_STUB ::=
5779 -- package body DEFINING_IDENTIFIER is separate;
5780
5781 -- N_Package_Body_Stub
5782 -- Sloc points to PACKAGE
5783 -- Defining_Identifier (Node1)
5784 -- Library_Unit (Node4-Sem) points to the subunit
5785 -- Corresponding_Body (Node5-Sem)
5786
5787 ----------------------------
5788 -- 10.1.3 Task Body Stub --
5789 ----------------------------
5790
5791 -- TASK_BODY_STUB ::=
5792 -- task body DEFINING_IDENTIFIER is separate;
5793
5794 -- N_Task_Body_Stub
5795 -- Sloc points to TASK
5796 -- Defining_Identifier (Node1)
5797 -- Library_Unit (Node4-Sem) points to the subunit
5798 -- Corresponding_Body (Node5-Sem)
5799
5800 ---------------------------------
5801 -- 10.1.3 Protected Body Stub --
5802 ---------------------------------
5803
5804 -- PROTECTED_BODY_STUB ::=
5805 -- protected body DEFINING_IDENTIFIER is separate;
5806
5807 -- Note: protected body stubs are not allowed in Ada 83 mode
5808
5809 -- N_Protected_Body_Stub
5810 -- Sloc points to PROTECTED
5811 -- Defining_Identifier (Node1)
5812 -- Library_Unit (Node4-Sem) points to the subunit
5813 -- Corresponding_Body (Node5-Sem)
5814
5815 ---------------------
5816 -- 10.1.3 Subunit --
5817 ---------------------
5818
5819 -- SUBUNIT ::= separate (PARENT_UNIT_NAME) PROPER_BODY
5820
5821 -- N_Subunit
5822 -- Sloc points to SEPARATE
5823 -- Name (Node2) is the name of the parent unit
5824 -- Proper_Body (Node1) is the subunit body
5825 -- Corresponding_Stub (Node3-Sem) is the stub declaration for the unit.
5826
5827 ---------------------------------
5828 -- 11.1 Exception Declaration --
5829 ---------------------------------
5830
5831 -- EXCEPTION_DECLARATION ::= DEFINING_IDENTIFIER_LIST : exception
5832 -- [ASPECT_SPECIFICATIONS];
5833
5834 -- For consistency with object declarations etc., the parser converts
5835 -- the case of multiple identifiers being declared to a series of
5836 -- declarations in which the expression is copied, using the More_Ids
5837 -- and Prev_Ids flags to remember the source form as described in the
5838 -- section on "Handling of Defining Identifier Lists".
5839
5840 -- N_Exception_Declaration
5841 -- Sloc points to EXCEPTION
5842 -- Defining_Identifier (Node1)
5843 -- Expression (Node3-Sem)
5844 -- Renaming_Exception (Node2-Sem)
5845 -- More_Ids (Flag5) (set to False if no more identifiers in list)
5846 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
5847
5848 ------------------------------------------
5849 -- 11.2 Handled Sequence Of Statements --
5850 ------------------------------------------
5851
5852 -- HANDLED_SEQUENCE_OF_STATEMENTS ::=
5853 -- SEQUENCE_OF_STATEMENTS
5854 -- [exception
5855 -- EXCEPTION_HANDLER
5856 -- {EXCEPTION_HANDLER}]
5857 -- [at end
5858 -- cleanup_procedure_call (param, param, param, ...);]
5859
5860 -- The AT END phrase is a GNAT extension to provide for cleanups. It is
5861 -- used only internally currently, but is considered to be syntactic.
5862 -- At the moment, the only cleanup action allowed is a single call to
5863 -- a parameterless procedure, and the Identifier field of the node is
5864 -- the procedure to be called. Also there is a current restriction
5865 -- that exception handles and a cleanup cannot be present in the same
5866 -- frame, so at least one of Exception_Handlers or the Identifier must
5867 -- be missing.
5868
5869 -- Actually, more accurately, this restriction applies to the original
5870 -- source program. In the expanded tree, if the At_End_Proc field is
5871 -- present, then there will also be an exception handler of the form:
5872
5873 -- when all others =>
5874 -- cleanup;
5875 -- raise;
5876
5877 -- where cleanup is the procedure to be generated. The reason we do
5878 -- this is so that the front end can handle the necessary entries in
5879 -- the exception tables, and other exception handler actions required
5880 -- as part of the normal handling for exception handlers.
5881
5882 -- The AT END cleanup handler protects only the sequence of statements
5883 -- (not the associated declarations of the parent), just like exception
5884 -- handlers. The big difference is that the cleanup procedure is called
5885 -- on either a normal or an abnormal exit from the statement sequence.
5886
5887 -- Note: the list of Exception_Handlers can contain pragmas as well
5888 -- as actual handlers. In practice these pragmas can only occur at
5889 -- the start of the list, since any pragmas occurring later on will
5890 -- be included in the statement list of the corresponding handler.
5891
5892 -- Note: although in the Ada syntax, the sequence of statements in
5893 -- a handled sequence of statements can only contain statements, we
5894 -- allow free mixing of declarations and statements in the resulting
5895 -- expanded tree. This is for example used to deal with the case of
5896 -- a cleanup procedure that must handle declarations as well as the
5897 -- statements of a block.
5898
5899 -- N_Handled_Sequence_Of_Statements
5900 -- Sloc points to first token of first statement
5901 -- Statements (List3)
5902 -- End_Label (Node4) (set to Empty if expander generated)
5903 -- Exception_Handlers (List5) (set to No_List if none present)
5904 -- At_End_Proc (Node1) (set to Empty if no clean up procedure)
5905 -- First_Real_Statement (Node2-Sem)
5906 -- Zero_Cost_Handling (Flag5-Sem)
5907
5908 -- Note: the parent always contains a Declarations field which contains
5909 -- declarations associated with the handled sequence of statements. This
5910 -- is true even in the case of an accept statement (see description of
5911 -- the N_Accept_Statement node).
5912
5913 -- End_Label refers to the containing construct
5914
5915 -----------------------------
5916 -- 11.2 Exception Handler --
5917 -----------------------------
5918
5919 -- EXCEPTION_HANDLER ::=
5920 -- when [CHOICE_PARAMETER_SPECIFICATION :]
5921 -- EXCEPTION_CHOICE {| EXCEPTION_CHOICE} =>
5922 -- SEQUENCE_OF_STATEMENTS
5923
5924 -- Note: choice parameter specification is not allowed in Ada 83 mode
5925
5926 -- N_Exception_Handler
5927 -- Sloc points to WHEN
5928 -- Choice_Parameter (Node2) (set to Empty if not present)
5929 -- Exception_Choices (List4)
5930 -- Statements (List3)
5931 -- Exception_Label (Node5-Sem) (set to Empty of not present)
5932 -- Zero_Cost_Handling (Flag5-Sem)
5933 -- Local_Raise_Statements (Elist1-Sem) (set to No_Elist if not present)
5934 -- Local_Raise_Not_OK (Flag7-Sem)
5935 -- Has_Local_Raise (Flag8-Sem)
5936
5937 ------------------------------------------
5938 -- 11.2 Choice parameter specification --
5939 ------------------------------------------
5940
5941 -- CHOICE_PARAMETER_SPECIFICATION ::= DEFINING_IDENTIFIER
5942
5943 ----------------------------
5944 -- 11.2 Exception Choice --
5945 ----------------------------
5946
5947 -- EXCEPTION_CHOICE ::= exception_NAME | others
5948
5949 -- Except in the case of OTHERS, no explicit node appears in the tree
5950 -- for exception choice. Instead the exception name appears directly.
5951 -- An OTHERS choice is represented by a N_Others_Choice node (see
5952 -- section 3.8.1.
5953
5954 -- Note: for the exception choice created for an at end handler, the
5955 -- exception choice is an N_Others_Choice node with All_Others set.
5956
5957 ---------------------------
5958 -- 11.3 Raise Statement --
5959 ---------------------------
5960
5961 -- RAISE_STATEMENT ::= raise [exception_NAME];
5962
5963 -- In Ada 2005, we have
5964
5965 -- RAISE_STATEMENT ::= raise; | raise exception_NAME [with EXPRESSION];
5966
5967 -- N_Raise_Statement
5968 -- Sloc points to RAISE
5969 -- Name (Node2) (set to Empty if no exception name present)
5970 -- Expression (Node3) (set to Empty if no expression present)
5971 -- From_At_End (Flag4-Sem)
5972
5973 -------------------------------
5974 -- 12.1 Generic Declaration --
5975 -------------------------------
5976
5977 -- GENERIC_DECLARATION ::=
5978 -- GENERIC_SUBPROGRAM_DECLARATION | GENERIC_PACKAGE_DECLARATION
5979
5980 ------------------------------------------
5981 -- 12.1 Generic Subprogram Declaration --
5982 ------------------------------------------
5983
5984 -- GENERIC_SUBPROGRAM_DECLARATION ::=
5985 -- GENERIC_FORMAL_PART SUBPROGRAM_SPECIFICATION;
5986
5987 -- Note: Generic_Formal_Declarations can include pragmas
5988
5989 -- N_Generic_Subprogram_Declaration
5990 -- Sloc points to GENERIC
5991 -- Specification (Node1) subprogram specification
5992 -- Corresponding_Body (Node5-Sem)
5993 -- Generic_Formal_Declarations (List2) from generic formal part
5994 -- Parent_Spec (Node4-Sem)
5995
5996 ---------------------------------------
5997 -- 12.1 Generic Package Declaration --
5998 ---------------------------------------
5999
6000 -- GENERIC_PACKAGE_DECLARATION ::=
6001 -- GENERIC_FORMAL_PART PACKAGE_SPECIFICATION
6002 -- [ASPECT_SPECIFICATIONS];
6003
6004 -- Note: when we do generics right, the Activation_Chain_Entity entry
6005 -- for this node can be removed (since the expander won't see generic
6006 -- units any more)???.
6007
6008 -- Note: Generic_Formal_Declarations can include pragmas
6009
6010 -- N_Generic_Package_Declaration
6011 -- Sloc points to GENERIC
6012 -- Specification (Node1) package specification
6013 -- Corresponding_Body (Node5-Sem)
6014 -- Generic_Formal_Declarations (List2) from generic formal part
6015 -- Parent_Spec (Node4-Sem)
6016 -- Activation_Chain_Entity (Node3-Sem)
6017
6018 -------------------------------
6019 -- 12.1 Generic Formal Part --
6020 -------------------------------
6021
6022 -- GENERIC_FORMAL_PART ::=
6023 -- generic {GENERIC_FORMAL_PARAMETER_DECLARATION | USE_CLAUSE}
6024
6025 ------------------------------------------------
6026 -- 12.1 Generic Formal Parameter Declaration --
6027 ------------------------------------------------
6028
6029 -- GENERIC_FORMAL_PARAMETER_DECLARATION ::=
6030 -- FORMAL_OBJECT_DECLARATION
6031 -- | FORMAL_TYPE_DECLARATION
6032 -- | FORMAL_SUBPROGRAM_DECLARATION
6033 -- | FORMAL_PACKAGE_DECLARATION
6034
6035 ---------------------------------
6036 -- 12.3 Generic Instantiation --
6037 ---------------------------------
6038
6039 -- GENERIC_INSTANTIATION ::=
6040 -- package DEFINING_PROGRAM_UNIT_NAME is
6041 -- new generic_package_NAME [GENERIC_ACTUAL_PART]
6042 -- [ASPECT_SPECIFICATIONS];
6043 -- | [[not] overriding]
6044 -- procedure DEFINING_PROGRAM_UNIT_NAME is
6045 -- new generic_procedure_NAME [GENERIC_ACTUAL_PART]
6046 -- [ASPECT_SPECIFICATIONS];
6047 -- | [[not] overriding]
6048 -- function DEFINING_DESIGNATOR is
6049 -- new generic_function_NAME [GENERIC_ACTUAL_PART]
6050 -- [ASPECT_SPECIFICATIONS];
6051
6052 -- N_Package_Instantiation
6053 -- Sloc points to PACKAGE
6054 -- Defining_Unit_Name (Node1)
6055 -- Name (Node2)
6056 -- Generic_Associations (List3) (set to No_List if no
6057 -- generic actual part)
6058 -- Parent_Spec (Node4-Sem)
6059 -- Instance_Spec (Node5-Sem)
6060 -- ABE_Is_Certain (Flag18-Sem)
6061
6062 -- N_Procedure_Instantiation
6063 -- Sloc points to PROCEDURE
6064 -- Defining_Unit_Name (Node1)
6065 -- Name (Node2)
6066 -- Parent_Spec (Node4-Sem)
6067 -- Generic_Associations (List3) (set to No_List if no
6068 -- generic actual part)
6069 -- Instance_Spec (Node5-Sem)
6070 -- Must_Override (Flag14) set if overriding indicator present
6071 -- Must_Not_Override (Flag15) set if not_overriding indicator present
6072 -- ABE_Is_Certain (Flag18-Sem)
6073
6074 -- N_Function_Instantiation
6075 -- Sloc points to FUNCTION
6076 -- Defining_Unit_Name (Node1)
6077 -- Name (Node2)
6078 -- Generic_Associations (List3) (set to No_List if no
6079 -- generic actual part)
6080 -- Parent_Spec (Node4-Sem)
6081 -- Instance_Spec (Node5-Sem)
6082 -- Must_Override (Flag14) set if overriding indicator present
6083 -- Must_Not_Override (Flag15) set if not_overriding indicator present
6084 -- ABE_Is_Certain (Flag18-Sem)
6085
6086 -- Note: overriding indicator is an Ada 2005 feature
6087
6088 -------------------------------
6089 -- 12.3 Generic Actual Part --
6090 -------------------------------
6091
6092 -- GENERIC_ACTUAL_PART ::=
6093 -- (GENERIC_ASSOCIATION {, GENERIC_ASSOCIATION})
6094
6095 -------------------------------
6096 -- 12.3 Generic Association --
6097 -------------------------------
6098
6099 -- GENERIC_ASSOCIATION ::=
6100 -- [generic_formal_parameter_SELECTOR_NAME =>]
6101
6102 -- Note: unlike the procedure call case, a generic association node
6103 -- is generated for every association, even if no formal parameter
6104 -- selector name is present. In this case the parser will leave the
6105 -- Selector_Name field set to Empty, to be filled in later by the
6106 -- semantic pass.
6107
6108 -- In Ada 2005, a formal may be associated with a box, if the
6109 -- association is part of the list of actuals for a formal package.
6110 -- If the association is given by OTHERS => <>, the association is
6111 -- an N_Others_Choice.
6112
6113 -- N_Generic_Association
6114 -- Sloc points to first token of generic association
6115 -- Selector_Name (Node2) (set to Empty if no formal
6116 -- parameter selector name)
6117 -- Explicit_Generic_Actual_Parameter (Node1) (Empty if box present)
6118 -- Box_Present (Flag15) (for formal_package associations with a box)
6119
6120 ---------------------------------------------
6121 -- 12.3 Explicit Generic Actual Parameter --
6122 ---------------------------------------------
6123
6124 -- EXPLICIT_GENERIC_ACTUAL_PARAMETER ::=
6125 -- EXPRESSION | variable_NAME | subprogram_NAME
6126 -- | entry_NAME | SUBTYPE_MARK | package_instance_NAME
6127
6128 -------------------------------------
6129 -- 12.4 Formal Object Declaration --
6130 -------------------------------------
6131
6132 -- FORMAL_OBJECT_DECLARATION ::=
6133 -- DEFINING_IDENTIFIER_LIST :
6134 -- MODE [NULL_EXCLUSION] SUBTYPE_MARK [:= DEFAULT_EXPRESSION]
6135 -- [ASPECT_SPECIFICATIONS];
6136 -- | DEFINING_IDENTIFIER_LIST :
6137 -- MODE ACCESS_DEFINITION [:= DEFAULT_EXPRESSION]
6138 -- [ASPECT_SPECIFICATIONS];
6139
6140 -- Although the syntax allows multiple identifiers in the list, the
6141 -- semantics is as though successive declarations were given with
6142 -- identical type definition and expression components. To simplify
6143 -- semantic processing, the parser represents a multiple declaration
6144 -- case as a sequence of single declarations, using the More_Ids and
6145 -- Prev_Ids flags to preserve the original source form as described
6146 -- in the section on "Handling of Defining Identifier Lists".
6147
6148 -- N_Formal_Object_Declaration
6149 -- Sloc points to first identifier
6150 -- Defining_Identifier (Node1)
6151 -- In_Present (Flag15)
6152 -- Out_Present (Flag17)
6153 -- Null_Exclusion_Present (Flag11) (set to False if not present)
6154 -- Subtype_Mark (Node4) (set to Empty if not present)
6155 -- Access_Definition (Node3) (set to Empty if not present)
6156 -- Default_Expression (Node5) (set to Empty if no default expression)
6157 -- More_Ids (Flag5) (set to False if no more identifiers in list)
6158 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
6159
6160 -----------------------------------
6161 -- 12.5 Formal Type Declaration --
6162 -----------------------------------
6163
6164 -- FORMAL_TYPE_DECLARATION ::=
6165 -- type DEFINING_IDENTIFIER [DISCRIMINANT_PART]
6166 -- is FORMAL_TYPE_DEFINITION
6167 -- [ASPECT_SPECIFICATIONS];
6168
6169 -- N_Formal_Type_Declaration
6170 -- Sloc points to TYPE
6171 -- Defining_Identifier (Node1)
6172 -- Formal_Type_Definition (Node3)
6173 -- Discriminant_Specifications (List4) (set to No_List if no
6174 -- discriminant part)
6175 -- Unknown_Discriminants_Present (Flag13) set if (<>) discriminant
6176
6177 ----------------------------------
6178 -- 12.5 Formal type definition --
6179 ----------------------------------
6180
6181 -- FORMAL_TYPE_DEFINITION ::=
6182 -- FORMAL_PRIVATE_TYPE_DEFINITION
6183 -- | FORMAL_DERIVED_TYPE_DEFINITION
6184 -- | FORMAL_DISCRETE_TYPE_DEFINITION
6185 -- | FORMAL_SIGNED_INTEGER_TYPE_DEFINITION
6186 -- | FORMAL_MODULAR_TYPE_DEFINITION
6187 -- | FORMAL_FLOATING_POINT_DEFINITION
6188 -- | FORMAL_ORDINARY_FIXED_POINT_DEFINITION
6189 -- | FORMAL_DECIMAL_FIXED_POINT_DEFINITION
6190 -- | FORMAL_ARRAY_TYPE_DEFINITION
6191 -- | FORMAL_ACCESS_TYPE_DEFINITION
6192 -- | FORMAL_INTERFACE_TYPE_DEFINITION
6193
6194 ---------------------------------------------
6195 -- 12.5.1 Formal Private Type Definition --
6196 ---------------------------------------------
6197
6198 -- FORMAL_PRIVATE_TYPE_DEFINITION ::=
6199 -- [[abstract] tagged] [limited] private
6200
6201 -- Note: TAGGED is not allowed in Ada 83 mode
6202
6203 -- N_Formal_Private_Type_Definition
6204 -- Sloc points to PRIVATE
6205 -- Abstract_Present (Flag4)
6206 -- Tagged_Present (Flag15)
6207 -- Limited_Present (Flag17)
6208
6209 --------------------------------------------
6210 -- 12.5.1 Formal Derived Type Definition --
6211 --------------------------------------------
6212
6213 -- FORMAL_DERIVED_TYPE_DEFINITION ::=
6214 -- [abstract] [limited | synchronized]
6215 -- new SUBTYPE_MARK [[and INTERFACE_LIST] with private]
6216 -- Note: this construct is not allowed in Ada 83 mode
6217
6218 -- N_Formal_Derived_Type_Definition
6219 -- Sloc points to NEW
6220 -- Subtype_Mark (Node4)
6221 -- Private_Present (Flag15)
6222 -- Abstract_Present (Flag4)
6223 -- Limited_Present (Flag17)
6224 -- Synchronized_Present (Flag7)
6225 -- Interface_List (List2) (set to No_List if none)
6226
6227 ---------------------------------------------
6228 -- 12.5.2 Formal Discrete Type Definition --
6229 ---------------------------------------------
6230
6231 -- FORMAL_DISCRETE_TYPE_DEFINITION ::= (<>)
6232
6233 -- N_Formal_Discrete_Type_Definition
6234 -- Sloc points to (
6235
6236 ---------------------------------------------------
6237 -- 12.5.2 Formal Signed Integer Type Definition --
6238 ---------------------------------------------------
6239
6240 -- FORMAL_SIGNED_INTEGER_TYPE_DEFINITION ::= range <>
6241
6242 -- N_Formal_Signed_Integer_Type_Definition
6243 -- Sloc points to RANGE
6244
6245 --------------------------------------------
6246 -- 12.5.2 Formal Modular Type Definition --
6247 --------------------------------------------
6248
6249 -- FORMAL_MODULAR_TYPE_DEFINITION ::= mod <>
6250
6251 -- N_Formal_Modular_Type_Definition
6252 -- Sloc points to MOD
6253
6254 ----------------------------------------------
6255 -- 12.5.2 Formal Floating Point Definition --
6256 ----------------------------------------------
6257
6258 -- FORMAL_FLOATING_POINT_DEFINITION ::= digits <>
6259
6260 -- N_Formal_Floating_Point_Definition
6261 -- Sloc points to DIGITS
6262
6263 ----------------------------------------------------
6264 -- 12.5.2 Formal Ordinary Fixed Point Definition --
6265 ----------------------------------------------------
6266
6267 -- FORMAL_ORDINARY_FIXED_POINT_DEFINITION ::= delta <>
6268
6269 -- N_Formal_Ordinary_Fixed_Point_Definition
6270 -- Sloc points to DELTA
6271
6272 ---------------------------------------------------
6273 -- 12.5.2 Formal Decimal Fixed Point Definition --
6274 ---------------------------------------------------
6275
6276 -- FORMAL_DECIMAL_FIXED_POINT_DEFINITION ::= delta <> digits <>
6277
6278 -- Note: formal decimal fixed point definition not allowed in Ada 83
6279
6280 -- N_Formal_Decimal_Fixed_Point_Definition
6281 -- Sloc points to DELTA
6282
6283 ------------------------------------------
6284 -- 12.5.3 Formal Array Type Definition --
6285 ------------------------------------------
6286
6287 -- FORMAL_ARRAY_TYPE_DEFINITION ::= ARRAY_TYPE_DEFINITION
6288
6289 -------------------------------------------
6290 -- 12.5.4 Formal Access Type Definition --
6291 -------------------------------------------
6292
6293 -- FORMAL_ACCESS_TYPE_DEFINITION ::= ACCESS_TYPE_DEFINITION
6294
6295 ----------------------------------------------
6296 -- 12.5.5 Formal Interface Type Definition --
6297 ----------------------------------------------
6298
6299 -- FORMAL_INTERFACE_TYPE_DEFINITION ::= INTERFACE_TYPE_DEFINITION
6300
6301 -----------------------------------------
6302 -- 12.6 Formal Subprogram Declaration --
6303 -----------------------------------------
6304
6305 -- FORMAL_SUBPROGRAM_DECLARATION ::=
6306 -- FORMAL_CONCRETE_SUBPROGRAM_DECLARATION
6307 -- | FORMAL_ABSTRACT_SUBPROGRAM_DECLARATION
6308
6309 --------------------------------------------------
6310 -- 12.6 Formal Concrete Subprogram Declaration --
6311 --------------------------------------------------
6312
6313 -- FORMAL_CONCRETE_SUBPROGRAM_DECLARATION ::=
6314 -- with SUBPROGRAM_SPECIFICATION [is SUBPROGRAM_DEFAULT]
6315 -- [ASPECT_SPECIFICATIONS];
6316
6317 -- N_Formal_Concrete_Subprogram_Declaration
6318 -- Sloc points to WITH
6319 -- Specification (Node1)
6320 -- Default_Name (Node2) (set to Empty if no subprogram default)
6321 -- Box_Present (Flag15)
6322
6323 -- Note: if no subprogram default is present, then Name is set
6324 -- to Empty, and Box_Present is False.
6325
6326 --------------------------------------------------
6327 -- 12.6 Formal Abstract Subprogram Declaration --
6328 --------------------------------------------------
6329
6330 -- FORMAL_ABSTRACT_SUBPROGRAM_DECLARATION ::=
6331 -- with SUBPROGRAM_SPECIFICATION is abstract [SUBPROGRAM_DEFAULT]
6332 -- [ASPECT_SPECIFICATIONS];
6333
6334 -- N_Formal_Abstract_Subprogram_Declaration
6335 -- Sloc points to WITH
6336 -- Specification (Node1)
6337 -- Default_Name (Node2) (set to Empty if no subprogram default)
6338 -- Box_Present (Flag15)
6339
6340 -- Note: if no subprogram default is present, then Name is set
6341 -- to Empty, and Box_Present is False.
6342
6343 ------------------------------
6344 -- 12.6 Subprogram Default --
6345 ------------------------------
6346
6347 -- SUBPROGRAM_DEFAULT ::= DEFAULT_NAME | <>
6348
6349 -- There is no separate node in the tree for a subprogram default.
6350 -- Instead the parent (N_Formal_Concrete_Subprogram_Declaration
6351 -- or N_Formal_Abstract_Subprogram_Declaration) node contains the
6352 -- default name or box indication, as needed.
6353
6354 ------------------------
6355 -- 12.6 Default Name --
6356 ------------------------
6357
6358 -- DEFAULT_NAME ::= NAME
6359
6360 --------------------------------------
6361 -- 12.7 Formal Package Declaration --
6362 --------------------------------------
6363
6364 -- FORMAL_PACKAGE_DECLARATION ::=
6365 -- with package DEFINING_IDENTIFIER
6366 -- is new generic_package_NAME FORMAL_PACKAGE_ACTUAL_PART
6367 -- [ASPECT_SPECIFICATIONS];
6368
6369 -- Note: formal package declarations not allowed in Ada 83 mode
6370
6371 -- N_Formal_Package_Declaration
6372 -- Sloc points to WITH
6373 -- Defining_Identifier (Node1)
6374 -- Name (Node2)
6375 -- Generic_Associations (List3) (set to No_List if (<>) case or
6376 -- empty generic actual part)
6377 -- Box_Present (Flag15)
6378 -- Instance_Spec (Node5-Sem)
6379 -- ABE_Is_Certain (Flag18-Sem)
6380
6381 --------------------------------------
6382 -- 12.7 Formal Package Actual Part --
6383 --------------------------------------
6384
6385 -- FORMAL_PACKAGE_ACTUAL_PART ::=
6386 -- ([OTHERS] => <>)
6387 -- | [GENERIC_ACTUAL_PART]
6388 -- (FORMAL_PACKAGE_ASSOCIATION {. FORMAL_PACKAGE_ASSOCIATION}
6389
6390 -- FORMAL_PACKAGE_ASSOCIATION ::=
6391 -- GENERIC_ASSOCIATION
6392 -- | GENERIC_FORMAL_PARAMETER_SELECTOR_NAME => <>
6393
6394 -- There is no explicit node in the tree for a formal package actual
6395 -- part. Instead the information appears in the parent node (i.e. the
6396 -- formal package declaration node itself).
6397
6398 -- There is no explicit node for a formal package association. All of
6399 -- them are represented either by a generic association, possibly with
6400 -- Box_Present, or by an N_Others_Choice.
6401
6402 ---------------------------------
6403 -- 13.1 Representation clause --
6404 ---------------------------------
6405
6406 -- REPRESENTATION_CLAUSE ::=
6407 -- ATTRIBUTE_DEFINITION_CLAUSE
6408 -- | ENUMERATION_REPRESENTATION_CLAUSE
6409 -- | RECORD_REPRESENTATION_CLAUSE
6410 -- | AT_CLAUSE
6411
6412 ----------------------
6413 -- 13.1 Local Name --
6414 ----------------------
6415
6416 -- LOCAL_NAME :=
6417 -- DIRECT_NAME
6418 -- | DIRECT_NAME'ATTRIBUTE_DESIGNATOR
6419 -- | library_unit_NAME
6420
6421 -- The construct DIRECT_NAME'ATTRIBUTE_DESIGNATOR appears in the tree
6422 -- as an attribute reference, which has essentially the same form.
6423
6424 ---------------------------------------
6425 -- 13.3 Attribute definition clause --
6426 ---------------------------------------
6427
6428 -- ATTRIBUTE_DEFINITION_CLAUSE ::=
6429 -- for LOCAL_NAME'ATTRIBUTE_DESIGNATOR use EXPRESSION;
6430 -- | for LOCAL_NAME'ATTRIBUTE_DESIGNATOR use NAME;
6431
6432 -- In Ada 83, the expression must be a simple expression and the
6433 -- local name must be a direct name.
6434
6435 -- Note: the only attribute definition clause that is processed by
6436 -- gigi is an address clause. For all other cases, the information
6437 -- is extracted by the front end and either results in setting entity
6438 -- information, e.g. Esize for the Size clause, or in appropriate
6439 -- expansion actions (e.g. in the case of Storage_Size).
6440
6441 -- For an address clause, Gigi constructs the appropriate addressing
6442 -- code. It also ensures that no aliasing optimizations are made
6443 -- for the object for which the address clause appears.
6444
6445 -- Note: for an address clause used to achieve an overlay:
6446
6447 -- A : Integer;
6448 -- B : Integer;
6449 -- for B'Address use A'Address;
6450
6451 -- the above rule means that Gigi will ensure that no optimizations
6452 -- will be made for B that would violate the implementation advice
6453 -- of RM 13.3(19). However, this advice applies only to B and not
6454 -- to A, which seems unfortunate. The GNAT front end will mark the
6455 -- object A as volatile to also prevent unwanted optimization
6456 -- assumptions based on no aliasing being made for B.
6457
6458 -- N_Attribute_Definition_Clause
6459 -- Sloc points to FOR
6460 -- Name (Node2) the local name
6461 -- Chars (Name1) the identifier name from the attribute designator
6462 -- Expression (Node3) the expression or name
6463 -- Entity (Node4-Sem)
6464 -- Next_Rep_Item (Node5-Sem)
6465 -- From_At_Mod (Flag4-Sem)
6466 -- Check_Address_Alignment (Flag11-Sem)
6467 -- From_Aspect_Specification (Flag13-Sem)
6468 -- Is_Delayed_Aspect (Flag14-Sem)
6469 -- Address_Warning_Posted (Flag18-Sem)
6470
6471 -- Note: if From_Aspect_Specification is set, then Sloc points to the
6472 -- aspect name, and Entity is resolved already to reference the entity
6473 -- to which the aspect applies.
6474
6475 -----------------------------------
6476 -- 13.3.1 Aspect Specifications --
6477 -----------------------------------
6478
6479 -- We modify the RM grammar here, the RM grammar is:
6480
6481 -- ASPECT_SPECIFICATION ::=
6482 -- with ASPECT_MARK [=> ASPECT_DEFINITION] {.
6483 -- ASPECT_MARK [=> ASPECT_DEFINITION] }
6484
6485 -- ASPECT_MARK ::= aspect_IDENTIFIER['Class]
6486
6487 -- ASPECT_DEFINITION ::= NAME | EXPRESSION
6488
6489 -- That's inconvenient, since there is no non-terminal name for a single
6490 -- entry in the list of aspects. So we use this grammar instead:
6491
6492 -- ASPECT_SPECIFICATIONS ::=
6493 -- with ASPECT_SPECIFICATION {, ASPECT_SPECIFICATION}
6494
6495 -- ASPECT_SPECIFICATION =>
6496 -- ASPECT_MARK [=> ASPECT_DEFINITION]
6497
6498 -- ASPECT_MARK ::= aspect_IDENTIFIER['Class]
6499
6500 -- ASPECT_DEFINITION ::= NAME | EXPRESSION
6501
6502 -- See separate package Aspects for details on the incorporation of
6503 -- these nodes into the tree, and how aspect specifications for a given
6504 -- declaration node are associated with that node.
6505
6506 -- N_Aspect_Specification
6507 -- Sloc points to aspect identifier
6508 -- Identifier (Node1) aspect identifier
6509 -- Aspect_Rep_Item (Node2-Sem)
6510 -- Expression (Node3) Aspect_Definition (set to Empty if none)
6511 -- Entity (Node4-Sem) entity to which the aspect applies
6512 -- Class_Present (Flag6) Set if 'Class present
6513 -- Next_Rep_Item (Node5-Sem)
6514 -- Split_PPC (Flag17) Set if split pre/post attribute
6515
6516 -- Note: Aspect_Specification is an Ada 2012 feature
6517
6518 -- Note: When a Pre or Post aspect specification is processed, it is
6519 -- broken into AND THEN sections. The left most section has Split_PPC
6520 -- set to False, indicating that it is the original specification (e.g.
6521 -- for posting errors). For the other sections, Split_PPC is set True.
6522
6523 ---------------------------------------------
6524 -- 13.4 Enumeration representation clause --
6525 ---------------------------------------------
6526
6527 -- ENUMERATION_REPRESENTATION_CLAUSE ::=
6528 -- for first_subtype_LOCAL_NAME use ENUMERATION_AGGREGATE;
6529
6530 -- In Ada 83, the name must be a direct name
6531
6532 -- N_Enumeration_Representation_Clause
6533 -- Sloc points to FOR
6534 -- Identifier (Node1) direct name
6535 -- Array_Aggregate (Node3)
6536 -- Next_Rep_Item (Node5-Sem)
6537
6538 ---------------------------------
6539 -- 13.4 Enumeration aggregate --
6540 ---------------------------------
6541
6542 -- ENUMERATION_AGGREGATE ::= ARRAY_AGGREGATE
6543
6544 ------------------------------------------
6545 -- 13.5.1 Record representation clause --
6546 ------------------------------------------
6547
6548 -- RECORD_REPRESENTATION_CLAUSE ::=
6549 -- for first_subtype_LOCAL_NAME use
6550 -- record [MOD_CLAUSE]
6551 -- {COMPONENT_CLAUSE}
6552 -- end record;
6553
6554 -- Gigi restriction: Mod_Clause is always Empty (if present it is
6555 -- replaced by a corresponding Alignment attribute definition clause).
6556
6557 -- Note: Component_Clauses can include pragmas
6558
6559 -- N_Record_Representation_Clause
6560 -- Sloc points to FOR
6561 -- Identifier (Node1) direct name
6562 -- Mod_Clause (Node2) (set to Empty if no mod clause present)
6563 -- Component_Clauses (List3)
6564 -- Next_Rep_Item (Node5-Sem)
6565
6566 ------------------------------
6567 -- 13.5.1 Component clause --
6568 ------------------------------
6569
6570 -- COMPONENT_CLAUSE ::=
6571 -- component_LOCAL_NAME at POSITION
6572 -- range FIRST_BIT .. LAST_BIT;
6573
6574 -- N_Component_Clause
6575 -- Sloc points to AT
6576 -- Component_Name (Node1) points to Name or Attribute_Reference
6577 -- Position (Node2)
6578 -- First_Bit (Node3)
6579 -- Last_Bit (Node4)
6580
6581 ----------------------
6582 -- 13.5.1 Position --
6583 ----------------------
6584
6585 -- POSITION ::= static_EXPRESSION
6586
6587 -----------------------
6588 -- 13.5.1 First_Bit --
6589 -----------------------
6590
6591 -- FIRST_BIT ::= static_SIMPLE_EXPRESSION
6592
6593 ----------------------
6594 -- 13.5.1 Last_Bit --
6595 ----------------------
6596
6597 -- LAST_BIT ::= static_SIMPLE_EXPRESSION
6598
6599 --------------------------
6600 -- 13.8 Code statement --
6601 --------------------------
6602
6603 -- CODE_STATEMENT ::= QUALIFIED_EXPRESSION;
6604
6605 -- Note: in GNAT, the qualified expression has the form
6606
6607 -- Asm_Insn'(Asm (...));
6608
6609 -- See package System.Machine_Code in file s-maccod.ads for details on
6610 -- the allowed parameters to Asm. There are two ways this node can
6611 -- arise, as a code statement, in which case the expression is the
6612 -- qualified expression, or as a result of the expansion of an intrinsic
6613 -- call to the Asm or Asm_Input procedure.
6614
6615 -- N_Code_Statement
6616 -- Sloc points to first token of the expression
6617 -- Expression (Node3)
6618
6619 -- Note: package Exp_Code contains an abstract functional interface
6620 -- for use by Gigi in accessing the data from N_Code_Statement nodes.
6621
6622 ------------------------
6623 -- 13.12 Restriction --
6624 ------------------------
6625
6626 -- RESTRICTION ::=
6627 -- restriction_IDENTIFIER
6628 -- | restriction_parameter_IDENTIFIER => EXPRESSION
6629
6630 -- There is no explicit node for restrictions. Instead the restriction
6631 -- appears in normal pragma syntax as a pragma argument association,
6632 -- which has the same syntactic form.
6633
6634 --------------------------
6635 -- B.2 Shift Operators --
6636 --------------------------
6637
6638 -- Calls to the intrinsic shift functions are converted to one of
6639 -- the following shift nodes, which have the form of normal binary
6640 -- operator names. Note that for a given shift operation, one node
6641 -- covers all possible types, as for normal operators.
6642
6643 -- Note: it is perfectly permissible for the expander to generate
6644 -- shift operation nodes directly, in which case they will be analyzed
6645 -- and parsed in the usual manner.
6646
6647 -- Sprint syntax: shift-function-name!(expr, count)
6648
6649 -- Note: the Left_Opnd field holds the first argument (the value to
6650 -- be shifted). The Right_Opnd field holds the second argument (the
6651 -- shift count). The Chars field is the name of the intrinsic function.
6652
6653 -- N_Op_Rotate_Left
6654 -- Sloc points to the function name
6655 -- plus fields for binary operator
6656 -- plus fields for expression
6657 -- Shift_Count_OK (Flag4-Sem)
6658
6659 -- N_Op_Rotate_Right
6660 -- Sloc points to the function name
6661 -- plus fields for binary operator
6662 -- plus fields for expression
6663 -- Shift_Count_OK (Flag4-Sem)
6664
6665 -- N_Op_Shift_Left
6666 -- Sloc points to the function name
6667 -- plus fields for binary operator
6668 -- plus fields for expression
6669 -- Shift_Count_OK (Flag4-Sem)
6670
6671 -- N_Op_Shift_Right_Arithmetic
6672 -- Sloc points to the function name
6673 -- plus fields for binary operator
6674 -- plus fields for expression
6675 -- Shift_Count_OK (Flag4-Sem)
6676
6677 -- N_Op_Shift_Right
6678 -- Sloc points to the function name
6679 -- plus fields for binary operator
6680 -- plus fields for expression
6681 -- Shift_Count_OK (Flag4-Sem)
6682
6683 --------------------------
6684 -- Obsolescent Features --
6685 --------------------------
6686
6687 -- The syntax descriptions and tree nodes for obsolescent features are
6688 -- grouped together, corresponding to their location in appendix I in
6689 -- the RM. However, parsing and semantic analysis for these constructs
6690 -- is located in an appropriate chapter (see individual notes).
6691
6692 ---------------------------
6693 -- J.3 Delta Constraint --
6694 ---------------------------
6695
6696 -- Note: the parse routine for this construct is located in section
6697 -- 3.5.9 of Par-Ch3, and semantic analysis is in Sem_Ch3, which is
6698 -- where delta constraint logically belongs.
6699
6700 -- DELTA_CONSTRAINT ::= DELTA static_EXPRESSION [RANGE_CONSTRAINT]
6701
6702 -- N_Delta_Constraint
6703 -- Sloc points to DELTA
6704 -- Delta_Expression (Node3)
6705 -- Range_Constraint (Node4) (set to Empty if not present)
6706
6707 --------------------
6708 -- J.7 At Clause --
6709 --------------------
6710
6711 -- AT_CLAUSE ::= for DIRECT_NAME use at EXPRESSION;
6712
6713 -- Note: the parse routine for this construct is located in Par-Ch13,
6714 -- and the semantic analysis is in Sem_Ch13, where at clause logically
6715 -- belongs if it were not obsolescent.
6716
6717 -- Note: in Ada 83 the expression must be a simple expression
6718
6719 -- Gigi restriction: This node never appears, it is rewritten as an
6720 -- address attribute definition clause.
6721
6722 -- N_At_Clause
6723 -- Sloc points to FOR
6724 -- Identifier (Node1)
6725 -- Expression (Node3)
6726
6727 ---------------------
6728 -- J.8 Mod clause --
6729 ---------------------
6730
6731 -- MOD_CLAUSE ::= at mod static_EXPRESSION;
6732
6733 -- Note: the parse routine for this construct is located in Par-Ch13,
6734 -- and the semantic analysis is in Sem_Ch13, where mod clause logically
6735 -- belongs if it were not obsolescent.
6736
6737 -- Note: in Ada 83, the expression must be a simple expression
6738
6739 -- Gigi restriction: this node never appears. It is replaced
6740 -- by a corresponding Alignment attribute definition clause.
6741
6742 -- Note: pragmas can appear before and after the MOD_CLAUSE since
6743 -- its name has "clause" in it. This is rather strange, but is quite
6744 -- definitely specified. The pragmas before are collected in the
6745 -- Pragmas_Before field of the mod clause node itself, and pragmas
6746 -- after are simply swallowed up in the list of component clauses.
6747
6748 -- N_Mod_Clause
6749 -- Sloc points to AT
6750 -- Expression (Node3)
6751 -- Pragmas_Before (List4) Pragmas before mod clause (No_List if none)
6752
6753 --------------------
6754 -- Semantic Nodes --
6755 --------------------
6756
6757 -- These semantic nodes are used to hold additional semantic information.
6758 -- They are inserted into the tree as a result of semantic processing.
6759 -- Although there are no legitimate source syntax constructions that
6760 -- correspond directly to these nodes, we need a source syntax for the
6761 -- reconstructed tree printed by Sprint, and the node descriptions here
6762 -- show this syntax.
6763
6764 -- Note: Case_Expression and Conditional_Expression is in this section for
6765 -- now, since they are extensions. We will move them to their appropriate
6766 -- places when they are officially approved as extensions (and then we will
6767 -- know what the exact grammar and place in the Reference Manual is!)
6768
6769 ---------------------
6770 -- Case Expression --
6771 ---------------------
6772
6773 -- CASE_EXPRESSION ::=
6774 -- case EXPRESSION is
6775 -- CASE_EXPRESSION_ALTERNATIVE
6776 -- {CASE_EXPRESSION_ALTERNATIVE}
6777
6778 -- Note that the Alternatives cannot include pragmas (this constrasts
6779 -- with the situation of case statements where pragmas are allowed).
6780
6781 -- N_Case_Expression
6782 -- Sloc points to CASE
6783 -- Expression (Node3)
6784 -- Alternatives (List4)
6785
6786 ---------------------------------
6787 -- Case Expression Alternative --
6788 ---------------------------------
6789
6790 -- CASE_STATEMENT_ALTERNATIVE ::=
6791 -- when DISCRETE_CHOICE_LIST =>
6792 -- EXPRESSION
6793
6794 -- N_Case_Expression_Alternative
6795 -- Sloc points to WHEN
6796 -- Actions (List1)
6797 -- Discrete_Choices (List4)
6798 -- Expression (Node3)
6799
6800 -- Note: The Actions field temporarily holds any actions associated with
6801 -- evaluation of the Expression. During expansion of the case expression
6802 -- these actions are wrapped into the an N_Expressions_With_Actions node
6803 -- replacing the original expression.
6804
6805 ----------------------------
6806 -- Conditional Expression --
6807 ----------------------------
6808
6809 -- This node is used to represent an expression corresponding to the
6810 -- C construct (condition ? then-expression : else_expression), where
6811 -- Expressions is a three element list, whose first expression is the
6812 -- condition, and whose second and third expressions are the then and
6813 -- else expressions respectively.
6814
6815 -- Note: the Then_Actions and Else_Actions fields are always set to
6816 -- No_List in the tree passed to Gigi. These fields are used only
6817 -- for temporary processing purposes in the expander.
6818
6819 -- The Ada language does not permit conditional expressions, however
6820 -- this is under discussion as a possible extension by the ARG, and we
6821 -- have implemented a form of this capability in GNAT under control of
6822 -- the -gnatX switch. The syntax is:
6823
6824 -- CONDITIONAL_EXPRESSION ::=
6825 -- if EXPRESSION then EXPRESSION
6826 -- {elsif EXPRESSION then EXPRESSION}
6827 -- [else EXPRESSION]
6828
6829 -- And we add the additional constructs
6830
6831 -- PRIMARY ::= ( CONDITIONAL_EXPRESION )
6832 -- PRAGMA_ARGUMENT_ASSOCIATION ::= CONDITIONAL_EXPRESSION
6833
6834 -- Note: if we have (IF x1 THEN x2 ELSIF x3 THEN x4 ELSE x5) then it
6835 -- is represented as (IF x1 THEN x2 ELSE (IF x3 THEN x4 ELSE x5)) and
6836 -- the Is_Elsif flag is set on the inner conditional expression.
6837
6838 -- N_Conditional_Expression
6839 -- Sloc points to IF or ELSIF keyword
6840 -- Expressions (List1)
6841 -- Then_Actions (List2-Sem)
6842 -- Else_Actions (List3-Sem)
6843 -- Is_Elsif (Flag13) (set if comes from ELSIF)
6844 -- plus fields for expression
6845
6846 -------------------
6847 -- Expanded_Name --
6848 -------------------
6849
6850 -- The N_Expanded_Name node is used to represent a selected component
6851 -- name that has been resolved to an expanded name. The semantic phase
6852 -- replaces N_Selected_Component nodes that represent names by the use
6853 -- of this node, leaving the N_Selected_Component node used only when
6854 -- the prefix is a record or protected type.
6855
6856 -- The fields of the N_Expanded_Name node are layed out identically
6857 -- to those of the N_Selected_Component node, allowing conversion of
6858 -- an expanded name node to a selected component node to be done
6859 -- easily, see Sinfo.CN.Change_Selected_Component_To_Expanded_Name.
6860
6861 -- There is no special sprint syntax for an expanded name
6862
6863 -- N_Expanded_Name
6864 -- Sloc points to the period
6865 -- Chars (Name1) copy of Chars field of selector name
6866 -- Prefix (Node3)
6867 -- Selector_Name (Node2)
6868 -- Entity (Node4-Sem)
6869 -- Associated_Node (Node4-Sem)
6870 -- Redundant_Use (Flag13-Sem)
6871 -- Has_Private_View (Flag11-Sem) set in generic units.
6872 -- plus fields for expression
6873
6874 -----------------------------
6875 -- Expression with Actions --
6876 -----------------------------
6877
6878 -- This node is created by the analyzer/expander to handle some
6879 -- expansion cases, notably short circuit forms where there are
6880 -- actions associated with the right hand operand.
6881
6882 -- The N_Expression_With_Actions node represents an expression with
6883 -- an associated set of actions (which are executable statements and
6884 -- declarations, as might occur in a handled statement sequence).
6885
6886 -- The required semantics is that the set of actions is executed in
6887 -- the order in which it appears just before the expression is
6888 -- evaluated (and these actions must only be executed if the value
6889 -- of the expression is evaluated). The node is considered to be
6890 -- a subexpression, whose value is the value of the Expression after
6891 -- executing all the actions.
6892
6893 -- Note: if the actions contain declarations, then these declarations
6894 -- maybe referenced with in the expression. It is thus appropriate for
6895 -- the back end to create a scope that encompasses the construct (any
6896 -- declarations within the actions will definitely not be referenced
6897 -- once elaboration of the construct is completed).
6898
6899 -- Sprint syntax: do
6900 -- action;
6901 -- action;
6902 -- ...
6903 -- action;
6904 -- in expression end
6905
6906 -- N_Expression_With_Actions
6907 -- Actions (List1)
6908 -- Expression (Node3)
6909 -- plus fields for expression
6910
6911 -- Note: the actions list is always non-null, since we would
6912 -- never have created this node if there weren't some actions.
6913
6914 --------------------
6915 -- Free Statement --
6916 --------------------
6917
6918 -- The N_Free_Statement node is generated as a result of a call to an
6919 -- instantiation of Unchecked_Deallocation. The instantiation of this
6920 -- generic is handled specially and generates this node directly.
6921
6922 -- Sprint syntax: free expression
6923
6924 -- N_Free_Statement
6925 -- Sloc is copied from the unchecked deallocation call
6926 -- Expression (Node3) argument to unchecked deallocation call
6927 -- Storage_Pool (Node1-Sem)
6928 -- Procedure_To_Call (Node2-Sem)
6929 -- Actual_Designated_Subtype (Node4-Sem)
6930
6931 -- Note: in the case where a debug source file is generated, the Sloc
6932 -- for this node points to the FREE keyword in the Sprint file output.
6933
6934 -------------------
6935 -- Freeze Entity --
6936 -------------------
6937
6938 -- This node marks the point in a declarative part at which an entity
6939 -- declared therein becomes frozen. The expander places initialization
6940 -- procedures for types at those points. Gigi uses the freezing point
6941 -- to elaborate entities that may depend on previous private types.
6942
6943 -- See the section in Einfo "Delayed Freezing and Elaboration" for
6944 -- a full description of the use of this node.
6945
6946 -- The Entity field points back to the entity for the type (whose
6947 -- Freeze_Node field points back to this freeze node).
6948
6949 -- The Actions field contains a list of declarations and statements
6950 -- generated by the expander which are associated with the freeze
6951 -- node, and are elaborated as though the freeze node were replaced
6952 -- by this sequence of actions.
6953
6954 -- Note: the Sloc field in the freeze node references a construct
6955 -- associated with the freezing point. This is used for posting
6956 -- messages in some error/warning situations, e.g. the case where
6957 -- a primitive operation of a tagged type is declared too late.
6958
6959 -- Sprint syntax: freeze entity-name [
6960 -- freeze actions
6961 -- ]
6962
6963 -- N_Freeze_Entity
6964 -- Sloc points near freeze point (see above special note)
6965 -- Entity (Node4-Sem)
6966 -- Access_Types_To_Process (Elist2-Sem) (set to No_Elist if none)
6967 -- TSS_Elist (Elist3-Sem) (set to No_Elist if no associated TSS's)
6968 -- Actions (List1) (set to No_List if no freeze actions)
6969 -- First_Subtype_Link (Node5-Sem) (set to Empty if no link)
6970
6971 -- The Actions field holds actions associated with the freeze. These
6972 -- actions are elaborated at the point where the type is frozen.
6973
6974 -- Note: in the case where a debug source file is generated, the Sloc
6975 -- for this node points to the FREEZE keyword in the Sprint file output.
6976
6977 --------------------------------
6978 -- Implicit Label Declaration --
6979 --------------------------------
6980
6981 -- An implicit label declaration is created for every occurrence of a
6982 -- label on a statement or a label on a block or loop. It is chained
6983 -- in the declarations of the innermost enclosing block as specified
6984 -- in RM section 5.1 (3).
6985
6986 -- The Defining_Identifier is the actual identifier for the statement
6987 -- identifier. Note that the occurrence of the label is a reference, NOT
6988 -- the defining occurrence. The defining occurrence occurs at the head
6989 -- of the innermost enclosing block, and is represented by this node.
6990
6991 -- Note: from the grammar, this might better be called an implicit
6992 -- statement identifier declaration, but the term we choose seems
6993 -- friendlier, since at least informally statement identifiers are
6994 -- called labels in both cases (i.e. when used in labels, and when
6995 -- used as the identifiers of blocks and loops).
6996
6997 -- Note: although this is logically a semantic node, since it does not
6998 -- correspond directly to a source syntax construction, these nodes are
6999 -- actually created by the parser in a post pass done just after parsing
7000 -- is complete, before semantic analysis is started (see Par.Labl).
7001
7002 -- Sprint syntax: labelname : label;
7003
7004 -- N_Implicit_Label_Declaration
7005 -- Sloc points to the << of the label
7006 -- Defining_Identifier (Node1)
7007 -- Label_Construct (Node2-Sem)
7008
7009 -- Note: in the case where a debug source file is generated, the Sloc
7010 -- for this node points to the label name in the generated declaration.
7011
7012 ---------------------
7013 -- Itype_Reference --
7014 ---------------------
7015
7016 -- This node is used to create a reference to an Itype. The only purpose
7017 -- is to make sure the Itype is defined if this is the first reference.
7018
7019 -- A typical use of this node is when an Itype is to be referenced in
7020 -- two branches of an IF statement. In this case it is important that
7021 -- the first use of the Itype not be inside the conditional, since then
7022 -- it might not be defined if the other branch of the IF is taken, in
7023 -- the case where the definition generates elaboration code.
7024
7025 -- The Itype field points to the referenced Itype
7026
7027 -- Sprint syntax: reference itype-name
7028
7029 -- N_Itype_Reference
7030 -- Sloc points to the node generating the reference
7031 -- Itype (Node1-Sem)
7032
7033 -- Note: in the case where a debug source file is generated, the Sloc
7034 -- for this node points to the REFERENCE keyword in the file output.
7035
7036 ---------------------
7037 -- Raise_xxx_Error --
7038 ---------------------
7039
7040 -- One of these nodes is created during semantic analysis to replace
7041 -- a node for an expression that is determined to definitely raise
7042 -- the corresponding exception.
7043
7044 -- The N_Raise_xxx_Error node may also stand alone in place
7045 -- of a declaration or statement, in which case it simply causes
7046 -- the exception to be raised (i.e. it is equivalent to a raise
7047 -- statement that raises the corresponding exception). This use
7048 -- is distinguished by the fact that the Etype in this case is
7049 -- Standard_Void_Type, In the subexpression case, the Etype is the
7050 -- same as the type of the subexpression which it replaces.
7051
7052 -- If Condition is empty, then the raise is unconditional. If the
7053 -- Condition field is non-empty, it is a boolean expression which
7054 -- is first evaluated, and the exception is raised only if the
7055 -- value of the expression is True. In the unconditional case, the
7056 -- creation of this node is usually accompanied by a warning message
7057 -- error. The creation of this node will usually be accompanied by a
7058 -- message (unless it appears within the right operand of a short
7059 -- circuit form whose left argument is static and decisively
7060 -- eliminates elaboration of the raise operation. The condition field
7061 -- can ONLY be present when the node is used as a statement form, it
7062 -- may NOT be present in the case where the node appears within an
7063 -- expression.
7064
7065 -- The exception is generated with a message that contains the
7066 -- file name and line number, and then appended text. The Reason
7067 -- code shows the text to be added. The Reason code is an element
7068 -- of the type Types.RT_Exception_Code, and indicates both the
7069 -- message to be added, and the exception to be raised (which must
7070 -- match the node type). The value is stored by storing a Uint which
7071 -- is the Pos value of the enumeration element in this type.
7072
7073 -- Gigi restriction: This expander ensures that the type of the
7074 -- Condition field is always Standard.Boolean, even if the type
7075 -- in the source is some non-standard boolean type.
7076
7077 -- Sprint syntax: [xxx_error "msg"]
7078 -- or: [xxx_error when condition "msg"]
7079
7080 -- N_Raise_Constraint_Error
7081 -- Sloc references related construct
7082 -- Condition (Node1) (set to Empty if no condition)
7083 -- Reason (Uint3)
7084 -- plus fields for expression
7085
7086 -- N_Raise_Program_Error
7087 -- Sloc references related construct
7088 -- Condition (Node1) (set to Empty if no condition)
7089 -- Reason (Uint3)
7090 -- plus fields for expression
7091
7092 -- N_Raise_Storage_Error
7093 -- Sloc references related construct
7094 -- Condition (Node1) (set to Empty if no condition)
7095 -- Reason (Uint3)
7096 -- plus fields for expression
7097
7098 -- Note: Sloc is copied from the expression generating the exception.
7099 -- In the case where a debug source file is generated, the Sloc for
7100 -- this node points to the left bracket in the Sprint file output.
7101
7102 -- Note: the back end may be required to translate these nodes into
7103 -- appropriate goto statements. See description of N_Push/Pop_xxx_Label.
7104
7105 ---------------------------------------------
7106 -- Optimization of Exception Raise to Goto --
7107 ---------------------------------------------
7108
7109 -- In some cases, the front end will determine that any exception raised
7110 -- by the back end for a certain exception should be transformed into a
7111 -- goto statement.
7112
7113 -- There are three kinds of exceptions raised by the back end (note that
7114 -- for this purpose we consider gigi to be part of the back end in the
7115 -- gcc case):
7116
7117 -- 1. Exceptions resulting from N_Raise_xxx_Error nodes
7118 -- 2. Exceptions from checks triggered by Do_xxx_Check flags
7119 -- 3. Other cases not specifically marked by the front end
7120
7121 -- Normally all such exceptions are translated into calls to the proper
7122 -- Rcheck_xx procedure, where xx encodes both the exception to be raised
7123 -- and the exception message.
7124
7125 -- The front end may determine that for a particular sequence of code,
7126 -- exceptions in any of these three categories for a particular builtin
7127 -- exception should result in a goto, rather than a call to Rcheck_xx.
7128 -- The exact sequence to be generated is:
7129
7130 -- Local_Raise (exception'Identity);
7131 -- goto Label
7132
7133 -- The front end marks such a sequence of code by bracketing it with
7134 -- push and pop nodes:
7135
7136 -- N_Push_xxx_Label (referencing the label)
7137 -- ...
7138 -- (code where transformation is expected for exception xxx)
7139 -- ...
7140 -- N_Pop_xxx_Label
7141
7142 -- The use of push/pop reflects the fact that such regions can properly
7143 -- nest, and one special case is a subregion in which no transformation
7144 -- is allowed. Such a region is marked by a N_Push_xxx_Label node whose
7145 -- Exception_Label field is Empty.
7146
7147 -- N_Push_Constraint_Error_Label
7148 -- Sloc references first statement in region covered
7149 -- Exception_Label (Node5-Sem)
7150
7151 -- N_Push_Program_Error_Label
7152 -- Sloc references first statement in region covered
7153 -- Exception_Label (Node5-Sem)
7154
7155 -- N_Push_Storage_Error_Label
7156 -- Sloc references first statement in region covered
7157 -- Exception_Label (Node5-Sem)
7158
7159 -- N_Pop_Constraint_Error_Label
7160 -- Sloc references last statement in region covered
7161
7162 -- N_Pop_Program_Error_Label
7163 -- Sloc references last statement in region covered
7164
7165 -- N_Pop_Storage_Error_Label
7166 -- Sloc references last statement in region covered
7167
7168 ---------------
7169 -- Reference --
7170 ---------------
7171
7172 -- For a number of purposes, we need to construct references to objects.
7173 -- These references are subsequently treated as normal access values.
7174 -- An example is the construction of the parameter block passed to a
7175 -- task entry. The N_Reference node is provided for this purpose. It is
7176 -- similar in effect to the use of the Unrestricted_Access attribute,
7177 -- and like Unrestricted_Access can be applied to objects which would
7178 -- not be valid prefixes for the Unchecked_Access attribute (e.g.
7179 -- objects which are not aliased, and slices). In addition it can be
7180 -- applied to composite type values as well as objects, including string
7181 -- values and aggregates.
7182
7183 -- Note: we use the Prefix field for this expression so that the
7184 -- resulting node can be treated using common code with the attribute
7185 -- nodes for the 'Access and related attributes. Logically it would make
7186 -- more sense to call it an Expression field, but then we would have to
7187 -- special case the treatment of the N_Reference node.
7188
7189 -- Sprint syntax: prefix'reference
7190
7191 -- N_Reference
7192 -- Sloc is copied from the expression
7193 -- Prefix (Node3)
7194 -- plus fields for expression
7195
7196 -- Note: in the case where a debug source file is generated, the Sloc
7197 -- for this node points to the quote in the Sprint file output.
7198
7199 -----------------
7200 -- SCIL Nodes --
7201 -----------------
7202
7203 -- SCIL nodes are special nodes added to the tree when the CodePeer
7204 -- mode is active. They help the CodePeer backend to locate nodes that
7205 -- require special processing.
7206
7207 -- Major documentation on the general design of the SCIL interface, and
7208 -- in particular detailed description of these nodes is missing and is
7209 -- to be supplied in the future, when the design has finalized ???
7210
7211 -- Meanwhile these nodes should be considered in experimental form, and
7212 -- should be ignored by all code generating back ends. ???
7213
7214 -- N_SCIL_Dispatch_Table_Tag_Init
7215 -- Sloc references a node for a tag initialization
7216 -- SCIL_Entity (Node4-Sem)
7217
7218 -- N_SCIL_Dispatching_Call
7219 -- Sloc references the node of a dispatching call
7220 -- SCIL_Target_Prim (Node2-Sem)
7221 -- SCIL_Entity (Node4-Sem)
7222 -- SCIL_Controlling_Tag (Node5-Sem)
7223
7224 -- N_SCIL_Membership_Test
7225 -- Sloc references the node of a membership test
7226 -- SCIL_Tag_Value (Node5-Sem)
7227 -- SCIL_Entity (Node4-Sem)
7228
7229 ---------------------
7230 -- Subprogram_Info --
7231 ---------------------
7232
7233 -- This node generates the appropriate Subprogram_Info value for a
7234 -- given procedure. See Ada.Exceptions for further details
7235
7236 -- Sprint syntax: subprog'subprogram_info
7237
7238 -- N_Subprogram_Info
7239 -- Sloc points to the entity for the procedure
7240 -- Identifier (Node1) identifier referencing the procedure
7241 -- Etype (Node5-Sem) type (always set to Ada.Exceptions.Code_Loc
7242
7243 -- Note: in the case where a debug source file is generated, the Sloc
7244 -- for this node points to the quote in the Sprint file output.
7245
7246 --------------------------
7247 -- Unchecked Expression --
7248 --------------------------
7249
7250 -- An unchecked expression is one that must be analyzed and resolved
7251 -- with all checks off, regardless of the current setting of scope
7252 -- suppress flags.
7253
7254 -- Sprint syntax: `(expression)
7255
7256 -- Note: this node is always removed from the tree (and replaced by
7257 -- its constituent expression) on completion of analysis, so it only
7258 -- appears in intermediate trees, and will never be seen by Gigi.
7259
7260 -- N_Unchecked_Expression
7261 -- Sloc is a copy of the Sloc of the expression
7262 -- Expression (Node3)
7263 -- plus fields for expression
7264
7265 -- Note: in the case where a debug source file is generated, the Sloc
7266 -- for this node points to the back quote in the Sprint file output.
7267
7268 -------------------------------
7269 -- Unchecked Type Conversion --
7270 -------------------------------
7271
7272 -- An unchecked type conversion node represents the semantic action
7273 -- corresponding to a call to an instantiation of Unchecked_Conversion.
7274 -- It is generated as a result of actual use of Unchecked_Conversion
7275 -- and also the expander generates unchecked type conversion nodes
7276 -- directly for expansion of complex semantic actions.
7277
7278 -- Note: an unchecked type conversion is a variable as far as the
7279 -- semantics are concerned, which is convenient for the expander.
7280 -- This does not change what Ada source programs are legal, since
7281 -- clearly a function call to an instantiation of Unchecked_Conversion
7282 -- is not a variable in any case.
7283
7284 -- Sprint syntax: subtype-mark!(expression)
7285
7286 -- N_Unchecked_Type_Conversion
7287 -- Sloc points to related node in source
7288 -- Subtype_Mark (Node4)
7289 -- Expression (Node3)
7290 -- Kill_Range_Check (Flag11-Sem)
7291 -- No_Truncation (Flag17-Sem)
7292 -- plus fields for expression
7293
7294 -- Note: in the case where a debug source file is generated, the Sloc
7295 -- for this node points to the exclamation in the Sprint file output.
7296
7297 -----------------------------------
7298 -- Validate_Unchecked_Conversion --
7299 -----------------------------------
7300
7301 -- The front end does most of the validation of unchecked conversion,
7302 -- including checking sizes (this is done after the back end is called
7303 -- to take advantage of back-annotation of calculated sizes).
7304
7305 -- The front end also deals with specific cases that are not allowed
7306 -- e.g. involving unconstrained array types.
7307
7308 -- For the case of the standard gigi backend, this means that all
7309 -- checks are done in the front-end.
7310
7311 -- However, in the case of specialized back-ends, notably the JVM
7312 -- backend for JGNAT, additional requirements and restrictions apply
7313 -- to unchecked conversion, and these are most conveniently performed
7314 -- in the specialized back-end.
7315
7316 -- To accommodate this requirement, for such back ends, the following
7317 -- special node is generated recording an unchecked conversion that
7318 -- needs to be validated. The back end should post an appropriate
7319 -- error message if the unchecked conversion is invalid or warrants
7320 -- a special warning message.
7321
7322 -- Source_Type and Target_Type point to the entities for the two
7323 -- types involved in the unchecked conversion instantiation that
7324 -- is to be validated.
7325
7326 -- Sprint syntax: validate Unchecked_Conversion (source, target);
7327
7328 -- N_Validate_Unchecked_Conversion
7329 -- Sloc points to instantiation (location for warning message)
7330 -- Source_Type (Node1-Sem)
7331 -- Target_Type (Node2-Sem)
7332
7333 -- Note: in the case where a debug source file is generated, the Sloc
7334 -- for this node points to the VALIDATE keyword in the file output.
7335
7336 -----------
7337 -- Empty --
7338 -----------
7339
7340 -- Used as the contents of the Nkind field of the dummy Empty node
7341 -- and in some other situations to indicate an uninitialized value.
7342
7343 -- N_Empty
7344 -- Chars (Name1) is set to No_Name
7345
7346 -----------
7347 -- Error --
7348 -----------
7349
7350 -- Used as the contents of the Nkind field of the dummy Error node.
7351 -- Has an Etype field, which gets set to Any_Type later on, to help
7352 -- error recovery (Error_Posted is also set in the Error node).
7353
7354 -- N_Error
7355 -- Chars (Name1) is set to Error_Name
7356 -- Etype (Node5-Sem)
7357
7358 --------------------------
7359 -- Node Type Definition --
7360 --------------------------
7361
7362 -- The following is the definition of the Node_Kind type. As previously
7363 -- discussed, this is separated off to allow rearrangement of the order to
7364 -- facilitate definition of subtype ranges. The comments show the subtype
7365 -- classes which apply to each set of node kinds. The first entry in the
7366 -- comment characterizes the following list of nodes.
7367
7368 type Node_Kind is (
7369 N_Unused_At_Start,
7370
7371 -- N_Representation_Clause
7372
7373 N_At_Clause,
7374 N_Component_Clause,
7375 N_Enumeration_Representation_Clause,
7376 N_Mod_Clause,
7377 N_Record_Representation_Clause,
7378
7379 -- N_Representation_Clause, N_Has_Chars
7380
7381 N_Attribute_Definition_Clause,
7382
7383 -- N_Has_Chars
7384
7385 N_Empty,
7386 N_Pragma_Argument_Association,
7387
7388 -- N_Has_Etype
7389
7390 N_Error,
7391
7392 -- N_Entity, N_Has_Etype, N_Has_Chars
7393
7394 N_Defining_Character_Literal,
7395 N_Defining_Identifier,
7396 N_Defining_Operator_Symbol,
7397
7398 -- N_Subexpr, N_Has_Etype, N_Has_Chars, N_Has_Entity
7399
7400 N_Expanded_Name,
7401
7402 -- N_Direct_Name, N_Subexpr, N_Has_Etype,
7403 -- N_Has_Chars, N_Has_Entity
7404
7405 N_Identifier,
7406 N_Operator_Symbol,
7407
7408 -- N_Direct_Name, N_Subexpr, N_Has_Etype,
7409 -- N_Has_Chars, N_Has_Entity
7410
7411 N_Character_Literal,
7412
7413 -- N_Binary_Op, N_Op, N_Subexpr,
7414 -- N_Has_Etype, N_Has_Chars, N_Has_Entity
7415
7416 N_Op_Add,
7417 N_Op_Concat,
7418 N_Op_Expon,
7419 N_Op_Subtract,
7420
7421 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Treat_Fixed_As_Integer
7422 -- N_Has_Etype, N_Has_Chars, N_Has_Entity, N_Multiplying_Operator
7423
7424 N_Op_Divide,
7425 N_Op_Mod,
7426 N_Op_Multiply,
7427 N_Op_Rem,
7428
7429 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Etype
7430 -- N_Has_Entity, N_Has_Chars, N_Op_Boolean
7431
7432 N_Op_And,
7433
7434 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Etype
7435 -- N_Has_Entity, N_Has_Chars, N_Op_Boolean, N_Op_Compare
7436
7437 N_Op_Eq,
7438 N_Op_Ge,
7439 N_Op_Gt,
7440 N_Op_Le,
7441 N_Op_Lt,
7442 N_Op_Ne,
7443
7444 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Etype
7445 -- N_Has_Entity, N_Has_Chars, N_Op_Boolean
7446
7447 N_Op_Or,
7448 N_Op_Xor,
7449
7450 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Etype,
7451 -- N_Op_Shift, N_Has_Chars, N_Has_Entity
7452
7453 N_Op_Rotate_Left,
7454 N_Op_Rotate_Right,
7455 N_Op_Shift_Left,
7456 N_Op_Shift_Right,
7457 N_Op_Shift_Right_Arithmetic,
7458
7459 -- N_Unary_Op, N_Op, N_Subexpr, N_Has_Etype,
7460 -- N_Has_Chars, N_Has_Entity
7461
7462 N_Op_Abs,
7463 N_Op_Minus,
7464 N_Op_Not,
7465 N_Op_Plus,
7466
7467 -- N_Subexpr, N_Has_Etype, N_Has_Entity
7468
7469 N_Attribute_Reference,
7470
7471 -- N_Subexpr, N_Has_Etype, N_Membership_Test
7472
7473 N_In,
7474 N_Not_In,
7475
7476 -- N_Subexpr, N_Has_Etype, N_Short_Circuit
7477
7478 N_And_Then,
7479 N_Or_Else,
7480
7481 -- N_Subexpr, N_Has_Etype
7482
7483 N_Conditional_Expression,
7484 N_Explicit_Dereference,
7485 N_Expression_With_Actions,
7486 N_Function_Call,
7487 N_Indexed_Component,
7488 N_Integer_Literal,
7489 N_Null,
7490 N_Procedure_Call_Statement,
7491 N_Qualified_Expression,
7492 N_Quantified_Expression,
7493
7494 -- N_Raise_xxx_Error, N_Subexpr, N_Has_Etype
7495
7496 N_Raise_Constraint_Error,
7497 N_Raise_Program_Error,
7498 N_Raise_Storage_Error,
7499
7500 -- N_Subexpr, N_Has_Etype
7501
7502 N_Aggregate,
7503 N_Allocator,
7504 N_Case_Expression,
7505 N_Extension_Aggregate,
7506 N_Range,
7507 N_Real_Literal,
7508 N_Reference,
7509 N_Selected_Component,
7510 N_Slice,
7511 N_String_Literal,
7512 N_Subprogram_Info,
7513 N_Type_Conversion,
7514 N_Unchecked_Expression,
7515 N_Unchecked_Type_Conversion,
7516
7517 -- N_Has_Etype
7518
7519 N_Subtype_Indication,
7520
7521 -- N_Declaration
7522
7523 N_Component_Declaration,
7524 N_Entry_Declaration,
7525 N_Formal_Object_Declaration,
7526 N_Formal_Type_Declaration,
7527 N_Full_Type_Declaration,
7528 N_Incomplete_Type_Declaration,
7529 N_Iterator_Specification,
7530 N_Loop_Parameter_Specification,
7531 N_Object_Declaration,
7532 N_Parameterized_Expression,
7533 N_Protected_Type_Declaration,
7534 N_Private_Extension_Declaration,
7535 N_Private_Type_Declaration,
7536 N_Subtype_Declaration,
7537
7538 -- N_Subprogram_Specification, N_Declaration
7539
7540 N_Function_Specification,
7541 N_Procedure_Specification,
7542
7543 -- N_Access_To_Subprogram_Definition
7544
7545 N_Access_Function_Definition,
7546 N_Access_Procedure_Definition,
7547
7548 -- N_Later_Decl_Item
7549
7550 N_Task_Type_Declaration,
7551
7552 -- N_Body_Stub, N_Later_Decl_Item
7553
7554 N_Package_Body_Stub,
7555 N_Protected_Body_Stub,
7556 N_Subprogram_Body_Stub,
7557 N_Task_Body_Stub,
7558
7559 -- N_Generic_Instantiation, N_Later_Decl_Item
7560 -- N_Subprogram_Instantiation
7561
7562 N_Function_Instantiation,
7563 N_Procedure_Instantiation,
7564
7565 -- N_Generic_Instantiation, N_Later_Decl_Item
7566
7567 N_Package_Instantiation,
7568
7569 -- N_Unit_Body, N_Later_Decl_Item, N_Proper_Body
7570
7571 N_Package_Body,
7572 N_Subprogram_Body,
7573
7574 -- N_Later_Decl_Item, N_Proper_Body
7575
7576 N_Protected_Body,
7577 N_Task_Body,
7578
7579 -- N_Later_Decl_Item
7580
7581 N_Implicit_Label_Declaration,
7582 N_Package_Declaration,
7583 N_Single_Task_Declaration,
7584 N_Subprogram_Declaration,
7585 N_Use_Package_Clause,
7586
7587 -- N_Generic_Declaration, N_Later_Decl_Item
7588
7589 N_Generic_Package_Declaration,
7590 N_Generic_Subprogram_Declaration,
7591
7592 -- N_Array_Type_Definition
7593
7594 N_Constrained_Array_Definition,
7595 N_Unconstrained_Array_Definition,
7596
7597 -- N_Renaming_Declaration
7598
7599 N_Exception_Renaming_Declaration,
7600 N_Object_Renaming_Declaration,
7601 N_Package_Renaming_Declaration,
7602 N_Subprogram_Renaming_Declaration,
7603
7604 -- N_Generic_Renaming_Declaration, N_Renaming_Declaration
7605
7606 N_Generic_Function_Renaming_Declaration,
7607 N_Generic_Package_Renaming_Declaration,
7608 N_Generic_Procedure_Renaming_Declaration,
7609
7610 -- N_Statement_Other_Than_Procedure_Call
7611
7612 N_Abort_Statement,
7613 N_Accept_Statement,
7614 N_Assignment_Statement,
7615 N_Asynchronous_Select,
7616 N_Block_Statement,
7617 N_Case_Statement,
7618 N_Code_Statement,
7619 N_Conditional_Entry_Call,
7620
7621 -- N_Statement_Other_Than_Procedure_Call. N_Delay_Statement
7622
7623 N_Delay_Relative_Statement,
7624 N_Delay_Until_Statement,
7625
7626 -- N_Statement_Other_Than_Procedure_Call
7627
7628 N_Entry_Call_Statement,
7629 N_Free_Statement,
7630 N_Goto_Statement,
7631 N_Loop_Statement,
7632 N_Null_Statement,
7633 N_Raise_Statement,
7634 N_Requeue_Statement,
7635 N_Return_Statement, -- renamed as N_Simple_Return_Statement below
7636 N_Extended_Return_Statement,
7637 N_Selective_Accept,
7638 N_Timed_Entry_Call,
7639
7640 -- N_Statement_Other_Than_Procedure_Call, N_Has_Condition
7641
7642 N_Exit_Statement,
7643 N_If_Statement,
7644
7645 -- N_Has_Condition
7646
7647 N_Accept_Alternative,
7648 N_Delay_Alternative,
7649 N_Elsif_Part,
7650 N_Entry_Body_Formal_Part,
7651 N_Iteration_Scheme,
7652 N_Terminate_Alternative,
7653
7654 -- N_Formal_Subprogram_Declaration
7655
7656 N_Formal_Abstract_Subprogram_Declaration,
7657 N_Formal_Concrete_Subprogram_Declaration,
7658
7659 -- N_Push_xxx_Label, N_Push_Pop_xxx_Label
7660
7661 N_Push_Constraint_Error_Label,
7662 N_Push_Program_Error_Label,
7663 N_Push_Storage_Error_Label,
7664
7665 -- N_Pop_xxx_Label, N_Push_Pop_xxx_Label
7666
7667 N_Pop_Constraint_Error_Label,
7668 N_Pop_Program_Error_Label,
7669 N_Pop_Storage_Error_Label,
7670
7671 -- SCIL nodes
7672
7673 N_SCIL_Dispatch_Table_Tag_Init,
7674 N_SCIL_Dispatching_Call,
7675 N_SCIL_Membership_Test,
7676
7677 -- Other nodes (not part of any subtype class)
7678
7679 N_Abortable_Part,
7680 N_Abstract_Subprogram_Declaration,
7681 N_Access_Definition,
7682 N_Access_To_Object_Definition,
7683 N_Aspect_Specification,
7684 N_Case_Expression_Alternative,
7685 N_Case_Statement_Alternative,
7686 N_Compilation_Unit,
7687 N_Compilation_Unit_Aux,
7688 N_Component_Association,
7689 N_Component_Definition,
7690 N_Component_List,
7691 N_Derived_Type_Definition,
7692 N_Decimal_Fixed_Point_Definition,
7693 N_Defining_Program_Unit_Name,
7694 N_Delta_Constraint,
7695 N_Designator,
7696 N_Digits_Constraint,
7697 N_Discriminant_Association,
7698 N_Discriminant_Specification,
7699 N_Enumeration_Type_Definition,
7700 N_Entry_Body,
7701 N_Entry_Call_Alternative,
7702 N_Entry_Index_Specification,
7703 N_Exception_Declaration,
7704 N_Exception_Handler,
7705 N_Floating_Point_Definition,
7706 N_Formal_Decimal_Fixed_Point_Definition,
7707 N_Formal_Derived_Type_Definition,
7708 N_Formal_Discrete_Type_Definition,
7709 N_Formal_Floating_Point_Definition,
7710 N_Formal_Modular_Type_Definition,
7711 N_Formal_Ordinary_Fixed_Point_Definition,
7712 N_Formal_Package_Declaration,
7713 N_Formal_Private_Type_Definition,
7714 N_Formal_Signed_Integer_Type_Definition,
7715 N_Freeze_Entity,
7716 N_Generic_Association,
7717 N_Handled_Sequence_Of_Statements,
7718 N_Index_Or_Discriminant_Constraint,
7719 N_Itype_Reference,
7720 N_Label,
7721 N_Modular_Type_Definition,
7722 N_Number_Declaration,
7723 N_Ordinary_Fixed_Point_Definition,
7724 N_Others_Choice,
7725 N_Package_Specification,
7726 N_Parameter_Association,
7727 N_Parameter_Specification,
7728 N_Pragma,
7729 N_Protected_Definition,
7730 N_Range_Constraint,
7731 N_Real_Range_Specification,
7732 N_Record_Definition,
7733 N_Signed_Integer_Type_Definition,
7734 N_Single_Protected_Declaration,
7735 N_Subunit,
7736 N_Task_Definition,
7737 N_Triggering_Alternative,
7738 N_Use_Type_Clause,
7739 N_Validate_Unchecked_Conversion,
7740 N_Variant,
7741 N_Variant_Part,
7742 N_With_Clause,
7743 N_Unused_At_End);
7744
7745 for Node_Kind'Size use 8;
7746 -- The data structures in Atree assume this!
7747
7748 ----------------------------
7749 -- Node Class Definitions --
7750 ----------------------------
7751
7752 subtype N_Access_To_Subprogram_Definition is Node_Kind range
7753 N_Access_Function_Definition ..
7754 N_Access_Procedure_Definition;
7755
7756 subtype N_Array_Type_Definition is Node_Kind range
7757 N_Constrained_Array_Definition ..
7758 N_Unconstrained_Array_Definition;
7759
7760 subtype N_Binary_Op is Node_Kind range
7761 N_Op_Add ..
7762 N_Op_Shift_Right_Arithmetic;
7763
7764 subtype N_Body_Stub is Node_Kind range
7765 N_Package_Body_Stub ..
7766 N_Task_Body_Stub;
7767
7768 subtype N_Declaration is Node_Kind range
7769 N_Component_Declaration ..
7770 N_Procedure_Specification;
7771 -- Note: this includes all constructs normally thought of as declarations
7772 -- except those which are separately grouped as later declarations.
7773
7774 subtype N_Delay_Statement is Node_Kind range
7775 N_Delay_Relative_Statement ..
7776 N_Delay_Until_Statement;
7777
7778 subtype N_Direct_Name is Node_Kind range
7779 N_Identifier ..
7780 N_Character_Literal;
7781
7782 subtype N_Entity is Node_Kind range
7783 N_Defining_Character_Literal ..
7784 N_Defining_Operator_Symbol;
7785
7786 subtype N_Formal_Subprogram_Declaration is Node_Kind range
7787 N_Formal_Abstract_Subprogram_Declaration ..
7788 N_Formal_Concrete_Subprogram_Declaration;
7789
7790 subtype N_Generic_Declaration is Node_Kind range
7791 N_Generic_Package_Declaration ..
7792 N_Generic_Subprogram_Declaration;
7793
7794 subtype N_Generic_Instantiation is Node_Kind range
7795 N_Function_Instantiation ..
7796 N_Package_Instantiation;
7797
7798 subtype N_Generic_Renaming_Declaration is Node_Kind range
7799 N_Generic_Function_Renaming_Declaration ..
7800 N_Generic_Procedure_Renaming_Declaration;
7801
7802 subtype N_Has_Chars is Node_Kind range
7803 N_Attribute_Definition_Clause ..
7804 N_Op_Plus;
7805
7806 subtype N_Has_Entity is Node_Kind range
7807 N_Expanded_Name ..
7808 N_Attribute_Reference;
7809 -- Nodes that have Entity fields
7810 -- Warning: DOES NOT INCLUDE N_Freeze_Entity, N_Aspect_Specification,
7811 -- or N_Attribute_Definition_Clause.
7812
7813 subtype N_Has_Etype is Node_Kind range
7814 N_Error ..
7815 N_Subtype_Indication;
7816
7817 subtype N_Has_Treat_Fixed_As_Integer is Node_Kind range
7818 N_Op_Divide ..
7819 N_Op_Rem;
7820
7821 subtype N_Multiplying_Operator is Node_Kind range
7822 N_Op_Divide ..
7823 N_Op_Rem;
7824
7825 subtype N_Later_Decl_Item is Node_Kind range
7826 N_Task_Type_Declaration ..
7827 N_Generic_Subprogram_Declaration;
7828 -- Note: this is Ada 83 relevant only (see Ada 83 RM 3.9 (2)) and includes
7829 -- only those items which can appear as later declarative items. This also
7830 -- includes N_Implicit_Label_Declaration which is not specifically in the
7831 -- grammar but may appear as a valid later declarative items. It does NOT
7832 -- include N_Pragma which can also appear among later declarative items.
7833 -- It does however include N_Protected_Body, which is a bit peculiar, but
7834 -- harmless since this cannot appear in Ada 83 mode anyway.
7835
7836 subtype N_Membership_Test is Node_Kind range
7837 N_In ..
7838 N_Not_In;
7839
7840 subtype N_Op is Node_Kind range
7841 N_Op_Add ..
7842 N_Op_Plus;
7843
7844 subtype N_Op_Boolean is Node_Kind range
7845 N_Op_And ..
7846 N_Op_Xor;
7847 -- Binary operators which take operands of a boolean type, and yield
7848 -- a result of a boolean type.
7849
7850 subtype N_Op_Compare is Node_Kind range
7851 N_Op_Eq ..
7852 N_Op_Ne;
7853
7854 subtype N_Op_Shift is Node_Kind range
7855 N_Op_Rotate_Left ..
7856 N_Op_Shift_Right_Arithmetic;
7857
7858 subtype N_Proper_Body is Node_Kind range
7859 N_Package_Body ..
7860 N_Task_Body;
7861
7862 subtype N_Push_xxx_Label is Node_Kind range
7863 N_Push_Constraint_Error_Label ..
7864 N_Push_Storage_Error_Label;
7865
7866 subtype N_Pop_xxx_Label is Node_Kind range
7867 N_Pop_Constraint_Error_Label ..
7868 N_Pop_Storage_Error_Label;
7869
7870 subtype N_Push_Pop_xxx_Label is Node_Kind range
7871 N_Push_Constraint_Error_Label ..
7872 N_Pop_Storage_Error_Label;
7873
7874 subtype N_Raise_xxx_Error is Node_Kind range
7875 N_Raise_Constraint_Error ..
7876 N_Raise_Storage_Error;
7877
7878 subtype N_Renaming_Declaration is Node_Kind range
7879 N_Exception_Renaming_Declaration ..
7880 N_Generic_Procedure_Renaming_Declaration;
7881
7882 subtype N_Representation_Clause is Node_Kind range
7883 N_At_Clause ..
7884 N_Attribute_Definition_Clause;
7885
7886 subtype N_Short_Circuit is Node_Kind range
7887 N_And_Then ..
7888 N_Or_Else;
7889
7890 subtype N_SCIL_Node is Node_Kind range
7891 N_SCIL_Dispatch_Table_Tag_Init ..
7892 N_SCIL_Membership_Test;
7893
7894 subtype N_Statement_Other_Than_Procedure_Call is Node_Kind range
7895 N_Abort_Statement ..
7896 N_If_Statement;
7897 -- Note that this includes all statement types except for the cases of the
7898 -- N_Procedure_Call_Statement which is considered to be a subexpression
7899 -- (since overloading is possible, so it needs to go through the normal
7900 -- overloading resolution for expressions).
7901
7902 subtype N_Subprogram_Instantiation is Node_Kind range
7903 N_Function_Instantiation ..
7904 N_Procedure_Instantiation;
7905
7906 subtype N_Has_Condition is Node_Kind range
7907 N_Exit_Statement ..
7908 N_Terminate_Alternative;
7909 -- Nodes with condition fields (does not include N_Raise_xxx_Error)
7910
7911 subtype N_Subexpr is Node_Kind range
7912 N_Expanded_Name ..
7913 N_Unchecked_Type_Conversion;
7914 -- Nodes with expression fields
7915
7916 subtype N_Subprogram_Specification is Node_Kind range
7917 N_Function_Specification ..
7918 N_Procedure_Specification;
7919
7920 subtype N_Unary_Op is Node_Kind range
7921 N_Op_Abs ..
7922 N_Op_Plus;
7923
7924 subtype N_Unit_Body is Node_Kind range
7925 N_Package_Body ..
7926 N_Subprogram_Body;
7927
7928 ---------------------------
7929 -- Node Access Functions --
7930 ---------------------------
7931
7932 -- The following functions return the contents of the indicated field of
7933 -- the node referenced by the argument, which is a Node_Id. They provide
7934 -- logical access to fields in the node which could be accessed using the
7935 -- Atree.Unchecked_Access package, but the idea is always to use these
7936 -- higher level routines which preserve strong typing. In debug mode,
7937 -- these routines check that they are being applied to an appropriate
7938 -- node, as well as checking that the node is in range.
7939
7940 function ABE_Is_Certain
7941 (N : Node_Id) return Boolean; -- Flag18
7942
7943 function Abort_Present
7944 (N : Node_Id) return Boolean; -- Flag15
7945
7946 function Abortable_Part
7947 (N : Node_Id) return Node_Id; -- Node2
7948
7949 function Abstract_Present
7950 (N : Node_Id) return Boolean; -- Flag4
7951
7952 function Accept_Handler_Records
7953 (N : Node_Id) return List_Id; -- List5
7954
7955 function Accept_Statement
7956 (N : Node_Id) return Node_Id; -- Node2
7957
7958 function Access_Definition
7959 (N : Node_Id) return Node_Id; -- Node3
7960
7961 function Access_To_Subprogram_Definition
7962 (N : Node_Id) return Node_Id; -- Node3
7963
7964 function Access_Types_To_Process
7965 (N : Node_Id) return Elist_Id; -- Elist2
7966
7967 function Actions
7968 (N : Node_Id) return List_Id; -- List1
7969
7970 function Activation_Chain_Entity
7971 (N : Node_Id) return Node_Id; -- Node3
7972
7973 function Acts_As_Spec
7974 (N : Node_Id) return Boolean; -- Flag4
7975
7976 function Actual_Designated_Subtype
7977 (N : Node_Id) return Node_Id; -- Node4
7978
7979 function Address_Warning_Posted
7980 (N : Node_Id) return Boolean; -- Flag18
7981
7982 function Aggregate_Bounds
7983 (N : Node_Id) return Node_Id; -- Node3
7984
7985 function Aliased_Present
7986 (N : Node_Id) return Boolean; -- Flag4
7987
7988 function All_Others
7989 (N : Node_Id) return Boolean; -- Flag11
7990
7991 function All_Present
7992 (N : Node_Id) return Boolean; -- Flag15
7993
7994 function Alternatives
7995 (N : Node_Id) return List_Id; -- List4
7996
7997 function Ancestor_Part
7998 (N : Node_Id) return Node_Id; -- Node3
7999
8000 function Array_Aggregate
8001 (N : Node_Id) return Node_Id; -- Node3
8002
8003 function Aspect_Cancel
8004 (N : Node_Id) return Boolean; -- Flag11
8005
8006 function Aspect_Rep_Item
8007 (N : Node_Id) return Node_Id; -- Node2
8008
8009 function Assignment_OK
8010 (N : Node_Id) return Boolean; -- Flag15
8011
8012 function Associated_Node
8013 (N : Node_Id) return Node_Id; -- Node4
8014
8015 function At_End_Proc
8016 (N : Node_Id) return Node_Id; -- Node1
8017
8018 function Attribute_Name
8019 (N : Node_Id) return Name_Id; -- Name2
8020
8021 function Aux_Decls_Node
8022 (N : Node_Id) return Node_Id; -- Node5
8023
8024 function Backwards_OK
8025 (N : Node_Id) return Boolean; -- Flag6
8026
8027 function Bad_Is_Detected
8028 (N : Node_Id) return Boolean; -- Flag15
8029
8030 function By_Ref
8031 (N : Node_Id) return Boolean; -- Flag5
8032
8033 function Body_Required
8034 (N : Node_Id) return Boolean; -- Flag13
8035
8036 function Body_To_Inline
8037 (N : Node_Id) return Node_Id; -- Node3
8038
8039 function Box_Present
8040 (N : Node_Id) return Boolean; -- Flag15
8041
8042 function Char_Literal_Value
8043 (N : Node_Id) return Uint; -- Uint2
8044
8045 function Chars
8046 (N : Node_Id) return Name_Id; -- Name1
8047
8048 function Check_Address_Alignment
8049 (N : Node_Id) return Boolean; -- Flag11
8050
8051 function Choice_Parameter
8052 (N : Node_Id) return Node_Id; -- Node2
8053
8054 function Choices
8055 (N : Node_Id) return List_Id; -- List1
8056
8057 function Class_Present
8058 (N : Node_Id) return Boolean; -- Flag6
8059
8060 function Coextensions
8061 (N : Node_Id) return Elist_Id; -- Elist4
8062
8063 function Comes_From_Extended_Return_Statement
8064 (N : Node_Id) return Boolean; -- Flag18
8065
8066 function Compile_Time_Known_Aggregate
8067 (N : Node_Id) return Boolean; -- Flag18
8068
8069 function Component_Associations
8070 (N : Node_Id) return List_Id; -- List2
8071
8072 function Component_Clauses
8073 (N : Node_Id) return List_Id; -- List3
8074
8075 function Component_Definition
8076 (N : Node_Id) return Node_Id; -- Node4
8077
8078 function Component_Items
8079 (N : Node_Id) return List_Id; -- List3
8080
8081 function Component_List
8082 (N : Node_Id) return Node_Id; -- Node1
8083
8084 function Component_Name
8085 (N : Node_Id) return Node_Id; -- Node1
8086
8087 function Componentwise_Assignment
8088 (N : Node_Id) return Boolean; -- Flag14
8089
8090 function Condition
8091 (N : Node_Id) return Node_Id; -- Node1
8092
8093 function Condition_Actions
8094 (N : Node_Id) return List_Id; -- List3
8095
8096 function Config_Pragmas
8097 (N : Node_Id) return List_Id; -- List4
8098
8099 function Constant_Present
8100 (N : Node_Id) return Boolean; -- Flag17
8101
8102 function Constraint
8103 (N : Node_Id) return Node_Id; -- Node3
8104
8105 function Constraints
8106 (N : Node_Id) return List_Id; -- List1
8107
8108 function Context_Installed
8109 (N : Node_Id) return Boolean; -- Flag13
8110
8111 function Context_Pending
8112 (N : Node_Id) return Boolean; -- Flag16
8113
8114 function Context_Items
8115 (N : Node_Id) return List_Id; -- List1
8116
8117 function Controlling_Argument
8118 (N : Node_Id) return Node_Id; -- Node1
8119
8120 function Conversion_OK
8121 (N : Node_Id) return Boolean; -- Flag14
8122
8123 function Corresponding_Body
8124 (N : Node_Id) return Node_Id; -- Node5
8125
8126 function Corresponding_Formal_Spec
8127 (N : Node_Id) return Node_Id; -- Node3
8128
8129 function Corresponding_Generic_Association
8130 (N : Node_Id) return Node_Id; -- Node5
8131
8132 function Corresponding_Integer_Value
8133 (N : Node_Id) return Uint; -- Uint4
8134
8135 function Corresponding_Spec
8136 (N : Node_Id) return Node_Id; -- Node5
8137
8138 function Corresponding_Stub
8139 (N : Node_Id) return Node_Id; -- Node3
8140
8141 function Dcheck_Function
8142 (N : Node_Id) return Entity_Id; -- Node5
8143
8144 function Debug_Statement
8145 (N : Node_Id) return Node_Id; -- Node3
8146
8147 function Declarations
8148 (N : Node_Id) return List_Id; -- List2
8149
8150 function Default_Expression
8151 (N : Node_Id) return Node_Id; -- Node5
8152
8153 function Default_Storage_Pool
8154 (N : Node_Id) return Node_Id; -- Node3
8155
8156 function Default_Name
8157 (N : Node_Id) return Node_Id; -- Node2
8158
8159 function Defining_Identifier
8160 (N : Node_Id) return Entity_Id; -- Node1
8161
8162 function Defining_Unit_Name
8163 (N : Node_Id) return Node_Id; -- Node1
8164
8165 function Delay_Alternative
8166 (N : Node_Id) return Node_Id; -- Node4
8167
8168 function Delay_Statement
8169 (N : Node_Id) return Node_Id; -- Node2
8170
8171 function Delta_Expression
8172 (N : Node_Id) return Node_Id; -- Node3
8173
8174 function Digits_Expression
8175 (N : Node_Id) return Node_Id; -- Node2
8176
8177 function Discr_Check_Funcs_Built
8178 (N : Node_Id) return Boolean; -- Flag11
8179
8180 function Discrete_Choices
8181 (N : Node_Id) return List_Id; -- List4
8182
8183 function Discrete_Range
8184 (N : Node_Id) return Node_Id; -- Node4
8185
8186 function Discrete_Subtype_Definition
8187 (N : Node_Id) return Node_Id; -- Node4
8188
8189 function Discrete_Subtype_Definitions
8190 (N : Node_Id) return List_Id; -- List2
8191
8192 function Discriminant_Specifications
8193 (N : Node_Id) return List_Id; -- List4
8194
8195 function Discriminant_Type
8196 (N : Node_Id) return Node_Id; -- Node5
8197
8198 function Do_Accessibility_Check
8199 (N : Node_Id) return Boolean; -- Flag13
8200
8201 function Do_Discriminant_Check
8202 (N : Node_Id) return Boolean; -- Flag13
8203
8204 function Do_Division_Check
8205 (N : Node_Id) return Boolean; -- Flag13
8206
8207 function Do_Length_Check
8208 (N : Node_Id) return Boolean; -- Flag4
8209
8210 function Do_Overflow_Check
8211 (N : Node_Id) return Boolean; -- Flag17
8212
8213 function Do_Range_Check
8214 (N : Node_Id) return Boolean; -- Flag9
8215
8216 function Do_Storage_Check
8217 (N : Node_Id) return Boolean; -- Flag17
8218
8219 function Do_Tag_Check
8220 (N : Node_Id) return Boolean; -- Flag13
8221
8222 function Elaborate_All_Desirable
8223 (N : Node_Id) return Boolean; -- Flag9
8224
8225 function Elaborate_All_Present
8226 (N : Node_Id) return Boolean; -- Flag14
8227
8228 function Elaborate_Desirable
8229 (N : Node_Id) return Boolean; -- Flag11
8230
8231 function Elaborate_Present
8232 (N : Node_Id) return Boolean; -- Flag4
8233
8234 function Elaboration_Boolean
8235 (N : Node_Id) return Node_Id; -- Node2
8236
8237 function Else_Actions
8238 (N : Node_Id) return List_Id; -- List3
8239
8240 function Else_Statements
8241 (N : Node_Id) return List_Id; -- List4
8242
8243 function Elsif_Parts
8244 (N : Node_Id) return List_Id; -- List3
8245
8246 function Enclosing_Variant
8247 (N : Node_Id) return Node_Id; -- Node2
8248
8249 function End_Label
8250 (N : Node_Id) return Node_Id; -- Node4
8251
8252 function End_Span
8253 (N : Node_Id) return Uint; -- Uint5
8254
8255 function Entity
8256 (N : Node_Id) return Node_Id; -- Node4
8257
8258 function Entity_Or_Associated_Node
8259 (N : Node_Id) return Node_Id; -- Node4
8260
8261 function Entry_Body_Formal_Part
8262 (N : Node_Id) return Node_Id; -- Node5
8263
8264 function Entry_Call_Alternative
8265 (N : Node_Id) return Node_Id; -- Node1
8266
8267 function Entry_Call_Statement
8268 (N : Node_Id) return Node_Id; -- Node1
8269
8270 function Entry_Direct_Name
8271 (N : Node_Id) return Node_Id; -- Node1
8272
8273 function Entry_Index
8274 (N : Node_Id) return Node_Id; -- Node5
8275
8276 function Entry_Index_Specification
8277 (N : Node_Id) return Node_Id; -- Node4
8278
8279 function Etype
8280 (N : Node_Id) return Node_Id; -- Node5
8281
8282 function Exception_Choices
8283 (N : Node_Id) return List_Id; -- List4
8284
8285 function Exception_Handlers
8286 (N : Node_Id) return List_Id; -- List5
8287
8288 function Exception_Junk
8289 (N : Node_Id) return Boolean; -- Flag8
8290
8291 function Exception_Label
8292 (N : Node_Id) return Node_Id; -- Node5
8293
8294 function Explicit_Actual_Parameter
8295 (N : Node_Id) return Node_Id; -- Node3
8296
8297 function Expansion_Delayed
8298 (N : Node_Id) return Boolean; -- Flag11
8299
8300 function Explicit_Generic_Actual_Parameter
8301 (N : Node_Id) return Node_Id; -- Node1
8302
8303 function Expression
8304 (N : Node_Id) return Node_Id; -- Node3
8305
8306 function Expressions
8307 (N : Node_Id) return List_Id; -- List1
8308
8309 function First_Bit
8310 (N : Node_Id) return Node_Id; -- Node3
8311
8312 function First_Inlined_Subprogram
8313 (N : Node_Id) return Entity_Id; -- Node3
8314
8315 function First_Name
8316 (N : Node_Id) return Boolean; -- Flag5
8317
8318 function First_Named_Actual
8319 (N : Node_Id) return Node_Id; -- Node4
8320
8321 function First_Real_Statement
8322 (N : Node_Id) return Node_Id; -- Node2
8323
8324 function First_Subtype_Link
8325 (N : Node_Id) return Entity_Id; -- Node5
8326
8327 function Float_Truncate
8328 (N : Node_Id) return Boolean; -- Flag11
8329
8330 function Formal_Type_Definition
8331 (N : Node_Id) return Node_Id; -- Node3
8332
8333 function Forwards_OK
8334 (N : Node_Id) return Boolean; -- Flag5
8335
8336 function From_Aspect_Specification
8337 (N : Node_Id) return Boolean; -- Flag13
8338
8339 function From_At_End
8340 (N : Node_Id) return Boolean; -- Flag4
8341
8342 function From_At_Mod
8343 (N : Node_Id) return Boolean; -- Flag4
8344
8345 function From_Default
8346 (N : Node_Id) return Boolean; -- Flag6
8347
8348 function Generic_Associations
8349 (N : Node_Id) return List_Id; -- List3
8350
8351 function Generic_Formal_Declarations
8352 (N : Node_Id) return List_Id; -- List2
8353
8354 function Generic_Parent
8355 (N : Node_Id) return Node_Id; -- Node5
8356
8357 function Generic_Parent_Type
8358 (N : Node_Id) return Node_Id; -- Node4
8359
8360 function Handled_Statement_Sequence
8361 (N : Node_Id) return Node_Id; -- Node4
8362
8363 function Handler_List_Entry
8364 (N : Node_Id) return Node_Id; -- Node2
8365
8366 function Has_Created_Identifier
8367 (N : Node_Id) return Boolean; -- Flag15
8368
8369 function Has_Dynamic_Length_Check
8370 (N : Node_Id) return Boolean; -- Flag10
8371
8372 function Has_Dynamic_Range_Check
8373 (N : Node_Id) return Boolean; -- Flag12
8374
8375 function Has_Init_Expression
8376 (N : Node_Id) return Boolean; -- Flag14
8377
8378 function Has_Local_Raise
8379 (N : Node_Id) return Boolean; -- Flag8
8380
8381 function Has_No_Elaboration_Code
8382 (N : Node_Id) return Boolean; -- Flag17
8383
8384 function Has_Pragma_CPU
8385 (N : Node_Id) return Boolean; -- Flag14
8386
8387 function Has_Pragma_Priority
8388 (N : Node_Id) return Boolean; -- Flag6
8389
8390 function Has_Pragma_Suppress_All
8391 (N : Node_Id) return Boolean; -- Flag14
8392
8393 function Has_Private_View
8394 (N : Node_Id) return Boolean; -- Flag11
8395
8396 function Has_Relative_Deadline_Pragma
8397 (N : Node_Id) return Boolean; -- Flag9
8398
8399 function Has_Self_Reference
8400 (N : Node_Id) return Boolean; -- Flag13
8401
8402 function Has_Storage_Size_Pragma
8403 (N : Node_Id) return Boolean; -- Flag5
8404
8405 function Has_Task_Info_Pragma
8406 (N : Node_Id) return Boolean; -- Flag7
8407
8408 function Has_Task_Name_Pragma
8409 (N : Node_Id) return Boolean; -- Flag8
8410
8411 function Has_Wide_Character
8412 (N : Node_Id) return Boolean; -- Flag11
8413
8414 function Has_Wide_Wide_Character
8415 (N : Node_Id) return Boolean; -- Flag13
8416
8417 function Hidden_By_Use_Clause
8418 (N : Node_Id) return Elist_Id; -- Elist4
8419
8420 function High_Bound
8421 (N : Node_Id) return Node_Id; -- Node2
8422
8423 function Identifier
8424 (N : Node_Id) return Node_Id; -- Node1
8425
8426 function Interface_List
8427 (N : Node_Id) return List_Id; -- List2
8428
8429 function Interface_Present
8430 (N : Node_Id) return Boolean; -- Flag16
8431
8432 function Implicit_With
8433 (N : Node_Id) return Boolean; -- Flag16
8434
8435 function Import_Interface_Present
8436 (N : Node_Id) return Boolean; -- Flag16
8437
8438 function In_Present
8439 (N : Node_Id) return Boolean; -- Flag15
8440
8441 function Includes_Infinities
8442 (N : Node_Id) return Boolean; -- Flag11
8443
8444 function Inherited_Discriminant
8445 (N : Node_Id) return Boolean; -- Flag13
8446
8447 function Instance_Spec
8448 (N : Node_Id) return Node_Id; -- Node5
8449
8450 function Intval
8451 (N : Node_Id) return Uint; -- Uint3
8452
8453 function Is_Accessibility_Actual
8454 (N : Node_Id) return Boolean; -- Flag13
8455
8456 function Is_Asynchronous_Call_Block
8457 (N : Node_Id) return Boolean; -- Flag7
8458
8459 function Is_Component_Left_Opnd
8460 (N : Node_Id) return Boolean; -- Flag13
8461
8462 function Is_Component_Right_Opnd
8463 (N : Node_Id) return Boolean; -- Flag14
8464
8465 function Is_Controlling_Actual
8466 (N : Node_Id) return Boolean; -- Flag16
8467
8468 function Is_Delayed_Aspect
8469 (N : Node_Id) return Boolean; -- Flag14
8470
8471 function Is_Dynamic_Coextension
8472 (N : Node_Id) return Boolean; -- Flag18
8473
8474 function Is_Elsif
8475 (N : Node_Id) return Boolean; -- Flag13
8476
8477 function Is_Entry_Barrier_Function
8478 (N : Node_Id) return Boolean; -- Flag8
8479
8480 function Is_Expanded_Build_In_Place_Call
8481 (N : Node_Id) return Boolean; -- Flag11
8482
8483 function Is_Folded_In_Parser
8484 (N : Node_Id) return Boolean; -- Flag4
8485
8486 function Is_In_Discriminant_Check
8487 (N : Node_Id) return Boolean; -- Flag11
8488
8489 function Is_Machine_Number
8490 (N : Node_Id) return Boolean; -- Flag11
8491
8492 function Is_Null_Loop
8493 (N : Node_Id) return Boolean; -- Flag16
8494
8495 function Is_Overloaded
8496 (N : Node_Id) return Boolean; -- Flag5
8497
8498 function Is_Power_Of_2_For_Shift
8499 (N : Node_Id) return Boolean; -- Flag13
8500
8501 function Is_Protected_Subprogram_Body
8502 (N : Node_Id) return Boolean; -- Flag7
8503
8504 function Is_Static_Coextension
8505 (N : Node_Id) return Boolean; -- Flag14
8506
8507 function Is_Static_Expression
8508 (N : Node_Id) return Boolean; -- Flag6
8509
8510 function Is_Subprogram_Descriptor
8511 (N : Node_Id) return Boolean; -- Flag16
8512
8513 function Is_Task_Allocation_Block
8514 (N : Node_Id) return Boolean; -- Flag6
8515
8516 function Is_Task_Master
8517 (N : Node_Id) return Boolean; -- Flag5
8518
8519 function Iteration_Scheme
8520 (N : Node_Id) return Node_Id; -- Node2
8521
8522 function Iterator_Specification
8523 (N : Node_Id) return Node_Id; -- Node2
8524
8525 function Itype
8526 (N : Node_Id) return Entity_Id; -- Node1
8527
8528 function Kill_Range_Check
8529 (N : Node_Id) return Boolean; -- Flag11
8530
8531 function Label_Construct
8532 (N : Node_Id) return Node_Id; -- Node2
8533
8534 function Left_Opnd
8535 (N : Node_Id) return Node_Id; -- Node2
8536
8537 function Last_Bit
8538 (N : Node_Id) return Node_Id; -- Node4
8539
8540 function Last_Name
8541 (N : Node_Id) return Boolean; -- Flag6
8542
8543 function Library_Unit
8544 (N : Node_Id) return Node_Id; -- Node4
8545
8546 function Limited_View_Installed
8547 (N : Node_Id) return Boolean; -- Flag18
8548
8549 function Limited_Present
8550 (N : Node_Id) return Boolean; -- Flag17
8551
8552 function Literals
8553 (N : Node_Id) return List_Id; -- List1
8554
8555 function Local_Raise_Not_OK
8556 (N : Node_Id) return Boolean; -- Flag7
8557
8558 function Local_Raise_Statements
8559 (N : Node_Id) return Elist_Id; -- Elist1
8560
8561 function Loop_Actions
8562 (N : Node_Id) return List_Id; -- List2
8563
8564 function Loop_Parameter_Specification
8565 (N : Node_Id) return Node_Id; -- Node4
8566
8567 function Low_Bound
8568 (N : Node_Id) return Node_Id; -- Node1
8569
8570 function Mod_Clause
8571 (N : Node_Id) return Node_Id; -- Node2
8572
8573 function More_Ids
8574 (N : Node_Id) return Boolean; -- Flag5
8575
8576 function Must_Be_Byte_Aligned
8577 (N : Node_Id) return Boolean; -- Flag14
8578
8579 function Must_Not_Freeze
8580 (N : Node_Id) return Boolean; -- Flag8
8581
8582 function Must_Not_Override
8583 (N : Node_Id) return Boolean; -- Flag15
8584
8585 function Must_Override
8586 (N : Node_Id) return Boolean; -- Flag14
8587
8588 function Name
8589 (N : Node_Id) return Node_Id; -- Node2
8590
8591 function Names
8592 (N : Node_Id) return List_Id; -- List2
8593
8594 function Next_Entity
8595 (N : Node_Id) return Node_Id; -- Node2
8596
8597 function Next_Exit_Statement
8598 (N : Node_Id) return Node_Id; -- Node3
8599
8600 function Next_Implicit_With
8601 (N : Node_Id) return Node_Id; -- Node3
8602
8603 function Next_Named_Actual
8604 (N : Node_Id) return Node_Id; -- Node4
8605
8606 function Next_Pragma
8607 (N : Node_Id) return Node_Id; -- Node1
8608
8609 function Next_Rep_Item
8610 (N : Node_Id) return Node_Id; -- Node5
8611
8612 function Next_Use_Clause
8613 (N : Node_Id) return Node_Id; -- Node3
8614
8615 function No_Ctrl_Actions
8616 (N : Node_Id) return Boolean; -- Flag7
8617
8618 function No_Elaboration_Check
8619 (N : Node_Id) return Boolean; -- Flag14
8620
8621 function No_Entities_Ref_In_Spec
8622 (N : Node_Id) return Boolean; -- Flag8
8623
8624 function No_Initialization
8625 (N : Node_Id) return Boolean; -- Flag13
8626
8627 function No_Truncation
8628 (N : Node_Id) return Boolean; -- Flag17
8629
8630 function Null_Present
8631 (N : Node_Id) return Boolean; -- Flag13
8632
8633 function Null_Exclusion_Present
8634 (N : Node_Id) return Boolean; -- Flag11
8635
8636 function Null_Exclusion_In_Return_Present
8637 (N : Node_Id) return Boolean; -- Flag14
8638
8639 function Null_Record_Present
8640 (N : Node_Id) return Boolean; -- Flag17
8641
8642 function Object_Definition
8643 (N : Node_Id) return Node_Id; -- Node4
8644
8645 function Of_Present
8646 (N : Node_Id) return Boolean; -- Flag16
8647
8648 function Original_Discriminant
8649 (N : Node_Id) return Node_Id; -- Node2
8650
8651 function Original_Entity
8652 (N : Node_Id) return Entity_Id; -- Node2
8653
8654 function Others_Discrete_Choices
8655 (N : Node_Id) return List_Id; -- List1
8656
8657 function Out_Present
8658 (N : Node_Id) return Boolean; -- Flag17
8659
8660 function Parameter_Associations
8661 (N : Node_Id) return List_Id; -- List3
8662
8663 function Parameter_List_Truncated
8664 (N : Node_Id) return Boolean; -- Flag17
8665
8666 function Parameter_Specifications
8667 (N : Node_Id) return List_Id; -- List3
8668
8669 function Parameter_Type
8670 (N : Node_Id) return Node_Id; -- Node2
8671
8672 function Parent_Spec
8673 (N : Node_Id) return Node_Id; -- Node4
8674
8675 function Position
8676 (N : Node_Id) return Node_Id; -- Node2
8677
8678 function Pragma_Argument_Associations
8679 (N : Node_Id) return List_Id; -- List2
8680
8681 function Pragma_Enabled
8682 (N : Node_Id) return Boolean; -- Flag5
8683
8684 function Pragma_Identifier
8685 (N : Node_Id) return Node_Id; -- Node4
8686
8687 function Pragmas_After
8688 (N : Node_Id) return List_Id; -- List5
8689
8690 function Pragmas_Before
8691 (N : Node_Id) return List_Id; -- List4
8692
8693 function Prefix
8694 (N : Node_Id) return Node_Id; -- Node3
8695
8696 function Present_Expr
8697 (N : Node_Id) return Uint; -- Uint3
8698
8699 function Prev_Ids
8700 (N : Node_Id) return Boolean; -- Flag6
8701
8702 function Print_In_Hex
8703 (N : Node_Id) return Boolean; -- Flag13
8704
8705 function Private_Declarations
8706 (N : Node_Id) return List_Id; -- List3
8707
8708 function Private_Present
8709 (N : Node_Id) return Boolean; -- Flag15
8710
8711 function Procedure_To_Call
8712 (N : Node_Id) return Node_Id; -- Node2
8713
8714 function Proper_Body
8715 (N : Node_Id) return Node_Id; -- Node1
8716
8717 function Protected_Definition
8718 (N : Node_Id) return Node_Id; -- Node3
8719
8720 function Protected_Present
8721 (N : Node_Id) return Boolean; -- Flag6
8722
8723 function Raises_Constraint_Error
8724 (N : Node_Id) return Boolean; -- Flag7
8725
8726 function Range_Constraint
8727 (N : Node_Id) return Node_Id; -- Node4
8728
8729 function Range_Expression
8730 (N : Node_Id) return Node_Id; -- Node4
8731
8732 function Real_Range_Specification
8733 (N : Node_Id) return Node_Id; -- Node4
8734
8735 function Realval
8736 (N : Node_Id) return Ureal; -- Ureal3
8737
8738 function Reason
8739 (N : Node_Id) return Uint; -- Uint3
8740
8741 function Record_Extension_Part
8742 (N : Node_Id) return Node_Id; -- Node3
8743
8744 function Redundant_Use
8745 (N : Node_Id) return Boolean; -- Flag13
8746
8747 function Renaming_Exception
8748 (N : Node_Id) return Node_Id; -- Node2
8749
8750 function Result_Definition
8751 (N : Node_Id) return Node_Id; -- Node4
8752
8753 function Return_Object_Declarations
8754 (N : Node_Id) return List_Id; -- List3
8755
8756 function Return_Statement_Entity
8757 (N : Node_Id) return Node_Id; -- Node5
8758
8759 function Reverse_Present
8760 (N : Node_Id) return Boolean; -- Flag15
8761
8762 function Right_Opnd
8763 (N : Node_Id) return Node_Id; -- Node3
8764
8765 function Rounded_Result
8766 (N : Node_Id) return Boolean; -- Flag18
8767
8768 function SCIL_Controlling_Tag
8769 (N : Node_Id) return Node_Id; -- Node5
8770
8771 function SCIL_Entity
8772 (N : Node_Id) return Node_Id; -- Node4
8773
8774 function SCIL_Tag_Value
8775 (N : Node_Id) return Node_Id; -- Node5
8776
8777 function SCIL_Target_Prim
8778 (N : Node_Id) return Node_Id; -- Node2
8779
8780 function Scope
8781 (N : Node_Id) return Node_Id; -- Node3
8782
8783 function Select_Alternatives
8784 (N : Node_Id) return List_Id; -- List1
8785
8786 function Selector_Name
8787 (N : Node_Id) return Node_Id; -- Node2
8788
8789 function Selector_Names
8790 (N : Node_Id) return List_Id; -- List1
8791
8792 function Shift_Count_OK
8793 (N : Node_Id) return Boolean; -- Flag4
8794
8795 function Source_Type
8796 (N : Node_Id) return Entity_Id; -- Node1
8797
8798 function Specification
8799 (N : Node_Id) return Node_Id; -- Node1
8800
8801 function Split_PPC
8802 (N : Node_Id) return Boolean; -- Flag17
8803
8804 function Statements
8805 (N : Node_Id) return List_Id; -- List3
8806
8807 function Static_Processing_OK
8808 (N : Node_Id) return Boolean; -- Flag4
8809
8810 function Storage_Pool
8811 (N : Node_Id) return Node_Id; -- Node1
8812
8813 function Strval
8814 (N : Node_Id) return String_Id; -- Str3
8815
8816 function Subtype_Indication
8817 (N : Node_Id) return Node_Id; -- Node5
8818
8819 function Subtype_Mark
8820 (N : Node_Id) return Node_Id; -- Node4
8821
8822 function Subtype_Marks
8823 (N : Node_Id) return List_Id; -- List2
8824
8825 function Suppress_Loop_Warnings
8826 (N : Node_Id) return Boolean; -- Flag17
8827
8828 function Synchronized_Present
8829 (N : Node_Id) return Boolean; -- Flag7
8830
8831 function Tagged_Present
8832 (N : Node_Id) return Boolean; -- Flag15
8833
8834 function Target_Type
8835 (N : Node_Id) return Entity_Id; -- Node2
8836
8837 function Task_Definition
8838 (N : Node_Id) return Node_Id; -- Node3
8839
8840 function Task_Present
8841 (N : Node_Id) return Boolean; -- Flag5
8842
8843 function Then_Actions
8844 (N : Node_Id) return List_Id; -- List2
8845
8846 function Then_Statements
8847 (N : Node_Id) return List_Id; -- List2
8848
8849 function Treat_Fixed_As_Integer
8850 (N : Node_Id) return Boolean; -- Flag14
8851
8852 function Triggering_Alternative
8853 (N : Node_Id) return Node_Id; -- Node1
8854
8855 function Triggering_Statement
8856 (N : Node_Id) return Node_Id; -- Node1
8857
8858 function TSS_Elist
8859 (N : Node_Id) return Elist_Id; -- Elist3
8860
8861 function Type_Definition
8862 (N : Node_Id) return Node_Id; -- Node3
8863
8864 function Unit
8865 (N : Node_Id) return Node_Id; -- Node2
8866
8867 function Unknown_Discriminants_Present
8868 (N : Node_Id) return Boolean; -- Flag13
8869
8870 function Unreferenced_In_Spec
8871 (N : Node_Id) return Boolean; -- Flag7
8872
8873 function Variant_Part
8874 (N : Node_Id) return Node_Id; -- Node4
8875
8876 function Variants
8877 (N : Node_Id) return List_Id; -- List1
8878
8879 function Visible_Declarations
8880 (N : Node_Id) return List_Id; -- List2
8881
8882 function Was_Originally_Stub
8883 (N : Node_Id) return Boolean; -- Flag13
8884
8885 function Withed_Body
8886 (N : Node_Id) return Node_Id; -- Node1
8887
8888 function Zero_Cost_Handling
8889 (N : Node_Id) return Boolean; -- Flag5
8890
8891 -- End functions (note used by xsinfo utility program to end processing)
8892
8893 ----------------------------
8894 -- Node Update Procedures --
8895 ----------------------------
8896
8897 -- These are the corresponding node update routines, which again provide
8898 -- a high level logical access with type checking. In addition to setting
8899 -- the indicated field of the node N to the given Val, in the case of
8900 -- tree pointers (List1-4), the parent pointer of the Val node is set to
8901 -- point back to node N. This automates the setting of the parent pointer.
8902
8903 procedure Set_ABE_Is_Certain
8904 (N : Node_Id; Val : Boolean := True); -- Flag18
8905
8906 procedure Set_Abort_Present
8907 (N : Node_Id; Val : Boolean := True); -- Flag15
8908
8909 procedure Set_Abortable_Part
8910 (N : Node_Id; Val : Node_Id); -- Node2
8911
8912 procedure Set_Abstract_Present
8913 (N : Node_Id; Val : Boolean := True); -- Flag4
8914
8915 procedure Set_Accept_Handler_Records
8916 (N : Node_Id; Val : List_Id); -- List5
8917
8918 procedure Set_Accept_Statement
8919 (N : Node_Id; Val : Node_Id); -- Node2
8920
8921 procedure Set_Access_Definition
8922 (N : Node_Id; Val : Node_Id); -- Node3
8923
8924 procedure Set_Access_To_Subprogram_Definition
8925 (N : Node_Id; Val : Node_Id); -- Node3
8926
8927 procedure Set_Access_Types_To_Process
8928 (N : Node_Id; Val : Elist_Id); -- Elist2
8929
8930 procedure Set_Actions
8931 (N : Node_Id; Val : List_Id); -- List1
8932
8933 procedure Set_Activation_Chain_Entity
8934 (N : Node_Id; Val : Node_Id); -- Node3
8935
8936 procedure Set_Acts_As_Spec
8937 (N : Node_Id; Val : Boolean := True); -- Flag4
8938
8939 procedure Set_Actual_Designated_Subtype
8940 (N : Node_Id; Val : Node_Id); -- Node4
8941
8942 procedure Set_Address_Warning_Posted
8943 (N : Node_Id; Val : Boolean := True); -- Flag18
8944
8945 procedure Set_Aggregate_Bounds
8946 (N : Node_Id; Val : Node_Id); -- Node3
8947
8948 procedure Set_Aliased_Present
8949 (N : Node_Id; Val : Boolean := True); -- Flag4
8950
8951 procedure Set_All_Others
8952 (N : Node_Id; Val : Boolean := True); -- Flag11
8953
8954 procedure Set_All_Present
8955 (N : Node_Id; Val : Boolean := True); -- Flag15
8956
8957 procedure Set_Alternatives
8958 (N : Node_Id; Val : List_Id); -- List4
8959
8960 procedure Set_Ancestor_Part
8961 (N : Node_Id; Val : Node_Id); -- Node3
8962
8963 procedure Set_Array_Aggregate
8964 (N : Node_Id; Val : Node_Id); -- Node3
8965
8966 procedure Set_Aspect_Cancel
8967 (N : Node_Id; Val : Boolean := True); -- Flag11
8968
8969 procedure Set_Aspect_Rep_Item
8970 (N : Node_Id; Val : Node_Id); -- Node2
8971
8972 procedure Set_Assignment_OK
8973 (N : Node_Id; Val : Boolean := True); -- Flag15
8974
8975 procedure Set_Associated_Node
8976 (N : Node_Id; Val : Node_Id); -- Node4
8977
8978 procedure Set_Attribute_Name
8979 (N : Node_Id; Val : Name_Id); -- Name2
8980
8981 procedure Set_At_End_Proc
8982 (N : Node_Id; Val : Node_Id); -- Node1
8983
8984 procedure Set_Aux_Decls_Node
8985 (N : Node_Id; Val : Node_Id); -- Node5
8986
8987 procedure Set_Backwards_OK
8988 (N : Node_Id; Val : Boolean := True); -- Flag6
8989
8990 procedure Set_Bad_Is_Detected
8991 (N : Node_Id; Val : Boolean := True); -- Flag15
8992
8993 procedure Set_Body_Required
8994 (N : Node_Id; Val : Boolean := True); -- Flag13
8995
8996 procedure Set_Body_To_Inline
8997 (N : Node_Id; Val : Node_Id); -- Node3
8998
8999 procedure Set_Box_Present
9000 (N : Node_Id; Val : Boolean := True); -- Flag15
9001
9002 procedure Set_By_Ref
9003 (N : Node_Id; Val : Boolean := True); -- Flag5
9004
9005 procedure Set_Char_Literal_Value
9006 (N : Node_Id; Val : Uint); -- Uint2
9007
9008 procedure Set_Chars
9009 (N : Node_Id; Val : Name_Id); -- Name1
9010
9011 procedure Set_Check_Address_Alignment
9012 (N : Node_Id; Val : Boolean := True); -- Flag11
9013
9014 procedure Set_Choice_Parameter
9015 (N : Node_Id; Val : Node_Id); -- Node2
9016
9017 procedure Set_Choices
9018 (N : Node_Id; Val : List_Id); -- List1
9019
9020 procedure Set_Class_Present
9021 (N : Node_Id; Val : Boolean := True); -- Flag6
9022
9023 procedure Set_Coextensions
9024 (N : Node_Id; Val : Elist_Id); -- Elist4
9025
9026 procedure Set_Comes_From_Extended_Return_Statement
9027 (N : Node_Id; Val : Boolean := True); -- Flag18
9028
9029 procedure Set_Compile_Time_Known_Aggregate
9030 (N : Node_Id; Val : Boolean := True); -- Flag18
9031
9032 procedure Set_Component_Associations
9033 (N : Node_Id; Val : List_Id); -- List2
9034
9035 procedure Set_Component_Clauses
9036 (N : Node_Id; Val : List_Id); -- List3
9037
9038 procedure Set_Component_Definition
9039 (N : Node_Id; Val : Node_Id); -- Node4
9040
9041 procedure Set_Component_Items
9042 (N : Node_Id; Val : List_Id); -- List3
9043
9044 procedure Set_Component_List
9045 (N : Node_Id; Val : Node_Id); -- Node1
9046
9047 procedure Set_Component_Name
9048 (N : Node_Id; Val : Node_Id); -- Node1
9049
9050 procedure Set_Componentwise_Assignment
9051 (N : Node_Id; Val : Boolean := True); -- Flag14
9052
9053 procedure Set_Condition
9054 (N : Node_Id; Val : Node_Id); -- Node1
9055
9056 procedure Set_Condition_Actions
9057 (N : Node_Id; Val : List_Id); -- List3
9058
9059 procedure Set_Config_Pragmas
9060 (N : Node_Id; Val : List_Id); -- List4
9061
9062 procedure Set_Constant_Present
9063 (N : Node_Id; Val : Boolean := True); -- Flag17
9064
9065 procedure Set_Constraint
9066 (N : Node_Id; Val : Node_Id); -- Node3
9067
9068 procedure Set_Constraints
9069 (N : Node_Id; Val : List_Id); -- List1
9070
9071 procedure Set_Context_Installed
9072 (N : Node_Id; Val : Boolean := True); -- Flag13
9073
9074 procedure Set_Context_Items
9075 (N : Node_Id; Val : List_Id); -- List1
9076
9077 procedure Set_Context_Pending
9078 (N : Node_Id; Val : Boolean := True); -- Flag16
9079
9080 procedure Set_Controlling_Argument
9081 (N : Node_Id; Val : Node_Id); -- Node1
9082
9083 procedure Set_Conversion_OK
9084 (N : Node_Id; Val : Boolean := True); -- Flag14
9085
9086 procedure Set_Corresponding_Body
9087 (N : Node_Id; Val : Node_Id); -- Node5
9088
9089 procedure Set_Corresponding_Formal_Spec
9090 (N : Node_Id; Val : Node_Id); -- Node3
9091
9092 procedure Set_Corresponding_Generic_Association
9093 (N : Node_Id; Val : Node_Id); -- Node5
9094
9095 procedure Set_Corresponding_Integer_Value
9096 (N : Node_Id; Val : Uint); -- Uint4
9097
9098 procedure Set_Corresponding_Spec
9099 (N : Node_Id; Val : Node_Id); -- Node5
9100
9101 procedure Set_Corresponding_Stub
9102 (N : Node_Id; Val : Node_Id); -- Node3
9103
9104 procedure Set_Dcheck_Function
9105 (N : Node_Id; Val : Entity_Id); -- Node5
9106
9107 procedure Set_Debug_Statement
9108 (N : Node_Id; Val : Node_Id); -- Node3
9109
9110 procedure Set_Declarations
9111 (N : Node_Id; Val : List_Id); -- List2
9112
9113 procedure Set_Default_Expression
9114 (N : Node_Id; Val : Node_Id); -- Node5
9115
9116 procedure Set_Default_Storage_Pool
9117 (N : Node_Id; Val : Node_Id); -- Node3
9118
9119 procedure Set_Default_Name
9120 (N : Node_Id; Val : Node_Id); -- Node2
9121
9122 procedure Set_Defining_Identifier
9123 (N : Node_Id; Val : Entity_Id); -- Node1
9124
9125 procedure Set_Defining_Unit_Name
9126 (N : Node_Id; Val : Node_Id); -- Node1
9127
9128 procedure Set_Delay_Alternative
9129 (N : Node_Id; Val : Node_Id); -- Node4
9130
9131 procedure Set_Delay_Statement
9132 (N : Node_Id; Val : Node_Id); -- Node2
9133
9134 procedure Set_Delta_Expression
9135 (N : Node_Id; Val : Node_Id); -- Node3
9136
9137 procedure Set_Digits_Expression
9138 (N : Node_Id; Val : Node_Id); -- Node2
9139
9140 procedure Set_Discr_Check_Funcs_Built
9141 (N : Node_Id; Val : Boolean := True); -- Flag11
9142
9143 procedure Set_Discrete_Choices
9144 (N : Node_Id; Val : List_Id); -- List4
9145
9146 procedure Set_Discrete_Range
9147 (N : Node_Id; Val : Node_Id); -- Node4
9148
9149 procedure Set_Discrete_Subtype_Definition
9150 (N : Node_Id; Val : Node_Id); -- Node4
9151
9152 procedure Set_Discrete_Subtype_Definitions
9153 (N : Node_Id; Val : List_Id); -- List2
9154
9155 procedure Set_Discriminant_Specifications
9156 (N : Node_Id; Val : List_Id); -- List4
9157
9158 procedure Set_Discriminant_Type
9159 (N : Node_Id; Val : Node_Id); -- Node5
9160
9161 procedure Set_Do_Accessibility_Check
9162 (N : Node_Id; Val : Boolean := True); -- Flag13
9163
9164 procedure Set_Do_Discriminant_Check
9165 (N : Node_Id; Val : Boolean := True); -- Flag13
9166
9167 procedure Set_Do_Division_Check
9168 (N : Node_Id; Val : Boolean := True); -- Flag13
9169
9170 procedure Set_Do_Length_Check
9171 (N : Node_Id; Val : Boolean := True); -- Flag4
9172
9173 procedure Set_Do_Overflow_Check
9174 (N : Node_Id; Val : Boolean := True); -- Flag17
9175
9176 procedure Set_Do_Range_Check
9177 (N : Node_Id; Val : Boolean := True); -- Flag9
9178
9179 procedure Set_Do_Storage_Check
9180 (N : Node_Id; Val : Boolean := True); -- Flag17
9181
9182 procedure Set_Do_Tag_Check
9183 (N : Node_Id; Val : Boolean := True); -- Flag13
9184
9185 procedure Set_Elaborate_All_Desirable
9186 (N : Node_Id; Val : Boolean := True); -- Flag9
9187
9188 procedure Set_Elaborate_All_Present
9189 (N : Node_Id; Val : Boolean := True); -- Flag14
9190
9191 procedure Set_Elaborate_Desirable
9192 (N : Node_Id; Val : Boolean := True); -- Flag11
9193
9194 procedure Set_Elaborate_Present
9195 (N : Node_Id; Val : Boolean := True); -- Flag4
9196
9197 procedure Set_Elaboration_Boolean
9198 (N : Node_Id; Val : Node_Id); -- Node2
9199
9200 procedure Set_Else_Actions
9201 (N : Node_Id; Val : List_Id); -- List3
9202
9203 procedure Set_Else_Statements
9204 (N : Node_Id; Val : List_Id); -- List4
9205
9206 procedure Set_Elsif_Parts
9207 (N : Node_Id; Val : List_Id); -- List3
9208
9209 procedure Set_Enclosing_Variant
9210 (N : Node_Id; Val : Node_Id); -- Node2
9211
9212 procedure Set_End_Label
9213 (N : Node_Id; Val : Node_Id); -- Node4
9214
9215 procedure Set_End_Span
9216 (N : Node_Id; Val : Uint); -- Uint5
9217
9218 procedure Set_Entity
9219 (N : Node_Id; Val : Node_Id); -- Node4
9220
9221 procedure Set_Entry_Body_Formal_Part
9222 (N : Node_Id; Val : Node_Id); -- Node5
9223
9224 procedure Set_Entry_Call_Alternative
9225 (N : Node_Id; Val : Node_Id); -- Node1
9226
9227 procedure Set_Entry_Call_Statement
9228 (N : Node_Id; Val : Node_Id); -- Node1
9229
9230 procedure Set_Entry_Direct_Name
9231 (N : Node_Id; Val : Node_Id); -- Node1
9232
9233 procedure Set_Entry_Index
9234 (N : Node_Id; Val : Node_Id); -- Node5
9235
9236 procedure Set_Entry_Index_Specification
9237 (N : Node_Id; Val : Node_Id); -- Node4
9238
9239 procedure Set_Etype
9240 (N : Node_Id; Val : Node_Id); -- Node5
9241
9242 procedure Set_Exception_Choices
9243 (N : Node_Id; Val : List_Id); -- List4
9244
9245 procedure Set_Exception_Handlers
9246 (N : Node_Id; Val : List_Id); -- List5
9247
9248 procedure Set_Exception_Junk
9249 (N : Node_Id; Val : Boolean := True); -- Flag8
9250
9251 procedure Set_Exception_Label
9252 (N : Node_Id; Val : Node_Id); -- Node5
9253
9254 procedure Set_Expansion_Delayed
9255 (N : Node_Id; Val : Boolean := True); -- Flag11
9256
9257 procedure Set_Explicit_Actual_Parameter
9258 (N : Node_Id; Val : Node_Id); -- Node3
9259
9260 procedure Set_Explicit_Generic_Actual_Parameter
9261 (N : Node_Id; Val : Node_Id); -- Node1
9262
9263 procedure Set_Expression
9264 (N : Node_Id; Val : Node_Id); -- Node3
9265
9266 procedure Set_Expressions
9267 (N : Node_Id; Val : List_Id); -- List1
9268
9269 procedure Set_First_Bit
9270 (N : Node_Id; Val : Node_Id); -- Node3
9271
9272 procedure Set_First_Inlined_Subprogram
9273 (N : Node_Id; Val : Entity_Id); -- Node3
9274
9275 procedure Set_First_Name
9276 (N : Node_Id; Val : Boolean := True); -- Flag5
9277
9278 procedure Set_First_Named_Actual
9279 (N : Node_Id; Val : Node_Id); -- Node4
9280
9281 procedure Set_First_Real_Statement
9282 (N : Node_Id; Val : Node_Id); -- Node2
9283
9284 procedure Set_First_Subtype_Link
9285 (N : Node_Id; Val : Entity_Id); -- Node5
9286
9287 procedure Set_Float_Truncate
9288 (N : Node_Id; Val : Boolean := True); -- Flag11
9289
9290 procedure Set_Formal_Type_Definition
9291 (N : Node_Id; Val : Node_Id); -- Node3
9292
9293 procedure Set_Forwards_OK
9294 (N : Node_Id; Val : Boolean := True); -- Flag5
9295
9296 procedure Set_From_At_Mod
9297 (N : Node_Id; Val : Boolean := True); -- Flag4
9298
9299 procedure Set_From_Aspect_Specification
9300 (N : Node_Id; Val : Boolean := True); -- Flag13
9301
9302 procedure Set_From_At_End
9303 (N : Node_Id; Val : Boolean := True); -- Flag4
9304
9305 procedure Set_From_Default
9306 (N : Node_Id; Val : Boolean := True); -- Flag6
9307
9308 procedure Set_Generic_Associations
9309 (N : Node_Id; Val : List_Id); -- List3
9310
9311 procedure Set_Generic_Formal_Declarations
9312 (N : Node_Id; Val : List_Id); -- List2
9313
9314 procedure Set_Generic_Parent
9315 (N : Node_Id; Val : Node_Id); -- Node5
9316
9317 procedure Set_Generic_Parent_Type
9318 (N : Node_Id; Val : Node_Id); -- Node4
9319
9320 procedure Set_Handled_Statement_Sequence
9321 (N : Node_Id; Val : Node_Id); -- Node4
9322
9323 procedure Set_Handler_List_Entry
9324 (N : Node_Id; Val : Node_Id); -- Node2
9325
9326 procedure Set_Has_Created_Identifier
9327 (N : Node_Id; Val : Boolean := True); -- Flag15
9328
9329 procedure Set_Has_Dynamic_Length_Check
9330 (N : Node_Id; Val : Boolean := True); -- Flag10
9331
9332 procedure Set_Has_Dynamic_Range_Check
9333 (N : Node_Id; Val : Boolean := True); -- Flag12
9334
9335 procedure Set_Has_Init_Expression
9336 (N : Node_Id; Val : Boolean := True); -- Flag14
9337
9338 procedure Set_Has_Local_Raise
9339 (N : Node_Id; Val : Boolean := True); -- Flag8
9340
9341 procedure Set_Has_No_Elaboration_Code
9342 (N : Node_Id; Val : Boolean := True); -- Flag17
9343
9344 procedure Set_Has_Pragma_CPU
9345 (N : Node_Id; Val : Boolean := True); -- Flag14
9346
9347 procedure Set_Has_Pragma_Priority
9348 (N : Node_Id; Val : Boolean := True); -- Flag6
9349
9350 procedure Set_Has_Pragma_Suppress_All
9351 (N : Node_Id; Val : Boolean := True); -- Flag14
9352
9353 procedure Set_Has_Private_View
9354 (N : Node_Id; Val : Boolean := True); -- Flag11
9355
9356 procedure Set_Has_Relative_Deadline_Pragma
9357 (N : Node_Id; Val : Boolean := True); -- Flag9
9358
9359 procedure Set_Has_Self_Reference
9360 (N : Node_Id; Val : Boolean := True); -- Flag13
9361
9362 procedure Set_Has_Storage_Size_Pragma
9363 (N : Node_Id; Val : Boolean := True); -- Flag5
9364
9365 procedure Set_Has_Task_Info_Pragma
9366 (N : Node_Id; Val : Boolean := True); -- Flag7
9367
9368 procedure Set_Has_Task_Name_Pragma
9369 (N : Node_Id; Val : Boolean := True); -- Flag8
9370
9371 procedure Set_Has_Wide_Character
9372 (N : Node_Id; Val : Boolean := True); -- Flag11
9373
9374 procedure Set_Has_Wide_Wide_Character
9375 (N : Node_Id; Val : Boolean := True); -- Flag13
9376
9377 procedure Set_Hidden_By_Use_Clause
9378 (N : Node_Id; Val : Elist_Id); -- Elist4
9379
9380 procedure Set_High_Bound
9381 (N : Node_Id; Val : Node_Id); -- Node2
9382
9383 procedure Set_Identifier
9384 (N : Node_Id; Val : Node_Id); -- Node1
9385
9386 procedure Set_Interface_List
9387 (N : Node_Id; Val : List_Id); -- List2
9388
9389 procedure Set_Interface_Present
9390 (N : Node_Id; Val : Boolean := True); -- Flag16
9391
9392 procedure Set_Implicit_With
9393 (N : Node_Id; Val : Boolean := True); -- Flag16
9394
9395 procedure Set_Import_Interface_Present
9396 (N : Node_Id; Val : Boolean := True); -- Flag16
9397
9398 procedure Set_In_Present
9399 (N : Node_Id; Val : Boolean := True); -- Flag15
9400
9401 procedure Set_Includes_Infinities
9402 (N : Node_Id; Val : Boolean := True); -- Flag11
9403
9404 procedure Set_Inherited_Discriminant
9405 (N : Node_Id; Val : Boolean := True); -- Flag13
9406
9407 procedure Set_Instance_Spec
9408 (N : Node_Id; Val : Node_Id); -- Node5
9409
9410 procedure Set_Intval
9411 (N : Node_Id; Val : Uint); -- Uint3
9412
9413 procedure Set_Is_Accessibility_Actual
9414 (N : Node_Id; Val : Boolean := True); -- Flag13
9415
9416 procedure Set_Is_Asynchronous_Call_Block
9417 (N : Node_Id; Val : Boolean := True); -- Flag7
9418
9419 procedure Set_Is_Component_Left_Opnd
9420 (N : Node_Id; Val : Boolean := True); -- Flag13
9421
9422 procedure Set_Is_Component_Right_Opnd
9423 (N : Node_Id; Val : Boolean := True); -- Flag14
9424
9425 procedure Set_Is_Controlling_Actual
9426 (N : Node_Id; Val : Boolean := True); -- Flag16
9427
9428 procedure Set_Is_Delayed_Aspect
9429 (N : Node_Id; Val : Boolean := True); -- Flag14
9430
9431 procedure Set_Is_Dynamic_Coextension
9432 (N : Node_Id; Val : Boolean := True); -- Flag18
9433
9434 procedure Set_Is_Elsif
9435 (N : Node_Id; Val : Boolean := True); -- Flag13
9436
9437 procedure Set_Is_Entry_Barrier_Function
9438 (N : Node_Id; Val : Boolean := True); -- Flag8
9439
9440 procedure Set_Is_Expanded_Build_In_Place_Call
9441 (N : Node_Id; Val : Boolean := True); -- Flag11
9442
9443 procedure Set_Is_Folded_In_Parser
9444 (N : Node_Id; Val : Boolean := True); -- Flag4
9445
9446 procedure Set_Is_In_Discriminant_Check
9447 (N : Node_Id; Val : Boolean := True); -- Flag11
9448
9449 procedure Set_Is_Machine_Number
9450 (N : Node_Id; Val : Boolean := True); -- Flag11
9451
9452 procedure Set_Is_Null_Loop
9453 (N : Node_Id; Val : Boolean := True); -- Flag16
9454
9455 procedure Set_Is_Overloaded
9456 (N : Node_Id; Val : Boolean := True); -- Flag5
9457
9458 procedure Set_Is_Power_Of_2_For_Shift
9459 (N : Node_Id; Val : Boolean := True); -- Flag13
9460
9461 procedure Set_Is_Protected_Subprogram_Body
9462 (N : Node_Id; Val : Boolean := True); -- Flag7
9463
9464 procedure Set_Is_Static_Coextension
9465 (N : Node_Id; Val : Boolean := True); -- Flag14
9466
9467 procedure Set_Is_Static_Expression
9468 (N : Node_Id; Val : Boolean := True); -- Flag6
9469
9470 procedure Set_Is_Subprogram_Descriptor
9471 (N : Node_Id; Val : Boolean := True); -- Flag16
9472
9473 procedure Set_Is_Task_Allocation_Block
9474 (N : Node_Id; Val : Boolean := True); -- Flag6
9475
9476 procedure Set_Is_Task_Master
9477 (N : Node_Id; Val : Boolean := True); -- Flag5
9478
9479 procedure Set_Iteration_Scheme
9480 (N : Node_Id; Val : Node_Id); -- Node2
9481
9482 procedure Set_Iterator_Specification
9483 (N : Node_Id; Val : Node_Id); -- Node2
9484
9485 procedure Set_Itype
9486 (N : Node_Id; Val : Entity_Id); -- Node1
9487
9488 procedure Set_Kill_Range_Check
9489 (N : Node_Id; Val : Boolean := True); -- Flag11
9490
9491 procedure Set_Last_Bit
9492 (N : Node_Id; Val : Node_Id); -- Node4
9493
9494 procedure Set_Last_Name
9495 (N : Node_Id; Val : Boolean := True); -- Flag6
9496
9497 procedure Set_Library_Unit
9498 (N : Node_Id; Val : Node_Id); -- Node4
9499
9500 procedure Set_Label_Construct
9501 (N : Node_Id; Val : Node_Id); -- Node2
9502
9503 procedure Set_Left_Opnd
9504 (N : Node_Id; Val : Node_Id); -- Node2
9505
9506 procedure Set_Limited_View_Installed
9507 (N : Node_Id; Val : Boolean := True); -- Flag18
9508
9509 procedure Set_Limited_Present
9510 (N : Node_Id; Val : Boolean := True); -- Flag17
9511
9512 procedure Set_Literals
9513 (N : Node_Id; Val : List_Id); -- List1
9514
9515 procedure Set_Local_Raise_Not_OK
9516 (N : Node_Id; Val : Boolean := True); -- Flag7
9517
9518 procedure Set_Local_Raise_Statements
9519 (N : Node_Id; Val : Elist_Id); -- Elist1
9520
9521 procedure Set_Loop_Actions
9522 (N : Node_Id; Val : List_Id); -- List2
9523
9524 procedure Set_Loop_Parameter_Specification
9525 (N : Node_Id; Val : Node_Id); -- Node4
9526
9527 procedure Set_Low_Bound
9528 (N : Node_Id; Val : Node_Id); -- Node1
9529
9530 procedure Set_Mod_Clause
9531 (N : Node_Id; Val : Node_Id); -- Node2
9532
9533 procedure Set_More_Ids
9534 (N : Node_Id; Val : Boolean := True); -- Flag5
9535
9536 procedure Set_Must_Be_Byte_Aligned
9537 (N : Node_Id; Val : Boolean := True); -- Flag14
9538
9539 procedure Set_Must_Not_Freeze
9540 (N : Node_Id; Val : Boolean := True); -- Flag8
9541
9542 procedure Set_Must_Not_Override
9543 (N : Node_Id; Val : Boolean := True); -- Flag15
9544
9545 procedure Set_Must_Override
9546 (N : Node_Id; Val : Boolean := True); -- Flag14
9547
9548 procedure Set_Name
9549 (N : Node_Id; Val : Node_Id); -- Node2
9550
9551 procedure Set_Names
9552 (N : Node_Id; Val : List_Id); -- List2
9553
9554 procedure Set_Next_Entity
9555 (N : Node_Id; Val : Node_Id); -- Node2
9556
9557 procedure Set_Next_Exit_Statement
9558 (N : Node_Id; Val : Node_Id); -- Node3
9559
9560 procedure Set_Next_Implicit_With
9561 (N : Node_Id; Val : Node_Id); -- Node3
9562
9563 procedure Set_Next_Named_Actual
9564 (N : Node_Id; Val : Node_Id); -- Node4
9565
9566 procedure Set_Next_Pragma
9567 (N : Node_Id; Val : Node_Id); -- Node1
9568
9569 procedure Set_Next_Rep_Item
9570 (N : Node_Id; Val : Node_Id); -- Node5
9571
9572 procedure Set_Next_Use_Clause
9573 (N : Node_Id; Val : Node_Id); -- Node3
9574
9575 procedure Set_No_Ctrl_Actions
9576 (N : Node_Id; Val : Boolean := True); -- Flag7
9577
9578 procedure Set_No_Elaboration_Check
9579 (N : Node_Id; Val : Boolean := True); -- Flag14
9580
9581 procedure Set_No_Entities_Ref_In_Spec
9582 (N : Node_Id; Val : Boolean := True); -- Flag8
9583
9584 procedure Set_No_Initialization
9585 (N : Node_Id; Val : Boolean := True); -- Flag13
9586
9587 procedure Set_No_Truncation
9588 (N : Node_Id; Val : Boolean := True); -- Flag17
9589
9590 procedure Set_Null_Present
9591 (N : Node_Id; Val : Boolean := True); -- Flag13
9592
9593 procedure Set_Null_Exclusion_Present
9594 (N : Node_Id; Val : Boolean := True); -- Flag11
9595
9596 procedure Set_Null_Exclusion_In_Return_Present
9597 (N : Node_Id; Val : Boolean := True); -- Flag14
9598
9599 procedure Set_Null_Record_Present
9600 (N : Node_Id; Val : Boolean := True); -- Flag17
9601
9602 procedure Set_Object_Definition
9603 (N : Node_Id; Val : Node_Id); -- Node4
9604
9605 procedure Set_Of_Present
9606 (N : Node_Id; Val : Boolean := True); -- Flag16
9607
9608 procedure Set_Original_Discriminant
9609 (N : Node_Id; Val : Node_Id); -- Node2
9610
9611 procedure Set_Original_Entity
9612 (N : Node_Id; Val : Entity_Id); -- Node2
9613
9614 procedure Set_Others_Discrete_Choices
9615 (N : Node_Id; Val : List_Id); -- List1
9616
9617 procedure Set_Out_Present
9618 (N : Node_Id; Val : Boolean := True); -- Flag17
9619
9620 procedure Set_Parameter_Associations
9621 (N : Node_Id; Val : List_Id); -- List3
9622
9623 procedure Set_Parameter_List_Truncated
9624 (N : Node_Id; Val : Boolean := True); -- Flag17
9625
9626 procedure Set_Parameter_Specifications
9627 (N : Node_Id; Val : List_Id); -- List3
9628
9629 procedure Set_Parameter_Type
9630 (N : Node_Id; Val : Node_Id); -- Node2
9631
9632 procedure Set_Parent_Spec
9633 (N : Node_Id; Val : Node_Id); -- Node4
9634
9635 procedure Set_Position
9636 (N : Node_Id; Val : Node_Id); -- Node2
9637
9638 procedure Set_Pragma_Argument_Associations
9639 (N : Node_Id; Val : List_Id); -- List2
9640
9641 procedure Set_Pragma_Enabled
9642 (N : Node_Id; Val : Boolean := True); -- Flag5
9643
9644 procedure Set_Pragma_Identifier
9645 (N : Node_Id; Val : Node_Id); -- Node4
9646
9647 procedure Set_Pragmas_After
9648 (N : Node_Id; Val : List_Id); -- List5
9649
9650 procedure Set_Pragmas_Before
9651 (N : Node_Id; Val : List_Id); -- List4
9652
9653 procedure Set_Prefix
9654 (N : Node_Id; Val : Node_Id); -- Node3
9655
9656 procedure Set_Present_Expr
9657 (N : Node_Id; Val : Uint); -- Uint3
9658
9659 procedure Set_Prev_Ids
9660 (N : Node_Id; Val : Boolean := True); -- Flag6
9661
9662 procedure Set_Print_In_Hex
9663 (N : Node_Id; Val : Boolean := True); -- Flag13
9664
9665 procedure Set_Private_Declarations
9666 (N : Node_Id; Val : List_Id); -- List3
9667
9668 procedure Set_Private_Present
9669 (N : Node_Id; Val : Boolean := True); -- Flag15
9670
9671 procedure Set_Procedure_To_Call
9672 (N : Node_Id; Val : Node_Id); -- Node2
9673
9674 procedure Set_Proper_Body
9675 (N : Node_Id; Val : Node_Id); -- Node1
9676
9677 procedure Set_Protected_Definition
9678 (N : Node_Id; Val : Node_Id); -- Node3
9679
9680 procedure Set_Protected_Present
9681 (N : Node_Id; Val : Boolean := True); -- Flag6
9682
9683 procedure Set_Raises_Constraint_Error
9684 (N : Node_Id; Val : Boolean := True); -- Flag7
9685
9686 procedure Set_Range_Constraint
9687 (N : Node_Id; Val : Node_Id); -- Node4
9688
9689 procedure Set_Range_Expression
9690 (N : Node_Id; Val : Node_Id); -- Node4
9691
9692 procedure Set_Real_Range_Specification
9693 (N : Node_Id; Val : Node_Id); -- Node4
9694
9695 procedure Set_Realval
9696 (N : Node_Id; Val : Ureal); -- Ureal3
9697
9698 procedure Set_Reason
9699 (N : Node_Id; Val : Uint); -- Uint3
9700
9701 procedure Set_Record_Extension_Part
9702 (N : Node_Id; Val : Node_Id); -- Node3
9703
9704 procedure Set_Redundant_Use
9705 (N : Node_Id; Val : Boolean := True); -- Flag13
9706
9707 procedure Set_Renaming_Exception
9708 (N : Node_Id; Val : Node_Id); -- Node2
9709
9710 procedure Set_Result_Definition
9711 (N : Node_Id; Val : Node_Id); -- Node4
9712
9713 procedure Set_Return_Object_Declarations
9714 (N : Node_Id; Val : List_Id); -- List3
9715
9716 procedure Set_Return_Statement_Entity
9717 (N : Node_Id; Val : Node_Id); -- Node5
9718
9719 procedure Set_Reverse_Present
9720 (N : Node_Id; Val : Boolean := True); -- Flag15
9721
9722 procedure Set_Right_Opnd
9723 (N : Node_Id; Val : Node_Id); -- Node3
9724
9725 procedure Set_Rounded_Result
9726 (N : Node_Id; Val : Boolean := True); -- Flag18
9727
9728 procedure Set_SCIL_Controlling_Tag
9729 (N : Node_Id; Val : Node_Id); -- Node5
9730
9731 procedure Set_SCIL_Entity
9732 (N : Node_Id; Val : Node_Id); -- Node4
9733
9734 procedure Set_SCIL_Tag_Value
9735 (N : Node_Id; Val : Node_Id); -- Node5
9736
9737 procedure Set_SCIL_Target_Prim
9738 (N : Node_Id; Val : Node_Id); -- Node2
9739
9740 procedure Set_Scope
9741 (N : Node_Id; Val : Node_Id); -- Node3
9742
9743 procedure Set_Select_Alternatives
9744 (N : Node_Id; Val : List_Id); -- List1
9745
9746 procedure Set_Selector_Name
9747 (N : Node_Id; Val : Node_Id); -- Node2
9748
9749 procedure Set_Selector_Names
9750 (N : Node_Id; Val : List_Id); -- List1
9751
9752 procedure Set_Shift_Count_OK
9753 (N : Node_Id; Val : Boolean := True); -- Flag4
9754
9755 procedure Set_Source_Type
9756 (N : Node_Id; Val : Entity_Id); -- Node1
9757
9758 procedure Set_Specification
9759 (N : Node_Id; Val : Node_Id); -- Node1
9760
9761 procedure Set_Split_PPC
9762 (N : Node_Id; Val : Boolean); -- Flag17
9763
9764 procedure Set_Statements
9765 (N : Node_Id; Val : List_Id); -- List3
9766
9767 procedure Set_Static_Processing_OK
9768 (N : Node_Id; Val : Boolean); -- Flag4
9769
9770 procedure Set_Storage_Pool
9771 (N : Node_Id; Val : Node_Id); -- Node1
9772
9773 procedure Set_Strval
9774 (N : Node_Id; Val : String_Id); -- Str3
9775
9776 procedure Set_Subtype_Indication
9777 (N : Node_Id; Val : Node_Id); -- Node5
9778
9779 procedure Set_Subtype_Mark
9780 (N : Node_Id; Val : Node_Id); -- Node4
9781
9782 procedure Set_Subtype_Marks
9783 (N : Node_Id; Val : List_Id); -- List2
9784
9785 procedure Set_Suppress_Loop_Warnings
9786 (N : Node_Id; Val : Boolean := True); -- Flag17
9787
9788 procedure Set_Synchronized_Present
9789 (N : Node_Id; Val : Boolean := True); -- Flag7
9790
9791 procedure Set_Tagged_Present
9792 (N : Node_Id; Val : Boolean := True); -- Flag15
9793
9794 procedure Set_Target_Type
9795 (N : Node_Id; Val : Entity_Id); -- Node2
9796
9797 procedure Set_Task_Definition
9798 (N : Node_Id; Val : Node_Id); -- Node3
9799
9800 procedure Set_Task_Present
9801 (N : Node_Id; Val : Boolean := True); -- Flag5
9802
9803 procedure Set_Then_Actions
9804 (N : Node_Id; Val : List_Id); -- List2
9805
9806 procedure Set_Then_Statements
9807 (N : Node_Id; Val : List_Id); -- List2
9808
9809 procedure Set_Treat_Fixed_As_Integer
9810 (N : Node_Id; Val : Boolean := True); -- Flag14
9811
9812 procedure Set_Triggering_Alternative
9813 (N : Node_Id; Val : Node_Id); -- Node1
9814
9815 procedure Set_Triggering_Statement
9816 (N : Node_Id; Val : Node_Id); -- Node1
9817
9818 procedure Set_TSS_Elist
9819 (N : Node_Id; Val : Elist_Id); -- Elist3
9820
9821 procedure Set_Type_Definition
9822 (N : Node_Id; Val : Node_Id); -- Node3
9823
9824 procedure Set_Unit
9825 (N : Node_Id; Val : Node_Id); -- Node2
9826
9827 procedure Set_Unknown_Discriminants_Present
9828 (N : Node_Id; Val : Boolean := True); -- Flag13
9829
9830 procedure Set_Unreferenced_In_Spec
9831 (N : Node_Id; Val : Boolean := True); -- Flag7
9832
9833 procedure Set_Variant_Part
9834 (N : Node_Id; Val : Node_Id); -- Node4
9835
9836 procedure Set_Variants
9837 (N : Node_Id; Val : List_Id); -- List1
9838
9839 procedure Set_Visible_Declarations
9840 (N : Node_Id; Val : List_Id); -- List2
9841
9842 procedure Set_Was_Originally_Stub
9843 (N : Node_Id; Val : Boolean := True); -- Flag13
9844
9845 procedure Set_Withed_Body
9846 (N : Node_Id; Val : Node_Id); -- Node1
9847
9848 procedure Set_Zero_Cost_Handling
9849 (N : Node_Id; Val : Boolean := True); -- Flag5
9850
9851 -------------------------
9852 -- Iterator Procedures --
9853 -------------------------
9854
9855 -- The call to Next_xxx (N) is equivalent to N := Next_xxx (N)
9856
9857 procedure Next_Entity (N : in out Node_Id);
9858 procedure Next_Named_Actual (N : in out Node_Id);
9859 procedure Next_Rep_Item (N : in out Node_Id);
9860 procedure Next_Use_Clause (N : in out Node_Id);
9861
9862 -------------------------------------------
9863 -- Miscellaneous Tree Access Subprograms --
9864 -------------------------------------------
9865
9866 function End_Location (N : Node_Id) return Source_Ptr;
9867 -- N is an N_If_Statement or N_Case_Statement node, and this function
9868 -- returns the location of the IF token in the END IF sequence by
9869 -- translating the value of the End_Span field.
9870
9871 procedure Set_End_Location (N : Node_Id; S : Source_Ptr);
9872 -- N is an N_If_Statement or N_Case_Statement node. This procedure sets
9873 -- the End_Span field to correspond to the given value S. In other words,
9874 -- End_Span is set to the difference between S and Sloc (N), the starting
9875 -- location.
9876
9877 function Get_Pragma_Arg (Arg : Node_Id) return Node_Id;
9878 -- Given an argument to a pragma Arg, this function returns the expression
9879 -- for the argument. This is Arg itself, or, in the case where Arg is a
9880 -- pragma argument association node, the expression from this node.
9881
9882 --------------------------------
9883 -- Node_Kind Membership Tests --
9884 --------------------------------
9885
9886 -- The following functions allow a convenient notation for testing whether
9887 -- a Node_Kind value matches any one of a list of possible values. In each
9888 -- case True is returned if the given T argument is equal to any of the V
9889 -- arguments. Note that there is a similar set of functions defined in
9890 -- Atree where the first argument is a Node_Id whose Nkind field is tested.
9891
9892 function Nkind_In
9893 (T : Node_Kind;
9894 V1 : Node_Kind;
9895 V2 : Node_Kind) return Boolean;
9896
9897 function Nkind_In
9898 (T : Node_Kind;
9899 V1 : Node_Kind;
9900 V2 : Node_Kind;
9901 V3 : Node_Kind) return Boolean;
9902
9903 function Nkind_In
9904 (T : Node_Kind;
9905 V1 : Node_Kind;
9906 V2 : Node_Kind;
9907 V3 : Node_Kind;
9908 V4 : Node_Kind) return Boolean;
9909
9910 function Nkind_In
9911 (T : Node_Kind;
9912 V1 : Node_Kind;
9913 V2 : Node_Kind;
9914 V3 : Node_Kind;
9915 V4 : Node_Kind;
9916 V5 : Node_Kind) return Boolean;
9917
9918 function Nkind_In
9919 (T : Node_Kind;
9920 V1 : Node_Kind;
9921 V2 : Node_Kind;
9922 V3 : Node_Kind;
9923 V4 : Node_Kind;
9924 V5 : Node_Kind;
9925 V6 : Node_Kind) return Boolean;
9926
9927 function Nkind_In
9928 (T : Node_Kind;
9929 V1 : Node_Kind;
9930 V2 : Node_Kind;
9931 V3 : Node_Kind;
9932 V4 : Node_Kind;
9933 V5 : Node_Kind;
9934 V6 : Node_Kind;
9935 V7 : Node_Kind) return Boolean;
9936
9937 function Nkind_In
9938 (T : Node_Kind;
9939 V1 : Node_Kind;
9940 V2 : Node_Kind;
9941 V3 : Node_Kind;
9942 V4 : Node_Kind;
9943 V5 : Node_Kind;
9944 V6 : Node_Kind;
9945 V7 : Node_Kind;
9946 V8 : Node_Kind) return Boolean;
9947
9948 function Nkind_In
9949 (T : Node_Kind;
9950 V1 : Node_Kind;
9951 V2 : Node_Kind;
9952 V3 : Node_Kind;
9953 V4 : Node_Kind;
9954 V5 : Node_Kind;
9955 V6 : Node_Kind;
9956 V7 : Node_Kind;
9957 V8 : Node_Kind;
9958 V9 : Node_Kind) return Boolean;
9959
9960 pragma Inline (Nkind_In);
9961 -- Inline all above functions
9962
9963 -----------------------
9964 -- Utility Functions --
9965 -----------------------
9966
9967 function Pragma_Name (N : Node_Id) return Name_Id;
9968 pragma Inline (Pragma_Name);
9969 -- Convenient function to obtain Chars field of Pragma_Identifier
9970
9971 -----------------------------
9972 -- Syntactic Parent Tables --
9973 -----------------------------
9974
9975 -- These tables show for each node, and for each of the five fields,
9976 -- whether the corresponding field is syntactic (True) or semantic (False).
9977 -- Unused entries are also set to False.
9978
9979 subtype Field_Num is Natural range 1 .. 5;
9980
9981 Is_Syntactic_Field : constant array (Node_Kind, Field_Num) of Boolean := (
9982
9983 -- Following entries can be built automatically from the sinfo sources
9984 -- using the makeisf utility (currently this program is in spitbol).
9985
9986 N_Identifier =>
9987 (1 => True, -- Chars (Name1)
9988 2 => False, -- Original_Discriminant (Node2-Sem)
9989 3 => False, -- unused
9990 4 => False, -- Entity (Node4-Sem)
9991 5 => False), -- Etype (Node5-Sem)
9992
9993 N_Integer_Literal =>
9994 (1 => False, -- unused
9995 2 => False, -- Original_Entity (Node2-Sem)
9996 3 => True, -- Intval (Uint3)
9997 4 => False, -- unused
9998 5 => False), -- Etype (Node5-Sem)
9999
10000 N_Real_Literal =>
10001 (1 => False, -- unused
10002 2 => False, -- Original_Entity (Node2-Sem)
10003 3 => True, -- Realval (Ureal3)
10004 4 => False, -- Corresponding_Integer_Value (Uint4-Sem)
10005 5 => False), -- Etype (Node5-Sem)
10006
10007 N_Character_Literal =>
10008 (1 => True, -- Chars (Name1)
10009 2 => True, -- Char_Literal_Value (Uint2)
10010 3 => False, -- unused
10011 4 => False, -- Entity (Node4-Sem)
10012 5 => False), -- Etype (Node5-Sem)
10013
10014 N_String_Literal =>
10015 (1 => False, -- unused
10016 2 => False, -- unused
10017 3 => True, -- Strval (Str3)
10018 4 => False, -- unused
10019 5 => False), -- Etype (Node5-Sem)
10020
10021 N_Pragma =>
10022 (1 => False, -- Next_Pragma (Node1-Sem)
10023 2 => True, -- Pragma_Argument_Associations (List2)
10024 3 => True, -- Debug_Statement (Node3)
10025 4 => True, -- Pragma_Identifier (Node4)
10026 5 => False), -- Next_Rep_Item (Node5-Sem)
10027
10028 N_Pragma_Argument_Association =>
10029 (1 => True, -- Chars (Name1)
10030 2 => False, -- unused
10031 3 => True, -- Expression (Node3)
10032 4 => False, -- unused
10033 5 => False), -- unused
10034
10035 N_Defining_Identifier =>
10036 (1 => True, -- Chars (Name1)
10037 2 => False, -- Next_Entity (Node2-Sem)
10038 3 => False, -- Scope (Node3-Sem)
10039 4 => False, -- unused
10040 5 => False), -- Etype (Node5-Sem)
10041
10042 N_Full_Type_Declaration =>
10043 (1 => True, -- Defining_Identifier (Node1)
10044 2 => False, -- unused
10045 3 => True, -- Type_Definition (Node3)
10046 4 => True, -- Discriminant_Specifications (List4)
10047 5 => False), -- unused
10048
10049 N_Subtype_Declaration =>
10050 (1 => True, -- Defining_Identifier (Node1)
10051 2 => False, -- unused
10052 3 => False, -- unused
10053 4 => False, -- Generic_Parent_Type (Node4-Sem)
10054 5 => True), -- Subtype_Indication (Node5)
10055
10056 N_Subtype_Indication =>
10057 (1 => False, -- unused
10058 2 => False, -- unused
10059 3 => True, -- Constraint (Node3)
10060 4 => True, -- Subtype_Mark (Node4)
10061 5 => False), -- Etype (Node5-Sem)
10062
10063 N_Object_Declaration =>
10064 (1 => True, -- Defining_Identifier (Node1)
10065 2 => False, -- Handler_List_Entry (Node2-Sem)
10066 3 => True, -- Expression (Node3)
10067 4 => True, -- Object_Definition (Node4)
10068 5 => False), -- Corresponding_Generic_Association (Node5-Sem)
10069
10070 N_Number_Declaration =>
10071 (1 => True, -- Defining_Identifier (Node1)
10072 2 => False, -- unused
10073 3 => True, -- Expression (Node3)
10074 4 => False, -- unused
10075 5 => False), -- unused
10076
10077 N_Derived_Type_Definition =>
10078 (1 => False, -- unused
10079 2 => True, -- Interface_List (List2)
10080 3 => True, -- Record_Extension_Part (Node3)
10081 4 => False, -- unused
10082 5 => True), -- Subtype_Indication (Node5)
10083
10084 N_Range_Constraint =>
10085 (1 => False, -- unused
10086 2 => False, -- unused
10087 3 => False, -- unused
10088 4 => True, -- Range_Expression (Node4)
10089 5 => False), -- unused
10090
10091 N_Range =>
10092 (1 => True, -- Low_Bound (Node1)
10093 2 => True, -- High_Bound (Node2)
10094 3 => False, -- unused
10095 4 => False, -- unused
10096 5 => False), -- Etype (Node5-Sem)
10097
10098 N_Enumeration_Type_Definition =>
10099 (1 => True, -- Literals (List1)
10100 2 => False, -- unused
10101 3 => False, -- unused
10102 4 => True, -- End_Label (Node4)
10103 5 => False), -- unused
10104
10105 N_Defining_Character_Literal =>
10106 (1 => True, -- Chars (Name1)
10107 2 => False, -- Next_Entity (Node2-Sem)
10108 3 => False, -- Scope (Node3-Sem)
10109 4 => False, -- unused
10110 5 => False), -- Etype (Node5-Sem)
10111
10112 N_Signed_Integer_Type_Definition =>
10113 (1 => True, -- Low_Bound (Node1)
10114 2 => True, -- High_Bound (Node2)
10115 3 => False, -- unused
10116 4 => False, -- unused
10117 5 => False), -- unused
10118
10119 N_Modular_Type_Definition =>
10120 (1 => False, -- unused
10121 2 => False, -- unused
10122 3 => True, -- Expression (Node3)
10123 4 => False, -- unused
10124 5 => False), -- unused
10125
10126 N_Floating_Point_Definition =>
10127 (1 => False, -- unused
10128 2 => True, -- Digits_Expression (Node2)
10129 3 => False, -- unused
10130 4 => True, -- Real_Range_Specification (Node4)
10131 5 => False), -- unused
10132
10133 N_Real_Range_Specification =>
10134 (1 => True, -- Low_Bound (Node1)
10135 2 => True, -- High_Bound (Node2)
10136 3 => False, -- unused
10137 4 => False, -- unused
10138 5 => False), -- unused
10139
10140 N_Ordinary_Fixed_Point_Definition =>
10141 (1 => False, -- unused
10142 2 => False, -- unused
10143 3 => True, -- Delta_Expression (Node3)
10144 4 => True, -- Real_Range_Specification (Node4)
10145 5 => False), -- unused
10146
10147 N_Decimal_Fixed_Point_Definition =>
10148 (1 => False, -- unused
10149 2 => True, -- Digits_Expression (Node2)
10150 3 => True, -- Delta_Expression (Node3)
10151 4 => True, -- Real_Range_Specification (Node4)
10152 5 => False), -- unused
10153
10154 N_Digits_Constraint =>
10155 (1 => False, -- unused
10156 2 => True, -- Digits_Expression (Node2)
10157 3 => False, -- unused
10158 4 => True, -- Range_Constraint (Node4)
10159 5 => False), -- unused
10160
10161 N_Unconstrained_Array_Definition =>
10162 (1 => False, -- unused
10163 2 => True, -- Subtype_Marks (List2)
10164 3 => False, -- unused
10165 4 => True, -- Component_Definition (Node4)
10166 5 => False), -- unused
10167
10168 N_Constrained_Array_Definition =>
10169 (1 => False, -- unused
10170 2 => True, -- Discrete_Subtype_Definitions (List2)
10171 3 => False, -- unused
10172 4 => True, -- Component_Definition (Node4)
10173 5 => False), -- unused
10174
10175 N_Component_Definition =>
10176 (1 => False, -- unused
10177 2 => False, -- unused
10178 3 => True, -- Access_Definition (Node3)
10179 4 => False, -- unused
10180 5 => True), -- Subtype_Indication (Node5)
10181
10182 N_Discriminant_Specification =>
10183 (1 => True, -- Defining_Identifier (Node1)
10184 2 => False, -- unused
10185 3 => True, -- Expression (Node3)
10186 4 => False, -- unused
10187 5 => True), -- Discriminant_Type (Node5)
10188
10189 N_Index_Or_Discriminant_Constraint =>
10190 (1 => True, -- Constraints (List1)
10191 2 => False, -- unused
10192 3 => False, -- unused
10193 4 => False, -- unused
10194 5 => False), -- unused
10195
10196 N_Discriminant_Association =>
10197 (1 => True, -- Selector_Names (List1)
10198 2 => False, -- unused
10199 3 => True, -- Expression (Node3)
10200 4 => False, -- unused
10201 5 => False), -- unused
10202
10203 N_Record_Definition =>
10204 (1 => True, -- Component_List (Node1)
10205 2 => True, -- Interface_List (List2)
10206 3 => False, -- unused
10207 4 => True, -- End_Label (Node4)
10208 5 => False), -- unused
10209
10210 N_Component_List =>
10211 (1 => False, -- unused
10212 2 => False, -- unused
10213 3 => True, -- Component_Items (List3)
10214 4 => True, -- Variant_Part (Node4)
10215 5 => False), -- unused
10216
10217 N_Component_Declaration =>
10218 (1 => True, -- Defining_Identifier (Node1)
10219 2 => False, -- unused
10220 3 => True, -- Expression (Node3)
10221 4 => True, -- Component_Definition (Node4)
10222 5 => False), -- unused
10223
10224 N_Variant_Part =>
10225 (1 => True, -- Variants (List1)
10226 2 => True, -- Name (Node2)
10227 3 => False, -- unused
10228 4 => False, -- unused
10229 5 => False), -- unused
10230
10231 N_Variant =>
10232 (1 => True, -- Component_List (Node1)
10233 2 => False, -- Enclosing_Variant (Node2-Sem)
10234 3 => False, -- Present_Expr (Uint3-Sem)
10235 4 => True, -- Discrete_Choices (List4)
10236 5 => False), -- Dcheck_Function (Node5-Sem)
10237
10238 N_Others_Choice =>
10239 (1 => False, -- Others_Discrete_Choices (List1-Sem)
10240 2 => False, -- unused
10241 3 => False, -- unused
10242 4 => False, -- unused
10243 5 => False), -- unused
10244
10245 N_Access_To_Object_Definition =>
10246 (1 => False, -- unused
10247 2 => False, -- unused
10248 3 => False, -- unused
10249 4 => False, -- unused
10250 5 => True), -- Subtype_Indication (Node5)
10251
10252 N_Access_Function_Definition =>
10253 (1 => False, -- unused
10254 2 => False, -- unused
10255 3 => True, -- Parameter_Specifications (List3)
10256 4 => True, -- Result_Definition (Node4)
10257 5 => False), -- unused
10258
10259 N_Access_Procedure_Definition =>
10260 (1 => False, -- unused
10261 2 => False, -- unused
10262 3 => True, -- Parameter_Specifications (List3)
10263 4 => False, -- unused
10264 5 => False), -- unused
10265
10266 N_Access_Definition =>
10267 (1 => False, -- unused
10268 2 => False, -- unused
10269 3 => True, -- Access_To_Subprogram_Definition (Node3)
10270 4 => True, -- Subtype_Mark (Node4)
10271 5 => False), -- unused
10272
10273 N_Incomplete_Type_Declaration =>
10274 (1 => True, -- Defining_Identifier (Node1)
10275 2 => False, -- unused
10276 3 => False, -- unused
10277 4 => True, -- Discriminant_Specifications (List4)
10278 5 => False), -- unused
10279
10280 N_Explicit_Dereference =>
10281 (1 => False, -- unused
10282 2 => False, -- unused
10283 3 => True, -- Prefix (Node3)
10284 4 => False, -- Actual_Designated_Subtype (Node4-Sem)
10285 5 => False), -- Etype (Node5-Sem)
10286
10287 N_Indexed_Component =>
10288 (1 => True, -- Expressions (List1)
10289 2 => False, -- unused
10290 3 => True, -- Prefix (Node3)
10291 4 => False, -- unused
10292 5 => False), -- Etype (Node5-Sem)
10293
10294 N_Slice =>
10295 (1 => False, -- unused
10296 2 => False, -- unused
10297 3 => True, -- Prefix (Node3)
10298 4 => True, -- Discrete_Range (Node4)
10299 5 => False), -- Etype (Node5-Sem)
10300
10301 N_Selected_Component =>
10302 (1 => False, -- unused
10303 2 => True, -- Selector_Name (Node2)
10304 3 => True, -- Prefix (Node3)
10305 4 => False, -- unused
10306 5 => False), -- Etype (Node5-Sem)
10307
10308 N_Attribute_Reference =>
10309 (1 => True, -- Expressions (List1)
10310 2 => True, -- Attribute_Name (Name2)
10311 3 => True, -- Prefix (Node3)
10312 4 => False, -- Entity (Node4-Sem)
10313 5 => False), -- Etype (Node5-Sem)
10314
10315 N_Aggregate =>
10316 (1 => True, -- Expressions (List1)
10317 2 => True, -- Component_Associations (List2)
10318 3 => False, -- Aggregate_Bounds (Node3-Sem)
10319 4 => False, -- unused
10320 5 => False), -- Etype (Node5-Sem)
10321
10322 N_Component_Association =>
10323 (1 => True, -- Choices (List1)
10324 2 => False, -- Loop_Actions (List2-Sem)
10325 3 => True, -- Expression (Node3)
10326 4 => False, -- unused
10327 5 => False), -- unused
10328
10329 N_Extension_Aggregate =>
10330 (1 => True, -- Expressions (List1)
10331 2 => True, -- Component_Associations (List2)
10332 3 => True, -- Ancestor_Part (Node3)
10333 4 => False, -- unused
10334 5 => False), -- Etype (Node5-Sem)
10335
10336 N_Null =>
10337 (1 => False, -- unused
10338 2 => False, -- unused
10339 3 => False, -- unused
10340 4 => False, -- unused
10341 5 => False), -- Etype (Node5-Sem)
10342
10343 N_And_Then =>
10344 (1 => False, -- Actions (List1-Sem)
10345 2 => True, -- Left_Opnd (Node2)
10346 3 => True, -- Right_Opnd (Node3)
10347 4 => False, -- unused
10348 5 => False), -- Etype (Node5-Sem)
10349
10350 N_Or_Else =>
10351 (1 => False, -- Actions (List1-Sem)
10352 2 => True, -- Left_Opnd (Node2)
10353 3 => True, -- Right_Opnd (Node3)
10354 4 => False, -- unused
10355 5 => False), -- Etype (Node5-Sem)
10356
10357 N_In =>
10358 (1 => False, -- unused
10359 2 => True, -- Left_Opnd (Node2)
10360 3 => True, -- Right_Opnd (Node3)
10361 4 => True, -- Alternatives (List4)
10362 5 => False), -- Etype (Node5-Sem)
10363
10364 N_Not_In =>
10365 (1 => False, -- unused
10366 2 => True, -- Left_Opnd (Node2)
10367 3 => True, -- Right_Opnd (Node3)
10368 4 => True, -- Alternatives (List4)
10369 5 => False), -- Etype (Node5-Sem)
10370
10371 N_Op_And =>
10372 (1 => True, -- Chars (Name1)
10373 2 => True, -- Left_Opnd (Node2)
10374 3 => True, -- Right_Opnd (Node3)
10375 4 => False, -- Entity (Node4-Sem)
10376 5 => False), -- Etype (Node5-Sem)
10377
10378 N_Op_Or =>
10379 (1 => True, -- Chars (Name1)
10380 2 => True, -- Left_Opnd (Node2)
10381 3 => True, -- Right_Opnd (Node3)
10382 4 => False, -- Entity (Node4-Sem)
10383 5 => False), -- Etype (Node5-Sem)
10384
10385 N_Op_Xor =>
10386 (1 => True, -- Chars (Name1)
10387 2 => True, -- Left_Opnd (Node2)
10388 3 => True, -- Right_Opnd (Node3)
10389 4 => False, -- Entity (Node4-Sem)
10390 5 => False), -- Etype (Node5-Sem)
10391
10392 N_Op_Eq =>
10393 (1 => True, -- Chars (Name1)
10394 2 => True, -- Left_Opnd (Node2)
10395 3 => True, -- Right_Opnd (Node3)
10396 4 => False, -- Entity (Node4-Sem)
10397 5 => False), -- Etype (Node5-Sem)
10398
10399 N_Op_Ne =>
10400 (1 => True, -- Chars (Name1)
10401 2 => True, -- Left_Opnd (Node2)
10402 3 => True, -- Right_Opnd (Node3)
10403 4 => False, -- Entity (Node4-Sem)
10404 5 => False), -- Etype (Node5-Sem)
10405
10406 N_Op_Lt =>
10407 (1 => True, -- Chars (Name1)
10408 2 => True, -- Left_Opnd (Node2)
10409 3 => True, -- Right_Opnd (Node3)
10410 4 => False, -- Entity (Node4-Sem)
10411 5 => False), -- Etype (Node5-Sem)
10412
10413 N_Op_Le =>
10414 (1 => True, -- Chars (Name1)
10415 2 => True, -- Left_Opnd (Node2)
10416 3 => True, -- Right_Opnd (Node3)
10417 4 => False, -- Entity (Node4-Sem)
10418 5 => False), -- Etype (Node5-Sem)
10419
10420 N_Op_Gt =>
10421 (1 => True, -- Chars (Name1)
10422 2 => True, -- Left_Opnd (Node2)
10423 3 => True, -- Right_Opnd (Node3)
10424 4 => False, -- Entity (Node4-Sem)
10425 5 => False), -- Etype (Node5-Sem)
10426
10427 N_Op_Ge =>
10428 (1 => True, -- Chars (Name1)
10429 2 => True, -- Left_Opnd (Node2)
10430 3 => True, -- Right_Opnd (Node3)
10431 4 => False, -- Entity (Node4-Sem)
10432 5 => False), -- Etype (Node5-Sem)
10433
10434 N_Op_Add =>
10435 (1 => True, -- Chars (Name1)
10436 2 => True, -- Left_Opnd (Node2)
10437 3 => True, -- Right_Opnd (Node3)
10438 4 => False, -- Entity (Node4-Sem)
10439 5 => False), -- Etype (Node5-Sem)
10440
10441 N_Op_Subtract =>
10442 (1 => True, -- Chars (Name1)
10443 2 => True, -- Left_Opnd (Node2)
10444 3 => True, -- Right_Opnd (Node3)
10445 4 => False, -- Entity (Node4-Sem)
10446 5 => False), -- Etype (Node5-Sem)
10447
10448 N_Op_Concat =>
10449 (1 => True, -- Chars (Name1)
10450 2 => True, -- Left_Opnd (Node2)
10451 3 => True, -- Right_Opnd (Node3)
10452 4 => False, -- Entity (Node4-Sem)
10453 5 => False), -- Etype (Node5-Sem)
10454
10455 N_Op_Multiply =>
10456 (1 => True, -- Chars (Name1)
10457 2 => True, -- Left_Opnd (Node2)
10458 3 => True, -- Right_Opnd (Node3)
10459 4 => False, -- Entity (Node4-Sem)
10460 5 => False), -- Etype (Node5-Sem)
10461
10462 N_Op_Divide =>
10463 (1 => True, -- Chars (Name1)
10464 2 => True, -- Left_Opnd (Node2)
10465 3 => True, -- Right_Opnd (Node3)
10466 4 => False, -- Entity (Node4-Sem)
10467 5 => False), -- Etype (Node5-Sem)
10468
10469 N_Op_Mod =>
10470 (1 => True, -- Chars (Name1)
10471 2 => True, -- Left_Opnd (Node2)
10472 3 => True, -- Right_Opnd (Node3)
10473 4 => False, -- Entity (Node4-Sem)
10474 5 => False), -- Etype (Node5-Sem)
10475
10476 N_Op_Rem =>
10477 (1 => True, -- Chars (Name1)
10478 2 => True, -- Left_Opnd (Node2)
10479 3 => True, -- Right_Opnd (Node3)
10480 4 => False, -- Entity (Node4-Sem)
10481 5 => False), -- Etype (Node5-Sem)
10482
10483 N_Op_Expon =>
10484 (1 => True, -- Chars (Name1)
10485 2 => True, -- Left_Opnd (Node2)
10486 3 => True, -- Right_Opnd (Node3)
10487 4 => False, -- Entity (Node4-Sem)
10488 5 => False), -- Etype (Node5-Sem)
10489
10490 N_Op_Plus =>
10491 (1 => True, -- Chars (Name1)
10492 2 => False, -- unused
10493 3 => True, -- Right_Opnd (Node3)
10494 4 => False, -- Entity (Node4-Sem)
10495 5 => False), -- Etype (Node5-Sem)
10496
10497 N_Op_Minus =>
10498 (1 => True, -- Chars (Name1)
10499 2 => False, -- unused
10500 3 => True, -- Right_Opnd (Node3)
10501 4 => False, -- Entity (Node4-Sem)
10502 5 => False), -- Etype (Node5-Sem)
10503
10504 N_Op_Abs =>
10505 (1 => True, -- Chars (Name1)
10506 2 => False, -- unused
10507 3 => True, -- Right_Opnd (Node3)
10508 4 => False, -- Entity (Node4-Sem)
10509 5 => False), -- Etype (Node5-Sem)
10510
10511 N_Op_Not =>
10512 (1 => True, -- Chars (Name1)
10513 2 => False, -- unused
10514 3 => True, -- Right_Opnd (Node3)
10515 4 => False, -- Entity (Node4-Sem)
10516 5 => False), -- Etype (Node5-Sem)
10517
10518 N_Type_Conversion =>
10519 (1 => False, -- unused
10520 2 => False, -- unused
10521 3 => True, -- Expression (Node3)
10522 4 => True, -- Subtype_Mark (Node4)
10523 5 => False), -- Etype (Node5-Sem)
10524
10525 N_Qualified_Expression =>
10526 (1 => False, -- unused
10527 2 => False, -- unused
10528 3 => True, -- Expression (Node3)
10529 4 => True, -- Subtype_Mark (Node4)
10530 5 => False), -- Etype (Node5-Sem)
10531
10532 N_Quantified_Expression =>
10533 (1 => True, -- Condition (Node1)
10534 2 => True, -- Iterator_Specification
10535 3 => False, -- unused
10536 4 => True, -- Loop_Parameter_Specification (Node4)
10537 5 => False), -- Etype (Node5-Sem)
10538
10539 N_Allocator =>
10540 (1 => False, -- Storage_Pool (Node1-Sem)
10541 2 => False, -- Procedure_To_Call (Node2-Sem)
10542 3 => True, -- Expression (Node3)
10543 4 => False, -- Coextensions (Elist4-Sem)
10544 5 => False), -- Etype (Node5-Sem)
10545
10546 N_Null_Statement =>
10547 (1 => False, -- unused
10548 2 => False, -- unused
10549 3 => False, -- unused
10550 4 => False, -- unused
10551 5 => False), -- unused
10552
10553 N_Label =>
10554 (1 => True, -- Identifier (Node1)
10555 2 => False, -- unused
10556 3 => False, -- unused
10557 4 => False, -- unused
10558 5 => False), -- unused
10559
10560 N_Assignment_Statement =>
10561 (1 => False, -- unused
10562 2 => True, -- Name (Node2)
10563 3 => True, -- Expression (Node3)
10564 4 => False, -- unused
10565 5 => False), -- unused
10566
10567 N_If_Statement =>
10568 (1 => True, -- Condition (Node1)
10569 2 => True, -- Then_Statements (List2)
10570 3 => True, -- Elsif_Parts (List3)
10571 4 => True, -- Else_Statements (List4)
10572 5 => True), -- End_Span (Uint5)
10573
10574 N_Elsif_Part =>
10575 (1 => True, -- Condition (Node1)
10576 2 => True, -- Then_Statements (List2)
10577 3 => False, -- Condition_Actions (List3-Sem)
10578 4 => False, -- unused
10579 5 => False), -- unused
10580
10581 N_Case_Expression =>
10582 (1 => False, -- unused
10583 2 => False, -- unused
10584 3 => True, -- Expression (Node3)
10585 4 => True, -- Alternatives (List4)
10586 5 => False), -- unused
10587
10588 N_Case_Expression_Alternative =>
10589 (1 => False, -- Actions (List1-Sem)
10590 2 => False, -- unused
10591 3 => True, -- Statements (List3)
10592 4 => True, -- Expression (Node4)
10593 5 => False), -- unused
10594
10595 N_Case_Statement =>
10596 (1 => False, -- unused
10597 2 => False, -- unused
10598 3 => True, -- Expression (Node3)
10599 4 => True, -- Alternatives (List4)
10600 5 => True), -- End_Span (Uint5)
10601
10602 N_Case_Statement_Alternative =>
10603 (1 => False, -- unused
10604 2 => False, -- unused
10605 3 => True, -- Statements (List3)
10606 4 => True, -- Discrete_Choices (List4)
10607 5 => False), -- unused
10608
10609 N_Loop_Statement =>
10610 (1 => True, -- Identifier (Node1)
10611 2 => True, -- Iteration_Scheme (Node2)
10612 3 => True, -- Statements (List3)
10613 4 => True, -- End_Label (Node4)
10614 5 => False), -- unused
10615
10616 N_Iteration_Scheme =>
10617 (1 => True, -- Condition (Node1)
10618 2 => True, -- Iterator_Specification (Node2)
10619 3 => False, -- Condition_Actions (List3-Sem)
10620 4 => True, -- Loop_Parameter_Specification (Node4)
10621 5 => False), -- unused
10622
10623 N_Loop_Parameter_Specification =>
10624 (1 => True, -- Defining_Identifier (Node1)
10625 2 => False, -- unused
10626 3 => False, -- unused
10627 4 => True, -- Discrete_Subtype_Definition (Node4)
10628 5 => False), -- unused
10629
10630 N_Iterator_Specification =>
10631 (1 => True, -- Defining_Identifier (Node1)
10632 2 => True, -- Name (Node2)
10633 3 => False, -- Unused
10634 4 => False, -- Unused
10635 5 => True), -- Subtype_Indication (Node5)
10636
10637 N_Block_Statement =>
10638 (1 => True, -- Identifier (Node1)
10639 2 => True, -- Declarations (List2)
10640 3 => False, -- Activation_Chain_Entity (Node3-Sem)
10641 4 => True, -- Handled_Statement_Sequence (Node4)
10642 5 => False), -- unused
10643
10644 N_Exit_Statement =>
10645 (1 => True, -- Condition (Node1)
10646 2 => True, -- Name (Node2)
10647 3 => False, -- unused
10648 4 => False, -- unused
10649 5 => False), -- unused
10650
10651 N_Goto_Statement =>
10652 (1 => False, -- unused
10653 2 => True, -- Name (Node2)
10654 3 => False, -- unused
10655 4 => False, -- unused
10656 5 => False), -- unused
10657
10658 N_Subprogram_Declaration =>
10659 (1 => True, -- Specification (Node1)
10660 2 => False, -- unused
10661 3 => False, -- Body_To_Inline (Node3-Sem)
10662 4 => False, -- Parent_Spec (Node4-Sem)
10663 5 => False), -- Corresponding_Body (Node5-Sem)
10664
10665 N_Abstract_Subprogram_Declaration =>
10666 (1 => True, -- Specification (Node1)
10667 2 => False, -- unused
10668 3 => False, -- unused
10669 4 => False, -- unused
10670 5 => False), -- unused
10671
10672 N_Function_Specification =>
10673 (1 => True, -- Defining_Unit_Name (Node1)
10674 2 => False, -- Elaboration_Boolean (Node2-Sem)
10675 3 => True, -- Parameter_Specifications (List3)
10676 4 => True, -- Result_Definition (Node4)
10677 5 => False), -- Generic_Parent (Node5-Sem)
10678
10679 N_Procedure_Specification =>
10680 (1 => True, -- Defining_Unit_Name (Node1)
10681 2 => False, -- Elaboration_Boolean (Node2-Sem)
10682 3 => True, -- Parameter_Specifications (List3)
10683 4 => False, -- unused
10684 5 => False), -- Generic_Parent (Node5-Sem)
10685
10686 N_Designator =>
10687 (1 => True, -- Identifier (Node1)
10688 2 => True, -- Name (Node2)
10689 3 => False, -- unused
10690 4 => False, -- unused
10691 5 => False), -- unused
10692
10693 N_Defining_Program_Unit_Name =>
10694 (1 => True, -- Defining_Identifier (Node1)
10695 2 => True, -- Name (Node2)
10696 3 => False, -- unused
10697 4 => False, -- unused
10698 5 => False), -- unused
10699
10700 N_Operator_Symbol =>
10701 (1 => True, -- Chars (Name1)
10702 2 => False, -- unused
10703 3 => True, -- Strval (Str3)
10704 4 => False, -- Entity (Node4-Sem)
10705 5 => False), -- Etype (Node5-Sem)
10706
10707 N_Defining_Operator_Symbol =>
10708 (1 => True, -- Chars (Name1)
10709 2 => False, -- Next_Entity (Node2-Sem)
10710 3 => False, -- Scope (Node3-Sem)
10711 4 => False, -- unused
10712 5 => False), -- Etype (Node5-Sem)
10713
10714 N_Parameter_Specification =>
10715 (1 => True, -- Defining_Identifier (Node1)
10716 2 => True, -- Parameter_Type (Node2)
10717 3 => True, -- Expression (Node3)
10718 4 => False, -- unused
10719 5 => False), -- Default_Expression (Node5-Sem)
10720
10721 N_Subprogram_Body =>
10722 (1 => True, -- Specification (Node1)
10723 2 => True, -- Declarations (List2)
10724 3 => False, -- Activation_Chain_Entity (Node3-Sem)
10725 4 => True, -- Handled_Statement_Sequence (Node4)
10726 5 => False), -- Corresponding_Spec (Node5-Sem)
10727
10728 N_Parameterized_Expression =>
10729 (1 => True, -- Specification (Node1)
10730 2 => False, -- unused
10731 3 => True, -- Expression (Node3)
10732 4 => False, -- unused
10733 5 => False), -- unused
10734
10735 N_Procedure_Call_Statement =>
10736 (1 => False, -- Controlling_Argument (Node1-Sem)
10737 2 => True, -- Name (Node2)
10738 3 => True, -- Parameter_Associations (List3)
10739 4 => False, -- First_Named_Actual (Node4-Sem)
10740 5 => False), -- Etype (Node5-Sem)
10741
10742 N_Function_Call =>
10743 (1 => False, -- Controlling_Argument (Node1-Sem)
10744 2 => True, -- Name (Node2)
10745 3 => True, -- Parameter_Associations (List3)
10746 4 => False, -- First_Named_Actual (Node4-Sem)
10747 5 => False), -- Etype (Node5-Sem)
10748
10749 N_Parameter_Association =>
10750 (1 => False, -- unused
10751 2 => True, -- Selector_Name (Node2)
10752 3 => True, -- Explicit_Actual_Parameter (Node3)
10753 4 => False, -- Next_Named_Actual (Node4-Sem)
10754 5 => False), -- unused
10755
10756 N_Return_Statement =>
10757 (1 => False, -- Storage_Pool (Node1-Sem)
10758 2 => False, -- Procedure_To_Call (Node2-Sem)
10759 3 => True, -- Expression (Node3)
10760 4 => False, -- unused
10761 5 => False), -- Return_Statement_Entity (Node5-Sem)
10762
10763 N_Extended_Return_Statement =>
10764 (1 => False, -- Storage_Pool (Node1-Sem)
10765 2 => False, -- Procedure_To_Call (Node2-Sem)
10766 3 => True, -- Return_Object_Declarations (List3)
10767 4 => True, -- Handled_Statement_Sequence (Node4)
10768 5 => False), -- Return_Statement_Entity (Node5-Sem)
10769
10770 N_Package_Declaration =>
10771 (1 => True, -- Specification (Node1)
10772 2 => False, -- unused
10773 3 => False, -- Activation_Chain_Entity (Node3-Sem)
10774 4 => False, -- Parent_Spec (Node4-Sem)
10775 5 => False), -- Corresponding_Body (Node5-Sem)
10776
10777 N_Package_Specification =>
10778 (1 => True, -- Defining_Unit_Name (Node1)
10779 2 => True, -- Visible_Declarations (List2)
10780 3 => True, -- Private_Declarations (List3)
10781 4 => True, -- End_Label (Node4)
10782 5 => False), -- Generic_Parent (Node5-Sem)
10783
10784 N_Package_Body =>
10785 (1 => True, -- Defining_Unit_Name (Node1)
10786 2 => True, -- Declarations (List2)
10787 3 => False, -- unused
10788 4 => True, -- Handled_Statement_Sequence (Node4)
10789 5 => False), -- Corresponding_Spec (Node5-Sem)
10790
10791 N_Private_Type_Declaration =>
10792 (1 => True, -- Defining_Identifier (Node1)
10793 2 => False, -- unused
10794 3 => False, -- unused
10795 4 => True, -- Discriminant_Specifications (List4)
10796 5 => False), -- unused
10797
10798 N_Private_Extension_Declaration =>
10799 (1 => True, -- Defining_Identifier (Node1)
10800 2 => True, -- Interface_List (List2)
10801 3 => False, -- unused
10802 4 => True, -- Discriminant_Specifications (List4)
10803 5 => True), -- Subtype_Indication (Node5)
10804
10805 N_Use_Package_Clause =>
10806 (1 => False, -- unused
10807 2 => True, -- Names (List2)
10808 3 => False, -- Next_Use_Clause (Node3-Sem)
10809 4 => False, -- Hidden_By_Use_Clause (Elist4-Sem)
10810 5 => False), -- unused
10811
10812 N_Use_Type_Clause =>
10813 (1 => False, -- unused
10814 2 => True, -- Subtype_Marks (List2)
10815 3 => False, -- Next_Use_Clause (Node3-Sem)
10816 4 => False, -- Hidden_By_Use_Clause (Elist4-Sem)
10817 5 => False), -- unused
10818
10819 N_Object_Renaming_Declaration =>
10820 (1 => True, -- Defining_Identifier (Node1)
10821 2 => True, -- Name (Node2)
10822 3 => True, -- Access_Definition (Node3)
10823 4 => True, -- Subtype_Mark (Node4)
10824 5 => False), -- Corresponding_Generic_Association (Node5-Sem)
10825
10826 N_Exception_Renaming_Declaration =>
10827 (1 => True, -- Defining_Identifier (Node1)
10828 2 => True, -- Name (Node2)
10829 3 => False, -- unused
10830 4 => False, -- unused
10831 5 => False), -- unused
10832
10833 N_Package_Renaming_Declaration =>
10834 (1 => True, -- Defining_Unit_Name (Node1)
10835 2 => True, -- Name (Node2)
10836 3 => False, -- unused
10837 4 => False, -- Parent_Spec (Node4-Sem)
10838 5 => False), -- unused
10839
10840 N_Subprogram_Renaming_Declaration =>
10841 (1 => True, -- Specification (Node1)
10842 2 => True, -- Name (Node2)
10843 3 => False, -- Corresponding_Formal_Spec (Node3-Sem)
10844 4 => False, -- Parent_Spec (Node4-Sem)
10845 5 => False), -- Corresponding_Spec (Node5-Sem)
10846
10847 N_Generic_Package_Renaming_Declaration =>
10848 (1 => True, -- Defining_Unit_Name (Node1)
10849 2 => True, -- Name (Node2)
10850 3 => False, -- unused
10851 4 => False, -- Parent_Spec (Node4-Sem)
10852 5 => False), -- unused
10853
10854 N_Generic_Procedure_Renaming_Declaration =>
10855 (1 => True, -- Defining_Unit_Name (Node1)
10856 2 => True, -- Name (Node2)
10857 3 => False, -- unused
10858 4 => False, -- Parent_Spec (Node4-Sem)
10859 5 => False), -- unused
10860
10861 N_Generic_Function_Renaming_Declaration =>
10862 (1 => True, -- Defining_Unit_Name (Node1)
10863 2 => True, -- Name (Node2)
10864 3 => False, -- unused
10865 4 => False, -- Parent_Spec (Node4-Sem)
10866 5 => False), -- unused
10867
10868 N_Task_Type_Declaration =>
10869 (1 => True, -- Defining_Identifier (Node1)
10870 2 => True, -- Interface_List (List2)
10871 3 => True, -- Task_Definition (Node3)
10872 4 => True, -- Discriminant_Specifications (List4)
10873 5 => False), -- Corresponding_Body (Node5-Sem)
10874
10875 N_Single_Task_Declaration =>
10876 (1 => True, -- Defining_Identifier (Node1)
10877 2 => True, -- Interface_List (List2)
10878 3 => True, -- Task_Definition (Node3)
10879 4 => False, -- unused
10880 5 => False), -- unused
10881
10882 N_Task_Definition =>
10883 (1 => False, -- unused
10884 2 => True, -- Visible_Declarations (List2)
10885 3 => True, -- Private_Declarations (List3)
10886 4 => True, -- End_Label (Node4)
10887 5 => False), -- unused
10888
10889 N_Task_Body =>
10890 (1 => True, -- Defining_Identifier (Node1)
10891 2 => True, -- Declarations (List2)
10892 3 => False, -- Activation_Chain_Entity (Node3-Sem)
10893 4 => True, -- Handled_Statement_Sequence (Node4)
10894 5 => False), -- Corresponding_Spec (Node5-Sem)
10895
10896 N_Protected_Type_Declaration =>
10897 (1 => True, -- Defining_Identifier (Node1)
10898 2 => True, -- Interface_List (List2)
10899 3 => True, -- Protected_Definition (Node3)
10900 4 => True, -- Discriminant_Specifications (List4)
10901 5 => False), -- Corresponding_Body (Node5-Sem)
10902
10903 N_Single_Protected_Declaration =>
10904 (1 => True, -- Defining_Identifier (Node1)
10905 2 => True, -- Interface_List (List2)
10906 3 => True, -- Protected_Definition (Node3)
10907 4 => False, -- unused
10908 5 => False), -- unused
10909
10910 N_Protected_Definition =>
10911 (1 => False, -- unused
10912 2 => True, -- Visible_Declarations (List2)
10913 3 => True, -- Private_Declarations (List3)
10914 4 => True, -- End_Label (Node4)
10915 5 => False), -- unused
10916
10917 N_Protected_Body =>
10918 (1 => True, -- Defining_Identifier (Node1)
10919 2 => True, -- Declarations (List2)
10920 3 => False, -- unused
10921 4 => True, -- End_Label (Node4)
10922 5 => False), -- Corresponding_Spec (Node5-Sem)
10923
10924 N_Entry_Declaration =>
10925 (1 => True, -- Defining_Identifier (Node1)
10926 2 => False, -- unused
10927 3 => True, -- Parameter_Specifications (List3)
10928 4 => True, -- Discrete_Subtype_Definition (Node4)
10929 5 => False), -- Corresponding_Body (Node5-Sem)
10930
10931 N_Accept_Statement =>
10932 (1 => True, -- Entry_Direct_Name (Node1)
10933 2 => True, -- Declarations (List2)
10934 3 => True, -- Parameter_Specifications (List3)
10935 4 => True, -- Handled_Statement_Sequence (Node4)
10936 5 => True), -- Entry_Index (Node5)
10937
10938 N_Entry_Body =>
10939 (1 => True, -- Defining_Identifier (Node1)
10940 2 => True, -- Declarations (List2)
10941 3 => False, -- Activation_Chain_Entity (Node3-Sem)
10942 4 => True, -- Handled_Statement_Sequence (Node4)
10943 5 => True), -- Entry_Body_Formal_Part (Node5)
10944
10945 N_Entry_Body_Formal_Part =>
10946 (1 => True, -- Condition (Node1)
10947 2 => False, -- unused
10948 3 => True, -- Parameter_Specifications (List3)
10949 4 => True, -- Entry_Index_Specification (Node4)
10950 5 => False), -- unused
10951
10952 N_Entry_Index_Specification =>
10953 (1 => True, -- Defining_Identifier (Node1)
10954 2 => False, -- unused
10955 3 => False, -- unused
10956 4 => True, -- Discrete_Subtype_Definition (Node4)
10957 5 => False), -- unused
10958
10959 N_Entry_Call_Statement =>
10960 (1 => False, -- unused
10961 2 => True, -- Name (Node2)
10962 3 => True, -- Parameter_Associations (List3)
10963 4 => False, -- First_Named_Actual (Node4-Sem)
10964 5 => False), -- unused
10965
10966 N_Requeue_Statement =>
10967 (1 => False, -- unused
10968 2 => True, -- Name (Node2)
10969 3 => False, -- unused
10970 4 => False, -- unused
10971 5 => False), -- unused
10972
10973 N_Delay_Until_Statement =>
10974 (1 => False, -- unused
10975 2 => False, -- unused
10976 3 => True, -- Expression (Node3)
10977 4 => False, -- unused
10978 5 => False), -- unused
10979
10980 N_Delay_Relative_Statement =>
10981 (1 => False, -- unused
10982 2 => False, -- unused
10983 3 => True, -- Expression (Node3)
10984 4 => False, -- unused
10985 5 => False), -- unused
10986
10987 N_Selective_Accept =>
10988 (1 => True, -- Select_Alternatives (List1)
10989 2 => False, -- unused
10990 3 => False, -- unused
10991 4 => True, -- Else_Statements (List4)
10992 5 => False), -- unused
10993
10994 N_Accept_Alternative =>
10995 (1 => True, -- Condition (Node1)
10996 2 => True, -- Accept_Statement (Node2)
10997 3 => True, -- Statements (List3)
10998 4 => True, -- Pragmas_Before (List4)
10999 5 => False), -- Accept_Handler_Records (List5-Sem)
11000
11001 N_Delay_Alternative =>
11002 (1 => True, -- Condition (Node1)
11003 2 => True, -- Delay_Statement (Node2)
11004 3 => True, -- Statements (List3)
11005 4 => True, -- Pragmas_Before (List4)
11006 5 => False), -- unused
11007
11008 N_Terminate_Alternative =>
11009 (1 => True, -- Condition (Node1)
11010 2 => False, -- unused
11011 3 => False, -- unused
11012 4 => True, -- Pragmas_Before (List4)
11013 5 => True), -- Pragmas_After (List5)
11014
11015 N_Timed_Entry_Call =>
11016 (1 => True, -- Entry_Call_Alternative (Node1)
11017 2 => False, -- unused
11018 3 => False, -- unused
11019 4 => True, -- Delay_Alternative (Node4)
11020 5 => False), -- unused
11021
11022 N_Entry_Call_Alternative =>
11023 (1 => True, -- Entry_Call_Statement (Node1)
11024 2 => False, -- unused
11025 3 => True, -- Statements (List3)
11026 4 => True, -- Pragmas_Before (List4)
11027 5 => False), -- unused
11028
11029 N_Conditional_Entry_Call =>
11030 (1 => True, -- Entry_Call_Alternative (Node1)
11031 2 => False, -- unused
11032 3 => False, -- unused
11033 4 => True, -- Else_Statements (List4)
11034 5 => False), -- unused
11035
11036 N_Asynchronous_Select =>
11037 (1 => True, -- Triggering_Alternative (Node1)
11038 2 => True, -- Abortable_Part (Node2)
11039 3 => False, -- unused
11040 4 => False, -- unused
11041 5 => False), -- unused
11042
11043 N_Triggering_Alternative =>
11044 (1 => True, -- Triggering_Statement (Node1)
11045 2 => False, -- unused
11046 3 => True, -- Statements (List3)
11047 4 => True, -- Pragmas_Before (List4)
11048 5 => False), -- unused
11049
11050 N_Abortable_Part =>
11051 (1 => False, -- unused
11052 2 => False, -- unused
11053 3 => True, -- Statements (List3)
11054 4 => False, -- unused
11055 5 => False), -- unused
11056
11057 N_Abort_Statement =>
11058 (1 => False, -- unused
11059 2 => True, -- Names (List2)
11060 3 => False, -- unused
11061 4 => False, -- unused
11062 5 => False), -- unused
11063
11064 N_Compilation_Unit =>
11065 (1 => True, -- Context_Items (List1)
11066 2 => True, -- Unit (Node2)
11067 3 => False, -- First_Inlined_Subprogram (Node3-Sem)
11068 4 => False, -- Library_Unit (Node4-Sem)
11069 5 => True), -- Aux_Decls_Node (Node5)
11070
11071 N_Compilation_Unit_Aux =>
11072 (1 => True, -- Actions (List1)
11073 2 => True, -- Declarations (List2)
11074 3 => False, -- Default_Storage_Pool (Node3)
11075 4 => True, -- Config_Pragmas (List4)
11076 5 => True), -- Pragmas_After (List5)
11077
11078 N_With_Clause =>
11079 (1 => False, -- unused
11080 2 => True, -- Name (Node2)
11081 3 => False, -- unused
11082 4 => False, -- Library_Unit (Node4-Sem)
11083 5 => False), -- Corresponding_Spec (Node5-Sem)
11084
11085 N_Subprogram_Body_Stub =>
11086 (1 => True, -- Specification (Node1)
11087 2 => False, -- unused
11088 3 => False, -- unused
11089 4 => False, -- Library_Unit (Node4-Sem)
11090 5 => False), -- Corresponding_Body (Node5-Sem)
11091
11092 N_Package_Body_Stub =>
11093 (1 => True, -- Defining_Identifier (Node1)
11094 2 => False, -- unused
11095 3 => False, -- unused
11096 4 => False, -- Library_Unit (Node4-Sem)
11097 5 => False), -- Corresponding_Body (Node5-Sem)
11098
11099 N_Task_Body_Stub =>
11100 (1 => True, -- Defining_Identifier (Node1)
11101 2 => False, -- unused
11102 3 => False, -- unused
11103 4 => False, -- Library_Unit (Node4-Sem)
11104 5 => False), -- Corresponding_Body (Node5-Sem)
11105
11106 N_Protected_Body_Stub =>
11107 (1 => True, -- Defining_Identifier (Node1)
11108 2 => False, -- unused
11109 3 => False, -- unused
11110 4 => False, -- Library_Unit (Node4-Sem)
11111 5 => False), -- Corresponding_Body (Node5-Sem)
11112
11113 N_Subunit =>
11114 (1 => True, -- Proper_Body (Node1)
11115 2 => True, -- Name (Node2)
11116 3 => False, -- Corresponding_Stub (Node3-Sem)
11117 4 => False, -- unused
11118 5 => False), -- unused
11119
11120 N_Exception_Declaration =>
11121 (1 => True, -- Defining_Identifier (Node1)
11122 2 => False, -- unused
11123 3 => False, -- Expression (Node3-Sem)
11124 4 => False, -- unused
11125 5 => False), -- unused
11126
11127 N_Handled_Sequence_Of_Statements =>
11128 (1 => True, -- At_End_Proc (Node1)
11129 2 => False, -- First_Real_Statement (Node2-Sem)
11130 3 => True, -- Statements (List3)
11131 4 => True, -- End_Label (Node4)
11132 5 => True), -- Exception_Handlers (List5)
11133
11134 N_Exception_Handler =>
11135 (1 => False, -- Local_Raise_Statements (Elist1)
11136 2 => True, -- Choice_Parameter (Node2)
11137 3 => True, -- Statements (List3)
11138 4 => True, -- Exception_Choices (List4)
11139 5 => False), -- Exception_Label (Node5)
11140
11141 N_Raise_Statement =>
11142 (1 => False, -- unused
11143 2 => True, -- Name (Node2)
11144 3 => True, -- Expression (Node3)
11145 4 => False, -- unused
11146 5 => False), -- unused
11147
11148 N_Generic_Subprogram_Declaration =>
11149 (1 => True, -- Specification (Node1)
11150 2 => True, -- Generic_Formal_Declarations (List2)
11151 3 => False, -- unused
11152 4 => False, -- Parent_Spec (Node4-Sem)
11153 5 => False), -- Corresponding_Body (Node5-Sem)
11154
11155 N_Generic_Package_Declaration =>
11156 (1 => True, -- Specification (Node1)
11157 2 => True, -- Generic_Formal_Declarations (List2)
11158 3 => False, -- Activation_Chain_Entity (Node3-Sem)
11159 4 => False, -- Parent_Spec (Node4-Sem)
11160 5 => False), -- Corresponding_Body (Node5-Sem)
11161
11162 N_Package_Instantiation =>
11163 (1 => True, -- Defining_Unit_Name (Node1)
11164 2 => True, -- Name (Node2)
11165 3 => True, -- Generic_Associations (List3)
11166 4 => False, -- Parent_Spec (Node4-Sem)
11167 5 => False), -- Instance_Spec (Node5-Sem)
11168
11169 N_Procedure_Instantiation =>
11170 (1 => True, -- Defining_Unit_Name (Node1)
11171 2 => True, -- Name (Node2)
11172 3 => True, -- Generic_Associations (List3)
11173 4 => False, -- Parent_Spec (Node4-Sem)
11174 5 => False), -- Instance_Spec (Node5-Sem)
11175
11176 N_Function_Instantiation =>
11177 (1 => True, -- Defining_Unit_Name (Node1)
11178 2 => True, -- Name (Node2)
11179 3 => True, -- Generic_Associations (List3)
11180 4 => False, -- Parent_Spec (Node4-Sem)
11181 5 => False), -- Instance_Spec (Node5-Sem)
11182
11183 N_Generic_Association =>
11184 (1 => True, -- Explicit_Generic_Actual_Parameter (Node1)
11185 2 => True, -- Selector_Name (Node2)
11186 3 => False, -- unused
11187 4 => False, -- unused
11188 5 => False), -- unused
11189
11190 N_Formal_Object_Declaration =>
11191 (1 => True, -- Defining_Identifier (Node1)
11192 2 => False, -- unused
11193 3 => True, -- Access_Definition (Node3)
11194 4 => True, -- Subtype_Mark (Node4)
11195 5 => True), -- Default_Expression (Node5)
11196
11197 N_Formal_Type_Declaration =>
11198 (1 => True, -- Defining_Identifier (Node1)
11199 2 => False, -- unused
11200 3 => True, -- Formal_Type_Definition (Node3)
11201 4 => True, -- Discriminant_Specifications (List4)
11202 5 => False), -- unused
11203
11204 N_Formal_Private_Type_Definition =>
11205 (1 => False, -- unused
11206 2 => False, -- unused
11207 3 => False, -- unused
11208 4 => False, -- unused
11209 5 => False), -- unused
11210
11211 N_Formal_Derived_Type_Definition =>
11212 (1 => False, -- unused
11213 2 => True, -- Interface_List (List2)
11214 3 => False, -- unused
11215 4 => True, -- Subtype_Mark (Node4)
11216 5 => False), -- unused
11217
11218 N_Formal_Discrete_Type_Definition =>
11219 (1 => False, -- unused
11220 2 => False, -- unused
11221 3 => False, -- unused
11222 4 => False, -- unused
11223 5 => False), -- unused
11224
11225 N_Formal_Signed_Integer_Type_Definition =>
11226 (1 => False, -- unused
11227 2 => False, -- unused
11228 3 => False, -- unused
11229 4 => False, -- unused
11230 5 => False), -- unused
11231
11232 N_Formal_Modular_Type_Definition =>
11233 (1 => False, -- unused
11234 2 => False, -- unused
11235 3 => False, -- unused
11236 4 => False, -- unused
11237 5 => False), -- unused
11238
11239 N_Formal_Floating_Point_Definition =>
11240 (1 => False, -- unused
11241 2 => False, -- unused
11242 3 => False, -- unused
11243 4 => False, -- unused
11244 5 => False), -- unused
11245
11246 N_Formal_Ordinary_Fixed_Point_Definition =>
11247 (1 => False, -- unused
11248 2 => False, -- unused
11249 3 => False, -- unused
11250 4 => False, -- unused
11251 5 => False), -- unused
11252
11253 N_Formal_Decimal_Fixed_Point_Definition =>
11254 (1 => False, -- unused
11255 2 => False, -- unused
11256 3 => False, -- unused
11257 4 => False, -- unused
11258 5 => False), -- unused
11259
11260 N_Formal_Concrete_Subprogram_Declaration =>
11261 (1 => True, -- Specification (Node1)
11262 2 => True, -- Default_Name (Node2)
11263 3 => False, -- unused
11264 4 => False, -- unused
11265 5 => False), -- unused
11266
11267 N_Formal_Abstract_Subprogram_Declaration =>
11268 (1 => True, -- Specification (Node1)
11269 2 => True, -- Default_Name (Node2)
11270 3 => False, -- unused
11271 4 => False, -- unused
11272 5 => False), -- unused
11273
11274 N_Formal_Package_Declaration =>
11275 (1 => True, -- Defining_Identifier (Node1)
11276 2 => True, -- Name (Node2)
11277 3 => True, -- Generic_Associations (List3)
11278 4 => False, -- unused
11279 5 => False), -- Instance_Spec (Node5-Sem)
11280
11281 N_Attribute_Definition_Clause =>
11282 (1 => True, -- Chars (Name1)
11283 2 => True, -- Name (Node2)
11284 3 => True, -- Expression (Node3)
11285 4 => False, -- unused
11286 5 => False), -- Next_Rep_Item (Node5-Sem)
11287
11288 N_Aspect_Specification =>
11289 (1 => True, -- Identifier (Node1)
11290 2 => False, -- Aspect_Rep_Item (Node2-Sem)
11291 3 => True, -- Expression (Node3)
11292 4 => False, -- Entity (Node4-Sem)
11293 5 => False), -- Next_Rep_Item (Node5-Sem)
11294
11295 N_Enumeration_Representation_Clause =>
11296 (1 => True, -- Identifier (Node1)
11297 2 => False, -- unused
11298 3 => True, -- Array_Aggregate (Node3)
11299 4 => False, -- unused
11300 5 => False), -- Next_Rep_Item (Node5-Sem)
11301
11302 N_Record_Representation_Clause =>
11303 (1 => True, -- Identifier (Node1)
11304 2 => True, -- Mod_Clause (Node2)
11305 3 => True, -- Component_Clauses (List3)
11306 4 => False, -- unused
11307 5 => False), -- Next_Rep_Item (Node5-Sem)
11308
11309 N_Component_Clause =>
11310 (1 => True, -- Component_Name (Node1)
11311 2 => True, -- Position (Node2)
11312 3 => True, -- First_Bit (Node3)
11313 4 => True, -- Last_Bit (Node4)
11314 5 => False), -- unused
11315
11316 N_Code_Statement =>
11317 (1 => False, -- unused
11318 2 => False, -- unused
11319 3 => True, -- Expression (Node3)
11320 4 => False, -- unused
11321 5 => False), -- unused
11322
11323 N_Op_Rotate_Left =>
11324 (1 => True, -- Chars (Name1)
11325 2 => True, -- Left_Opnd (Node2)
11326 3 => True, -- Right_Opnd (Node3)
11327 4 => False, -- Entity (Node4-Sem)
11328 5 => False), -- Etype (Node5-Sem)
11329
11330 N_Op_Rotate_Right =>
11331 (1 => True, -- Chars (Name1)
11332 2 => True, -- Left_Opnd (Node2)
11333 3 => True, -- Right_Opnd (Node3)
11334 4 => False, -- Entity (Node4-Sem)
11335 5 => False), -- Etype (Node5-Sem)
11336
11337 N_Op_Shift_Left =>
11338 (1 => True, -- Chars (Name1)
11339 2 => True, -- Left_Opnd (Node2)
11340 3 => True, -- Right_Opnd (Node3)
11341 4 => False, -- Entity (Node4-Sem)
11342 5 => False), -- Etype (Node5-Sem)
11343
11344 N_Op_Shift_Right_Arithmetic =>
11345 (1 => True, -- Chars (Name1)
11346 2 => True, -- Left_Opnd (Node2)
11347 3 => True, -- Right_Opnd (Node3)
11348 4 => False, -- Entity (Node4-Sem)
11349 5 => False), -- Etype (Node5-Sem)
11350
11351 N_Op_Shift_Right =>
11352 (1 => True, -- Chars (Name1)
11353 2 => True, -- Left_Opnd (Node2)
11354 3 => True, -- Right_Opnd (Node3)
11355 4 => False, -- Entity (Node4-Sem)
11356 5 => False), -- Etype (Node5-Sem)
11357
11358 N_Delta_Constraint =>
11359 (1 => False, -- unused
11360 2 => False, -- unused
11361 3 => True, -- Delta_Expression (Node3)
11362 4 => True, -- Range_Constraint (Node4)
11363 5 => False), -- unused
11364
11365 N_At_Clause =>
11366 (1 => True, -- Identifier (Node1)
11367 2 => False, -- unused
11368 3 => True, -- Expression (Node3)
11369 4 => False, -- unused
11370 5 => False), -- unused
11371
11372 N_Mod_Clause =>
11373 (1 => False, -- unused
11374 2 => False, -- unused
11375 3 => True, -- Expression (Node3)
11376 4 => True, -- Pragmas_Before (List4)
11377 5 => False), -- unused
11378
11379 N_Conditional_Expression =>
11380 (1 => True, -- Expressions (List1)
11381 2 => False, -- Then_Actions (List2-Sem)
11382 3 => False, -- Else_Actions (List3-Sem)
11383 4 => False, -- unused
11384 5 => False), -- Etype (Node5-Sem)
11385
11386 N_Expanded_Name =>
11387 (1 => True, -- Chars (Name1)
11388 2 => True, -- Selector_Name (Node2)
11389 3 => True, -- Prefix (Node3)
11390 4 => False, -- Entity (Node4-Sem)
11391 5 => False), -- Etype (Node5-Sem)
11392
11393 N_Expression_With_Actions =>
11394 (1 => True, -- Actions (List1)
11395 2 => False, -- unused
11396 3 => True, -- Expression (Node3)
11397 4 => False, -- unused
11398 5 => False), -- unused
11399
11400 N_Free_Statement =>
11401 (1 => False, -- Storage_Pool (Node1-Sem)
11402 2 => False, -- Procedure_To_Call (Node2-Sem)
11403 3 => True, -- Expression (Node3)
11404 4 => False, -- Actual_Designated_Subtype (Node4-Sem)
11405 5 => False), -- unused
11406
11407 N_Freeze_Entity =>
11408 (1 => True, -- Actions (List1)
11409 2 => False, -- Access_Types_To_Process (Elist2-Sem)
11410 3 => False, -- TSS_Elist (Elist3-Sem)
11411 4 => False, -- Entity (Node4-Sem)
11412 5 => False), -- First_Subtype_Link (Node5-Sem)
11413
11414 N_Implicit_Label_Declaration =>
11415 (1 => True, -- Defining_Identifier (Node1)
11416 2 => False, -- Label_Construct (Node2-Sem)
11417 3 => False, -- unused
11418 4 => False, -- unused
11419 5 => False), -- unused
11420
11421 N_Itype_Reference =>
11422 (1 => False, -- Itype (Node1-Sem)
11423 2 => False, -- unused
11424 3 => False, -- unused
11425 4 => False, -- unused
11426 5 => False), -- unused
11427
11428 N_Raise_Constraint_Error =>
11429 (1 => True, -- Condition (Node1)
11430 2 => False, -- unused
11431 3 => True, -- Reason (Uint3)
11432 4 => False, -- unused
11433 5 => False), -- Etype (Node5-Sem)
11434
11435 N_Raise_Program_Error =>
11436 (1 => True, -- Condition (Node1)
11437 2 => False, -- unused
11438 3 => True, -- Reason (Uint3)
11439 4 => False, -- unused
11440 5 => False), -- Etype (Node5-Sem)
11441
11442 N_Raise_Storage_Error =>
11443 (1 => True, -- Condition (Node1)
11444 2 => False, -- unused
11445 3 => True, -- Reason (Uint3)
11446 4 => False, -- unused
11447 5 => False), -- Etype (Node5-Sem)
11448
11449 N_Push_Constraint_Error_Label =>
11450 (1 => False, -- unused
11451 2 => False, -- unused
11452 3 => False, -- unused
11453 4 => False, -- unused
11454 5 => False), -- unused
11455
11456 N_Push_Program_Error_Label =>
11457 (1 => False, -- Exception_Label
11458 2 => False, -- unused
11459 3 => False, -- unused
11460 4 => False, -- unused
11461 5 => False), -- Exception_Label
11462
11463 N_Push_Storage_Error_Label =>
11464 (1 => False, -- Exception_Label
11465 2 => False, -- unused
11466 3 => False, -- unused
11467 4 => False, -- unused
11468 5 => False), -- Exception_Label
11469
11470 N_Pop_Constraint_Error_Label =>
11471 (1 => False, -- unused
11472 2 => False, -- unused
11473 3 => False, -- unused
11474 4 => False, -- unused
11475 5 => False), -- unused
11476
11477 N_Pop_Program_Error_Label =>
11478 (1 => False, -- unused
11479 2 => False, -- unused
11480 3 => False, -- unused
11481 4 => False, -- unused
11482 5 => False), -- unused
11483
11484 N_Pop_Storage_Error_Label =>
11485 (1 => False, -- unused
11486 2 => False, -- unused
11487 3 => False, -- unused
11488 4 => False, -- unused
11489 5 => False), -- unused
11490
11491 N_Reference =>
11492 (1 => False, -- unused
11493 2 => False, -- unused
11494 3 => True, -- Prefix (Node3)
11495 4 => False, -- unused
11496 5 => False), -- Etype (Node5-Sem)
11497
11498 N_Subprogram_Info =>
11499 (1 => True, -- Identifier (Node1)
11500 2 => False, -- unused
11501 3 => False, -- unused
11502 4 => False, -- unused
11503 5 => False), -- Etype (Node5-Sem)
11504
11505 N_Unchecked_Expression =>
11506 (1 => False, -- unused
11507 2 => False, -- unused
11508 3 => True, -- Expression (Node3)
11509 4 => False, -- unused
11510 5 => False), -- Etype (Node5-Sem)
11511
11512 N_Unchecked_Type_Conversion =>
11513 (1 => False, -- unused
11514 2 => False, -- unused
11515 3 => True, -- Expression (Node3)
11516 4 => True, -- Subtype_Mark (Node4)
11517 5 => False), -- Etype (Node5-Sem)
11518
11519 N_Validate_Unchecked_Conversion =>
11520 (1 => False, -- Source_Type (Node1-Sem)
11521 2 => False, -- Target_Type (Node2-Sem)
11522 3 => False, -- unused
11523 4 => False, -- unused
11524 5 => False), -- unused
11525
11526 -- Entries for SCIL nodes
11527
11528 N_SCIL_Dispatch_Table_Tag_Init =>
11529 (1 => False, -- unused
11530 2 => False, -- unused
11531 3 => False, -- unused
11532 4 => False, -- SCIL_Entity (Node4-Sem)
11533 5 => False), -- unused
11534
11535 N_SCIL_Dispatching_Call =>
11536 (1 => False, -- unused
11537 2 => False, -- SCIL_Target_Prim (Node2-Sem)
11538 3 => False, -- unused
11539 4 => False, -- SCIL_Entity (Node4-Sem)
11540 5 => False), -- SCIL_Controlling_Tag (Node5-Sem)
11541
11542 N_SCIL_Membership_Test =>
11543 (1 => False, -- unused
11544 2 => False, -- unused
11545 3 => False, -- unused
11546 4 => False, -- SCIL_Entity (Node4-Sem)
11547 5 => False), -- SCIL_Tag_Value (Node5-Sem)
11548
11549 -- Entries for Empty, Error and Unused. Even thought these have a Chars
11550 -- field for debugging purposes, they are not really syntactic fields, so
11551 -- we mark all fields as unused.
11552
11553 N_Empty =>
11554 (1 => False, -- unused
11555 2 => False, -- unused
11556 3 => False, -- unused
11557 4 => False, -- unused
11558 5 => False), -- unused
11559
11560 N_Error =>
11561 (1 => False, -- unused
11562 2 => False, -- unused
11563 3 => False, -- unused
11564 4 => False, -- unused
11565 5 => False), -- unused
11566
11567 N_Unused_At_Start =>
11568 (1 => False, -- unused
11569 2 => False, -- unused
11570 3 => False, -- unused
11571 4 => False, -- unused
11572 5 => False), -- unused
11573
11574 N_Unused_At_End =>
11575 (1 => False, -- unused
11576 2 => False, -- unused
11577 3 => False, -- unused
11578 4 => False, -- unused
11579 5 => False)); -- unused
11580
11581 --------------------
11582 -- Inline Pragmas --
11583 --------------------
11584
11585 pragma Inline (ABE_Is_Certain);
11586 pragma Inline (Abort_Present);
11587 pragma Inline (Abortable_Part);
11588 pragma Inline (Abstract_Present);
11589 pragma Inline (Accept_Handler_Records);
11590 pragma Inline (Accept_Statement);
11591 pragma Inline (Access_Definition);
11592 pragma Inline (Access_To_Subprogram_Definition);
11593 pragma Inline (Access_Types_To_Process);
11594 pragma Inline (Actions);
11595 pragma Inline (Activation_Chain_Entity);
11596 pragma Inline (Acts_As_Spec);
11597 pragma Inline (Actual_Designated_Subtype);
11598 pragma Inline (Address_Warning_Posted);
11599 pragma Inline (Aggregate_Bounds);
11600 pragma Inline (Aliased_Present);
11601 pragma Inline (All_Others);
11602 pragma Inline (All_Present);
11603 pragma Inline (Alternatives);
11604 pragma Inline (Ancestor_Part);
11605 pragma Inline (Array_Aggregate);
11606 pragma Inline (Aspect_Cancel);
11607 pragma Inline (Aspect_Rep_Item);
11608 pragma Inline (Assignment_OK);
11609 pragma Inline (Associated_Node);
11610 pragma Inline (At_End_Proc);
11611 pragma Inline (Attribute_Name);
11612 pragma Inline (Aux_Decls_Node);
11613 pragma Inline (Backwards_OK);
11614 pragma Inline (Bad_Is_Detected);
11615 pragma Inline (Body_To_Inline);
11616 pragma Inline (Body_Required);
11617 pragma Inline (By_Ref);
11618 pragma Inline (Box_Present);
11619 pragma Inline (Char_Literal_Value);
11620 pragma Inline (Chars);
11621 pragma Inline (Check_Address_Alignment);
11622 pragma Inline (Choice_Parameter);
11623 pragma Inline (Choices);
11624 pragma Inline (Class_Present);
11625 pragma Inline (Coextensions);
11626 pragma Inline (Comes_From_Extended_Return_Statement);
11627 pragma Inline (Compile_Time_Known_Aggregate);
11628 pragma Inline (Component_Associations);
11629 pragma Inline (Component_Clauses);
11630 pragma Inline (Component_Definition);
11631 pragma Inline (Component_Items);
11632 pragma Inline (Component_List);
11633 pragma Inline (Component_Name);
11634 pragma Inline (Componentwise_Assignment);
11635 pragma Inline (Condition);
11636 pragma Inline (Condition_Actions);
11637 pragma Inline (Config_Pragmas);
11638 pragma Inline (Constant_Present);
11639 pragma Inline (Constraint);
11640 pragma Inline (Constraints);
11641 pragma Inline (Context_Installed);
11642 pragma Inline (Context_Items);
11643 pragma Inline (Context_Pending);
11644 pragma Inline (Controlling_Argument);
11645 pragma Inline (Conversion_OK);
11646 pragma Inline (Corresponding_Body);
11647 pragma Inline (Corresponding_Formal_Spec);
11648 pragma Inline (Corresponding_Generic_Association);
11649 pragma Inline (Corresponding_Integer_Value);
11650 pragma Inline (Corresponding_Spec);
11651 pragma Inline (Corresponding_Stub);
11652 pragma Inline (Dcheck_Function);
11653 pragma Inline (Debug_Statement);
11654 pragma Inline (Declarations);
11655 pragma Inline (Default_Expression);
11656 pragma Inline (Default_Storage_Pool);
11657 pragma Inline (Default_Name);
11658 pragma Inline (Defining_Identifier);
11659 pragma Inline (Defining_Unit_Name);
11660 pragma Inline (Delay_Alternative);
11661 pragma Inline (Delay_Statement);
11662 pragma Inline (Delta_Expression);
11663 pragma Inline (Digits_Expression);
11664 pragma Inline (Discr_Check_Funcs_Built);
11665 pragma Inline (Discrete_Choices);
11666 pragma Inline (Discrete_Range);
11667 pragma Inline (Discrete_Subtype_Definition);
11668 pragma Inline (Discrete_Subtype_Definitions);
11669 pragma Inline (Discriminant_Specifications);
11670 pragma Inline (Discriminant_Type);
11671 pragma Inline (Do_Accessibility_Check);
11672 pragma Inline (Do_Discriminant_Check);
11673 pragma Inline (Do_Length_Check);
11674 pragma Inline (Do_Division_Check);
11675 pragma Inline (Do_Overflow_Check);
11676 pragma Inline (Do_Range_Check);
11677 pragma Inline (Do_Storage_Check);
11678 pragma Inline (Do_Tag_Check);
11679 pragma Inline (Elaborate_Present);
11680 pragma Inline (Elaborate_All_Desirable);
11681 pragma Inline (Elaborate_All_Present);
11682 pragma Inline (Elaborate_Desirable);
11683 pragma Inline (Elaboration_Boolean);
11684 pragma Inline (Else_Actions);
11685 pragma Inline (Else_Statements);
11686 pragma Inline (Elsif_Parts);
11687 pragma Inline (Enclosing_Variant);
11688 pragma Inline (End_Label);
11689 pragma Inline (End_Span);
11690 pragma Inline (Entity);
11691 pragma Inline (Entity_Or_Associated_Node);
11692 pragma Inline (Entry_Body_Formal_Part);
11693 pragma Inline (Entry_Call_Alternative);
11694 pragma Inline (Entry_Call_Statement);
11695 pragma Inline (Entry_Direct_Name);
11696 pragma Inline (Entry_Index);
11697 pragma Inline (Entry_Index_Specification);
11698 pragma Inline (Etype);
11699 pragma Inline (Exception_Choices);
11700 pragma Inline (Exception_Handlers);
11701 pragma Inline (Exception_Junk);
11702 pragma Inline (Exception_Label);
11703 pragma Inline (Expansion_Delayed);
11704 pragma Inline (Explicit_Actual_Parameter);
11705 pragma Inline (Explicit_Generic_Actual_Parameter);
11706 pragma Inline (Expression);
11707 pragma Inline (Expressions);
11708 pragma Inline (First_Bit);
11709 pragma Inline (First_Inlined_Subprogram);
11710 pragma Inline (First_Name);
11711 pragma Inline (First_Named_Actual);
11712 pragma Inline (First_Real_Statement);
11713 pragma Inline (First_Subtype_Link);
11714 pragma Inline (Float_Truncate);
11715 pragma Inline (Formal_Type_Definition);
11716 pragma Inline (Forwards_OK);
11717 pragma Inline (From_Aspect_Specification);
11718 pragma Inline (From_At_End);
11719 pragma Inline (From_At_Mod);
11720 pragma Inline (From_Default);
11721 pragma Inline (Generic_Associations);
11722 pragma Inline (Generic_Formal_Declarations);
11723 pragma Inline (Generic_Parent);
11724 pragma Inline (Generic_Parent_Type);
11725 pragma Inline (Handled_Statement_Sequence);
11726 pragma Inline (Handler_List_Entry);
11727 pragma Inline (Has_Created_Identifier);
11728 pragma Inline (Has_Dynamic_Length_Check);
11729 pragma Inline (Has_Dynamic_Range_Check);
11730 pragma Inline (Has_Init_Expression);
11731 pragma Inline (Has_Local_Raise);
11732 pragma Inline (Has_Self_Reference);
11733 pragma Inline (Has_No_Elaboration_Code);
11734 pragma Inline (Has_Pragma_CPU);
11735 pragma Inline (Has_Pragma_Priority);
11736 pragma Inline (Has_Pragma_Suppress_All);
11737 pragma Inline (Has_Private_View);
11738 pragma Inline (Has_Relative_Deadline_Pragma);
11739 pragma Inline (Has_Storage_Size_Pragma);
11740 pragma Inline (Has_Task_Info_Pragma);
11741 pragma Inline (Has_Task_Name_Pragma);
11742 pragma Inline (Has_Wide_Character);
11743 pragma Inline (Has_Wide_Wide_Character);
11744 pragma Inline (Hidden_By_Use_Clause);
11745 pragma Inline (High_Bound);
11746 pragma Inline (Identifier);
11747 pragma Inline (Implicit_With);
11748 pragma Inline (Interface_List);
11749 pragma Inline (Interface_Present);
11750 pragma Inline (Includes_Infinities);
11751 pragma Inline (Import_Interface_Present);
11752 pragma Inline (In_Present);
11753 pragma Inline (Inherited_Discriminant);
11754 pragma Inline (Instance_Spec);
11755 pragma Inline (Intval);
11756 pragma Inline (Is_Accessibility_Actual);
11757 pragma Inline (Is_Asynchronous_Call_Block);
11758 pragma Inline (Is_Component_Left_Opnd);
11759 pragma Inline (Is_Component_Right_Opnd);
11760 pragma Inline (Is_Controlling_Actual);
11761 pragma Inline (Is_Delayed_Aspect);
11762 pragma Inline (Is_Dynamic_Coextension);
11763 pragma Inline (Is_Elsif);
11764 pragma Inline (Is_Entry_Barrier_Function);
11765 pragma Inline (Is_Expanded_Build_In_Place_Call);
11766 pragma Inline (Is_Folded_In_Parser);
11767 pragma Inline (Is_In_Discriminant_Check);
11768 pragma Inline (Is_Machine_Number);
11769 pragma Inline (Is_Null_Loop);
11770 pragma Inline (Is_Overloaded);
11771 pragma Inline (Is_Power_Of_2_For_Shift);
11772 pragma Inline (Is_Protected_Subprogram_Body);
11773 pragma Inline (Is_Static_Coextension);
11774 pragma Inline (Is_Static_Expression);
11775 pragma Inline (Is_Subprogram_Descriptor);
11776 pragma Inline (Is_Task_Allocation_Block);
11777 pragma Inline (Is_Task_Master);
11778 pragma Inline (Iteration_Scheme);
11779 pragma Inline (Itype);
11780 pragma Inline (Kill_Range_Check);
11781 pragma Inline (Last_Bit);
11782 pragma Inline (Last_Name);
11783 pragma Inline (Library_Unit);
11784 pragma Inline (Label_Construct);
11785 pragma Inline (Left_Opnd);
11786 pragma Inline (Limited_View_Installed);
11787 pragma Inline (Limited_Present);
11788 pragma Inline (Literals);
11789 pragma Inline (Local_Raise_Not_OK);
11790 pragma Inline (Local_Raise_Statements);
11791 pragma Inline (Loop_Actions);
11792 pragma Inline (Loop_Parameter_Specification);
11793 pragma Inline (Low_Bound);
11794 pragma Inline (Mod_Clause);
11795 pragma Inline (More_Ids);
11796 pragma Inline (Must_Be_Byte_Aligned);
11797 pragma Inline (Must_Not_Freeze);
11798 pragma Inline (Must_Not_Override);
11799 pragma Inline (Must_Override);
11800 pragma Inline (Name);
11801 pragma Inline (Names);
11802 pragma Inline (Next_Entity);
11803 pragma Inline (Next_Exit_Statement);
11804 pragma Inline (Next_Implicit_With);
11805 pragma Inline (Next_Named_Actual);
11806 pragma Inline (Next_Pragma);
11807 pragma Inline (Next_Rep_Item);
11808 pragma Inline (Next_Use_Clause);
11809 pragma Inline (No_Ctrl_Actions);
11810 pragma Inline (No_Elaboration_Check);
11811 pragma Inline (No_Entities_Ref_In_Spec);
11812 pragma Inline (No_Initialization);
11813 pragma Inline (No_Truncation);
11814 pragma Inline (Null_Present);
11815 pragma Inline (Null_Exclusion_Present);
11816 pragma Inline (Null_Exclusion_In_Return_Present);
11817 pragma Inline (Null_Record_Present);
11818 pragma Inline (Object_Definition);
11819 pragma Inline (Original_Discriminant);
11820 pragma Inline (Original_Entity);
11821 pragma Inline (Others_Discrete_Choices);
11822 pragma Inline (Out_Present);
11823 pragma Inline (Parameter_Associations);
11824 pragma Inline (Parameter_Specifications);
11825 pragma Inline (Parameter_List_Truncated);
11826 pragma Inline (Parameter_Type);
11827 pragma Inline (Parent_Spec);
11828 pragma Inline (Position);
11829 pragma Inline (Pragma_Argument_Associations);
11830 pragma Inline (Pragma_Enabled);
11831 pragma Inline (Pragma_Identifier);
11832 pragma Inline (Pragmas_After);
11833 pragma Inline (Pragmas_Before);
11834 pragma Inline (Prefix);
11835 pragma Inline (Present_Expr);
11836 pragma Inline (Prev_Ids);
11837 pragma Inline (Print_In_Hex);
11838 pragma Inline (Private_Declarations);
11839 pragma Inline (Private_Present);
11840 pragma Inline (Procedure_To_Call);
11841 pragma Inline (Proper_Body);
11842 pragma Inline (Protected_Definition);
11843 pragma Inline (Protected_Present);
11844 pragma Inline (Raises_Constraint_Error);
11845 pragma Inline (Range_Constraint);
11846 pragma Inline (Range_Expression);
11847 pragma Inline (Real_Range_Specification);
11848 pragma Inline (Realval);
11849 pragma Inline (Reason);
11850 pragma Inline (Record_Extension_Part);
11851 pragma Inline (Redundant_Use);
11852 pragma Inline (Renaming_Exception);
11853 pragma Inline (Result_Definition);
11854 pragma Inline (Return_Object_Declarations);
11855 pragma Inline (Return_Statement_Entity);
11856 pragma Inline (Reverse_Present);
11857 pragma Inline (Right_Opnd);
11858 pragma Inline (Rounded_Result);
11859 pragma Inline (SCIL_Controlling_Tag);
11860 pragma Inline (SCIL_Entity);
11861 pragma Inline (SCIL_Tag_Value);
11862 pragma Inline (SCIL_Target_Prim);
11863 pragma Inline (Scope);
11864 pragma Inline (Select_Alternatives);
11865 pragma Inline (Selector_Name);
11866 pragma Inline (Selector_Names);
11867 pragma Inline (Shift_Count_OK);
11868 pragma Inline (Source_Type);
11869 pragma Inline (Specification);
11870 pragma Inline (Split_PPC);
11871 pragma Inline (Statements);
11872 pragma Inline (Static_Processing_OK);
11873 pragma Inline (Storage_Pool);
11874 pragma Inline (Strval);
11875 pragma Inline (Subtype_Indication);
11876 pragma Inline (Subtype_Mark);
11877 pragma Inline (Subtype_Marks);
11878 pragma Inline (Suppress_Loop_Warnings);
11879 pragma Inline (Synchronized_Present);
11880 pragma Inline (Tagged_Present);
11881 pragma Inline (Target_Type);
11882 pragma Inline (Task_Definition);
11883 pragma Inline (Task_Present);
11884 pragma Inline (Then_Actions);
11885 pragma Inline (Then_Statements);
11886 pragma Inline (Triggering_Alternative);
11887 pragma Inline (Triggering_Statement);
11888 pragma Inline (Treat_Fixed_As_Integer);
11889 pragma Inline (TSS_Elist);
11890 pragma Inline (Type_Definition);
11891 pragma Inline (Unit);
11892 pragma Inline (Unknown_Discriminants_Present);
11893 pragma Inline (Unreferenced_In_Spec);
11894 pragma Inline (Variant_Part);
11895 pragma Inline (Variants);
11896 pragma Inline (Visible_Declarations);
11897 pragma Inline (Was_Originally_Stub);
11898 pragma Inline (Withed_Body);
11899 pragma Inline (Zero_Cost_Handling);
11900
11901 pragma Inline (Set_ABE_Is_Certain);
11902 pragma Inline (Set_Abort_Present);
11903 pragma Inline (Set_Abortable_Part);
11904 pragma Inline (Set_Abstract_Present);
11905 pragma Inline (Set_Accept_Handler_Records);
11906 pragma Inline (Set_Accept_Statement);
11907 pragma Inline (Set_Access_Definition);
11908 pragma Inline (Set_Access_To_Subprogram_Definition);
11909 pragma Inline (Set_Access_Types_To_Process);
11910 pragma Inline (Set_Actions);
11911 pragma Inline (Set_Activation_Chain_Entity);
11912 pragma Inline (Set_Acts_As_Spec);
11913 pragma Inline (Set_Actual_Designated_Subtype);
11914 pragma Inline (Set_Address_Warning_Posted);
11915 pragma Inline (Set_Aggregate_Bounds);
11916 pragma Inline (Set_Aliased_Present);
11917 pragma Inline (Set_All_Others);
11918 pragma Inline (Set_All_Present);
11919 pragma Inline (Set_Alternatives);
11920 pragma Inline (Set_Ancestor_Part);
11921 pragma Inline (Set_Array_Aggregate);
11922 pragma Inline (Set_Aspect_Cancel);
11923 pragma Inline (Set_Aspect_Rep_Item);
11924 pragma Inline (Set_Assignment_OK);
11925 pragma Inline (Set_Associated_Node);
11926 pragma Inline (Set_At_End_Proc);
11927 pragma Inline (Set_Attribute_Name);
11928 pragma Inline (Set_Aux_Decls_Node);
11929 pragma Inline (Set_Backwards_OK);
11930 pragma Inline (Set_Bad_Is_Detected);
11931 pragma Inline (Set_Body_To_Inline);
11932 pragma Inline (Set_Body_Required);
11933 pragma Inline (Set_By_Ref);
11934 pragma Inline (Set_Box_Present);
11935 pragma Inline (Set_Char_Literal_Value);
11936 pragma Inline (Set_Chars);
11937 pragma Inline (Set_Check_Address_Alignment);
11938 pragma Inline (Set_Choice_Parameter);
11939 pragma Inline (Set_Choices);
11940 pragma Inline (Set_Class_Present);
11941 pragma Inline (Set_Coextensions);
11942 pragma Inline (Set_Comes_From_Extended_Return_Statement);
11943 pragma Inline (Set_Compile_Time_Known_Aggregate);
11944 pragma Inline (Set_Component_Associations);
11945 pragma Inline (Set_Component_Clauses);
11946 pragma Inline (Set_Component_Definition);
11947 pragma Inline (Set_Component_Items);
11948 pragma Inline (Set_Component_List);
11949 pragma Inline (Set_Component_Name);
11950 pragma Inline (Set_Componentwise_Assignment);
11951 pragma Inline (Set_Condition);
11952 pragma Inline (Set_Condition_Actions);
11953 pragma Inline (Set_Config_Pragmas);
11954 pragma Inline (Set_Constant_Present);
11955 pragma Inline (Set_Constraint);
11956 pragma Inline (Set_Constraints);
11957 pragma Inline (Set_Context_Installed);
11958 pragma Inline (Set_Context_Items);
11959 pragma Inline (Set_Context_Pending);
11960 pragma Inline (Set_Controlling_Argument);
11961 pragma Inline (Set_Conversion_OK);
11962 pragma Inline (Set_Corresponding_Body);
11963 pragma Inline (Set_Corresponding_Formal_Spec);
11964 pragma Inline (Set_Corresponding_Generic_Association);
11965 pragma Inline (Set_Corresponding_Integer_Value);
11966 pragma Inline (Set_Corresponding_Spec);
11967 pragma Inline (Set_Corresponding_Stub);
11968 pragma Inline (Set_Dcheck_Function);
11969 pragma Inline (Set_Debug_Statement);
11970 pragma Inline (Set_Declarations);
11971 pragma Inline (Set_Default_Expression);
11972 pragma Inline (Set_Default_Storage_Pool);
11973 pragma Inline (Set_Default_Name);
11974 pragma Inline (Set_Defining_Identifier);
11975 pragma Inline (Set_Defining_Unit_Name);
11976 pragma Inline (Set_Delay_Alternative);
11977 pragma Inline (Set_Delay_Statement);
11978 pragma Inline (Set_Delta_Expression);
11979 pragma Inline (Set_Digits_Expression);
11980 pragma Inline (Set_Discr_Check_Funcs_Built);
11981 pragma Inline (Set_Discrete_Choices);
11982 pragma Inline (Set_Discrete_Range);
11983 pragma Inline (Set_Discrete_Subtype_Definition);
11984 pragma Inline (Set_Discrete_Subtype_Definitions);
11985 pragma Inline (Set_Discriminant_Specifications);
11986 pragma Inline (Set_Discriminant_Type);
11987 pragma Inline (Set_Do_Accessibility_Check);
11988 pragma Inline (Set_Do_Discriminant_Check);
11989 pragma Inline (Set_Do_Length_Check);
11990 pragma Inline (Set_Do_Division_Check);
11991 pragma Inline (Set_Do_Overflow_Check);
11992 pragma Inline (Set_Do_Range_Check);
11993 pragma Inline (Set_Do_Storage_Check);
11994 pragma Inline (Set_Do_Tag_Check);
11995 pragma Inline (Set_Elaborate_Present);
11996 pragma Inline (Set_Elaborate_All_Desirable);
11997 pragma Inline (Set_Elaborate_All_Present);
11998 pragma Inline (Set_Elaborate_Desirable);
11999 pragma Inline (Set_Elaboration_Boolean);
12000 pragma Inline (Set_Else_Actions);
12001 pragma Inline (Set_Else_Statements);
12002 pragma Inline (Set_Elsif_Parts);
12003 pragma Inline (Set_Enclosing_Variant);
12004 pragma Inline (Set_End_Label);
12005 pragma Inline (Set_End_Span);
12006 pragma Inline (Set_Entity);
12007 pragma Inline (Set_Entry_Body_Formal_Part);
12008 pragma Inline (Set_Entry_Call_Alternative);
12009 pragma Inline (Set_Entry_Call_Statement);
12010 pragma Inline (Set_Entry_Direct_Name);
12011 pragma Inline (Set_Entry_Index);
12012 pragma Inline (Set_Entry_Index_Specification);
12013 pragma Inline (Set_Etype);
12014 pragma Inline (Set_Exception_Choices);
12015 pragma Inline (Set_Exception_Handlers);
12016 pragma Inline (Set_Exception_Junk);
12017 pragma Inline (Set_Exception_Label);
12018 pragma Inline (Set_Expansion_Delayed);
12019 pragma Inline (Set_Explicit_Actual_Parameter);
12020 pragma Inline (Set_Explicit_Generic_Actual_Parameter);
12021 pragma Inline (Set_Expression);
12022 pragma Inline (Set_Expressions);
12023 pragma Inline (Set_First_Bit);
12024 pragma Inline (Set_First_Inlined_Subprogram);
12025 pragma Inline (Set_First_Name);
12026 pragma Inline (Set_First_Named_Actual);
12027 pragma Inline (Set_First_Real_Statement);
12028 pragma Inline (Set_First_Subtype_Link);
12029 pragma Inline (Set_Float_Truncate);
12030 pragma Inline (Set_Formal_Type_Definition);
12031 pragma Inline (Set_Forwards_OK);
12032 pragma Inline (Set_From_Aspect_Specification);
12033 pragma Inline (Set_From_At_End);
12034 pragma Inline (Set_From_At_Mod);
12035 pragma Inline (Set_From_Default);
12036 pragma Inline (Set_Generic_Associations);
12037 pragma Inline (Set_Generic_Formal_Declarations);
12038 pragma Inline (Set_Generic_Parent);
12039 pragma Inline (Set_Generic_Parent_Type);
12040 pragma Inline (Set_Handled_Statement_Sequence);
12041 pragma Inline (Set_Handler_List_Entry);
12042 pragma Inline (Set_Has_Created_Identifier);
12043 pragma Inline (Set_Has_Dynamic_Length_Check);
12044 pragma Inline (Set_Has_Init_Expression);
12045 pragma Inline (Set_Has_Local_Raise);
12046 pragma Inline (Set_Has_Dynamic_Range_Check);
12047 pragma Inline (Set_Has_No_Elaboration_Code);
12048 pragma Inline (Set_Has_Pragma_CPU);
12049 pragma Inline (Set_Has_Pragma_Priority);
12050 pragma Inline (Set_Has_Pragma_Suppress_All);
12051 pragma Inline (Set_Has_Private_View);
12052 pragma Inline (Set_Has_Relative_Deadline_Pragma);
12053 pragma Inline (Set_Has_Storage_Size_Pragma);
12054 pragma Inline (Set_Has_Task_Info_Pragma);
12055 pragma Inline (Set_Has_Task_Name_Pragma);
12056 pragma Inline (Set_Has_Wide_Character);
12057 pragma Inline (Set_Has_Wide_Wide_Character);
12058 pragma Inline (Set_Hidden_By_Use_Clause);
12059 pragma Inline (Set_High_Bound);
12060 pragma Inline (Set_Identifier);
12061 pragma Inline (Set_Implicit_With);
12062 pragma Inline (Set_Includes_Infinities);
12063 pragma Inline (Set_Interface_List);
12064 pragma Inline (Set_Interface_Present);
12065 pragma Inline (Set_Import_Interface_Present);
12066 pragma Inline (Set_In_Present);
12067 pragma Inline (Set_Inherited_Discriminant);
12068 pragma Inline (Set_Instance_Spec);
12069 pragma Inline (Set_Intval);
12070 pragma Inline (Set_Is_Accessibility_Actual);
12071 pragma Inline (Set_Is_Asynchronous_Call_Block);
12072 pragma Inline (Set_Is_Component_Left_Opnd);
12073 pragma Inline (Set_Is_Component_Right_Opnd);
12074 pragma Inline (Set_Is_Controlling_Actual);
12075 pragma Inline (Set_Is_Delayed_Aspect);
12076 pragma Inline (Set_Is_Dynamic_Coextension);
12077 pragma Inline (Set_Is_Elsif);
12078 pragma Inline (Set_Is_Entry_Barrier_Function);
12079 pragma Inline (Set_Is_Expanded_Build_In_Place_Call);
12080 pragma Inline (Set_Is_Folded_In_Parser);
12081 pragma Inline (Set_Is_In_Discriminant_Check);
12082 pragma Inline (Set_Is_Machine_Number);
12083 pragma Inline (Set_Is_Null_Loop);
12084 pragma Inline (Set_Is_Overloaded);
12085 pragma Inline (Set_Is_Power_Of_2_For_Shift);
12086 pragma Inline (Set_Is_Protected_Subprogram_Body);
12087 pragma Inline (Set_Has_Self_Reference);
12088 pragma Inline (Set_Is_Static_Coextension);
12089 pragma Inline (Set_Is_Static_Expression);
12090 pragma Inline (Set_Is_Subprogram_Descriptor);
12091 pragma Inline (Set_Is_Task_Allocation_Block);
12092 pragma Inline (Set_Is_Task_Master);
12093 pragma Inline (Set_Iteration_Scheme);
12094 pragma Inline (Set_Itype);
12095 pragma Inline (Set_Kill_Range_Check);
12096 pragma Inline (Set_Last_Bit);
12097 pragma Inline (Set_Last_Name);
12098 pragma Inline (Set_Library_Unit);
12099 pragma Inline (Set_Label_Construct);
12100 pragma Inline (Set_Left_Opnd);
12101 pragma Inline (Set_Limited_View_Installed);
12102 pragma Inline (Set_Limited_Present);
12103 pragma Inline (Set_Literals);
12104 pragma Inline (Set_Local_Raise_Not_OK);
12105 pragma Inline (Set_Local_Raise_Statements);
12106 pragma Inline (Set_Loop_Actions);
12107 pragma Inline (Set_Loop_Parameter_Specification);
12108 pragma Inline (Set_Low_Bound);
12109 pragma Inline (Set_Mod_Clause);
12110 pragma Inline (Set_More_Ids);
12111 pragma Inline (Set_Must_Be_Byte_Aligned);
12112 pragma Inline (Set_Must_Not_Freeze);
12113 pragma Inline (Set_Must_Not_Override);
12114 pragma Inline (Set_Must_Override);
12115 pragma Inline (Set_Name);
12116 pragma Inline (Set_Names);
12117 pragma Inline (Set_Next_Entity);
12118 pragma Inline (Set_Next_Exit_Statement);
12119 pragma Inline (Set_Next_Implicit_With);
12120 pragma Inline (Set_Next_Named_Actual);
12121 pragma Inline (Set_Next_Pragma);
12122 pragma Inline (Set_Next_Rep_Item);
12123 pragma Inline (Set_Next_Use_Clause);
12124 pragma Inline (Set_No_Ctrl_Actions);
12125 pragma Inline (Set_No_Elaboration_Check);
12126 pragma Inline (Set_No_Entities_Ref_In_Spec);
12127 pragma Inline (Set_No_Initialization);
12128 pragma Inline (Set_No_Truncation);
12129 pragma Inline (Set_Null_Present);
12130 pragma Inline (Set_Null_Exclusion_Present);
12131 pragma Inline (Set_Null_Exclusion_In_Return_Present);
12132 pragma Inline (Set_Null_Record_Present);
12133 pragma Inline (Set_Object_Definition);
12134 pragma Inline (Set_Original_Discriminant);
12135 pragma Inline (Set_Original_Entity);
12136 pragma Inline (Set_Others_Discrete_Choices);
12137 pragma Inline (Set_Out_Present);
12138 pragma Inline (Set_Parameter_Associations);
12139 pragma Inline (Set_Parameter_Specifications);
12140 pragma Inline (Set_Parameter_List_Truncated);
12141 pragma Inline (Set_Parameter_Type);
12142 pragma Inline (Set_Parent_Spec);
12143 pragma Inline (Set_Position);
12144 pragma Inline (Set_Pragma_Argument_Associations);
12145 pragma Inline (Set_Pragma_Enabled);
12146 pragma Inline (Set_Pragma_Identifier);
12147 pragma Inline (Set_Pragmas_After);
12148 pragma Inline (Set_Pragmas_Before);
12149 pragma Inline (Set_Prefix);
12150 pragma Inline (Set_Present_Expr);
12151 pragma Inline (Set_Prev_Ids);
12152 pragma Inline (Set_Print_In_Hex);
12153 pragma Inline (Set_Private_Declarations);
12154 pragma Inline (Set_Private_Present);
12155 pragma Inline (Set_Procedure_To_Call);
12156 pragma Inline (Set_Proper_Body);
12157 pragma Inline (Set_Protected_Definition);
12158 pragma Inline (Set_Protected_Present);
12159 pragma Inline (Set_Raises_Constraint_Error);
12160 pragma Inline (Set_Range_Constraint);
12161 pragma Inline (Set_Range_Expression);
12162 pragma Inline (Set_Real_Range_Specification);
12163 pragma Inline (Set_Realval);
12164 pragma Inline (Set_Reason);
12165 pragma Inline (Set_Record_Extension_Part);
12166 pragma Inline (Set_Redundant_Use);
12167 pragma Inline (Set_Renaming_Exception);
12168 pragma Inline (Set_Result_Definition);
12169 pragma Inline (Set_Return_Object_Declarations);
12170 pragma Inline (Set_Reverse_Present);
12171 pragma Inline (Set_Right_Opnd);
12172 pragma Inline (Set_Rounded_Result);
12173 pragma Inline (Set_SCIL_Controlling_Tag);
12174 pragma Inline (Set_SCIL_Entity);
12175 pragma Inline (Set_SCIL_Tag_Value);
12176 pragma Inline (Set_SCIL_Target_Prim);
12177 pragma Inline (Set_Scope);
12178 pragma Inline (Set_Select_Alternatives);
12179 pragma Inline (Set_Selector_Name);
12180 pragma Inline (Set_Selector_Names);
12181 pragma Inline (Set_Shift_Count_OK);
12182 pragma Inline (Set_Source_Type);
12183 pragma Inline (Set_Specification);
12184 pragma Inline (Set_Split_PPC);
12185 pragma Inline (Set_Statements);
12186 pragma Inline (Set_Static_Processing_OK);
12187 pragma Inline (Set_Storage_Pool);
12188 pragma Inline (Set_Strval);
12189 pragma Inline (Set_Subtype_Indication);
12190 pragma Inline (Set_Subtype_Mark);
12191 pragma Inline (Set_Subtype_Marks);
12192 pragma Inline (Set_Suppress_Loop_Warnings);
12193 pragma Inline (Set_Synchronized_Present);
12194 pragma Inline (Set_Tagged_Present);
12195 pragma Inline (Set_Target_Type);
12196 pragma Inline (Set_Task_Definition);
12197 pragma Inline (Set_Task_Present);
12198 pragma Inline (Set_Then_Actions);
12199 pragma Inline (Set_Then_Statements);
12200 pragma Inline (Set_Triggering_Alternative);
12201 pragma Inline (Set_Triggering_Statement);
12202 pragma Inline (Set_Treat_Fixed_As_Integer);
12203 pragma Inline (Set_TSS_Elist);
12204 pragma Inline (Set_Type_Definition);
12205 pragma Inline (Set_Unit);
12206 pragma Inline (Set_Unknown_Discriminants_Present);
12207 pragma Inline (Set_Unreferenced_In_Spec);
12208 pragma Inline (Set_Variant_Part);
12209 pragma Inline (Set_Variants);
12210 pragma Inline (Set_Visible_Declarations);
12211 pragma Inline (Set_Was_Originally_Stub);
12212 pragma Inline (Set_Withed_Body);
12213 pragma Inline (Set_Zero_Cost_Handling);
12214
12215 N_Simple_Return_Statement : constant Node_Kind := N_Return_Statement;
12216 -- Rename N_Return_Statement to be N_Simple_Return_Statement. Clients
12217 -- should refer to N_Simple_Return_Statement.
12218
12219 end Sinfo;