1 ------------------------------------------------------------------------------
3 -- GNAT COMPILER COMPONENTS --
9 -- Copyright (C) 1992-2014, Free Software Foundation, Inc. --
11 -- GNAT is free software; you can redistribute it and/or modify it under --
12 -- terms of the GNU General Public License as published by the Free Soft- --
13 -- ware Foundation; either version 3, or (at your option) any later ver- --
14 -- sion. GNAT is distributed in the hope that it will be useful, but WITH- --
15 -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY --
16 -- or FITNESS FOR A PARTICULAR PURPOSE. --
18 -- As a special exception under Section 7 of GPL version 3, you are granted --
19 -- additional permissions described in the GCC Runtime Library Exception, --
20 -- version 3.1, as published by the Free Software Foundation. --
22 -- You should have received a copy of the GNU General Public License and --
23 -- a copy of the GCC Runtime Library Exception along with this program; --
24 -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see --
25 -- <http://www.gnu.org/licenses/>. --
27 -- GNAT was originally developed by the GNAT team at New York University. --
28 -- Extensive contributions were provided by Ada Core Technologies Inc. --
30 ------------------------------------------------------------------------------
32 -- 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.
36 -- The grammar in the RM is followed very closely in the tree design, and is
37 -- repeated as part of this source file.
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.
46 -- WARNING: Several files are automatically generated from this package.
47 -- See below for details.
49 with Namet; use Namet;
50 with Types; use Types;
51 with Uintp; use Uintp;
52 with Urealp; use Urealp;
56 ---------------------------------
57 -- Making Changes to This File --
58 ---------------------------------
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:
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
73 -- The body of the access function
74 -- The body of the set procedure
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
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.
84 -- If a new tree node is added, then the following changes are made
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 -- Add an entry in Is_Syntactic_Field
90 -- In the body (sinfo), add entries to the access functions for all
91 -- its fields (except standard expression fields) to include the new
92 -- node in the checks.
93 -- Add an appropriate section to the case statement in sprint.adb
94 -- Add an appropriate section to the case statement in sem.adb
95 -- Add an appropriate section to the case statement in exp_util.adb
96 -- (Insert_Actions procedure)
97 -- For a subexpression, add an appropriate section to the case
98 -- statement in sem_eval.adb
99 -- For a subexpression, add an appropriate section to the case
100 -- statement in sem_res.adb
102 -- All back ends must be made aware of the new node kind.
104 -- Finally, four utility programs must be run:
106 -- (Optional.) Run CSinfo to check that you have made the changes
107 -- consistently. It checks most of the rules given above. This utility
108 -- reads sinfo.ads and sinfo.adb and generates a report to standard
109 -- output. This step is optional because XSinfo runs CSinfo.
111 -- Run XSinfo to create sinfo.h, the corresponding C header. This
112 -- utility reads sinfo.ads and generates sinfo.h. Note that it does
113 -- not need to read sinfo.adb, since the contents of the body are
114 -- algorithmically determinable from the spec.
116 -- Run XTreeprs to create treeprs.ads, an updated version of the module
117 -- that is used to drive the tree print routine. This utility reads (but
118 -- does not modify) treeprs.adt, the template that provides the basic
119 -- structure of the file, and then fills in the data from the comments
122 -- Run XNmake to create nmake.ads and nmake.adb, the package body and
123 -- spec of the Nmake package which contains functions for constructing
126 -- The above steps are done automatically by the build scripts when you do
129 -- Note: sometime we could write a utility that actually generated the body
130 -- of sinfo from the spec instead of simply checking it, since, as noted
131 -- above, the contents of the body can be determined from the spec.
133 --------------------------------
134 -- Implicit Nodes in the Tree --
135 --------------------------------
137 -- Generally the structure of the tree very closely follows the grammar as
138 -- defined in the RM. However, certain nodes are omitted to save space and
139 -- simplify semantic processing. Two general classes of such omitted nodes
142 -- If the only possibilities for a non-terminal are one or more other
143 -- non-terminals (i.e. the rule is a "skinny" rule), then usually the
144 -- corresponding node is omitted from the tree, and the target construct
145 -- appears directly. For example, a real type definition is either
146 -- floating point definition or a fixed point definition. No explicit node
147 -- appears for real type definition. Instead either the floating point
148 -- definition or fixed point definition appears directly.
150 -- If a non-terminal corresponds to a list of some other non-terminal
151 -- (possibly with separating punctuation), then usually it is omitted from
152 -- the tree, and a list of components appears instead. For example,
153 -- sequence of statements does not appear explicitly in the tree. Instead
154 -- a list of statements appears directly.
156 -- Some additional cases of omitted nodes occur and are documented
157 -- individually. In particular, many nodes are omitted in the tree
158 -- generated for an expression.
160 -------------------------------------------
161 -- Handling of Defining Identifier Lists --
162 -------------------------------------------
164 -- In several declarative forms in the syntax, lists of defining
165 -- identifiers appear (object declarations, component declarations, number
166 -- declarations etc.)
168 -- The semantics of such statements are equivalent to a series of identical
169 -- declarations of single defining identifiers (except that conformance
170 -- checks require the same grouping of identifiers in the parameter case).
172 -- To simplify semantic processing, the parser breaks down such multiple
173 -- declaration cases into sequences of single declarations, duplicating
174 -- type and initialization information as required. The flags More_Ids and
175 -- Prev_Ids are used to record the original form of the source in the case
176 -- where the original source used a list of names, More_Ids being set on
177 -- all but the last name and Prev_Ids being set on all but the first name.
178 -- These flags are used to reconstruct the original source (e.g. in the
179 -- Sprint package), and also are included in the conformance checks, but
180 -- otherwise have no semantic significance.
182 -- Note: the reason that we use More_Ids and Prev_Ids rather than
183 -- First_Name and Last_Name flags is so that the flags are off in the
184 -- normal one identifier case, which minimizes tree print output.
186 -----------------------
187 -- Use of Node Lists --
188 -----------------------
190 -- With a few exceptions, if a construction of the form {non-terminal}
191 -- appears in the tree, lists are used in the corresponding tree node (see
192 -- package Nlists for handling of node lists). In this case a field of the
193 -- parent node points to a list of nodes for the non-terminal. The field
194 -- name for such fields has a plural name which always ends in "s". For
195 -- example, a case statement has a field Alternatives pointing to list of
196 -- case statement alternative nodes.
198 -- Only fields pointing to lists have names ending in "s", so generally the
199 -- structure is strongly typed, fields not ending in s point to single
200 -- nodes, and fields ending in s point to lists.
202 -- The following example shows how a traversal of a list is written. We
203 -- suppose here that Stmt points to a N_Case_Statement node which has a
204 -- list field called Alternatives:
206 -- Alt := First (Alternatives (Stmt));
207 -- while Present (Alt) loop
209 -- -- processing for case statement alternative Alt
211 -- Alt := Next (Alt);
214 -- The Present function tests for Empty, which in this case signals the end
215 -- of the list. First returns Empty immediately if the list is empty.
216 -- Present is defined in Atree, First and Next are defined in Nlists.
218 -- The exceptions to this rule occur with {DEFINING_IDENTIFIERS} in all
219 -- contexts, which is handled as described in the previous section, and
220 -- with {,library_unit_NAME} in the N_With_Clause mode, which is handled
221 -- using the First_Name and Last_Name flags, as further detailed in the
222 -- description of the N_With_Clause node.
228 -- Pragmas can appear in many different context, but are not included in
229 -- the grammar. Still they must appear in the tree, so they can be properly
232 -- Two approaches are used. In some cases, an extra field is defined in an
233 -- appropriate node that contains a list of pragmas appearing in the
234 -- expected context. For example pragmas can appear before an
235 -- Accept_Alternative in a Selective_Accept_Statement, and these pragmas
236 -- appear in the Pragmas_Before field of the N_Accept_Alternative node.
238 -- The other approach is to simply allow pragmas to appear in syntactic
239 -- lists where the grammar (of course) does not include the possibility.
240 -- For example, the Variants field of an N_Variant_Part node points to a
241 -- list that can contain both N_Pragma and N_Variant nodes.
243 -- To make processing easier in the latter case, the Nlists package
244 -- provides a set of routines (First_Non_Pragma, Last_Non_Pragma,
245 -- Next_Non_Pragma, Prev_Non_Pragma) that allow such lists to be handled
246 -- ignoring all pragmas.
248 -- In the case of the variants list, we can either write:
250 -- Variant := First (Variants (N));
251 -- while Present (Variant) loop
253 -- Variant := Next (Variant);
258 -- Variant := First_Non_Pragma (Variants (N));
259 -- while Present (Variant) loop
261 -- Variant := Next_Non_Pragma (Variant);
264 -- In the first form of the loop, Variant can either be an N_Pragma or an
265 -- N_Variant node. In the second form, Variant can only be N_Variant since
266 -- all pragmas are skipped.
268 ---------------------
269 -- Optional Fields --
270 ---------------------
272 -- Fields which correspond to a section of the syntax enclosed in square
273 -- brackets are generally omitted (and the corresponding field set to Empty
274 -- for a node, or No_List for a list). The documentation of such fields
275 -- notes these cases. One exception to this rule occurs in the case of
276 -- possibly empty statement sequences (such as the sequence of statements
277 -- in an entry call alternative). Such cases appear in the syntax rules as
278 -- [SEQUENCE_OF_STATEMENTS] and the fields corresponding to such optional
279 -- statement sequences always contain an empty list (not No_List) if no
280 -- statements are present.
282 -- Note: the utility program that constructs the body and spec of the Nmake
283 -- package relies on the format of the comments to determine if a field
284 -- should have a default value in the corresponding make routine. The rule
285 -- is that if the first line of the description of the field contains the
286 -- string "(set to xxx if", then a default value of xxx is provided for
287 -- this field in the corresponding Make_yyy routine.
289 -----------------------------------
290 -- Note on Body/Spec Terminology --
291 -----------------------------------
293 -- In informal discussions about Ada, it is customary to refer to package
294 -- and subprogram specs and bodies. However, this is not technically
295 -- correct, what is normally referred to as a spec or specification is in
296 -- fact a package declaration or subprogram declaration. We are careful in
297 -- GNAT to use the correct terminology and in particular, the full word
298 -- specification is never used as an incorrect substitute for declaration.
299 -- The structure and terminology used in the tree also reflects the grammar
300 -- and thus uses declaration and specification in the technically correct
303 -- However, there are contexts in which the informal terminology is useful.
304 -- We have the word "body" to refer to the Interp_Etype declared by the
305 -- declaration of a unit body, and in some contexts we need similar term to
306 -- refer to the entity declared by the package or subprogram declaration,
307 -- and simply using declaration can be confusing since the body also has a
310 -- An example of such a context is the link between the package body and
311 -- its declaration. With_Declaration is confusing, since the package body
312 -- itself is a declaration.
314 -- To deal with this problem, we reserve the informal term Spec, i.e. the
315 -- popular abbreviation used in this context, to refer to the entity
316 -- declared by the package or subprogram declaration. So in the above
317 -- example case, the field in the body is called With_Spec.
319 -- Another important context for the use of the word Spec is in error
320 -- messages, where a hyper-correct use of declaration would be confusing to
321 -- a typical Ada programmer, and even for an expert programmer can cause
322 -- confusion since the body has a declaration as well.
326 -- Declaration always refers to the syntactic entity that is called
327 -- a declaration. In particular, subprogram declaration
328 -- and package declaration are used to describe the
329 -- syntactic entity that includes the semicolon.
331 -- Specification always refers to the syntactic entity that is called
332 -- a specification. In particular, the terms procedure
333 -- specification, function specification, package
334 -- specification, subprogram specification always refer
335 -- to the syntactic entity that has no semicolon.
337 -- Spec is an informal term, used to refer to the entity
338 -- that is declared by a task declaration, protected
339 -- declaration, generic declaration, subprogram
340 -- declaration or package declaration.
342 -- This convention is followed throughout the GNAT documentation
343 -- both internal and external, and in all error message text.
345 ------------------------
346 -- Internal Use Nodes --
347 ------------------------
349 -- These are Node_Kind settings used in the internal implementation which
350 -- are not logically part of the specification.
353 -- Completely unused entry at the start of the enumeration type. This
354 -- is inserted so that no legitimate value is zero, which helps to get
355 -- better debugging behavior, since zero is a likely uninitialized value).
358 -- Completely unused entry at the end of the enumeration type. This is
359 -- handy so that arrays with Node_Kind as the index type have an extra
360 -- entry at the end (see for example the use of the Pchar_Pos_Array in
361 -- Treepr, where the extra entry provides the limit value when dealing with
362 -- the last used entry in the array).
364 -----------------------------------------
365 -- Note on the settings of Sloc fields --
366 -----------------------------------------
368 -- The Sloc field of nodes that come from the source is set by the parser.
369 -- For internal nodes, and nodes generated during expansion the Sloc is
370 -- usually set in the call to the constructor for the node. In general the
371 -- Sloc value chosen for an internal node is the Sloc of the source node
372 -- whose processing is responsible for the expansion. For example, the Sloc
373 -- of an inherited primitive operation is the Sloc of the corresponding
374 -- derived type declaration.
376 -- For the nodes of a generic instantiation, the Sloc value is encoded to
377 -- represent both the original Sloc in the generic unit, and the Sloc of
378 -- the instantiation itself. See Sinput.ads for details.
380 -- Subprogram instances create two callable entities: one is the visible
381 -- subprogram instance, and the other is an anonymous subprogram nested
382 -- within a wrapper package that contains the renamings for the actuals.
383 -- Both of these entities have the Sloc of the defining entity in the
384 -- instantiation node. This simplifies some ASIS queries.
386 -----------------------
387 -- Field Definitions --
388 -----------------------
390 -- In the following node definitions, all fields, both syntactic and
391 -- semantic, are documented. The one exception is in the case of entities
392 -- (defining identifiers, character literals and operator symbols), where
393 -- the usage of the fields depends on the entity kind. Entity fields are
394 -- fully documented in the separate package Einfo.
396 -- In the node definitions, three common sets of fields are abbreviated to
397 -- save both space in the documentation, and also space in the string
398 -- (defined in Tree_Print_Strings) used to print trees. The following
399 -- abbreviations are used:
401 -- Note: the utility program that creates the Treeprs spec (in the file
402 -- xtreeprs.adb) knows about the special fields here, so it must be
403 -- modified if any change is made to these fields.
405 -- "plus fields for binary operator"
406 -- Chars (Name1) Name_Id for the operator
407 -- Left_Opnd (Node2) left operand expression
408 -- Right_Opnd (Node3) right operand expression
409 -- Entity (Node4-Sem) defining entity for operator
410 -- Associated_Node (Node4-Sem) for generic processing
411 -- Do_Overflow_Check (Flag17-Sem) set if overflow check needed
412 -- Has_Private_View (Flag11-Sem) set in generic units.
414 -- "plus fields for unary operator"
415 -- Chars (Name1) Name_Id for the operator
416 -- Right_Opnd (Node3) right operand expression
417 -- Entity (Node4-Sem) defining entity for operator
418 -- Associated_Node (Node4-Sem) for generic processing
419 -- Do_Overflow_Check (Flag17-Sem) set if overflow check needed
420 -- Has_Private_View (Flag11-Sem) set in generic units.
422 -- "plus fields for expression"
423 -- Paren_Count number of parentheses levels
424 -- Etype (Node5-Sem) type of the expression
425 -- Is_Overloaded (Flag5-Sem) >1 type interpretation exists
426 -- Is_Static_Expression (Flag6-Sem) set for static expression
427 -- Raises_Constraint_Error (Flag7-Sem) evaluation raises CE
428 -- Must_Not_Freeze (Flag8-Sem) set if must not freeze
429 -- Do_Range_Check (Flag9-Sem) set if a range check needed
430 -- Has_Dynamic_Length_Check (Flag10-Sem) set if length check inserted
431 -- Has_Dynamic_Range_Check (Flag12-Sem) set if range check inserted
432 -- Assignment_OK (Flag15-Sem) set if modification is OK
433 -- Is_Controlling_Actual (Flag16-Sem) set for controlling argument
435 -- Note: see under (EXPRESSION) for further details on the use of
436 -- the Paren_Count field to record the number of parentheses levels.
438 -- Node_Kind is the type used in the Nkind field to indicate the node kind.
439 -- The actual definition of this type is given later (the reason for this
440 -- is that we want the descriptions ordered by logical chapter in the RM,
441 -- but the type definition is reordered to facilitate the definition of
442 -- some subtype ranges. The individual descriptions of the nodes show how
443 -- the various fields are used in each node kind, as well as providing
444 -- logical names for the fields. Functions and procedures are provided for
445 -- accessing and setting these fields using these logical names.
447 -----------------------
448 -- Gigi Restrictions --
449 -----------------------
451 -- The tree passed to Gigi is more restricted than the general tree form.
452 -- For example, as a result of expansion, most of the tasking nodes can
453 -- never appear. For each node to which either a complete or partial
454 -- restriction applies, a note entitled "Gigi restriction" appears which
455 -- documents the restriction.
457 -- Note that most of these restrictions apply only to trees generated when
458 -- code is being generated, since they involved expander actions that
465 -- When a file is compiled in ASIS mode (-gnatct), expansion is skipped,
466 -- and the analysis must generate a tree in a form that meets all ASIS
469 -- ASIS must be able to recover the original tree that corresponds to the
470 -- source. It relies heavily on Original_Node for this purpose, which as
471 -- described in Atree, records the history when a node is rewritten. ASIS
472 -- uses Original_Node to recover the original node before the Rewrite.
474 -- At least in ASIS mode (not really important in non-ASIS mode), when
475 -- N1 is rewritten as N2:
477 -- The subtree rooted by the original node N1 should be fully decorated,
478 -- i.e. all semantic fields noted in sinfo.ads should be set properly
479 -- and any referenced entities should be complete (with exceptions for
480 -- representation information, noted below).
482 -- For all the direct descendants of N1 (original node) their Parent
483 -- links should point not to N1, but to N2 (rewriting node).
485 -- The Parent links of rewritten nodes (N1 in this example) are set in
486 -- some cases (to point to the rewritten parent), but in other cases
487 -- they are set to Empty. This needs sorting out ??? It would be much
488 -- cleaner if they could always be set in the original node ???
490 -- Representation Information
492 -- For the purposes of the data description annex, the representation
493 -- information for source declared entities must be complete in the
496 -- This requires that the front end call the back end (gigi/gcc) in
497 -- a special "back annotate only" mode to obtain information on layout
498 -- from the back end.
500 -- For the purposes of this special "back annotate only" mode, the
501 -- requirements that would normally need to be met to generate code
502 -- are relaxed as follows:
504 -- Anonymous types need not have full representation information (e.g.
505 -- sizes need not be set for types where the front end would normally
506 -- set the sizes), since anonymous types can be ignored in this mode.
508 -- In this mode, gigi will see at least fragments of a fully annotated
509 -- unexpanded tree. This means that it will encounter nodes it does
510 -- not normally handle (such as stubs, task bodies etc). It should
511 -- simply ignore these nodes, since they are not relevant to the task
512 -- of back annotating representation information.
518 -- When a file is compiled in GNATprove mode (-gnatd.F), a very light
519 -- expansion is performed and the analysis must generate a tree in a
520 -- form that meets additional requirements.
522 -- This light expansion does two transformations of the tree that cannot
523 -- be postponed till after semantic analysis:
525 -- 1. Replace object renamings by renamed object. This requires the
526 -- introduction of temporaries at the point of the renaming, which
527 -- must be properly analyzed.
529 -- 2. Fully qualify entity names. This is needed to generate suitable
530 -- local effects and call-graphs in ALI files, with the completely
531 -- qualified names (in particular the suffix to distinguish homonyms).
533 -- The tree after this light expansion should be fully analyzed
534 -- semantically, which sometimes requires the insertion of semantic
535 -- pre-analysis, for example for subprogram contracts and pragma
536 -- check/assert. In particular, all expression must have their proper type,
537 -- and semantic links should be set between tree nodes (partial to full
538 -- view, etc.) Some kinds of nodes should be either absent, or can be
539 -- ignored by the formal verification backend:
541 -- N_Object_Renaming_Declaration: can be ignored safely
542 -- N_Expression_Function: absent (rewritten)
543 -- N_Expression_With_Actions: absent (not generated)
545 -- SPARK cross-references are generated from the regular cross-references
546 -- (used for browsing and code understanding) and additional references
547 -- collected during semantic analysis, in particular on all dereferences.
548 -- These SPARK cross-references are output in a separate section of ALI
549 -- files, as described in spark_xrefs.adb. They are the basis for the
550 -- computation of data dependences in GNATprove. This implies that all
551 -- cross-references should be generated in this mode, even those that would
552 -- not make sense from a user point-of-view, and that cross-references that
553 -- do not lead to data dependences for subprograms can be safely ignored.
555 -- In addition pragma Debug statements are removed from the tree (rewritten
556 -- to NULL stmt), since they should be ignored in formal verification.
558 -- An error is also issued for missing subunits, similar to the warning
559 -- issued when generating code, to avoid formal verification of a partial
562 -----------------------
563 -- Check Flag Fields --
564 -----------------------
566 -- The following flag fields appear in expression nodes:
572 -- These three flags are always set by the front end during semantic
573 -- analysis, on expression nodes that may trigger the corresponding
574 -- check. The front end then inserts or not the check during expansion. In
575 -- particular, these flags should also be correctly set in ASIS mode and
578 -- Note: the expander always takes care of the Do_Range check case,
579 -- so this flag will never be set in the expanded tree passed to the
580 -- back end code generator.
582 -- Note that this accounts for all nodes that trigger the corresponding
583 -- checks, except for range checks on subtype_indications, which may be
584 -- required to check that a range_constraint is compatible with the given
585 -- subtype (RM 3.2.2(11)).
587 -- The following flag fields appear in various nodes:
589 -- Do_Accessibility_Check
590 -- Do_Discriminant_Check
595 -- These flags are used in some specific cases by the front end, either
596 -- during semantic analysis or during expansion, and cannot be expected
597 -- to be set on all nodes that trigger the corresponding check.
599 ------------------------
600 -- Common Flag Fields --
601 ------------------------
603 -- The following flag fields appear in all nodes:
606 -- This flag is used to indicate that a node (and all its children have
607 -- been analyzed. It is used to avoid reanalysis of a node that has
608 -- already been analyzed, both for efficiency and functional correctness
612 -- This flag is set if the node comes directly from an explicit construct
613 -- in the source. It is normally on for any nodes built by the scanner or
614 -- parser from the source program, with the exception that in a few cases
615 -- the parser adds nodes to normalize the representation (in particular
616 -- a null statement is added to a package body if there is no begin/end
617 -- initialization section.
619 -- Most nodes inserted by the analyzer or expander are not considered
620 -- as coming from source, so the flag is off for such nodes. In a few
621 -- cases, the expander constructs nodes closely equivalent to nodes
622 -- from the source program (e.g. the allocator built for build-in-place
623 -- case), and the Comes_From_Source flag is deliberately set.
626 -- This flag is used to avoid multiple error messages being posted on or
627 -- referring to the same node. This flag is set if an error message
628 -- refers to a node or is posted on its source location, and has the
629 -- effect of inhibiting further messages involving this same node.
631 -----------------------
632 -- Modify_Tree_For_C --
633 -----------------------
635 -- If the flag Opt.Modify_Tree_For_C is set True, then the tree is modified
636 -- in ways that help match the semantics better with C, easing the task of
637 -- interfacing to C code generators (other than GCC, where the work is done
638 -- in gigi, and there is no point in changing that), and also making life
639 -- easier for Cprint in generating C source code.
641 -- The current modifications implemented are as follows:
643 -- N_Op_Rotate_Left, N_Op_Rotate_Right, N_Shift_Right_Arithmetic nodes
644 -- are eliminated from the tree (since these operations do not exist in
645 -- C), and the operations are rewritten in terms of logical shifts and
646 -- other logical operations that do exist in C. See Exp_Ch4 expansion
647 -- routines for these operators for details of the transformations made.
649 -- The right operand of N_Op_Shift_Right and N_Op_Shift_Left is always
650 -- less than the word size (since other values are not well-defined in
651 -- C). This is done using an explicit test if necessary.
653 -- Min and Max attributes are expanded into equivalent if expressions,
654 -- dealing properly with side effect issues.
656 -- Mod for signed integer types is expanded into equivalent expressions
657 -- using Rem (which is % in C) and other C-available operators.
659 -- The Actions list of an Expression_With_Actions node does not contain
660 -- any declarations,(so that DO X, .. Y IN Z becomes (X, .. Y, Z) in C).
662 ------------------------------------
663 -- Description of Semantic Fields --
664 ------------------------------------
666 -- The meaning of the syntactic fields is generally clear from their names
667 -- without any further description, since the names are chosen to
668 -- correspond very closely to the syntax in the reference manual. This
669 -- section describes the usage of the semantic fields, which are used to
670 -- contain additional information determined during semantic analysis.
672 -- ABE_Is_Certain (Flag18-Sem)
673 -- This flag is set in an instantiation node or a call node is determined
674 -- to be sure to raise an ABE. This is used to trigger special handling
675 -- of such cases, particularly in the instantiation case where we avoid
676 -- instantiating the body if this flag is set. This flag is also present
677 -- in an N_Formal_Package_Declaration_Node since formal package
678 -- declarations are treated like instantiations, but it is always set to
679 -- False in this context.
681 -- Accept_Handler_Records (List5-Sem)
682 -- This field is present only in an N_Accept_Alternative node. It is used
683 -- to temporarily hold the exception handler records from an accept
684 -- statement in a selective accept. These exception handlers will
685 -- eventually be placed in the Handler_Records list of the procedure
686 -- built for this accept (see Expand_N_Selective_Accept procedure in
687 -- Exp_Ch9 for further details).
689 -- Access_Types_To_Process (Elist2-Sem)
690 -- Present in N_Freeze_Entity nodes for Incomplete or private types.
691 -- Contains the list of access types which may require specific treatment
692 -- when the nature of the type completion is completely known. An example
693 -- of such treatment is the generation of the associated_final_chain.
695 -- Actions (List1-Sem)
696 -- This field contains a sequence of actions that are associated with the
697 -- node holding the field. See the individual node types for details of
698 -- how this field is used, as well as the description of the specific use
699 -- for a particular node type.
701 -- Activation_Chain_Entity (Node3-Sem)
702 -- This is used in tree nodes representing task activators (blocks,
703 -- subprogram bodies, package declarations, and task bodies). It is
704 -- initially Empty, and then gets set to point to the entity for the
705 -- declared Activation_Chain variable when the first task is declared.
706 -- When tasks are declared in the corresponding declarative region this
707 -- entity is located by name (its name is always _Chain) and the declared
708 -- tasks are added to the chain. Note that N_Extended_Return_Statement
709 -- does not have this attribute, although it does have an activation
710 -- chain. This chain is used to store the tasks temporarily, and is not
711 -- used for activating them. On successful completion of the return
712 -- statement, the tasks are moved to the caller's chain, and the caller
715 -- Acts_As_Spec (Flag4-Sem)
716 -- A flag set in the N_Subprogram_Body node for a subprogram body which
717 -- is acting as its own spec, except in the case of a library level
718 -- subprogram, in which case the flag is set on the parent compilation
719 -- unit node instead.
721 -- Actual_Designated_Subtype (Node4-Sem)
722 -- Present in N_Free_Statement and N_Explicit_Dereference nodes. If gigi
723 -- needs to known the dynamic constrained subtype of the designated
724 -- object, this attribute is set to that type. This is done for
725 -- N_Free_Statements for access-to-classwide types and access to
726 -- unconstrained packed array types, and for N_Explicit_Dereference when
727 -- the designated type is an unconstrained packed array and the
728 -- dereference is the prefix of a 'Size attribute reference.
730 -- Address_Warning_Posted (Flag18-Sem)
731 -- Present in N_Attribute_Definition nodes. Set to indicate that we have
732 -- posted a warning for the address clause regarding size or alignment
733 -- issues. Used to inhibit multiple redundant messages.
735 -- Aggregate_Bounds (Node3-Sem)
736 -- Present in array N_Aggregate nodes. If the bounds of the aggregate are
737 -- known at compile time, this field points to an N_Range node with those
738 -- bounds. Otherwise Empty.
740 -- All_Others (Flag11-Sem)
741 -- Present in an N_Others_Choice node. This flag is set for an others
742 -- exception where all exceptions are to be caught, even those that are
743 -- not normally handled (in particular the tasking abort signal). This
744 -- is used for translation of the at end handler into a normal exception
747 -- Aspect_Rep_Item (Node2-Sem)
748 -- Present in N_Aspect_Specification nodes. Points to the corresponding
749 -- pragma/attribute definition node used to process the aspect.
751 -- Assignment_OK (Flag15-Sem)
752 -- This flag is set in a subexpression node for an object, indicating
753 -- that the associated object can be modified, even if this would not
754 -- normally be permissible (either by direct assignment, or by being
755 -- passed as an out or in-out parameter). This is used by the expander
756 -- for a number of purposes, including initialization of constants and
757 -- limited type objects (such as tasks), setting discriminant fields,
758 -- setting tag values, etc. N_Object_Declaration nodes also have this
759 -- flag defined. Here it is used to indicate that an initialization
760 -- expression is valid, even where it would normally not be allowed
761 -- (e.g. where the type involved is limited).
763 -- Associated_Node (Node4-Sem)
764 -- Present in nodes that can denote an entity: identifiers, character
765 -- literals, operator symbols, expanded names, operator nodes, and
766 -- attribute reference nodes (all these nodes have an Entity field).
767 -- This field is also present in N_Aggregate, N_Selected_Component, and
768 -- N_Extension_Aggregate nodes. This field is used in generic processing
769 -- to create links between the generic template and the generic copy.
770 -- See Sem_Ch12.Get_Associated_Node for full details. Note that this
771 -- field overlaps Entity, which is fine, since, as explained in Sem_Ch12,
772 -- the normal function of Entity is not required at the point where the
773 -- Associated_Node is set. Note also, that in generic templates, this
774 -- means that the Entity field does not necessarily point to an Entity.
775 -- Since the back end is expected to ignore generic templates, this is
778 -- Atomic_Sync_Required (Flag14-Sem)
779 -- This flag is set on a node for which atomic synchronization is
780 -- required for the corresponding reference or modification.
782 -- At_End_Proc (Node1)
783 -- This field is present in an N_Handled_Sequence_Of_Statements node.
784 -- It contains an identifier reference for the cleanup procedure to be
785 -- called. See description of this node for further details.
787 -- Backwards_OK (Flag6-Sem)
788 -- A flag present in the N_Assignment_Statement node. It is used only
789 -- if the type being assigned is an array type, and is set if analysis
790 -- determines that it is definitely safe to do the copy backwards, i.e.
791 -- starting at the highest addressed element. This is the case if either
792 -- the operands do not overlap, or they may overlap, but if they do,
793 -- then the left operand is at a higher address than the right operand.
795 -- Note: If neither of the flags Forwards_OK or Backwards_OK is set, it
796 -- means that the front end could not determine that either direction is
797 -- definitely safe, and a runtime check may be required if the backend
798 -- cannot figure it out. If both flags Forwards_OK and Backwards_OK are
799 -- set, it means that the front end can assure no overlap of operands.
801 -- Body_To_Inline (Node3-Sem)
802 -- present in subprogram declarations. Denotes analyzed but unexpanded
803 -- body of subprogram, to be used when inlining calls. Present when the
804 -- subprogram has an Inline pragma and inlining is enabled. If the
805 -- declaration is completed by a renaming_as_body, and the renamed en-
806 -- tity is a subprogram, the Body_To_Inline is the name of that entity,
807 -- which is used directly in later calls to the original subprogram.
809 -- Body_Required (Flag13-Sem)
810 -- A flag that appears in the N_Compilation_Unit node indicating that
811 -- the corresponding unit requires a body. For the package case, this
812 -- indicates that a completion is required. In Ada 95, if the flag is not
813 -- set for the package case, then a body may not be present. In Ada 83,
814 -- if the flag is not set for the package case, then body is optional.
815 -- For a subprogram declaration, the flag is set except in the case where
816 -- a pragma Import or Interface applies, in which case no body is
817 -- permitted (in Ada 83 or Ada 95).
819 -- By_Ref (Flag5-Sem)
820 -- Present in N_Simple_Return_Statement and N_Extended_Return_Statement,
821 -- this flag is set when the returned expression is already allocated on
822 -- the secondary stack and thus the result is passed by reference rather
823 -- than copied another time.
825 -- Check_Address_Alignment (Flag11-Sem)
826 -- A flag present in N_Attribute_Definition clause for a 'Address
827 -- attribute definition. This flag is set if a dynamic check should be
828 -- generated at the freeze point for the entity to which this address
829 -- clause applies. The reason that we need this flag is that we want to
830 -- check for range checks being suppressed at the point where the
831 -- attribute definition clause is given, rather than testing this at the
834 -- Comes_From_Extended_Return_Statement (Flag18-Sem)
835 -- Present in N_Simple_Return_Statement nodes. True if this node was
836 -- constructed as part of the N_Extended_Return_Statement expansion.
838 -- Compile_Time_Known_Aggregate (Flag18-Sem)
839 -- Present in N_Aggregate nodes. Set for aggregates which can be fully
840 -- evaluated at compile time without raising constraint error. Such
841 -- aggregates can be passed as is the back end without any expansion.
842 -- See Exp_Aggr for specific conditions under which this flag gets set.
844 -- Componentwise_Assignment (Flag14-Sem)
845 -- Present in N_Assignment_Statement nodes. Set for a record assignment
846 -- where all that needs doing is to expand it into component-by-component
847 -- assignments. This is used internally for the case of tagged types with
848 -- rep clauses, where we need to avoid recursion (we don't want to try to
849 -- generate a call to the primitive operation, because this is the case
850 -- where we are compiling the primitive operation). Note that when we are
851 -- expanding component assignments in this case, we never assign the _tag
852 -- field, but we recursively assign components of the parent type.
854 -- Condition_Actions (List3-Sem)
855 -- This field appears in else-if nodes and in the iteration scheme node
856 -- for while loops. This field is only used during semantic processing to
857 -- temporarily hold actions inserted into the tree. In the tree passed
858 -- to gigi, the condition actions field is always set to No_List. For
859 -- details on how this field is used, see the routine Insert_Actions in
860 -- package Exp_Util, and also the expansion routines for the relevant
863 -- Context_Pending (Flag16-Sem)
864 -- This field appears in Compilation_Unit nodes, to indicate that the
865 -- context of the unit is being compiled. Used to detect circularities
866 -- that are not otherwise detected by the loading mechanism. Such
867 -- circularities can occur in the presence of limited and non-limited
868 -- with_clauses that mention the same units.
870 -- Controlling_Argument (Node1-Sem)
871 -- This field is set in procedure and function call nodes if the call
872 -- is a dispatching call (it is Empty for a non-dispatching call). It
873 -- indicates the source of the call's controlling tag. For procedure
874 -- calls, the Controlling_Argument is one of the actuals. For function
875 -- that has a dispatching result, it is an entity in the context of the
876 -- call that can provide a tag, or else it is the tag of the root type
877 -- of the class. It can also specify a tag directly rather than being a
878 -- tagged object. The latter is needed by the implementations of AI-239
881 -- Conversion_OK (Flag14-Sem)
882 -- A flag set on type conversion nodes to indicate that the conversion
883 -- is to be considered as being valid, even though it is the case that
884 -- the conversion is not valid Ada. This is used for attributes Enum_Rep,
885 -- Fixed_Value and Integer_Value, for internal conversions done for
886 -- fixed-point operations, and for certain conversions for calls to
887 -- initialization procedures. If Conversion_OK is set, then Etype must be
888 -- set (the analyzer assumes that Etype has been set). For the case of
889 -- fixed-point operands, it also indicates that the conversion is to be
890 -- direct conversion of the underlying integer result, with no regard to
891 -- the small operand.
893 -- Convert_To_Return_False (Flag13-Sem)
894 -- Present in N_Raise_Expression nodes that appear in the body of the
895 -- special predicateM function used to test a predicate in the context
896 -- of a membership test, where raise expression results in returning a
897 -- value of False rather than raising an exception.
899 -- Corresponding_Aspect (Node3-Sem)
900 -- Present in N_Pragma node. Used to point back to the source aspect from
901 -- the corresponding pragma. This field is Empty for source pragmas.
903 -- Corresponding_Body (Node5-Sem)
904 -- This field is set in subprogram declarations, package declarations,
905 -- entry declarations of protected types, and in generic units. It points
906 -- to the defining entity for the corresponding body (NOT the node for
909 -- Corresponding_Formal_Spec (Node3-Sem)
910 -- This field is set in subprogram renaming declarations, where it points
911 -- to the defining entity for a formal subprogram in the case where the
912 -- renaming corresponds to a generic formal subprogram association in an
913 -- instantiation. The field is Empty if the renaming does not correspond
914 -- to such a formal association.
916 -- Corresponding_Generic_Association (Node5-Sem)
917 -- This field is defined for object declarations and object renaming
918 -- declarations. It is set for the declarations within an instance that
919 -- map generic formals to their actuals. If set, the field points to
920 -- a generic_association which is the original parent of the expression
921 -- or name appearing in the declaration. This simplifies ASIS queries.
923 -- Corresponding_Integer_Value (Uint4-Sem)
924 -- This field is set in real literals of fixed-point types (it is not
925 -- used for floating-point types). It contains the integer value used
926 -- to represent the fixed-point value. It is also set on the universal
927 -- real literals used to represent bounds of fixed-point base types
928 -- and their first named subtypes.
930 -- Corresponding_Spec (Node5-Sem)
931 -- This field is set in subprogram, package, task, and protected body
932 -- nodes, where it points to the defining entity in the corresponding
933 -- spec. The attribute is also set in N_With_Clause nodes where it points
934 -- to the defining entity for the with'ed spec, and in a subprogram
935 -- renaming declaration when it is a Renaming_As_Body. The field is Empty
936 -- if there is no corresponding spec, as in the case of a subprogram body
937 -- that serves as its own spec.
939 -- In Ada 2012, Corresponding_Spec is set on expression functions that
940 -- complete a subprogram declaration.
942 -- Corresponding_Spec_Of_Stub (Node2-Sem)
943 -- This field is present in subprogram, package, task and protected body
944 -- stubs where it points to the corresponding spec of the stub. Due to
945 -- clashes in the structure of nodes, we cannot use Corresponding_Spec.
947 -- Corresponding_Stub (Node3-Sem)
948 -- This field is present in an N_Subunit node. It holds the node in
949 -- the parent unit that is the stub declaration for the subunit. It is
950 -- set when analysis of the stub forces loading of the proper body. If
951 -- expansion of the proper body creates new declarative nodes, they are
952 -- inserted at the point of the corresponding_stub.
954 -- Dcheck_Function (Node5-Sem)
955 -- This field is present in an N_Variant node, It references the entity
956 -- for the discriminant checking function for the variant.
958 -- Default_Expression (Node5-Sem)
959 -- This field is Empty if there is no default expression. If there is a
960 -- simple default expression (one with no side effects), then this field
961 -- simply contains a copy of the Expression field (both point to the tree
962 -- for the default expression). Default_Expression is used for
963 -- conformance checking.
965 -- Default_Storage_Pool (Node3-Sem)
966 -- This field is present in N_Compilation_Unit_Aux nodes. It is set to a
967 -- copy of Opt.Default_Pool at the end of the compilation unit. See
968 -- package Opt for details. This is used for inheriting the
969 -- Default_Storage_Pool in child units.
971 -- Discr_Check_Funcs_Built (Flag11-Sem)
972 -- This flag is present in N_Full_Type_Declaration nodes. It is set when
973 -- discriminant checking functions are constructed. The purpose is to
974 -- avoid attempting to set these functions more than once.
976 -- Do_Accessibility_Check (Flag13-Sem)
977 -- This flag is set on N_Parameter_Specification nodes to indicate
978 -- that an accessibility check is required for the parameter. It is
979 -- not yet decided who takes care of this check (TBD ???).
981 -- Do_Discriminant_Check (Flag1-Sem)
982 -- This flag is set on N_Selected_Component nodes to indicate that a
983 -- discriminant check is required using the discriminant check routine
984 -- associated with the selector. The actual check is generated by the
985 -- expander when processing selected components. In the case of
986 -- Unchecked_Union, the flag is also set, but no discriminant check
987 -- routine is associated with the selector, and the expander does not
988 -- generate a check. This flag is also present in assignment statements
989 -- (and set if the assignment requires a discriminant check), and in type
990 -- conversion nodes (and set if the conversion requires a check).
992 -- Do_Division_Check (Flag13-Sem)
993 -- This flag is set on a division operator (/ mod rem) to indicate
994 -- that a zero divide check is required. The actual check is dealt
995 -- with by the backend (all the front end does is to set the flag).
997 -- Do_Length_Check (Flag4-Sem)
998 -- This flag is set in an N_Assignment_Statement, N_Op_And, N_Op_Or,
999 -- N_Op_Xor, or N_Type_Conversion node to indicate that a length check
1000 -- is required. It is not determined who deals with this flag (???).
1002 -- Do_Overflow_Check (Flag17-Sem)
1003 -- This flag is set on an operator where an overflow check is required on
1004 -- the operation. The actual check is dealt with by the backend (all the
1005 -- front end does is to set the flag). The other cases where this flag is
1006 -- used is on a Type_Conversion node and for attribute reference nodes.
1007 -- For a type conversion, it means that the conversion is from one base
1008 -- type to another, and the value may not fit in the target base type.
1009 -- See also the description of Do_Range_Check for this case. The only
1010 -- attribute references which use this flag are Pred and Succ, where it
1011 -- means that the result should be checked for going outside the base
1012 -- range. Note that this flag is not set for modular types. This flag is
1013 -- also set on if and case expression nodes if we are operating in either
1014 -- MINIMIZED or ELIMINATED overflow checking mode (to make sure that we
1015 -- properly process overflow checking for dependent expressions).
1017 -- Do_Range_Check (Flag9-Sem)
1018 -- This flag is set on an expression which appears in a context where a
1019 -- range check is required. The target type is clear from the context.
1020 -- The contexts in which this flag can appear are the following:
1022 -- Right side of an assignment. In this case the target type is
1023 -- taken from the left side of the assignment, which is referenced
1024 -- by the Name of the N_Assignment_Statement node.
1026 -- Subscript expressions in an indexed component. In this case the
1027 -- target type is determined from the type of the array, which is
1028 -- referenced by the Prefix of the N_Indexed_Component node.
1030 -- Argument expression for a parameter, appearing either directly in
1031 -- the Parameter_Associations list of a call or as the Expression of an
1032 -- N_Parameter_Association node that appears in this list. In either
1033 -- case, the check is against the type of the formal. Note that the
1034 -- flag is relevant only in IN and IN OUT parameters, and will be
1035 -- ignored for OUT parameters, where no check is required in the call,
1036 -- and if a check is required on the return, it is generated explicitly
1037 -- with a type conversion.
1039 -- Initialization expression for the initial value in an object
1040 -- declaration. In this case the Do_Range_Check flag is set on
1041 -- the initialization expression, and the check is against the
1042 -- range of the type of the object being declared.
1044 -- The expression of a type conversion. In this case the range check is
1045 -- against the target type of the conversion. See also the use of
1046 -- Do_Overflow_Check on a type conversion. The distinction is that the
1047 -- overflow check protects against a value that is outside the range of
1048 -- the target base type, whereas a range check checks that the
1049 -- resulting value (which is a value of the base type of the target
1050 -- type), satisfies the range constraint of the target type.
1052 -- Note: when a range check is required in contexts other than those
1053 -- listed above (e.g. in a return statement), an additional type
1054 -- conversion node is introduced to represent the required check.
1056 -- A special case arises for the arguments of the Pred/Succ attributes.
1057 -- Here the range check needed is against First + 1 .. Last (Pred) or
1058 -- First .. Last - 1 (Succ) of the corresponding base type. Essentially
1059 -- these checks are what would be performed within the implicit body of
1060 -- the functions that correspond to these attributes. In these cases,
1061 -- the Do_Range check flag is set on the argument to the attribute
1062 -- function, and the back end must special case the appropriate range
1063 -- to check against.
1065 -- Do_Storage_Check (Flag17-Sem)
1066 -- This flag is set in an N_Allocator node to indicate that a storage
1067 -- check is required for the allocation, or in an N_Subprogram_Body node
1068 -- to indicate that a stack check is required in the subprogram prolog.
1069 -- The N_Allocator case is handled by the routine that expands the call
1070 -- to the runtime routine. The N_Subprogram_Body case is handled by the
1071 -- backend, and all the semantics does is set the flag.
1073 -- Do_Tag_Check (Flag13-Sem)
1074 -- This flag is set on an N_Assignment_Statement, N_Function_Call,
1075 -- N_Procedure_Call_Statement, N_Type_Conversion,
1076 -- N_Simple_Return_Statement, or N_Extended_Return_Statement
1077 -- node to indicate that the tag check can be suppressed. It is not
1078 -- yet decided how this flag is used (TBD ???).
1080 -- Elaborate_Present (Flag4-Sem)
1081 -- This flag is set in the N_With_Clause node to indicate that pragma
1082 -- Elaborate pragma appears for the with'ed units.
1084 -- Elaborate_All_Desirable (Flag9-Sem)
1085 -- This flag is set in the N_With_Clause mode to indicate that the static
1086 -- elaboration processing has determined that an Elaborate_All pragma is
1087 -- desirable for correct elaboration for this unit.
1089 -- Elaborate_All_Present (Flag14-Sem)
1090 -- This flag is set in the N_With_Clause node to indicate that a
1091 -- pragma Elaborate_All pragma appears for the with'ed units.
1093 -- Elaborate_Desirable (Flag11-Sem)
1094 -- This flag is set in the N_With_Clause mode to indicate that the static
1095 -- elaboration processing has determined that an Elaborate pragma is
1096 -- desirable for correct elaboration for this unit.
1098 -- Elaboration_Boolean (Node2-Sem)
1099 -- This field is present in function and procedure specification nodes.
1100 -- If set, it points to the entity for a Boolean flag that must be tested
1101 -- for certain calls to check for access before elaboration. See body of
1102 -- Sem_Elab for further details. This field is Empty if no elaboration
1103 -- boolean is required.
1105 -- Else_Actions (List3-Sem)
1106 -- This field is present in if expression nodes. During code
1107 -- expansion we use the Insert_Actions procedure (in Exp_Util) to insert
1108 -- actions at an appropriate place in the tree to get elaborated at the
1109 -- right time. For if expressions, we have to be sure that the actions
1110 -- for the Else branch are only elaborated if the condition is False.
1111 -- The Else_Actions field is used as a temporary parking place for
1112 -- these actions. The final tree is always rewritten to eliminate the
1113 -- need for this field, so in the tree passed to Gigi, this field is
1114 -- always set to No_List.
1116 -- Enclosing_Variant (Node2-Sem)
1117 -- This field is present in the N_Variant node and identifies the Node_Id
1118 -- corresponding to the immediately enclosing variant when the variant is
1119 -- nested, and N_Empty otherwise. Set during semantic processing of the
1120 -- variant part of a record type.
1122 -- Entity (Node4-Sem)
1123 -- Appears in all direct names (identifiers, character literals, and
1124 -- operator symbols), as well as expanded names, and attributes that
1125 -- denote entities, such as 'Class. Points to entity for corresponding
1126 -- defining occurrence. Set after name resolution. For identifiers in a
1127 -- WITH list, the corresponding defining occurrence is in a separately
1128 -- compiled file, and Entity must be set by the library Load procedure.
1130 -- Note: During name resolution, the value in Entity may be temporarily
1131 -- incorrect (e.g. during overload resolution, Entity is initially set to
1132 -- the first possible correct interpretation, and then later modified if
1133 -- necessary to contain the correct value after resolution).
1135 -- Note: This field overlaps Associated_Node, which is used during
1136 -- generic processing (see Sem_Ch12 for details). Note also that in
1137 -- generic templates, this means that the Entity field does not always
1138 -- point to an Entity. Since the back end is expected to ignore generic
1139 -- templates, this is harmless.
1141 -- Note: This field also appears in N_Attribute_Definition_Clause nodes.
1142 -- It is used only for stream attributes definition clauses. In this
1143 -- case, it denotes a (possibly dummy) subprogram entity that is declared
1144 -- conceptually at the point of the clause. Thus the visibility of the
1145 -- attribute definition clause (in the sense of 8.3(23) as amended by
1146 -- AI-195) can be checked by testing the visibility of that subprogram.
1148 -- Note: Normally the Entity field of an identifier points to the entity
1149 -- for the corresponding defining identifier, and hence the Chars field
1150 -- of an identifier will match the Chars field of the entity. However,
1151 -- there is no requirement that these match, and there are obscure cases
1152 -- of generated code where they do not match.
1154 -- Note: Ada 2012 aspect specifications require additional links between
1155 -- identifiers and various attributes. These attributes can be of
1156 -- arbitrary types, and the entity field of identifiers that denote
1157 -- aspects must be used to store arbitrary expressions for later semantic
1158 -- checks. See section on aspect specifications for details.
1160 -- Entity_Or_Associated_Node (Node4-Sem)
1161 -- A synonym for both Entity and Associated_Node. Used by convention in
1162 -- the code when referencing this field in cases where it is not known
1163 -- whether the field contains an Entity or an Associated_Node.
1165 -- Etype (Node5-Sem)
1166 -- Appears in all expression nodes, all direct names, and all entities.
1167 -- Points to the entity for the related type. Set after type resolution.
1168 -- Normally this is the actual subtype of the expression. However, in
1169 -- certain contexts such as the right side of an assignment, subscripts,
1170 -- arguments to calls, returned value in a function, initial value etc.
1171 -- it is the desired target type. In the event that this is different
1172 -- from the actual type, the Do_Range_Check flag will be set if a range
1173 -- check is required. Note: if the Is_Overloaded flag is set, then Etype
1174 -- points to an essentially arbitrary choice from the possible set of
1177 -- Exception_Junk (Flag8-Sem)
1178 -- This flag is set in a various nodes appearing in a statement sequence
1179 -- to indicate that the corresponding node is an artifact of the
1180 -- generated code for exception handling, and should be ignored when
1181 -- analyzing the control flow of the relevant sequence of statements
1182 -- (e.g. to check that it does not end with a bad return statement).
1184 -- Exception_Label (Node5-Sem)
1185 -- Appears in N_Push_xxx_Label nodes. Points to the entity of the label
1186 -- to be used for transforming the corresponding exception into a goto,
1187 -- or contains Empty, if this exception is not to be transformed. Also
1188 -- appears in N_Exception_Handler nodes, where, if set, it indicates
1189 -- that there may be a local raise for the handler, so that expansion
1190 -- to allow a goto is required (and this field contains the label for
1191 -- this goto). See Exp_Ch11.Expand_Local_Exception_Handlers for details.
1193 -- Expansion_Delayed (Flag11-Sem)
1194 -- Set on aggregates and extension aggregates that need a top-down rather
1195 -- than bottom-up expansion. Typically aggregate expansion happens bottom
1196 -- up. For nested aggregates the expansion is delayed until the enclosing
1197 -- aggregate itself is expanded, e.g. in the context of a declaration. To
1198 -- delay it we set this flag. This is done to avoid creating a temporary
1199 -- for each level of a nested aggregates, and also to prevent the
1200 -- premature generation of constraint checks. This is also a requirement
1201 -- if we want to generate the proper attachment to the internal
1202 -- finalization lists (for record with controlled components). Top down
1203 -- expansion of aggregates is also used for in-place array aggregate
1204 -- assignment or initialization. When the full context is known, the
1205 -- target of the assignment or initialization is used to generate the
1206 -- left-hand side of individual assignment to each sub-component.
1208 -- First_Inlined_Subprogram (Node3-Sem)
1209 -- Present in the N_Compilation_Unit node for the main program. Points
1210 -- to a chain of entities for subprograms that are to be inlined. The
1211 -- Next_Inlined_Subprogram field of these entities is used as a link
1212 -- pointer with Empty marking the end of the list. This field is Empty
1213 -- if there are no inlined subprograms or inlining is not active.
1215 -- First_Named_Actual (Node4-Sem)
1216 -- Present in procedure call statement and function call nodes, and also
1217 -- in Intrinsic nodes. Set during semantic analysis to point to the first
1218 -- named parameter where parameters are ordered by declaration order (as
1219 -- opposed to the actual order in the call which may be different due to
1220 -- named associations). Note: this field points to the explicit actual
1221 -- parameter itself, not the N_Parameter_Association node (its parent).
1223 -- First_Real_Statement (Node2-Sem)
1224 -- Present in N_Handled_Sequence_Of_Statements node. Normally set to
1225 -- Empty. Used only when declarations are moved into the statement part
1226 -- of a construct as a result of wrapping an AT END handler that is
1227 -- required to cover the declarations. In this case, this field is used
1228 -- to remember the location in the statements list of the first real
1229 -- statement, i.e. the statement that used to be first in the statement
1230 -- list before the declarations were prepended.
1232 -- First_Subtype_Link (Node5-Sem)
1233 -- Present in N_Freeze_Entity node for an anonymous base type that is
1234 -- implicitly created by the declaration of a first subtype. It points
1235 -- to the entity for the first subtype.
1237 -- Float_Truncate (Flag11-Sem)
1238 -- A flag present in type conversion nodes. This is used for float to
1239 -- integer conversions where truncation is required rather than rounding.
1240 -- Note that Gigi does not handle type conversions from real to integer
1241 -- with rounding (see Expand_N_Type_Conversion).
1243 -- Forwards_OK (Flag5-Sem)
1244 -- A flag present in the N_Assignment_Statement node. It is used only
1245 -- if the type being assigned is an array type, and is set if analysis
1246 -- determines that it is definitely safe to do the copy forwards, i.e.
1247 -- starting at the lowest addressed element. This is the case if either
1248 -- the operands do not overlap, or they may overlap, but if they do,
1249 -- then the left operand is at a lower address than the right operand.
1251 -- Note: If neither of the flags Forwards_OK or Backwards_OK is set, it
1252 -- means that the front end could not determine that either direction is
1253 -- definitely safe, and a runtime check may be required if the backend
1254 -- cannot figure it out. If both flags Forwards_OK and Backwards_OK are
1255 -- set, it means that the front end can assure no overlap of operands.
1257 -- From_Aspect_Specification (Flag13-Sem)
1258 -- Processing of aspect specifications typically results in insertion in
1259 -- the tree of corresponding pragma or attribute definition clause nodes.
1260 -- These generated nodes have the From_Aspect_Specification flag set to
1261 -- indicate that they came from aspect specifications originally.
1263 -- From_At_End (Flag4-Sem)
1264 -- This flag is set on an N_Raise_Statement node if it corresponds to
1265 -- the reraise statement generated as the last statement of an AT END
1266 -- handler when SJLJ exception handling is active. It is used to stop
1267 -- a bogus violation of restriction (No_Exception_Propagation), bogus
1268 -- because if the restriction is set, the reraise is not generated.
1270 -- From_At_Mod (Flag4-Sem)
1271 -- This flag is set on the attribute definition clause node that is
1272 -- generated by a transformation of an at mod phrase in a record
1273 -- representation clause. This is used to give slightly different (Ada 83
1274 -- compatible) semantics to such a clause, namely it is used to specify a
1275 -- minimum acceptable alignment for the base type and all subtypes. In
1276 -- Ada 95 terms, the actual alignment of the base type and all subtypes
1277 -- must be a multiple of the given value, and the representation clause
1278 -- is considered to be type specific instead of subtype specific.
1280 -- From_Default (Flag6-Sem)
1281 -- This flag is set on the subprogram renaming declaration created in an
1282 -- instance for a formal subprogram, when the formal is declared with a
1283 -- box, and there is no explicit actual. If the flag is present, the
1284 -- declaration is treated as an implicit reference to the formal in the
1287 -- Generalized_Indexing (Node4-Sem)
1288 -- Present in N_Indexed_Component nodes. Set for Indexed_Component nodes
1289 -- that are Ada 2012 container indexing operations. The value of the
1290 -- attribute is a function call (possibly dereferenced) that corresponds
1291 -- to the proper expansion of the source indexing operation. Before
1292 -- expansion, the source node is rewritten as the resolved generalized
1293 -- indexing. In ASIS mode, the expansion does not take place, so that
1294 -- the source is preserved and properly annotated with types.
1296 -- Generic_Parent (Node5-Sem)
1297 -- Generic_Parent is defined on declaration nodes that are instances. The
1298 -- value of Generic_Parent is the generic entity from which the instance
1299 -- is obtained. Generic_Parent is also defined for the renaming
1300 -- declarations and object declarations created for the actuals in an
1301 -- instantiation. The generic parent of such a declaration is the
1302 -- corresponding generic association in the Instantiation node.
1304 -- Generic_Parent_Type (Node4-Sem)
1305 -- Generic_Parent_Type is defined on Subtype_Declaration nodes for the
1306 -- actuals of formal private and derived types. Within the instance, the
1307 -- operations on the actual are those inherited from the parent. For a
1308 -- formal private type, the parent type is the generic type itself. The
1309 -- Generic_Parent_Type is also used in an instance to determine whether a
1310 -- private operation overrides an inherited one.
1312 -- Handler_List_Entry (Node2-Sem)
1313 -- This field is present in N_Object_Declaration nodes. It is set only
1314 -- for the Handler_Record entry generated for an exception in zero cost
1315 -- exception handling mode. It references the corresponding item in the
1316 -- handler list, and is used to delete this entry if the corresponding
1317 -- handler is deleted during optimization. For further details on why
1318 -- this is required, see Exp_Ch11.Remove_Handler_Entries.
1320 -- Has_Dereference_Action (Flag13-Sem)
1321 -- This flag is present in N_Explicit_Dereference nodes. It is set to
1322 -- indicate that the expansion has aready produced a call to primitive
1323 -- Dereference of a System.Checked_Pools.Checked_Pool implementation.
1324 -- Such dereference actions are produced for debugging purposes.
1326 -- Has_Dynamic_Length_Check (Flag10-Sem)
1327 -- This flag is present in all expression nodes. It is set to indicate
1328 -- that one of the routines in unit Checks has generated a length check
1329 -- action which has been inserted at the flagged node. This is used to
1330 -- avoid the generation of duplicate checks.
1332 -- Has_Dynamic_Range_Check (Flag12-Sem)
1333 -- This flag is present in N_Subtype_Declaration nodes and on all
1334 -- expression nodes. It is set to indicate that one of the routines in
1335 -- unit Checks has generated a range check action which has been inserted
1336 -- at the flagged node. This is used to avoid the generation of duplicate
1337 -- checks. Why does this occur on N_Subtype_Declaration nodes, what does
1338 -- it mean in that context???
1340 -- Has_Local_Raise (Flag8-Sem)
1341 -- Present in exception handler nodes. Set if the handler can be entered
1342 -- via a local raise that gets transformed to a goto statement. This will
1343 -- always be set if Local_Raise_Statements is non-empty, but can also be
1344 -- set as a result of generation of N_Raise_xxx nodes, or flags set in
1345 -- nodes requiring generation of back end checks.
1347 -- Has_No_Elaboration_Code (Flag17-Sem)
1348 -- A flag that appears in the N_Compilation_Unit node to indicate whether
1349 -- or not elaboration code is present for this unit. It is initially set
1350 -- true for subprogram specs and bodies and for all generic units and
1351 -- false for non-generic package specs and bodies. Gigi may set the flag
1352 -- in the non-generic package case if it determines that no elaboration
1353 -- code is generated. Note that this flag is not related to the
1354 -- Is_Preelaborated status, there can be preelaborated packages that
1355 -- generate elaboration code, and non-preelaborated packages which do
1356 -- not generate elaboration code.
1358 -- Has_Pragma_Suppress_All (Flag14-Sem)
1359 -- This flag is set in an N_Compilation_Unit node if the Suppress_All
1360 -- pragma appears anywhere in the unit. This accommodates the rather
1361 -- strange placement rules of other compilers (DEC permits it at the
1362 -- end of a unit, and Rational allows it as a program unit pragma). We
1363 -- allow it anywhere at all, and consider it equivalent to a pragma
1364 -- Suppress (All_Checks) appearing at the start of the configuration
1365 -- pragmas for the unit.
1367 -- Has_Private_View (Flag11-Sem)
1368 -- A flag present in generic nodes that have an entity, to indicate that
1369 -- the node has a private type. Used to exchange private and full
1370 -- declarations if the visibility at instantiation is different from the
1371 -- visibility at generic definition.
1373 -- Has_Relative_Deadline_Pragma (Flag9-Sem)
1374 -- A flag present in N_Subprogram_Body and N_Task_Definition nodes to
1375 -- flag the presence of a pragma Relative_Deadline.
1377 -- Has_Self_Reference (Flag13-Sem)
1378 -- Present in N_Aggregate and N_Extension_Aggregate. Indicates that one
1379 -- of the expressions contains an access attribute reference to the
1380 -- enclosing type. Such a self-reference can only appear in default-
1381 -- initialized aggregate for a record type.
1383 -- Has_SP_Choice (Flag15-Sem)
1384 -- Present in all nodes containing a Discrete_Choices field (N_Variant,
1385 -- N_Case_Expression_Alternative, N_Case_Statement_Alternative). Set to
1386 -- True if the Discrete_Choices list has at least one occurrence of a
1387 -- statically predicated subtype.
1389 -- Has_Storage_Size_Pragma (Flag5-Sem)
1390 -- A flag present in an N_Task_Definition node to flag the presence of a
1391 -- Storage_Size pragma.
1393 -- Has_Wide_Character (Flag11-Sem)
1394 -- Present in string literals, set if any wide character (i.e. character
1395 -- code outside the Character range but within Wide_Character range)
1396 -- appears in the string. Used to implement pragma preference rules.
1398 -- Has_Wide_Wide_Character (Flag13-Sem)
1399 -- Present in string literals, set if any wide character (i.e. character
1400 -- code outside the Wide_Character range) appears in the string. Used to
1401 -- implement pragma preference rules.
1403 -- Header_Size_Added (Flag11-Sem)
1404 -- Present in N_Attribute_Reference nodes, set only for attribute
1405 -- Max_Size_In_Storage_Elements. The flag indicates that the size of the
1406 -- hidden list header used by the runtime finalization support has been
1407 -- added to the size of the prefix. The flag also prevents the infinite
1408 -- expansion of the same attribute in the said context.
1410 -- Hidden_By_Use_Clause (Elist4-Sem)
1411 -- An entity list present in use clauses that appear within
1412 -- instantiations. For the resolution of local entities, entities
1413 -- introduced by these use clauses have priority over global ones, and
1414 -- outer entities must be explicitly hidden/restored on exit.
1416 -- Implicit_With (Flag16-Sem)
1417 -- This flag is set in the N_With_Clause node that is implicitly
1418 -- generated for runtime units that are loaded by the expander, and also
1419 -- for package System, if it is loaded implicitly by a use of the
1420 -- 'Address or 'Tag attribute. ???There are other implicit with clauses
1423 -- Implicit_With_From_Instantiation (Flag12-Sem)
1424 -- Set in N_With_Clause nodes from generic instantiations.
1426 -- Import_Interface_Present (Flag16-Sem)
1427 -- This flag is set in an Interface or Import pragma if a matching
1428 -- pragma of the other kind is also present. This is used to avoid
1429 -- generating some unwanted error messages.
1431 -- Includes_Infinities (Flag11-Sem)
1432 -- This flag is present in N_Range nodes. It is set for the range of
1433 -- unconstrained float types defined in Standard, which include not only
1434 -- the given range of values, but also legitimately can include infinite
1435 -- values. This flag is false for any float type for which an explicit
1436 -- range is given by the programmer, even if that range is identical to
1437 -- the range for Float.
1439 -- Inherited_Discriminant (Flag13-Sem)
1440 -- This flag is present in N_Component_Association nodes. It indicates
1441 -- that a given component association in an extension aggregate is the
1442 -- value obtained from a constraint on an ancestor. Used to prevent
1443 -- double expansion when the aggregate has expansion delayed.
1445 -- Instance_Spec (Node5-Sem)
1446 -- This field is present in generic instantiation nodes, and also in
1447 -- formal package declaration nodes (formal package declarations are
1448 -- treated in a manner very similar to package instantiations). It points
1449 -- to the node for the spec of the instance, inserted as part of the
1450 -- semantic processing for instantiations in Sem_Ch12.
1452 -- Is_Accessibility_Actual (Flag13-Sem)
1453 -- Present in N_Parameter_Association nodes. True if the parameter is
1454 -- an extra actual that carries the accessibility level of the actual
1455 -- for an access parameter, in a function that dispatches on result and
1456 -- is called in a dispatching context. Used to prevent a formal/actual
1457 -- mismatch when the call is rewritten as a dispatching call.
1459 -- Is_Asynchronous_Call_Block (Flag7-Sem)
1460 -- A flag set in a Block_Statement node to indicate that it is the
1461 -- expansion of an asynchronous entry call. Such a block needs cleanup
1462 -- handler to assure that the call is cancelled.
1464 -- Is_Boolean_Aspect (Flag16-Sem)
1465 -- Present in N_Aspect_Specification node. Set if the aspect is for a
1466 -- boolean aspect (i.e. Aspect_Id is in Boolean_Aspect subtype).
1468 -- Is_Checked (Flag11-Sem)
1469 -- Present in N_Aspect_Specification and N_Pragma nodes. Set for an
1470 -- assertion aspect or pragma, or check pragma for an assertion, that
1471 -- is to be checked at run time. If either Is_Checked or Is_Ignored
1472 -- is set (they cannot both be set), then this means that the status of
1473 -- the pragma has been checked at the appropriate point and should not
1474 -- be further modified (in some cases these flags are copied when a
1475 -- pragma is rewritten).
1477 -- Is_Component_Left_Opnd (Flag13-Sem)
1478 -- Is_Component_Right_Opnd (Flag14-Sem)
1479 -- Present in concatenation nodes, to indicate that the corresponding
1480 -- operand is of the component type of the result. Used in resolving
1481 -- concatenation nodes in instances.
1483 -- Is_Delayed_Aspect (Flag14-Sem)
1484 -- Present in N_Pragma and N_Attribute_Definition_Clause nodes which
1485 -- come from aspect specifications, where the evaluation of the aspect
1486 -- must be delayed to the freeze point. This flag is also set True in
1487 -- the corresponding N_Aspect_Specification node.
1489 -- Is_Controlling_Actual (Flag16-Sem)
1490 -- This flag is set on in an expression that is a controlling argument in
1491 -- a dispatching call. It is off in all other cases. See Sem_Disp for
1492 -- details of its use.
1494 -- Is_Disabled (Flag15-Sem)
1495 -- A flag set in an N_Aspect_Specification or N_Pragma node if there was
1496 -- a Check_Policy or Assertion_Policy (or in the case of a Debug_Pragma)
1497 -- a Debug_Policy pragma that resulted in totally disabling the flagged
1498 -- aspect or policy as a result of using the GNAT-defined policy DISABLE.
1499 -- If this flag is set, the aspect or policy is not analyzed for semantic
1500 -- correctness, so any expressions etc will not be marked as analyzed.
1502 -- Is_Dynamic_Coextension (Flag18-Sem)
1503 -- Present in allocator nodes, to indicate that this is an allocator
1504 -- for an access discriminant of a dynamically allocated object. The
1505 -- coextension must be deallocated and finalized at the same time as
1506 -- the enclosing object.
1508 -- Is_Entry_Barrier_Function (Flag8-Sem)
1509 -- This flag is set in an N_Subprogram_Body node which is the expansion
1510 -- of an entry barrier from a protected entry body. It is used for the
1511 -- circuitry checking for incorrect use of Current_Task.
1513 -- Is_Expanded_Build_In_Place_Call (Flag11-Sem)
1514 -- This flag is set in an N_Function_Call node to indicate that the extra
1515 -- actuals to support a build-in-place style of call have been added to
1518 -- Is_Finalization_Wrapper (Flag9-Sem);
1519 -- This flag is present in N_Block_Statement nodes. It is set when the
1520 -- block acts as a wrapper of a handled construct which has controlled
1521 -- objects. The wrapper prevents interference between exception handlers
1522 -- and At_End handlers.
1524 -- Is_Ignored (Flag9-Sem)
1525 -- A flag set in an N_Aspect_Specification or N_Pragma node if there was
1526 -- a Check_Policy or Assertion_Policy (or in the case of a Debug_Pragma)
1527 -- a Debug_Policy pragma that specified a policy of IGNORE, DISABLE, or
1528 -- OFF, for the pragma/aspect. If there was a Policy pragma specifying
1529 -- a Policy of ON or CHECK, then this flag is reset. If no Policy pragma
1530 -- gives a policy for the aspect or pragma, then there are two cases. For
1531 -- an assertion aspect or pragma (one of the assertion kinds allowed in
1532 -- an Assertion_Policy pragma), then Is_Ignored is set if assertions are
1533 -- ignored because of the absence of a -gnata switch. For any other
1534 -- aspects or pragmas, the flag is off. If this flag is set, the
1535 -- aspect/pragma is fully analyzed and checked for other syntactic
1536 -- and semantic errors, but it does not have any semantic effect.
1538 -- Is_In_Discriminant_Check (Flag11-Sem)
1539 -- This flag is present in a selected component, and is used to indicate
1540 -- that the reference occurs within a discriminant check. The
1541 -- significance is that optimizations based on assuming that the
1542 -- discriminant check has a correct value cannot be performed in this
1543 -- case (or the discriminant check may be optimized away).
1545 -- Is_Machine_Number (Flag11-Sem)
1546 -- This flag is set in an N_Real_Literal node to indicate that the value
1547 -- is a machine number. This avoids some unnecessary cases of converting
1548 -- real literals to machine numbers.
1550 -- Is_Null_Loop (Flag16-Sem)
1551 -- This flag is set in an N_Loop_Statement node if the corresponding loop
1552 -- can be determined to be null at compile time. This is used to remove
1553 -- the loop entirely at expansion time.
1555 -- Is_Overloaded (Flag5-Sem)
1556 -- A flag present in all expression nodes. Used temporarily during
1557 -- overloading determination. The setting of this flag is not relevant
1558 -- once overloading analysis is complete.
1560 -- Is_Power_Of_2_For_Shift (Flag13-Sem)
1561 -- A flag present only in N_Op_Expon nodes. It is set when the
1562 -- exponentiation is of the form 2 ** N, where the type of N is an
1563 -- unsigned integral subtype whose size does not exceed the size of
1564 -- Standard_Integer (i.e. a type that can be safely converted to
1565 -- Natural), and the exponentiation appears as the right operand of an
1566 -- integer multiplication or an integer division where the dividend is
1567 -- unsigned. It is also required that overflow checking is off for both
1568 -- the exponentiation and the multiply/divide node. If this set of
1569 -- conditions holds, and the flag is set, then the division or
1570 -- multiplication can be (and is) converted to a shift.
1572 -- Is_Prefixed_Call (Flag17-Sem)
1573 -- This flag is set in a selected component within a generic unit, if
1574 -- it resolves to a prefixed call to a primitive operation. The flag
1575 -- is used to prevent accidental overloadings in an instance, when a
1576 -- primitive operation and a private record component may be homographs.
1578 -- Is_Protected_Subprogram_Body (Flag7-Sem)
1579 -- A flag set in a Subprogram_Body block to indicate that it is the
1580 -- implementation of a protected subprogram. Such a body needs cleanup
1581 -- handler to make sure that the associated protected object is unlocked
1582 -- when the subprogram completes.
1584 -- Is_Static_Coextension (Flag14-Sem)
1585 -- Present in N_Allocator nodes. Set if the allocator is a coextension
1586 -- of an object allocated on the stack rather than the heap.
1588 -- Is_Static_Expression (Flag6-Sem)
1589 -- Indicates that an expression is a static expression (RM 4.9). See spec
1590 -- of package Sem_Eval for full details on the use of this flag.
1592 -- Is_Subprogram_Descriptor (Flag16-Sem)
1593 -- Present in N_Object_Declaration, and set only for the object
1594 -- declaration generated for a subprogram descriptor in fast exception
1595 -- mode. See Exp_Ch11 for details of use.
1597 -- Is_Task_Allocation_Block (Flag6-Sem)
1598 -- A flag set in a Block_Statement node to indicate that it is the
1599 -- expansion of a task allocator, or the allocator of an object
1600 -- containing tasks. Such a block requires a cleanup handler to call
1601 -- Expunge_Unactivated_Tasks to complete any tasks that have been
1602 -- allocated but not activated when the allocator completes abnormally.
1604 -- Is_Task_Master (Flag5-Sem)
1605 -- A flag set in a Subprogram_Body, Block_Statement or Task_Body node to
1606 -- indicate that the construct is a task master (i.e. has declared tasks
1607 -- or declares an access to a task type).
1609 -- Itype (Node1-Sem)
1610 -- Used in N_Itype_Reference node to reference an itype for which it is
1611 -- important to ensure that it is defined. See description of this node
1612 -- for further details.
1614 -- Kill_Range_Check (Flag11-Sem)
1615 -- Used in an N_Unchecked_Type_Conversion node to indicate that the
1616 -- result should not be subjected to range checks. This is used for the
1617 -- implementation of Normalize_Scalars.
1619 -- Label_Construct (Node2-Sem)
1620 -- Used in an N_Implicit_Label_Declaration node. Refers to an N_Label,
1621 -- N_Block_Statement or N_Loop_Statement node to which the label
1622 -- declaration applies. This attribute is used both in the compiler and
1623 -- in the implementation of ASIS queries. The field is left empty for the
1624 -- special labels generated as part of expanding raise statements with a
1625 -- local exception handler.
1627 -- Library_Unit (Node4-Sem)
1628 -- In a stub node, Library_Unit points to the compilation unit node of
1629 -- the corresponding subunit.
1631 -- In a with clause node, Library_Unit points to the spec of the with'ed
1634 -- In a compilation unit node, the usage depends on the unit type:
1636 -- For a library unit body, Library_Unit points to the compilation unit
1637 -- node of the corresponding spec, unless it's a subprogram body with
1638 -- Acts_As_Spec set, in which case it points to itself.
1640 -- For a spec, Library_Unit points to the compilation unit node of the
1641 -- corresponding body, if present. The body will be present if the spec
1642 -- is or contains generics that we needed to instantiate. Similarly, the
1643 -- body will be present if we needed it for inlining purposes. Thus, if
1644 -- we have a spec/body pair, both of which are present, they point to
1645 -- each other via Library_Unit.
1647 -- For a subunit, Library_Unit points to the compilation unit node of
1650 -- Note that this field is not used to hold the parent pointer for child
1651 -- unit (which might in any case need to use it for some other purpose as
1652 -- described above). Instead for a child unit, implicit with's are
1653 -- generated for all parents.
1655 -- Local_Raise_Statements (Elist1)
1656 -- This field is present in exception handler nodes. It is set to
1657 -- No_Elist in the normal case. If there is at least one raise statement
1658 -- which can potentially be handled as a local raise, then this field
1659 -- points to a list of raise nodes, which are calls to a routine to raise
1660 -- an exception. These are raise nodes which can be optimized into gotos
1661 -- if the handler turns out to meet the conditions which permit this
1662 -- transformation. Note that this does NOT include instances of the
1663 -- N_Raise_xxx_Error nodes since the transformation of these nodes is
1664 -- handled by the back end (using the N_Push/N_Pop mechanism).
1666 -- Loop_Actions (List2-Sem)
1667 -- A list present in Component_Association nodes in array aggregates.
1668 -- Used to collect actions that must be executed within the loop because
1669 -- they may need to be evaluated anew each time through.
1671 -- Limited_View_Installed (Flag18-Sem)
1672 -- Present in With_Clauses and in package specifications. If set on
1673 -- with_clause, it indicates that this clause has created the current
1674 -- limited view of the designated package. On a package specification, it
1675 -- indicates that the limited view has already been created because the
1676 -- package is mentioned in a limited_with_clause in the closure of the
1677 -- unit being compiled.
1679 -- Local_Raise_Not_OK (Flag7-Sem)
1680 -- Present in N_Exception_Handler nodes. Set if the handler contains
1681 -- a construct (reraise statement, or call to subprogram in package
1682 -- GNAT.Current_Exception) that makes the handler unsuitable as a target
1683 -- for a local raise (one that could otherwise be converted to a goto).
1685 -- Must_Be_Byte_Aligned (Flag14-Sem)
1686 -- This flag is present in N_Attribute_Reference nodes. It can be set
1687 -- only for the Address and Unrestricted_Access attributes. If set it
1688 -- means that the object for which the address/access is given must be on
1689 -- a byte (more accurately a storage unit) boundary. If necessary, a copy
1690 -- of the object is to be made before taking the address (this copy is in
1691 -- the current scope on the stack frame). This is used for certain cases
1692 -- of code generated by the expander that passes parameters by address.
1694 -- The reason the copy is not made by the front end is that the back end
1695 -- has more information about type layout and may be able to (but is not
1696 -- guaranteed to) prevent making unnecessary copies.
1698 -- Must_Not_Freeze (Flag8-Sem)
1699 -- A flag present in all expression nodes. Normally expressions cause
1700 -- freezing as described in the RM. If this flag is set, then this is
1701 -- inhibited. This is used by the analyzer and expander to label nodes
1702 -- that are created by semantic analysis or expansion and which must not
1703 -- cause freezing even though they normally would. This flag is also
1704 -- present in an N_Subtype_Indication node, since we also use these in
1705 -- calls to Freeze_Expression.
1707 -- Next_Entity (Node2-Sem)
1708 -- Present in defining identifiers, defining character literals and
1709 -- defining operator symbols (i.e. in all entities). The entities of a
1710 -- scope are chained, and this field is used as the forward pointer for
1711 -- this list. See Einfo for further details.
1713 -- Next_Exit_Statement (Node3-Sem)
1714 -- Present in N_Exit_Statement nodes. The exit statements for a loop are
1715 -- chained (in reverse order of appearance) from the First_Exit_Statement
1716 -- field of the E_Loop entity for the loop. Next_Exit_Statement points to
1717 -- the next entry on this chain (Empty = end of list).
1719 -- Next_Implicit_With (Node3-Sem)
1720 -- Present in N_With_Clause. Part of a chain of with_clauses generated
1721 -- in rtsfind to indicate implicit dependencies on predefined units. Used
1722 -- to prevent multiple with_clauses for the same unit in a given context.
1723 -- A postorder traversal of the tree whose nodes are units and whose
1724 -- links are with_clauses defines the order in which CodePeer must
1725 -- examine a compiled unit and its full context. This ordering ensures
1726 -- that any subprogram call is examined after the subprogram declaration
1729 -- Next_Named_Actual (Node4-Sem)
1730 -- Present in parameter association nodes. Set during semantic analysis
1731 -- to point to the next named parameter, where parameters are ordered by
1732 -- declaration order (as opposed to the actual order in the call, which
1733 -- may be different due to named associations). Not that this field
1734 -- points to the explicit actual parameter itself, not to the
1735 -- N_Parameter_Association node (its parent).
1737 -- Next_Pragma (Node1-Sem)
1738 -- Present in N_Pragma nodes. Used to create a linked list of pragma
1739 -- nodes. Currently used for two purposes:
1741 -- Create a list of linked Check_Policy pragmas. The head of this list
1742 -- is stored in Opt.Check_Policy_List (which has further details).
1744 -- Used by processing for Pre/Postcondition pragmas to store a list of
1745 -- pragmas associated with the spec of a subprogram (see Sem_Prag for
1748 -- Used by processing for pragma SPARK_Mode to store multiple pragmas
1749 -- the apply to the same construct. These are visible/private mode for
1750 -- a package spec and declarative/statement mode for package body.
1752 -- Next_Rep_Item (Node5-Sem)
1753 -- Present in pragma nodes, attribute definition nodes, enumeration rep
1754 -- clauses, record rep clauses, aspect specification nodes. Used to link
1755 -- representation items that apply to an entity. See full description of
1756 -- First_Rep_Item field in Einfo for further details.
1758 -- Next_Use_Clause (Node3-Sem)
1759 -- While use clauses are active during semantic processing, they are
1760 -- chained from the scope stack entry, using Next_Use_Clause as a link
1761 -- pointer, with Empty marking the end of the list. The head pointer is
1762 -- in the scope stack entry (First_Use_Clause). At the end of semantic
1763 -- processing (i.e. when Gigi sees the tree, the contents of this field
1764 -- is undefined and should not be read).
1766 -- No_Ctrl_Actions (Flag7-Sem)
1767 -- Present in N_Assignment_Statement to indicate that no Finalize nor
1768 -- Adjust should take place on this assignment even though the RHS is
1769 -- controlled. Also indicates that the primitive _assign should not be
1770 -- used for a tagged assignment. This is used in init procs and aggregate
1771 -- expansions where the generated assignments are initializations, not
1772 -- real assignments.
1774 -- No_Elaboration_Check (Flag14-Sem)
1775 -- Present in N_Function_Call and N_Procedure_Call_Statement. Indicates
1776 -- that no elaboration check is needed on the call, because it appears in
1777 -- the context of a local Suppress pragma. This is used on calls within
1778 -- task bodies, where the actual elaboration checks are applied after
1779 -- analysis, when the local scope stack is not present.
1781 -- No_Entities_Ref_In_Spec (Flag8-Sem)
1782 -- Present in N_With_Clause nodes. Set if the with clause is on the
1783 -- package or subprogram spec where the main unit is the corresponding
1784 -- body, and no entities of the with'ed unit are referenced by the spec
1785 -- (an entity may still be referenced in the body, so this flag is used
1786 -- to generate the proper message (see Sem_Util.Check_Unused_Withs for
1789 -- No_Initialization (Flag13-Sem)
1790 -- Present in N_Object_Declaration and N_Allocator to indicate that the
1791 -- object must not be initialized (by Initialize or call to an init
1792 -- proc). This is needed for controlled aggregates. When the Object
1793 -- declaration has an expression, this flag means that this expression
1794 -- should not be taken into account (needed for in place initialization
1795 -- with aggregates, and for object with an address clause, which are
1796 -- initialized with an assignment at freeze time).
1798 -- No_Minimize_Eliminate (Flag17-Sem)
1799 -- This flag is present in membership operator nodes (N_In/N_Not_In).
1800 -- It is used to indicate that processing for extended overflow checking
1801 -- modes is not required (this is used to prevent infinite recursion).
1803 -- No_Truncation (Flag17-Sem)
1804 -- Present in N_Unchecked_Type_Conversion node. This flag has an effect
1805 -- only if the RM_Size of the source is greater than the RM_Size of the
1806 -- target for scalar operands. Normally in such a case we truncate some
1807 -- higher order bits of the source, and then sign/zero extend the result
1808 -- to form the output value. But if this flag is set, then we do not do
1809 -- any truncation, so for example, if an 8 bit input is converted to 5
1810 -- bit result which is in fact stored in 8 bits, then the high order
1811 -- three bits of the target result will be copied from the source. This
1812 -- is used for properly setting out of range values for use by pragmas
1813 -- Initialize_Scalars and Normalize_Scalars.
1815 -- Non_Aliased_Prefix (Flag18-Sem)
1816 -- Present in N_Attribute_Reference nodes. Set only for the case of an
1817 -- Unrestricted_Access reference whose prefix is non-aliased, which is
1818 -- the case that is permitted for Unrestricted_Access except when the
1819 -- expected type is a thin pointer to unconstrained array. This flag is
1820 -- to assist in detecting this illegal use of Unrestricted_Access.
1822 -- Original_Discriminant (Node2-Sem)
1823 -- Present in identifiers. Used in references to discriminants that
1824 -- appear in generic units. Because the names of the discriminants may be
1825 -- different in an instance, we use this field to recover the position of
1826 -- the discriminant in the original type, and replace it with the
1827 -- discriminant at the same position in the instantiated type.
1829 -- Original_Entity (Node2-Sem)
1830 -- Present in numeric literals. Used to denote the named number that has
1831 -- been constant-folded into the given literal. If literal is from
1832 -- source, or the result of some other constant-folding operation, then
1833 -- Original_Entity is empty. This field is needed to handle properly
1834 -- named numbers in generic units, where the Associated_Node field
1835 -- interferes with the Entity field, making it impossible to preserve the
1836 -- original entity at the point of instantiation (ASIS problem).
1838 -- Others_Discrete_Choices (List1-Sem)
1839 -- When a case statement or variant is analyzed, the semantic checks
1840 -- determine the actual list of choices that correspond to an others
1841 -- choice. This list is materialized for later use by the expander and
1842 -- the Others_Discrete_Choices field of an N_Others_Choice node points to
1843 -- this materialized list of choices, which is in standard format for a
1844 -- list of discrete choices, except that of course it cannot contain an
1845 -- N_Others_Choice entry.
1847 -- Parameter_List_Truncated (Flag17-Sem)
1848 -- Present in N_Function_Call and N_Procedure_Call_Statement nodes. Set
1849 -- (for OpenVMS ports of GNAT only) if the parameter list is truncated as
1850 -- a result of a First_Optional_Parameter specification in an
1851 -- Import_Function, Import_Procedure, or Import_Valued_Procedure pragma.
1852 -- The truncation is done by the expander by removing trailing parameters
1853 -- from the argument list, in accordance with the set of rules allowing
1854 -- such parameter removal. In particular, parameters can be removed
1855 -- working from the end of the parameter list backwards up to and
1856 -- including the entry designated by First_Optional_Parameter in the
1857 -- Import pragma. Parameters can be removed if they are implicit and the
1858 -- default value is a known-at-compile-time value, including the use of
1859 -- the Null_Parameter attribute, or if explicit parameter values are
1860 -- present that match the corresponding defaults.
1862 -- Parent_Spec (Node4-Sem)
1863 -- For a library unit that is a child unit spec (package or subprogram
1864 -- declaration, generic declaration or instantiation, or library level
1865 -- rename, this field points to the compilation unit node for the parent
1866 -- package specification. This field is Empty for library bodies (the
1867 -- parent spec in this case can be found from the corresponding spec).
1869 -- Premature_Use (Node5-Sem)
1870 -- Present in N_Incomplete_Type_Declaration node. Used for improved
1871 -- error diagnostics: if there is a premature usage of an incomplete
1872 -- type, a subsequently generated error message indicates the position
1873 -- of its full declaration.
1875 -- Present_Expr (Uint3-Sem)
1876 -- Present in an N_Variant node. This has a meaningful value only after
1877 -- Gigi has back annotated the tree with representation information. At
1878 -- this point, it contains a reference to a gcc expression that depends
1879 -- on the values of one or more discriminants. Give a set of discriminant
1880 -- values, this expression evaluates to False (zero) if variant is not
1881 -- present, and True (non-zero) if it is present. See unit Repinfo for
1882 -- further details on gigi back annotation. This field is used during
1883 -- ASIS processing (data decomposition annex) to determine if a field is
1886 -- Print_In_Hex (Flag13-Sem)
1887 -- Set on an N_Integer_Literal node to indicate that the value should be
1888 -- printed in hexadecimal in the sprint listing. Has no effect on
1889 -- legality or semantics of program, only on the displayed output. This
1890 -- is used to clarify output from the packed array cases.
1892 -- Procedure_To_Call (Node2-Sem)
1893 -- Present in N_Allocator, N_Free_Statement, N_Simple_Return_Statement,
1894 -- and N_Extended_Return_Statement nodes. References the entity for the
1895 -- declaration of the procedure to be called to accomplish the required
1896 -- operation (i.e. for the Allocate procedure in the case of N_Allocator
1897 -- and N_Simple_Return_Statement and N_Extended_Return_Statement (for
1898 -- allocating the return value), and for the Deallocate procedure in the
1899 -- case of N_Free_Statement.
1901 -- Raises_Constraint_Error (Flag7-Sem)
1902 -- Set on an expression whose evaluation will definitely fail constraint
1903 -- error check. In the case of static expressions, this flag must be set
1904 -- accurately (and if it is set, the expression is typically illegal
1905 -- unless it appears as a non-elaborated branch of a short-circuit form).
1906 -- For a non-static expression, this flag may be set whenever an
1907 -- expression (e.g. an aggregate) is known to raise constraint error. If
1908 -- set, the expression definitely will raise CE if elaborated at runtime.
1909 -- If not set, the expression may or may not raise CE. In other words, on
1910 -- static expressions, the flag is set accurately, on non-static
1911 -- expressions it is set conservatively.
1913 -- Redundant_Use (Flag13-Sem)
1914 -- Present in nodes that can appear as an operand in a use clause or use
1915 -- type clause (identifiers, expanded names, attribute references). Set
1916 -- to indicate that a use is redundant (and therefore need not be undone
1919 -- Renaming_Exception (Node2-Sem)
1920 -- Present in N_Exception_Declaration node. Used to point back to the
1921 -- exception renaming for an exception declared within a subprogram.
1922 -- What happens is that an exception declared in a subprogram is moved
1923 -- to the library level with a unique name, and the original exception
1924 -- becomes a renaming. This link from the library level exception to the
1925 -- renaming declaration allows registering of the proper exception name.
1927 -- Return_Statement_Entity (Node5-Sem)
1928 -- Present in N_Simple_Return_Statement and N_Extended_Return_Statement.
1929 -- Points to an E_Return_Statement representing the return statement.
1931 -- Return_Object_Declarations (List3)
1932 -- Present in N_Extended_Return_Statement. Points to a list initially
1933 -- containing a single N_Object_Declaration representing the return
1934 -- object. We use a list (instead of just a pointer to the object decl)
1935 -- because Analyze wants to insert extra actions on this list.
1937 -- Rounded_Result (Flag18-Sem)
1938 -- Present in N_Type_Conversion, N_Op_Divide and N_Op_Multiply nodes.
1939 -- Used in the fixed-point cases to indicate that the result must be
1940 -- rounded as a result of the use of the 'Round attribute. Also used for
1941 -- integer N_Op_Divide nodes to indicate that the result should be
1942 -- rounded to the nearest integer (breaking ties away from zero), rather
1943 -- than truncated towards zero as usual. These rounded integer operations
1944 -- are the result of expansion of rounded fixed-point divide, conversion
1945 -- and multiplication operations.
1947 -- SCIL_Entity (Node4-Sem)
1948 -- Present in SCIL nodes. Used to reference the tagged type associated
1949 -- with the SCIL node.
1951 -- SCIL_Controlling_Tag (Node5-Sem)
1952 -- Present in N_SCIL_Dispatching_Call nodes. Used to reference the
1953 -- controlling tag of a dispatching call.
1955 -- SCIL_Tag_Value (Node5-Sem)
1956 -- Present in N_SCIL_Membership_Test nodes. Used to reference the tag
1957 -- value that is being tested.
1959 -- SCIL_Target_Prim (Node2-Sem)
1960 -- Present in N_SCIL_Dispatching_Call nodes. Used to reference the tagged
1961 -- type primitive associated with the SCIL node.
1963 -- Scope (Node3-Sem)
1964 -- Present in defining identifiers, defining character literals and
1965 -- defining operator symbols (i.e. in all entities). The entities of a
1966 -- scope all use this field to reference the corresponding scope entity.
1967 -- See Einfo for further details.
1969 -- Shift_Count_OK (Flag4-Sem)
1970 -- A flag present in shift nodes to indicate that the shift count is
1971 -- known to be in range, i.e. is in the range from zero to word length
1972 -- minus one. If this flag is not set, then the shift count may be
1973 -- outside this range, i.e. larger than the word length, and the code
1974 -- must ensure that such shift counts give the appropriate result.
1976 -- Source_Type (Node1-Sem)
1977 -- Used in an N_Validate_Unchecked_Conversion node to point to the
1978 -- source type entity for the unchecked conversion instantiation
1979 -- which gigi must do size validation for.
1981 -- Split_PPC (Flag17)
1982 -- When a Pre or Post aspect specification is processed, it is broken
1983 -- into AND THEN sections. The left most section has Split_PPC set to
1984 -- False, indicating that it is the original specification (e.g. for
1985 -- posting errors). For other sections, Split_PPC is set to True.
1986 -- This flag is set in both the N_Aspect_Specification node itself,
1987 -- and in the pragma which is generated from this node.
1989 -- Storage_Pool (Node1-Sem)
1990 -- Present in N_Allocator, N_Free_Statement, N_Simple_Return_Statement,
1991 -- and N_Extended_Return_Statement nodes. References the entity for the
1992 -- storage pool to be used for the allocate or free call or for the
1993 -- allocation of the returned value from function. Empty indicates that
1994 -- the global default pool is to be used. Note that in the case
1995 -- of a return statement, this field is set only if the function returns
1996 -- value of a type whose size is not known at compile time on the
1999 -- Suppress_Assignment_Checks (Flag18-Sem)
2000 -- Used in generated N_Assignment_Statement nodes to suppress predicate
2001 -- and range checks in cases where the generated code knows that the
2002 -- value being assigned is in range and satisfies any predicate. Also
2003 -- can be set in N_Object_Declaration nodes, to similarly suppress any
2004 -- checks on the initializing value.
2006 -- Suppress_Loop_Warnings (Flag17-Sem)
2007 -- Used in N_Loop_Statement node to indicate that warnings within the
2008 -- body of the loop should be suppressed. This is set when the range
2009 -- of a FOR loop is known to be null, or is probably null (loop would
2010 -- only execute if invalid values are present).
2012 -- Target_Type (Node2-Sem)
2013 -- Used in an N_Validate_Unchecked_Conversion node to point to the target
2014 -- type entity for the unchecked conversion instantiation which gigi must
2015 -- do size validation for.
2017 -- Then_Actions (List3-Sem)
2018 -- This field is present in if expression nodes. During code expansion
2019 -- we use the Insert_Actions procedure (in Exp_Util) to insert actions
2020 -- at an appropriate place in the tree to get elaborated at the right
2021 -- time. For if expressions, we have to be sure that the actions for
2022 -- for the Then branch are only elaborated if the condition is True.
2023 -- The Then_Actions field is used as a temporary parking place for
2024 -- these actions. The final tree is always rewritten to eliminate the
2025 -- need for this field, so in the tree passed to Gigi, this field is
2026 -- always set to No_List.
2028 -- Treat_Fixed_As_Integer (Flag14-Sem)
2029 -- This flag appears in operator nodes for divide, multiply, mod and rem
2030 -- on fixed-point operands. It indicates that the operands are to be
2031 -- treated as integer values, ignoring small values. This flag is only
2032 -- set as a result of expansion of fixed-point operations. Typically a
2033 -- fixed-point multiplication in the source generates subsidiary
2034 -- multiplication and division operations that work with the underlying
2035 -- integer values and have this flag set. Note that this flag is not
2036 -- needed on other arithmetic operations (add, neg, subtract etc.) since
2037 -- in these cases it is always the case that fixed is treated as integer.
2038 -- The Etype field MUST be set if this flag is set. The analyzer knows to
2039 -- leave such nodes alone, and whoever makes them must set the correct
2042 -- TSS_Elist (Elist3-Sem)
2043 -- Present in N_Freeze_Entity nodes. Holds an element list containing
2044 -- entries for each TSS (type support subprogram) associated with the
2045 -- frozen type. The elements of the list are the entities for the
2046 -- subprograms (see package Exp_TSS for further details). Set to No_Elist
2047 -- if there are no type support subprograms for the type or if the freeze
2048 -- node is not for a type.
2050 -- Unreferenced_In_Spec (Flag7-Sem)
2051 -- Present in N_With_Clause nodes. Set if the with clause is on the
2052 -- package or subprogram spec where the main unit is the corresponding
2053 -- body, and is not referenced by the spec (it may still be referenced by
2054 -- the body, so this flag is used to generate the proper message (see
2055 -- Sem_Util.Check_Unused_Withs for details)
2057 -- Uninitialized_Variable (Node3-Sem)
2058 -- Present in N_Formal_Private_Type_Definition and in N_Private_
2059 -- Extension_Declarations. Indicates that a variable in a generic unit
2060 -- whose type is a formal private or derived type is read without being
2061 -- initialized. Used to warn if the corresponding actual type is not
2062 -- a fully initialized type.
2064 -- Used_Operations (Elist5-Sem)
2065 -- Present in N_Use_Type_Clause nodes. Holds the list of operations that
2066 -- are made potentially use-visible by the clause. Simplifies processing
2067 -- on exit from the scope of the use_type_clause, in particular in the
2068 -- case of Use_All_Type, when those operations several scopes.
2070 -- Was_Originally_Stub (Flag13-Sem)
2071 -- This flag is set in the node for a proper body that replaces stub.
2072 -- During the analysis procedure, stubs in some situations get rewritten
2073 -- by the corresponding bodies, and we set this flag to remember that
2074 -- this happened. Note that it is not good enough to rely on the use of
2075 -- Original_Node here because of the case of nested instantiations where
2076 -- the substituted node can be copied.
2078 -- Withed_Body (Node1-Sem)
2079 -- Present in N_With_Clause nodes. Set if the unit in whose context
2080 -- the with_clause appears instantiates a generic contained in the
2081 -- library unit of the with_clause and as a result loads its body.
2082 -- Used for a more precise unit traversal for CodePeer.
2084 --------------------------------------------------
2085 -- Note on Use of End_Label and End_Span Fields --
2086 --------------------------------------------------
2088 -- Several constructs have end lines:
2090 -- Loop Statement end loop [loop_IDENTIFIER];
2091 -- Package Specification end [[PARENT_UNIT_NAME .] IDENTIFIER]
2092 -- Task Definition end [task_IDENTIFIER]
2093 -- Protected Definition end [protected_IDENTIFIER]
2094 -- Protected Body end [protected_IDENTIFIER]
2096 -- Block Statement end [block_IDENTIFIER];
2097 -- Subprogram Body end [DESIGNATOR];
2098 -- Package Body end [[PARENT_UNIT_NAME .] IDENTIFIER];
2099 -- Task Body end [task_IDENTIFIER];
2100 -- Accept Statement end [entry_IDENTIFIER]];
2101 -- Entry Body end [entry_IDENTIFIER];
2103 -- If Statement end if;
2104 -- Case Statement end case;
2106 -- Record Definition end record;
2107 -- Enumeration Definition );
2109 -- The End_Label and End_Span fields are used to mark the locations of
2110 -- these lines, and also keep track of the label in the case where a label
2113 -- For the first group above, the End_Label field of the corresponding node
2114 -- is used to point to the label identifier. In the case where there is no
2115 -- label in the source, the parser supplies a dummy identifier (with
2116 -- Comes_From_Source set to False), and the Sloc of this dummy identifier
2117 -- marks the location of the token following the END token.
2119 -- For the second group, the use of End_Label is similar, but the End_Label
2120 -- is found in the N_Handled_Sequence_Of_Statements node. This is done
2121 -- simply because in some cases there is no room in the parent node.
2123 -- For the third group, there is never any label, and instead of using
2124 -- End_Label, we use the End_Span field which gives the location of the
2125 -- token following END, relative to the starting Sloc of the construct,
2126 -- i.e. add Sloc (Node) + End_Span (Node) to get the Sloc of the IF or CASE
2127 -- following the End_Label.
2129 -- The record definition case is handled specially, we treat it as though
2130 -- it required an optional label which is never present, and so the parser
2131 -- always builds a dummy identifier with Comes From Source set False. The
2132 -- reason we do this, rather than using End_Span in this case, is that we
2133 -- want to generate a cross-ref entry for the end of a record, since it
2134 -- represents a scope for name declaration purposes.
2136 -- The enumeration definition case is handled in an exactly similar manner,
2137 -- building a dummy identifier to get a cross-reference.
2139 -- Note: the reason we store the difference as a Uint, instead of storing
2140 -- the Source_Ptr value directly, is that Source_Ptr values cannot be
2141 -- distinguished from other types of values, and we count on all general
2142 -- use fields being self describing. To make things easier for clients,
2143 -- note that we provide function End_Location, and procedure
2144 -- Set_End_Location to allow access to the logical value (which is the
2145 -- Source_Ptr value for the end token).
2147 ---------------------
2148 -- Syntactic Nodes --
2149 ---------------------
2151 ---------------------
2152 -- 2.3 Identifier --
2153 ---------------------
2155 -- IDENTIFIER ::= IDENTIFIER_LETTER {[UNDERLINE] LETTER_OR_DIGIT}
2156 -- LETTER_OR_DIGIT ::= IDENTIFIER_LETTER | DIGIT
2158 -- An IDENTIFIER shall not be a reserved word
2160 -- In the Ada grammar identifiers are the bottom level tokens which have
2161 -- very few semantics. Actual program identifiers are direct names. If
2162 -- we were being 100% honest with the grammar, then we would have a node
2163 -- called N_Direct_Name which would point to an identifier. However,
2164 -- that's too many extra nodes, so we just use the N_Identifier node
2165 -- directly as a direct name, and it contains the expression fields and
2166 -- Entity field that correspond to its use as a direct name. In those
2167 -- few cases where identifiers appear in contexts where they are not
2168 -- direct names (pragmas, pragma argument associations, attribute
2169 -- references and attribute definition clauses), the Chars field of the
2170 -- node contains the Name_Id for the identifier name.
2172 -- Note: in GNAT, a reserved word can be treated as an identifier in two
2173 -- cases. First, an incorrect use of a reserved word as an identifier is
2174 -- diagnosed and then treated as a normal identifier. Second, an
2175 -- attribute designator of the form of a reserved word (access, delta,
2176 -- digits, range) is treated as an identifier.
2178 -- Note: The set of letters that is permitted in an identifier depends
2179 -- on the character set in use. See package Csets for full details.
2182 -- Sloc points to identifier
2183 -- Chars (Name1) contains the Name_Id for the identifier
2184 -- Entity (Node4-Sem)
2185 -- Associated_Node (Node4-Sem)
2186 -- Original_Discriminant (Node2-Sem)
2187 -- Redundant_Use (Flag13-Sem)
2188 -- Atomic_Sync_Required (Flag14-Sem)
2189 -- Has_Private_View (Flag11-Sem) (set in generic units)
2190 -- plus fields for expression
2192 --------------------------
2193 -- 2.4 Numeric Literal --
2194 --------------------------
2196 -- NUMERIC_LITERAL ::= DECIMAL_LITERAL | BASED_LITERAL
2198 ----------------------------
2199 -- 2.4.1 Decimal Literal --
2200 ----------------------------
2202 -- DECIMAL_LITERAL ::= NUMERAL [.NUMERAL] [EXPONENT]
2204 -- NUMERAL ::= DIGIT {[UNDERLINE] DIGIT}
2206 -- EXPONENT ::= E [+] NUMERAL | E - NUMERAL
2208 -- Decimal literals appear in the tree as either integer literal nodes
2209 -- or real literal nodes, depending on whether a period is present.
2211 -- Note: literal nodes appear as a result of direct use of literals
2212 -- in the source program, and also as the result of evaluating
2213 -- expressions at compile time. In the latter case, it is possible
2214 -- to construct real literals that have no syntactic representation
2215 -- using the standard literal format. Such literals are listed by
2216 -- Sprint using the notation [numerator / denominator].
2218 -- Note: the value of an integer literal node created by the front end
2219 -- is never outside the range of values of the base type. However, it
2220 -- can be the case that the created value is outside the range of the
2221 -- particular subtype. This happens in the case of integer overflows
2222 -- with checks suppressed.
2224 -- N_Integer_Literal
2225 -- Sloc points to literal
2226 -- Original_Entity (Node2-Sem) If not Empty, holds Named_Number that
2227 -- has been constant-folded into its literal value.
2228 -- Intval (Uint3) contains integer value of literal
2229 -- plus fields for expression
2230 -- Print_In_Hex (Flag13-Sem)
2233 -- Sloc points to literal
2234 -- Original_Entity (Node2-Sem) If not Empty, holds Named_Number that
2235 -- has been constant-folded into its literal value.
2236 -- Realval (Ureal3) contains real value of literal
2237 -- Corresponding_Integer_Value (Uint4-Sem)
2238 -- Is_Machine_Number (Flag11-Sem)
2239 -- plus fields for expression
2241 --------------------------
2242 -- 2.4.2 Based Literal --
2243 --------------------------
2245 -- BASED_LITERAL ::=
2246 -- BASE # BASED_NUMERAL [.BASED_NUMERAL] # [EXPONENT]
2250 -- BASED_NUMERAL ::=
2251 -- EXTENDED_DIGIT {[UNDERLINE] EXTENDED_DIGIT}
2253 -- EXTENDED_DIGIT ::= DIGIT | A | B | C | D | E | F
2255 -- Based literals appear in the tree as either integer literal nodes
2256 -- or real literal nodes, depending on whether a period is present.
2258 ----------------------------
2259 -- 2.5 Character Literal --
2260 ----------------------------
2262 -- CHARACTER_LITERAL ::= ' GRAPHIC_CHARACTER '
2264 -- N_Character_Literal
2265 -- Sloc points to literal
2266 -- Chars (Name1) contains the Name_Id for the identifier
2267 -- Char_Literal_Value (Uint2) contains the literal value
2268 -- Entity (Node4-Sem)
2269 -- Associated_Node (Node4-Sem)
2270 -- Has_Private_View (Flag11-Sem) set in generic units.
2271 -- plus fields for expression
2273 -- Note: the Entity field will be missing (set to Empty) for character
2274 -- literals whose type is Standard.Wide_Character or Standard.Character
2275 -- or a type derived from one of these two. In this case the character
2276 -- literal stands for its own coding. The reason we take this irregular
2277 -- short cut is to avoid the need to build lots of junk defining
2278 -- character literal nodes.
2280 -------------------------
2281 -- 2.6 String Literal --
2282 -------------------------
2284 -- STRING LITERAL ::= "{STRING_ELEMENT}"
2286 -- A STRING_ELEMENT is either a pair of quotation marks ("), or a
2287 -- single GRAPHIC_CHARACTER other than a quotation mark.
2289 -- Is_Folded_In_Parser is True if the parser created this literal by
2290 -- folding a sequence of "&" operators. For example, if the source code
2291 -- says "aaa" & "bbb" & "ccc", and this produces "aaabbbccc", the flag
2292 -- is set. This flag is needed because the parser doesn't know about
2293 -- visibility, so the folded result might be wrong, and semantic
2294 -- analysis needs to check for that.
2297 -- Sloc points to literal
2298 -- Strval (Str3) contains Id of string value
2299 -- Has_Wide_Character (Flag11-Sem)
2300 -- Has_Wide_Wide_Character (Flag13-Sem)
2301 -- Is_Folded_In_Parser (Flag4)
2302 -- plus fields for expression
2308 -- A COMMENT starts with two adjacent hyphens and extends up to the
2309 -- end of the line. A COMMENT may appear on any line of a program.
2311 -- Comments are skipped by the scanner and do not appear in the tree.
2312 -- It is possible to reconstruct the position of comments with respect
2313 -- to the elements of the tree by using the source position (Sloc)
2314 -- pointers that appear in every tree node.
2320 -- PRAGMA ::= pragma IDENTIFIER
2321 -- [(PRAGMA_ARGUMENT_ASSOCIATION {, PRAGMA_ARGUMENT_ASSOCIATION})];
2323 -- Note that a pragma may appear in the tree anywhere a declaration
2324 -- or a statement may appear, as well as in some other situations
2325 -- which are explicitly documented.
2328 -- Sloc points to PRAGMA
2329 -- Next_Pragma (Node1-Sem)
2330 -- Pragma_Argument_Associations (List2) (set to No_List if none)
2331 -- Corresponding_Aspect (Node3-Sem) (set to Empty if not present)
2332 -- Pragma_Identifier (Node4)
2333 -- Next_Rep_Item (Node5-Sem)
2334 -- Class_Present (Flag6) set if from Aspect with 'Class
2335 -- From_Aspect_Specification (Flag13-Sem)
2336 -- Is_Delayed_Aspect (Flag14-Sem)
2337 -- Is_Disabled (Flag15-Sem)
2338 -- Is_Ignored (Flag9-Sem)
2339 -- Is_Checked (Flag11-Sem)
2340 -- Import_Interface_Present (Flag16-Sem)
2341 -- Split_PPC (Flag17) set if corresponding aspect had Split_PPC set
2343 -- Note: we should have a section on what pragmas are passed on to
2344 -- the back end to be processed. This section should note that pragma
2345 -- Psect_Object is always converted to Common_Object, but there are
2346 -- undoubtedly many other similar notes required ???
2348 -- Note: a utility function Pragma_Name may be applied to pragma nodes
2349 -- to conveniently obtain the Chars field of the Pragma_Identifier.
2351 -- Note: if From_Aspect_Specification is set, then Sloc points to the
2352 -- aspect name, as does the Pragma_Identifier. In this case if the
2353 -- pragma has a local name argument (such as pragma Inline), it is
2354 -- resolved to point to the specific entity affected by the pragma.
2356 --------------------------------------
2357 -- 2.8 Pragma Argument Association --
2358 --------------------------------------
2360 -- PRAGMA_ARGUMENT_ASSOCIATION ::=
2361 -- [pragma_argument_IDENTIFIER =>] NAME
2362 -- | [pragma_argument_IDENTIFIER =>] EXPRESSION
2364 -- In Ada 2012, there are two more possibilities:
2366 -- PRAGMA_ARGUMENT_ASSOCIATION ::=
2367 -- [pragma_argument_ASPECT_MARK =>] NAME
2368 -- | [pragma_argument_ASPECT_MARK =>] EXPRESSION
2370 -- where the interesting allowed cases (which do not fit the syntax of
2371 -- the first alternative above) are
2373 -- ASPECT_MARK => Pre'Class |
2375 -- Type_Invariant'Class |
2378 -- We allow this special usage in all Ada modes, but it would be a
2379 -- pain to allow these aspects to pervade the pragma syntax, and the
2380 -- representation of pragma nodes internally. So what we do is to
2381 -- replace these ASPECT_MARK forms with identifiers whose name is one
2382 -- of the special internal names _Pre, _Post or _Type_Invariant.
2384 -- We do a similar replacement of these Aspect_Mark forms in the
2385 -- Expression of a pragma argument association for the cases of
2386 -- the first arguments of any Check pragmas and Check_Policy pragmas
2388 -- N_Pragma_Argument_Association
2389 -- Sloc points to first token in association
2390 -- Chars (Name1) (set to No_Name if no pragma argument identifier)
2391 -- Expression (Node3)
2393 ------------------------
2394 -- 2.9 Reserved Word --
2395 ------------------------
2397 -- Reserved words are parsed by the scanner, and returned as the
2398 -- corresponding token types (e.g. PACKAGE is returned as Tok_Package)
2400 ----------------------------
2401 -- 3.1 Basic Declaration --
2402 ----------------------------
2404 -- BASIC_DECLARATION ::=
2405 -- TYPE_DECLARATION | SUBTYPE_DECLARATION
2406 -- | OBJECT_DECLARATION | NUMBER_DECLARATION
2407 -- | SUBPROGRAM_DECLARATION | ABSTRACT_SUBPROGRAM_DECLARATION
2408 -- | PACKAGE_DECLARATION | RENAMING_DECLARATION
2409 -- | EXCEPTION_DECLARATION | GENERIC_DECLARATION
2410 -- | GENERIC_INSTANTIATION
2412 -- Basic declaration also includes IMPLICIT_LABEL_DECLARATION
2413 -- see further description in section on semantic nodes.
2415 -- Also, in the tree that is constructed, a pragma may appear
2416 -- anywhere that a declaration may appear.
2418 ------------------------------
2419 -- 3.1 Defining Identifier --
2420 ------------------------------
2422 -- DEFINING_IDENTIFIER ::= IDENTIFIER
2424 -- A defining identifier is an entity, which has additional fields
2425 -- depending on the setting of the Ekind field. These additional
2426 -- fields are defined (and access subprograms declared) in package
2429 -- Note: N_Defining_Identifier is an extended node whose fields are
2430 -- deliberate layed out to match the layout of fields in an ordinary
2431 -- N_Identifier node allowing for easy alteration of an identifier
2432 -- node into a defining identifier node. For details, see procedure
2433 -- Sinfo.CN.Change_Identifier_To_Defining_Identifier.
2435 -- N_Defining_Identifier
2436 -- Sloc points to identifier
2437 -- Chars (Name1) contains the Name_Id for the identifier
2438 -- Next_Entity (Node2-Sem)
2439 -- Scope (Node3-Sem)
2440 -- Etype (Node5-Sem)
2442 -----------------------------
2443 -- 3.2.1 Type Declaration --
2444 -----------------------------
2446 -- TYPE_DECLARATION ::=
2447 -- FULL_TYPE_DECLARATION
2448 -- | INCOMPLETE_TYPE_DECLARATION
2449 -- | PRIVATE_TYPE_DECLARATION
2450 -- | PRIVATE_EXTENSION_DECLARATION
2452 ----------------------------------
2453 -- 3.2.1 Full Type Declaration --
2454 ----------------------------------
2456 -- FULL_TYPE_DECLARATION ::=
2457 -- type DEFINING_IDENTIFIER [KNOWN_DISCRIMINANT_PART]
2458 -- is TYPE_DEFINITION
2459 -- [ASPECT_SPECIFICATIONS];
2460 -- | TASK_TYPE_DECLARATION
2461 -- | PROTECTED_TYPE_DECLARATION
2463 -- The full type declaration node is used only for the first case. The
2464 -- second case (concurrent type declaration), is represented directly
2465 -- by a task type declaration or a protected type declaration.
2467 -- N_Full_Type_Declaration
2468 -- Sloc points to TYPE
2469 -- Defining_Identifier (Node1)
2470 -- Discriminant_Specifications (List4) (set to No_List if none)
2471 -- Type_Definition (Node3)
2472 -- Discr_Check_Funcs_Built (Flag11-Sem)
2474 ----------------------------
2475 -- 3.2.1 Type Definition --
2476 ----------------------------
2478 -- TYPE_DEFINITION ::=
2479 -- ENUMERATION_TYPE_DEFINITION | INTEGER_TYPE_DEFINITION
2480 -- | REAL_TYPE_DEFINITION | ARRAY_TYPE_DEFINITION
2481 -- | RECORD_TYPE_DEFINITION | ACCESS_TYPE_DEFINITION
2482 -- | DERIVED_TYPE_DEFINITION | INTERFACE_TYPE_DEFINITION
2484 --------------------------------
2485 -- 3.2.2 Subtype Declaration --
2486 --------------------------------
2488 -- SUBTYPE_DECLARATION ::=
2489 -- subtype DEFINING_IDENTIFIER is [NULL_EXCLUSION] SUBTYPE_INDICATION
2490 -- [ASPECT_SPECIFICATIONS];
2492 -- The subtype indication field is set to Empty for subtypes
2493 -- declared in package Standard (Positive, Natural).
2495 -- N_Subtype_Declaration
2496 -- Sloc points to SUBTYPE
2497 -- Defining_Identifier (Node1)
2498 -- Null_Exclusion_Present (Flag11)
2499 -- Subtype_Indication (Node5)
2500 -- Generic_Parent_Type (Node4-Sem) (set for an actual derived type).
2501 -- Exception_Junk (Flag8-Sem)
2502 -- Has_Dynamic_Range_Check (Flag12-Sem)
2504 -------------------------------
2505 -- 3.2.2 Subtype Indication --
2506 -------------------------------
2508 -- SUBTYPE_INDICATION ::= SUBTYPE_MARK [CONSTRAINT]
2510 -- Note: if no constraint is present, the subtype indication appears
2511 -- directly in the tree as a subtype mark. The N_Subtype_Indication
2512 -- node is used only if a constraint is present.
2514 -- Note: [For Ada 2005 (AI-231)]: Because Ada 2005 extends this rule
2515 -- with the null-exclusion part (see AI-231), we had to introduce a new
2516 -- attribute in all the parents of subtype_indication nodes to indicate
2517 -- if the null-exclusion is present.
2519 -- Note: the reason that this node has expression fields is that a
2520 -- subtype indication can appear as an operand of a membership test.
2522 -- N_Subtype_Indication
2523 -- Sloc points to first token of subtype mark
2524 -- Subtype_Mark (Node4)
2525 -- Constraint (Node3)
2526 -- Etype (Node5-Sem)
2527 -- Must_Not_Freeze (Flag8-Sem)
2529 -- Note: Depending on context, the Etype is either the entity of the
2530 -- Subtype_Mark field, or it is an itype constructed to reify the
2531 -- subtype indication. In particular, such itypes are created for a
2532 -- subtype indication that appears in an array type declaration. This
2533 -- simplifies constraint checking in indexed components.
2535 -- For subtype indications that appear in scalar type and subtype
2536 -- declarations, the Etype is the entity of the subtype mark.
2538 -------------------------
2539 -- 3.2.2 Subtype Mark --
2540 -------------------------
2542 -- SUBTYPE_MARK ::= subtype_NAME
2544 -----------------------
2545 -- 3.2.2 Constraint --
2546 -----------------------
2548 -- CONSTRAINT ::= SCALAR_CONSTRAINT | COMPOSITE_CONSTRAINT
2550 ------------------------------
2551 -- 3.2.2 Scalar Constraint --
2552 ------------------------------
2554 -- SCALAR_CONSTRAINT ::=
2555 -- RANGE_CONSTRAINT | DIGITS_CONSTRAINT | DELTA_CONSTRAINT
2557 ---------------------------------
2558 -- 3.2.2 Composite Constraint --
2559 ---------------------------------
2561 -- COMPOSITE_CONSTRAINT ::=
2562 -- INDEX_CONSTRAINT | DISCRIMINANT_CONSTRAINT
2564 -------------------------------
2565 -- 3.3.1 Object Declaration --
2566 -------------------------------
2568 -- OBJECT_DECLARATION ::=
2569 -- DEFINING_IDENTIFIER_LIST : [aliased] [constant]
2570 -- [NULL_EXCLUSION] SUBTYPE_INDICATION [:= EXPRESSION]
2571 -- [ASPECT_SPECIFICATIONS];
2572 -- | DEFINING_IDENTIFIER_LIST : [aliased] [constant]
2573 -- ACCESS_DEFINITION [:= EXPRESSION]
2574 -- [ASPECT_SPECIFICATIONS];
2575 -- | DEFINING_IDENTIFIER_LIST : [aliased] [constant]
2576 -- ARRAY_TYPE_DEFINITION [:= EXPRESSION]
2577 -- [ASPECT_SPECIFICATIONS];
2578 -- | SINGLE_TASK_DECLARATION
2579 -- | SINGLE_PROTECTED_DECLARATION
2581 -- Note: aliased is not permitted in Ada 83 mode
2583 -- The N_Object_Declaration node is only for the first two cases.
2584 -- Single task declaration is handled by P_Task (9.1)
2585 -- Single protected declaration is handled by P_protected (9.5)
2587 -- Although the syntax allows multiple identifiers in the list, the
2588 -- semantics is as though successive declarations were given with
2589 -- identical type definition and expression components. To simplify
2590 -- semantic processing, the parser represents a multiple declaration
2591 -- case as a sequence of single declarations, using the More_Ids and
2592 -- Prev_Ids flags to preserve the original source form as described
2593 -- in the section on "Handling of Defining Identifier Lists".
2595 -- The flag Has_Init_Expression is set if an initializing expression
2596 -- is present. Normally it is set if and only if Expression contains
2597 -- a non-empty value, but there is an exception to this. When the
2598 -- initializing expression is an aggregate which requires explicit
2599 -- assignments, the Expression field gets set to Empty, but this flag
2600 -- is still set, so we don't forget we had an initializing expression.
2602 -- Note: if a range check is required for the initialization
2603 -- expression then the Do_Range_Check flag is set in the Expression,
2604 -- with the check being done against the type given by the object
2605 -- definition, which is also the Etype of the defining identifier.
2607 -- Note: the contents of the Expression field must be ignored (i.e.
2608 -- treated as though it were Empty) if No_Initialization is set True.
2610 -- Note: the back end places some restrictions on the form of the
2611 -- Expression field. If the object being declared is Atomic, then
2612 -- the Expression may not have the form of an aggregate (since this
2613 -- might cause the back end to generate separate assignments). In this
2614 -- case the front end must generate an extra temporary and initialize
2615 -- this temporary as required (the temporary itself is not atomic).
2617 -- Note: there is not node kind for object definition. Instead, the
2618 -- corresponding field holds a subtype indication, an array type
2619 -- definition, or (Ada 2005, AI-406) an access definition.
2621 -- N_Object_Declaration
2622 -- Sloc points to first identifier
2623 -- Defining_Identifier (Node1)
2624 -- Aliased_Present (Flag4)
2625 -- Constant_Present (Flag17) set if CONSTANT appears
2626 -- Null_Exclusion_Present (Flag11)
2627 -- Object_Definition (Node4) subtype indic./array type def./access def.
2628 -- Expression (Node3) (set to Empty if not present)
2629 -- Handler_List_Entry (Node2-Sem)
2630 -- Corresponding_Generic_Association (Node5-Sem)
2631 -- More_Ids (Flag5) (set to False if no more identifiers in list)
2632 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
2633 -- No_Initialization (Flag13-Sem)
2634 -- Assignment_OK (Flag15-Sem)
2635 -- Exception_Junk (Flag8-Sem)
2636 -- Is_Subprogram_Descriptor (Flag16-Sem)
2637 -- Has_Init_Expression (Flag14)
2638 -- Suppress_Assignment_Checks (Flag18-Sem)
2640 -------------------------------------
2641 -- 3.3.1 Defining Identifier List --
2642 -------------------------------------
2644 -- DEFINING_IDENTIFIER_LIST ::=
2645 -- DEFINING_IDENTIFIER {, DEFINING_IDENTIFIER}
2647 -------------------------------
2648 -- 3.3.2 Number Declaration --
2649 -------------------------------
2651 -- NUMBER_DECLARATION ::=
2652 -- DEFINING_IDENTIFIER_LIST : constant := static_EXPRESSION;
2654 -- Although the syntax allows multiple identifiers in the list, the
2655 -- semantics is as though successive declarations were given with
2656 -- identical expressions. To simplify semantic processing, the parser
2657 -- represents a multiple declaration case as a sequence of single
2658 -- declarations, using the More_Ids and Prev_Ids flags to preserve
2659 -- the original source form as described in the section on "Handling
2660 -- of Defining Identifier Lists".
2662 -- N_Number_Declaration
2663 -- Sloc points to first identifier
2664 -- Defining_Identifier (Node1)
2665 -- Expression (Node3)
2666 -- More_Ids (Flag5) (set to False if no more identifiers in list)
2667 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
2669 ----------------------------------
2670 -- 3.4 Derived Type Definition --
2671 ----------------------------------
2673 -- DERIVED_TYPE_DEFINITION ::=
2674 -- [abstract] [limited] new [NULL_EXCLUSION] parent_SUBTYPE_INDICATION
2675 -- [[and INTERFACE_LIST] RECORD_EXTENSION_PART]
2677 -- Note: ABSTRACT, LIMITED and record extension part are not permitted
2680 -- Note: a record extension part is required if ABSTRACT is present
2682 -- N_Derived_Type_Definition
2683 -- Sloc points to NEW
2684 -- Abstract_Present (Flag4)
2685 -- Null_Exclusion_Present (Flag11) (set to False if not present)
2686 -- Subtype_Indication (Node5)
2687 -- Record_Extension_Part (Node3) (set to Empty if not present)
2688 -- Limited_Present (Flag17)
2689 -- Task_Present (Flag5) set in task interfaces
2690 -- Protected_Present (Flag6) set in protected interfaces
2691 -- Synchronized_Present (Flag7) set in interfaces
2692 -- Interface_List (List2) (set to No_List if none)
2693 -- Interface_Present (Flag16) set in abstract interfaces
2695 -- Note: Task_Present, Protected_Present, Synchronized_Present,
2696 -- Interface_List, and Interface_Present are used for abstract
2697 -- interfaces (see comments for INTERFACE_TYPE_DEFINITION).
2699 ---------------------------
2700 -- 3.5 Range Constraint --
2701 ---------------------------
2703 -- RANGE_CONSTRAINT ::= range RANGE
2705 -- N_Range_Constraint
2706 -- Sloc points to RANGE
2707 -- Range_Expression (Node4)
2714 -- RANGE_ATTRIBUTE_REFERENCE
2715 -- | SIMPLE_EXPRESSION .. SIMPLE_EXPRESSION
2717 -- Note: the case of a range given as a range attribute reference
2718 -- appears directly in the tree as an attribute reference.
2720 -- Note: the field name for a reference to a range is Range_Expression
2721 -- rather than Range, because range is a reserved keyword in Ada.
2723 -- Note: the reason that this node has expression fields is that a
2724 -- range can appear as an operand of a membership test. The Etype
2725 -- field is the type of the range (we do NOT construct an implicit
2726 -- subtype to represent the range exactly).
2729 -- Sloc points to ..
2730 -- Low_Bound (Node1)
2731 -- High_Bound (Node2)
2732 -- Includes_Infinities (Flag11)
2733 -- plus fields for expression
2735 -- Note: if the range appears in a context, such as a subtype
2736 -- declaration, where range checks are required on one or both of
2737 -- the expression fields, then type conversion nodes are inserted
2738 -- to represent the required checks.
2740 ----------------------------------------
2741 -- 3.5.1 Enumeration Type Definition --
2742 ----------------------------------------
2744 -- ENUMERATION_TYPE_DEFINITION ::=
2745 -- (ENUMERATION_LITERAL_SPECIFICATION
2746 -- {, ENUMERATION_LITERAL_SPECIFICATION})
2748 -- Note: the Literals field in the node described below is null for
2749 -- the case of the standard types CHARACTER and WIDE_CHARACTER, for
2750 -- which special processing handles these types as special cases.
2752 -- N_Enumeration_Type_Definition
2753 -- Sloc points to left parenthesis
2754 -- Literals (List1) (Empty for CHARACTER or WIDE_CHARACTER)
2755 -- End_Label (Node4) (set to Empty if internally generated record)
2757 ----------------------------------------------
2758 -- 3.5.1 Enumeration Literal Specification --
2759 ----------------------------------------------
2761 -- ENUMERATION_LITERAL_SPECIFICATION ::=
2762 -- DEFINING_IDENTIFIER | DEFINING_CHARACTER_LITERAL
2764 ---------------------------------------
2765 -- 3.5.1 Defining Character Literal --
2766 ---------------------------------------
2768 -- DEFINING_CHARACTER_LITERAL ::= CHARACTER_LITERAL
2770 -- A defining character literal is an entity, which has additional
2771 -- fields depending on the setting of the Ekind field. These
2772 -- additional fields are defined (and access subprograms declared)
2773 -- in package Einfo.
2775 -- Note: N_Defining_Character_Literal is an extended node whose fields
2776 -- are deliberate layed out to match the layout of fields in an ordinary
2777 -- N_Character_Literal node allowing for easy alteration of a character
2778 -- literal node into a defining character literal node. For details, see
2779 -- Sinfo.CN.Change_Character_Literal_To_Defining_Character_Literal.
2781 -- N_Defining_Character_Literal
2782 -- Sloc points to literal
2783 -- Chars (Name1) contains the Name_Id for the identifier
2784 -- Next_Entity (Node2-Sem)
2785 -- Scope (Node3-Sem)
2786 -- Etype (Node5-Sem)
2788 ------------------------------------
2789 -- 3.5.4 Integer Type Definition --
2790 ------------------------------------
2792 -- Note: there is an error in this rule in the latest version of the
2793 -- grammar, so we have retained the old rule pending clarification.
2795 -- INTEGER_TYPE_DEFINITION ::=
2796 -- SIGNED_INTEGER_TYPE_DEFINITION
2797 -- | MODULAR_TYPE_DEFINITION
2799 -------------------------------------------
2800 -- 3.5.4 Signed Integer Type Definition --
2801 -------------------------------------------
2803 -- SIGNED_INTEGER_TYPE_DEFINITION ::=
2804 -- range static_SIMPLE_EXPRESSION .. static_SIMPLE_EXPRESSION
2806 -- Note: the Low_Bound and High_Bound fields are set to Empty
2807 -- for integer types defined in package Standard.
2809 -- N_Signed_Integer_Type_Definition
2810 -- Sloc points to RANGE
2811 -- Low_Bound (Node1)
2812 -- High_Bound (Node2)
2814 ------------------------------------
2815 -- 3.5.4 Modular Type Definition --
2816 ------------------------------------
2818 -- MODULAR_TYPE_DEFINITION ::= mod static_EXPRESSION
2820 -- N_Modular_Type_Definition
2821 -- Sloc points to MOD
2822 -- Expression (Node3)
2824 ---------------------------------
2825 -- 3.5.6 Real Type Definition --
2826 ---------------------------------
2828 -- REAL_TYPE_DEFINITION ::=
2829 -- FLOATING_POINT_DEFINITION | FIXED_POINT_DEFINITION
2831 --------------------------------------
2832 -- 3.5.7 Floating Point Definition --
2833 --------------------------------------
2835 -- FLOATING_POINT_DEFINITION ::=
2836 -- digits static_SIMPLE_EXPRESSION [REAL_RANGE_SPECIFICATION]
2838 -- Note: The Digits_Expression and Real_Range_Specifications fields
2839 -- are set to Empty for floating-point types declared in Standard.
2841 -- N_Floating_Point_Definition
2842 -- Sloc points to DIGITS
2843 -- Digits_Expression (Node2)
2844 -- Real_Range_Specification (Node4) (set to Empty if not present)
2846 -------------------------------------
2847 -- 3.5.7 Real Range Specification --
2848 -------------------------------------
2850 -- REAL_RANGE_SPECIFICATION ::=
2851 -- range static_SIMPLE_EXPRESSION .. static_SIMPLE_EXPRESSION
2853 -- N_Real_Range_Specification
2854 -- Sloc points to RANGE
2855 -- Low_Bound (Node1)
2856 -- High_Bound (Node2)
2858 -----------------------------------
2859 -- 3.5.9 Fixed Point Definition --
2860 -----------------------------------
2862 -- FIXED_POINT_DEFINITION ::=
2863 -- ORDINARY_FIXED_POINT_DEFINITION | DECIMAL_FIXED_POINT_DEFINITION
2865 --------------------------------------------
2866 -- 3.5.9 Ordinary Fixed Point Definition --
2867 --------------------------------------------
2869 -- ORDINARY_FIXED_POINT_DEFINITION ::=
2870 -- delta static_EXPRESSION REAL_RANGE_SPECIFICATION
2872 -- Note: In Ada 83, the EXPRESSION must be a SIMPLE_EXPRESSION
2874 -- N_Ordinary_Fixed_Point_Definition
2875 -- Sloc points to DELTA
2876 -- Delta_Expression (Node3)
2877 -- Real_Range_Specification (Node4)
2879 -------------------------------------------
2880 -- 3.5.9 Decimal Fixed Point Definition --
2881 -------------------------------------------
2883 -- DECIMAL_FIXED_POINT_DEFINITION ::=
2884 -- delta static_EXPRESSION
2885 -- digits static_EXPRESSION [REAL_RANGE_SPECIFICATION]
2887 -- Note: decimal types are not permitted in Ada 83 mode
2889 -- N_Decimal_Fixed_Point_Definition
2890 -- Sloc points to DELTA
2891 -- Delta_Expression (Node3)
2892 -- Digits_Expression (Node2)
2893 -- Real_Range_Specification (Node4) (set to Empty if not present)
2895 ------------------------------
2896 -- 3.5.9 Digits Constraint --
2897 ------------------------------
2899 -- DIGITS_CONSTRAINT ::=
2900 -- digits static_EXPRESSION [RANGE_CONSTRAINT]
2902 -- Note: in Ada 83, the EXPRESSION must be a SIMPLE_EXPRESSION
2903 -- Note: in Ada 95, reduced accuracy subtypes are obsolescent
2905 -- N_Digits_Constraint
2906 -- Sloc points to DIGITS
2907 -- Digits_Expression (Node2)
2908 -- Range_Constraint (Node4) (set to Empty if not present)
2910 --------------------------------
2911 -- 3.6 Array Type Definition --
2912 --------------------------------
2914 -- ARRAY_TYPE_DEFINITION ::=
2915 -- UNCONSTRAINED_ARRAY_DEFINITION | CONSTRAINED_ARRAY_DEFINITION
2917 -----------------------------------------
2918 -- 3.6 Unconstrained Array Definition --
2919 -----------------------------------------
2921 -- UNCONSTRAINED_ARRAY_DEFINITION ::=
2922 -- array (INDEX_SUBTYPE_DEFINITION {, INDEX_SUBTYPE_DEFINITION}) of
2923 -- COMPONENT_DEFINITION
2925 -- Note: dimensionality of array is indicated by number of entries in
2926 -- the Subtype_Marks list, which has one entry for each dimension.
2928 -- N_Unconstrained_Array_Definition
2929 -- Sloc points to ARRAY
2930 -- Subtype_Marks (List2)
2931 -- Component_Definition (Node4)
2933 -----------------------------------
2934 -- 3.6 Index Subtype Definition --
2935 -----------------------------------
2937 -- INDEX_SUBTYPE_DEFINITION ::= SUBTYPE_MARK range <>
2939 -- There is no explicit node in the tree for an index subtype
2940 -- definition since the N_Unconstrained_Array_Definition node
2941 -- incorporates the type marks which appear in this context.
2943 ---------------------------------------
2944 -- 3.6 Constrained Array Definition --
2945 ---------------------------------------
2947 -- CONSTRAINED_ARRAY_DEFINITION ::=
2948 -- array (DISCRETE_SUBTYPE_DEFINITION
2949 -- {, DISCRETE_SUBTYPE_DEFINITION})
2950 -- of COMPONENT_DEFINITION
2952 -- Note: dimensionality of array is indicated by number of entries
2953 -- in the Discrete_Subtype_Definitions list, which has one entry
2954 -- for each dimension.
2956 -- N_Constrained_Array_Definition
2957 -- Sloc points to ARRAY
2958 -- Discrete_Subtype_Definitions (List2)
2959 -- Component_Definition (Node4)
2961 -- Note: although the language allows the full syntax for discrete
2962 -- subtype definitions (i.e. a discrete subtype indication or a range),
2963 -- in the generated tree, we always rewrite these as N_Range nodes.
2965 --------------------------------------
2966 -- 3.6 Discrete Subtype Definition --
2967 --------------------------------------
2969 -- DISCRETE_SUBTYPE_DEFINITION ::=
2970 -- discrete_SUBTYPE_INDICATION | RANGE
2972 -------------------------------
2973 -- 3.6 Component Definition --
2974 -------------------------------
2976 -- COMPONENT_DEFINITION ::=
2977 -- [aliased] [NULL_EXCLUSION] SUBTYPE_INDICATION | ACCESS_DEFINITION
2979 -- Note: although the syntax does not permit a component definition to
2980 -- be an anonymous array (and the parser will diagnose such an attempt
2981 -- with an appropriate message), it is possible for anonymous arrays
2982 -- to appear as component definitions. The semantics and back end handle
2983 -- this case properly, and the expander in fact generates such cases.
2984 -- Access_Definition is an optional field that gives support to
2985 -- Ada 2005 (AI-230). The parser generates nodes that have either the
2986 -- Subtype_Indication field or else the Access_Definition field.
2988 -- N_Component_Definition
2989 -- Sloc points to ALIASED, ACCESS or to first token of subtype mark
2990 -- Aliased_Present (Flag4)
2991 -- Null_Exclusion_Present (Flag11)
2992 -- Subtype_Indication (Node5) (set to Empty if not present)
2993 -- Access_Definition (Node3) (set to Empty if not present)
2995 -----------------------------
2996 -- 3.6.1 Index Constraint --
2997 -----------------------------
2999 -- INDEX_CONSTRAINT ::= (DISCRETE_RANGE {, DISCRETE_RANGE})
3001 -- It is not in general possible to distinguish between discriminant
3002 -- constraints and index constraints at parse time, since a simple
3003 -- name could be either the subtype mark of a discrete range, or an
3004 -- expression in a discriminant association with no name. Either
3005 -- entry appears simply as the name, and the semantic parse must
3006 -- distinguish between the two cases. Thus we use a common tree
3007 -- node format for both of these constraint types.
3009 -- See Discriminant_Constraint for format of node
3011 ---------------------------
3012 -- 3.6.1 Discrete Range --
3013 ---------------------------
3015 -- DISCRETE_RANGE ::= discrete_SUBTYPE_INDICATION | RANGE
3017 ----------------------------
3018 -- 3.7 Discriminant Part --
3019 ----------------------------
3021 -- DISCRIMINANT_PART ::=
3022 -- UNKNOWN_DISCRIMINANT_PART | KNOWN_DISCRIMINANT_PART
3024 ------------------------------------
3025 -- 3.7 Unknown Discriminant Part --
3026 ------------------------------------
3028 -- UNKNOWN_DISCRIMINANT_PART ::= (<>)
3030 -- Note: unknown discriminant parts are not permitted in Ada 83 mode
3032 -- There is no explicit node in the tree for an unknown discriminant
3033 -- part. Instead the Unknown_Discriminants_Present flag is set in the
3036 ----------------------------------
3037 -- 3.7 Known Discriminant Part --
3038 ----------------------------------
3040 -- KNOWN_DISCRIMINANT_PART ::=
3041 -- (DISCRIMINANT_SPECIFICATION {; DISCRIMINANT_SPECIFICATION})
3043 -------------------------------------
3044 -- 3.7 Discriminant Specification --
3045 -------------------------------------
3047 -- DISCRIMINANT_SPECIFICATION ::=
3048 -- DEFINING_IDENTIFIER_LIST : [NULL_EXCLUSION] SUBTYPE_MARK
3049 -- [:= DEFAULT_EXPRESSION]
3050 -- | DEFINING_IDENTIFIER_LIST : ACCESS_DEFINITION
3051 -- [:= DEFAULT_EXPRESSION]
3053 -- Although the syntax allows multiple identifiers in the list, the
3054 -- semantics is as though successive specifications were given with
3055 -- identical type definition and expression components. To simplify
3056 -- semantic processing, the parser represents a multiple declaration
3057 -- case as a sequence of single specifications, using the More_Ids and
3058 -- Prev_Ids flags to preserve the original source form as described
3059 -- in the section on "Handling of Defining Identifier Lists".
3061 -- N_Discriminant_Specification
3062 -- Sloc points to first identifier
3063 -- Defining_Identifier (Node1)
3064 -- Null_Exclusion_Present (Flag11)
3065 -- Discriminant_Type (Node5) subtype mark or access parameter definition
3066 -- Expression (Node3) (set to Empty if no default expression)
3067 -- More_Ids (Flag5) (set to False if no more identifiers in list)
3068 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
3070 -----------------------------
3071 -- 3.7 Default Expression --
3072 -----------------------------
3074 -- DEFAULT_EXPRESSION ::= EXPRESSION
3076 ------------------------------------
3077 -- 3.7.1 Discriminant Constraint --
3078 ------------------------------------
3080 -- DISCRIMINANT_CONSTRAINT ::=
3081 -- (DISCRIMINANT_ASSOCIATION {, DISCRIMINANT_ASSOCIATION})
3083 -- It is not in general possible to distinguish between discriminant
3084 -- constraints and index constraints at parse time, since a simple
3085 -- name could be either the subtype mark of a discrete range, or an
3086 -- expression in a discriminant association with no name. Either
3087 -- entry appears simply as the name, and the semantic parse must
3088 -- distinguish between the two cases. Thus we use a common tree
3089 -- node format for both of these constraint types.
3091 -- N_Index_Or_Discriminant_Constraint
3092 -- Sloc points to left paren
3093 -- Constraints (List1) points to list of discrete ranges or
3094 -- discriminant associations
3096 -------------------------------------
3097 -- 3.7.1 Discriminant Association --
3098 -------------------------------------
3100 -- DISCRIMINANT_ASSOCIATION ::=
3101 -- [discriminant_SELECTOR_NAME
3102 -- {| discriminant_SELECTOR_NAME} =>] EXPRESSION
3104 -- Note: a discriminant association that has no selector name list
3105 -- appears directly as an expression in the tree.
3107 -- N_Discriminant_Association
3108 -- Sloc points to first token of discriminant association
3109 -- Selector_Names (List1) (always non-empty, since if no selector
3110 -- names are present, this node is not used, see comment above)
3111 -- Expression (Node3)
3113 ---------------------------------
3114 -- 3.8 Record Type Definition --
3115 ---------------------------------
3117 -- RECORD_TYPE_DEFINITION ::=
3118 -- [[abstract] tagged] [limited] RECORD_DEFINITION
3120 -- Note: ABSTRACT, TAGGED, LIMITED are not permitted in Ada 83 mode
3122 -- There is no explicit node in the tree for a record type definition.
3123 -- Instead the flags for Tagged_Present and Limited_Present appear in
3124 -- the N_Record_Definition node for a record definition appearing in
3125 -- the context of a record type definition.
3127 ----------------------------
3128 -- 3.8 Record Definition --
3129 ----------------------------
3131 -- RECORD_DEFINITION ::=
3137 -- Note: the Abstract_Present, Tagged_Present and Limited_Present
3138 -- flags appear only for a record definition appearing in a record
3141 -- Note: the NULL RECORD case is not permitted in Ada 83
3143 -- N_Record_Definition
3144 -- Sloc points to RECORD or NULL
3145 -- End_Label (Node4) (set to Empty if internally generated record)
3146 -- Abstract_Present (Flag4)
3147 -- Tagged_Present (Flag15)
3148 -- Limited_Present (Flag17)
3149 -- Component_List (Node1) empty in null record case
3150 -- Null_Present (Flag13) set in null record case
3151 -- Task_Present (Flag5) set in task interfaces
3152 -- Protected_Present (Flag6) set in protected interfaces
3153 -- Synchronized_Present (Flag7) set in interfaces
3154 -- Interface_Present (Flag16) set in abstract interfaces
3155 -- Interface_List (List2) (set to No_List if none)
3157 -- Note: Task_Present, Protected_Present, Synchronized _Present,
3158 -- Interface_List and Interface_Present are used for abstract
3159 -- interfaces (see comments for INTERFACE_TYPE_DEFINITION).
3161 -------------------------
3162 -- 3.8 Component List --
3163 -------------------------
3165 -- COMPONENT_LIST ::=
3166 -- COMPONENT_ITEM {COMPONENT_ITEM}
3167 -- | {COMPONENT_ITEM} VARIANT_PART
3171 -- Sloc points to first token of component list
3172 -- Component_Items (List3)
3173 -- Variant_Part (Node4) (set to Empty if no variant part)
3174 -- Null_Present (Flag13)
3176 -------------------------
3177 -- 3.8 Component Item --
3178 -------------------------
3180 -- COMPONENT_ITEM ::= COMPONENT_DECLARATION | REPRESENTATION_CLAUSE
3182 -- Note: A component item can also be a pragma, and in the tree
3183 -- that is obtained after semantic processing, a component item
3184 -- can be an N_Null node resulting from a non-recognized pragma.
3186 --------------------------------
3187 -- 3.8 Component Declaration --
3188 --------------------------------
3190 -- COMPONENT_DECLARATION ::=
3191 -- DEFINING_IDENTIFIER_LIST : COMPONENT_DEFINITION
3192 -- [:= DEFAULT_EXPRESSION]
3193 -- [ASPECT_SPECIFICATIONS];
3195 -- Note: although the syntax does not permit a component definition to
3196 -- be an anonymous array (and the parser will diagnose such an attempt
3197 -- with an appropriate message), it is possible for anonymous arrays
3198 -- to appear as component definitions. The semantics and back end handle
3199 -- this case properly, and the expander in fact generates such cases.
3201 -- Although the syntax allows multiple identifiers in the list, the
3202 -- semantics is as though successive declarations were given with the
3203 -- same component definition and expression components. To simplify
3204 -- semantic processing, the parser represents a multiple declaration
3205 -- case as a sequence of single declarations, using the More_Ids and
3206 -- Prev_Ids flags to preserve the original source form as described
3207 -- in the section on "Handling of Defining Identifier Lists".
3209 -- N_Component_Declaration
3210 -- Sloc points to first identifier
3211 -- Defining_Identifier (Node1)
3212 -- Component_Definition (Node4)
3213 -- Expression (Node3) (set to Empty if no default expression)
3214 -- More_Ids (Flag5) (set to False if no more identifiers in list)
3215 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
3217 -------------------------
3218 -- 3.8.1 Variant Part --
3219 -------------------------
3222 -- case discriminant_DIRECT_NAME is
3223 -- VARIANT {VARIANT}
3226 -- Note: the variants list can contain pragmas as well as variants.
3227 -- In a properly formed program there is at least one variant.
3230 -- Sloc points to CASE
3234 --------------------
3236 --------------------
3239 -- when DISCRETE_CHOICE_LIST =>
3243 -- Sloc points to WHEN
3244 -- Discrete_Choices (List4)
3245 -- Component_List (Node1)
3246 -- Enclosing_Variant (Node2-Sem)
3247 -- Present_Expr (Uint3-Sem)
3248 -- Dcheck_Function (Node5-Sem)
3249 -- Has_SP_Choice (Flag15-Sem)
3251 -- Note: in the list of Discrete_Choices, the tree passed to the back
3252 -- end does not have choice entries corresponding to names of statically
3253 -- predicated subtypes. Such entries are always expanded out to the list
3254 -- of equivalent values or ranges. The ASIS tree generated in -gnatct
3255 -- mode also has this expansion, but done with a proper Rewrite call on
3256 -- the N_Variant node so that ASIS can properly retrieve the original.
3258 ---------------------------------
3259 -- 3.8.1 Discrete Choice List --
3260 ---------------------------------
3262 -- DISCRETE_CHOICE_LIST ::= DISCRETE_CHOICE {| DISCRETE_CHOICE}
3264 ----------------------------
3265 -- 3.8.1 Discrete Choice --
3266 ----------------------------
3268 -- DISCRETE_CHOICE ::= EXPRESSION | DISCRETE_RANGE | others
3270 -- Note: in Ada 83 mode, the expression must be a simple expression
3272 -- The only choice that appears explicitly is the OTHERS choice, as
3273 -- defined here. Other cases of discrete choice (expression and
3274 -- discrete range) appear directly. This production is also used
3275 -- for the OTHERS possibility of an exception choice.
3277 -- Note: in accordance with the syntax, the parser does not check that
3278 -- OTHERS appears at the end on its own in a choice list context. This
3279 -- is a semantic check.
3282 -- Sloc points to OTHERS
3283 -- Others_Discrete_Choices (List1-Sem)
3284 -- All_Others (Flag11-Sem)
3286 ----------------------------------
3287 -- 3.9.1 Record Extension Part --
3288 ----------------------------------
3290 -- RECORD_EXTENSION_PART ::= with RECORD_DEFINITION
3292 -- Note: record extension parts are not permitted in Ada 83 mode
3294 --------------------------------------
3295 -- 3.9.4 Interface Type Definition --
3296 --------------------------------------
3298 -- INTERFACE_TYPE_DEFINITION ::=
3299 -- [limited | task | protected | synchronized]
3300 -- interface [interface_list]
3302 -- Note: Interfaces are implemented with N_Record_Definition and
3303 -- N_Derived_Type_Definition nodes because most of the support
3304 -- for the analysis of abstract types has been reused to
3305 -- analyze abstract interfaces.
3307 ----------------------------------
3308 -- 3.10 Access Type Definition --
3309 ----------------------------------
3311 -- ACCESS_TYPE_DEFINITION ::=
3312 -- ACCESS_TO_OBJECT_DEFINITION
3313 -- | ACCESS_TO_SUBPROGRAM_DEFINITION
3315 --------------------------
3316 -- 3.10 Null Exclusion --
3317 --------------------------
3319 -- NULL_EXCLUSION ::= not null
3321 ---------------------------------------
3322 -- 3.10 Access To Object Definition --
3323 ---------------------------------------
3325 -- ACCESS_TO_OBJECT_DEFINITION ::=
3326 -- [NULL_EXCLUSION] access [GENERAL_ACCESS_MODIFIER]
3327 -- SUBTYPE_INDICATION
3329 -- N_Access_To_Object_Definition
3330 -- Sloc points to ACCESS
3331 -- All_Present (Flag15)
3332 -- Null_Exclusion_Present (Flag11)
3333 -- Subtype_Indication (Node5)
3334 -- Constant_Present (Flag17)
3336 -----------------------------------
3337 -- 3.10 General Access Modifier --
3338 -----------------------------------
3340 -- GENERAL_ACCESS_MODIFIER ::= all | constant
3342 -- Note: general access modifiers are not permitted in Ada 83 mode
3344 -- There is no explicit node in the tree for general access modifier.
3345 -- Instead the All_Present or Constant_Present flags are set in the
3348 -------------------------------------------
3349 -- 3.10 Access To Subprogram Definition --
3350 -------------------------------------------
3352 -- ACCESS_TO_SUBPROGRAM_DEFINITION
3353 -- [NULL_EXCLUSION] access [protected] procedure PARAMETER_PROFILE
3354 -- | [NULL_EXCLUSION] access [protected] function
3355 -- PARAMETER_AND_RESULT_PROFILE
3357 -- Note: access to subprograms are not permitted in Ada 83 mode
3359 -- N_Access_Function_Definition
3360 -- Sloc points to ACCESS
3361 -- Null_Exclusion_Present (Flag11)
3362 -- Null_Exclusion_In_Return_Present (Flag14)
3363 -- Protected_Present (Flag6)
3364 -- Parameter_Specifications (List3) (set to No_List if no formal part)
3365 -- Result_Definition (Node4) result subtype (subtype mark or access def)
3367 -- N_Access_Procedure_Definition
3368 -- Sloc points to ACCESS
3369 -- Null_Exclusion_Present (Flag11)
3370 -- Protected_Present (Flag6)
3371 -- Parameter_Specifications (List3) (set to No_List if no formal part)
3373 -----------------------------
3374 -- 3.10 Access Definition --
3375 -----------------------------
3377 -- ACCESS_DEFINITION ::=
3378 -- [NULL_EXCLUSION] access [GENERAL_ACCESS_MODIFIER] SUBTYPE_MARK
3379 -- | ACCESS_TO_SUBPROGRAM_DEFINITION
3381 -- Note: access to subprograms are an Ada 2005 (AI-254) extension
3383 -- N_Access_Definition
3384 -- Sloc points to ACCESS
3385 -- Null_Exclusion_Present (Flag11)
3386 -- All_Present (Flag15)
3387 -- Constant_Present (Flag17)
3388 -- Subtype_Mark (Node4)
3389 -- Access_To_Subprogram_Definition (Node3) (set to Empty if not present)
3391 -----------------------------------------
3392 -- 3.10.1 Incomplete Type Declaration --
3393 -----------------------------------------
3395 -- INCOMPLETE_TYPE_DECLARATION ::=
3396 -- type DEFINING_IDENTIFIER [DISCRIMINANT_PART] [IS TAGGED];
3398 -- N_Incomplete_Type_Declaration
3399 -- Sloc points to TYPE
3400 -- Defining_Identifier (Node1)
3401 -- Discriminant_Specifications (List4) (set to No_List if no
3402 -- discriminant part, or if the discriminant part is an
3403 -- unknown discriminant part)
3404 -- Premature_Use (Node5-Sem) used for improved diagnostics.
3405 -- Unknown_Discriminants_Present (Flag13) set if (<>) discriminant
3406 -- Tagged_Present (Flag15)
3408 ----------------------------
3409 -- 3.11 Declarative Part --
3410 ----------------------------
3412 -- DECLARATIVE_PART ::= {DECLARATIVE_ITEM}
3414 -- Note: although the parser enforces the syntactic requirement that
3415 -- a declarative part can contain only declarations, the semantic
3416 -- processing may add statements to the list of actions in a
3417 -- declarative part, so the code generator should be prepared
3418 -- to accept a statement in this position.
3420 ----------------------------
3421 -- 3.11 Declarative Item --
3422 ----------------------------
3424 -- DECLARATIVE_ITEM ::= BASIC_DECLARATIVE_ITEM | BODY
3426 ----------------------------------
3427 -- 3.11 Basic Declarative Item --
3428 ----------------------------------
3430 -- BASIC_DECLARATIVE_ITEM ::=
3431 -- BASIC_DECLARATION | REPRESENTATION_CLAUSE | USE_CLAUSE
3437 -- BODY ::= PROPER_BODY | BODY_STUB
3439 -----------------------
3440 -- 3.11 Proper Body --
3441 -----------------------
3444 -- SUBPROGRAM_BODY | PACKAGE_BODY | TASK_BODY | PROTECTED_BODY
3451 -- DIRECT_NAME | EXPLICIT_DEREFERENCE
3452 -- | INDEXED_COMPONENT | SLICE
3453 -- | SELECTED_COMPONENT | ATTRIBUTE_REFERENCE
3454 -- | TYPE_CONVERSION | FUNCTION_CALL
3455 -- | CHARACTER_LITERAL
3457 ----------------------
3458 -- 4.1 Direct Name --
3459 ----------------------
3461 -- DIRECT_NAME ::= IDENTIFIER | OPERATOR_SYMBOL
3467 -- PREFIX ::= NAME | IMPLICIT_DEREFERENCE
3469 -------------------------------
3470 -- 4.1 Explicit Dereference --
3471 -------------------------------
3473 -- EXPLICIT_DEREFERENCE ::= NAME . all
3475 -- N_Explicit_Dereference
3476 -- Sloc points to ALL
3478 -- Actual_Designated_Subtype (Node4-Sem)
3479 -- Atomic_Sync_Required (Flag14-Sem)
3480 -- Has_Dereference_Action (Flag13-Sem)
3481 -- plus fields for expression
3483 -------------------------------
3484 -- 4.1 Implicit Dereference --
3485 -------------------------------
3487 -- IMPLICIT_DEREFERENCE ::= NAME
3489 ------------------------------
3490 -- 4.1.1 Indexed Component --
3491 ------------------------------
3493 -- INDEXED_COMPONENT ::= PREFIX (EXPRESSION {, EXPRESSION})
3495 -- Note: the parser may generate this node in some situations where it
3496 -- should be a function call. The semantic pass must correct this
3497 -- misidentification (which is inevitable at the parser level).
3499 -- N_Indexed_Component
3500 -- Sloc contains a copy of the Sloc value of the Prefix
3502 -- Expressions (List1)
3503 -- Generalized_Indexing (Node4-Sem)
3504 -- Atomic_Sync_Required (Flag14-Sem)
3505 -- plus fields for expression
3507 -- Note: if any of the subscripts requires a range check, then the
3508 -- Do_Range_Check flag is set on the corresponding expression, with
3509 -- the index type being determined from the type of the Prefix, which
3510 -- references the array being indexed.
3512 -- Note: in a fully analyzed and expanded indexed component node, and
3513 -- hence in any such node that gigi sees, if the prefix is an access
3514 -- type, then an explicit dereference operation has been inserted.
3520 -- SLICE ::= PREFIX (DISCRETE_RANGE)
3522 -- Note: an implicit subtype is created to describe the resulting
3523 -- type, so that the bounds of this type are the bounds of the slice.
3526 -- Sloc points to first token of prefix
3528 -- Discrete_Range (Node4)
3529 -- plus fields for expression
3531 -------------------------------
3532 -- 4.1.3 Selected Component --
3533 -------------------------------
3535 -- SELECTED_COMPONENT ::= PREFIX . SELECTOR_NAME
3537 -- Note: selected components that are semantically expanded names get
3538 -- changed during semantic processing into the separate N_Expanded_Name
3539 -- node. See description of this node in the section on semantic nodes.
3541 -- N_Selected_Component
3542 -- Sloc points to period
3544 -- Selector_Name (Node2)
3545 -- Associated_Node (Node4-Sem)
3546 -- Do_Discriminant_Check (Flag1-Sem)
3547 -- Is_In_Discriminant_Check (Flag11-Sem)
3548 -- Is_Prefixed_Call (Flag17-Sem)
3549 -- Atomic_Sync_Required (Flag14-Sem)
3550 -- plus fields for expression
3552 --------------------------
3553 -- 4.1.3 Selector Name --
3554 --------------------------
3556 -- SELECTOR_NAME ::= IDENTIFIER | CHARACTER_LITERAL | OPERATOR_SYMBOL
3558 --------------------------------
3559 -- 4.1.4 Attribute Reference --
3560 --------------------------------
3562 -- ATTRIBUTE_REFERENCE ::= PREFIX ' ATTRIBUTE_DESIGNATOR
3564 -- Note: the syntax is quite ambiguous at this point. Consider:
3566 -- A'Length (X) X is part of the attribute designator
3567 -- A'Pos (X) X is an explicit actual parameter of function A'Pos
3568 -- A'Class (X) X is the expression of a type conversion
3570 -- It would be possible for the parser to distinguish these cases
3571 -- by looking at the attribute identifier. However, that would mean
3572 -- more work in introducing new implementation defined attributes,
3573 -- and also it would mean that special processing for attributes
3574 -- would be scattered around, instead of being centralized in the
3575 -- semantic routine that handles an N_Attribute_Reference node.
3576 -- Consequently, the parser in all the above cases stores the
3577 -- expression (X in these examples) as a single element list in
3578 -- in the Expressions field of the N_Attribute_Reference node.
3580 -- Similarly, for attributes like Max which take two arguments,
3581 -- we store the two arguments as a two element list in the
3582 -- Expressions field. Of course it is clear at parse time that
3583 -- this case is really a function call with an attribute as the
3584 -- prefix, but it turns out to be convenient to handle the two
3585 -- argument case in a similar manner to the one argument case,
3586 -- and indeed in general the parser will accept any number of
3587 -- expressions in this position and store them as a list in the
3588 -- attribute reference node. This allows for future addition of
3589 -- attributes that take more than two arguments.
3591 -- Note: named associates are not permitted in function calls where
3592 -- the function is an attribute (see RM 6.4(3)) so it is legitimate
3593 -- to skip the normal subprogram argument processing.
3595 -- Note: for the attributes whose designators are technically keywords,
3596 -- i.e. digits, access, delta, range, the Attribute_Name field contains
3597 -- the corresponding name, even though no identifier is involved.
3599 -- Note: the generated code may contain stream attributes applied to
3600 -- limited types for which no stream routines exist officially. In such
3601 -- case, the result is to use the stream attribute for the underlying
3602 -- full type, or in the case of a protected type, the components
3603 -- (including any discriminants) are merely streamed in order.
3605 -- See Exp_Attr for a complete description of which attributes are
3606 -- passed onto Gigi, and which are handled entirely by the front end.
3608 -- Gigi restriction: For the Pos attribute, the prefix cannot be
3609 -- a non-standard enumeration type or a nonzero/zero semantics
3610 -- boolean type, so the value is simply the stored representation.
3612 -- Gigi requirement: For the Mechanism_Code attribute, if the prefix
3613 -- references a subprogram that is a renaming, then the front end must
3614 -- rewrite the attribute to refer directly to the renamed entity.
3616 -- Note: In generated code, the Address and Unrestricted_Access
3617 -- attributes can be applied to any expression, and the meaning is
3618 -- to create an object containing the value (the object is in the
3619 -- current stack frame), and pass the address of this value. If the
3620 -- Must_Be_Byte_Aligned flag is set, then the object whose address
3621 -- is taken must be on a byte (storage unit) boundary, and if it is
3622 -- not (or may not be), then the generated code must create a copy
3623 -- that is byte aligned, and pass the address of this copy.
3625 -- N_Attribute_Reference
3626 -- Sloc points to apostrophe
3628 -- Attribute_Name (Name2) identifier name from attribute designator
3629 -- Expressions (List1) (set to No_List if no associated expressions)
3630 -- Entity (Node4-Sem) used if the attribute yields a type
3631 -- Associated_Node (Node4-Sem)
3632 -- Do_Overflow_Check (Flag17-Sem)
3633 -- Header_Size_Added (Flag11-Sem)
3634 -- Must_Be_Byte_Aligned (Flag14-Sem)
3635 -- Non_Aliased_Prefix (Flag18-Sem)
3636 -- Redundant_Use (Flag13-Sem)
3638 -- plus fields for expression
3640 -- Note: in Modify_Tree_For_C mode, Max and Min attributes are expanded
3641 -- into equivalent if expressions, properly taking care of side effects.
3643 ---------------------------------
3644 -- 4.1.4 Attribute Designator --
3645 ---------------------------------
3647 -- ATTRIBUTE_DESIGNATOR ::=
3648 -- IDENTIFIER [(static_EXPRESSION)]
3649 -- | access | delta | digits
3651 -- There is no explicit node in the tree for an attribute designator.
3652 -- Instead the Attribute_Name and Expressions fields of the parent
3653 -- node (N_Attribute_Reference node) hold the information.
3655 -- Note: if ACCESS, DELTA or DIGITS appears in an attribute
3656 -- designator, then they are treated as identifiers internally
3657 -- rather than the keywords of the same name.
3659 --------------------------------------
3660 -- 4.1.4 Range Attribute Reference --
3661 --------------------------------------
3663 -- RANGE_ATTRIBUTE_REFERENCE ::= PREFIX ' RANGE_ATTRIBUTE_DESIGNATOR
3665 -- A range attribute reference is represented in the tree using the
3666 -- normal N_Attribute_Reference node.
3668 ---------------------------------------
3669 -- 4.1.4 Range Attribute Designator --
3670 ---------------------------------------
3672 -- RANGE_ATTRIBUTE_DESIGNATOR ::= Range [(static_EXPRESSION)]
3674 -- A range attribute designator is represented in the tree using the
3675 -- normal N_Attribute_Reference node.
3677 --------------------
3679 --------------------
3682 -- RECORD_AGGREGATE | EXTENSION_AGGREGATE | ARRAY_AGGREGATE
3684 -----------------------------
3685 -- 4.3.1 Record Aggregate --
3686 -----------------------------
3688 -- RECORD_AGGREGATE ::= (RECORD_COMPONENT_ASSOCIATION_LIST)
3691 -- Sloc points to left parenthesis
3692 -- Expressions (List1) (set to No_List if none or null record case)
3693 -- Component_Associations (List2) (set to No_List if none)
3694 -- Null_Record_Present (Flag17)
3695 -- Aggregate_Bounds (Node3-Sem)
3696 -- Associated_Node (Node4-Sem)
3697 -- Compile_Time_Known_Aggregate (Flag18-Sem)
3698 -- Expansion_Delayed (Flag11-Sem)
3699 -- Has_Self_Reference (Flag13-Sem)
3700 -- plus fields for expression
3702 -- Note: this structure is used for both record and array aggregates
3703 -- since the two cases are not separable by the parser. The parser
3704 -- makes no attempt to enforce consistency here, so it is up to the
3705 -- semantic phase to make sure that the aggregate is consistent (i.e.
3706 -- that it is not a "half-and-half" case that mixes record and array
3707 -- syntax. In particular, for a record aggregate, the expressions
3708 -- field will be set if there are positional associations.
3710 -- Note: N_Aggregate is not used for all aggregates; in particular,
3711 -- there is a separate node kind for extension aggregates.
3713 -- Note: gigi/gcc can handle array aggregates correctly providing that
3714 -- they are entirely positional, and the array subtype involved has a
3715 -- known at compile time length and is not bit packed, or a convention
3716 -- Fortran array with more than one dimension. If these conditions
3717 -- are not met, then the front end must translate the aggregate into
3718 -- an appropriate set of assignments into a temporary.
3720 -- Note: for the record aggregate case, gigi/gcc can handle all cases of
3721 -- record aggregates, including those for packed, and rep-claused
3722 -- records, and also variant records, providing that there are no
3723 -- variable length fields whose size is not known at compile time, and
3724 -- providing that the aggregate is presented in fully named form.
3726 ----------------------------------------------
3727 -- 4.3.1 Record Component Association List --
3728 ----------------------------------------------
3730 -- RECORD_COMPONENT_ASSOCIATION_LIST ::=
3731 -- RECORD_COMPONENT_ASSOCIATION {, RECORD_COMPONENT_ASSOCIATION}
3734 -- There is no explicit node in the tree for a record component
3735 -- association list. Instead the Null_Record_Present flag is set in
3736 -- the parent node for the NULL RECORD case.
3738 ------------------------------------------------------
3739 -- 4.3.1 Record Component Association (also 4.3.3) --
3740 ------------------------------------------------------
3742 -- RECORD_COMPONENT_ASSOCIATION ::=
3743 -- [COMPONENT_CHOICE_LIST =>] EXPRESSION
3745 -- N_Component_Association
3746 -- Sloc points to first selector name
3748 -- Loop_Actions (List2-Sem)
3749 -- Expression (Node3) (empty if Box_Present)
3750 -- Box_Present (Flag15)
3751 -- Inherited_Discriminant (Flag13)
3753 -- Note: this structure is used for both record component associations
3754 -- and array component associations, since the two cases aren't always
3755 -- separable by the parser. The choices list may represent either a
3756 -- list of selector names in the record aggregate case, or a list of
3757 -- discrete choices in the array aggregate case or an N_Others_Choice
3758 -- node (which appears as a singleton list). Box_Present gives support
3759 -- to Ada 2005 (AI-287).
3761 ----------------------------------
3762 -- 4.3.1 Component Choice List --
3763 ----------------------------------
3765 -- COMPONENT_CHOICE_LIST ::=
3766 -- component_SELECTOR_NAME {| component_SELECTOR_NAME}
3769 -- The entries of a component choice list appear in the Choices list of
3770 -- the associated N_Component_Association, as either selector names, or
3771 -- as an N_Others_Choice node.
3773 --------------------------------
3774 -- 4.3.2 Extension Aggregate --
3775 --------------------------------
3777 -- EXTENSION_AGGREGATE ::=
3778 -- (ANCESTOR_PART with RECORD_COMPONENT_ASSOCIATION_LIST)
3780 -- Note: extension aggregates are not permitted in Ada 83 mode
3782 -- N_Extension_Aggregate
3783 -- Sloc points to left parenthesis
3784 -- Ancestor_Part (Node3)
3785 -- Associated_Node (Node4-Sem)
3786 -- Expressions (List1) (set to No_List if none or null record case)
3787 -- Component_Associations (List2) (set to No_List if none)
3788 -- Null_Record_Present (Flag17)
3789 -- Expansion_Delayed (Flag11-Sem)
3790 -- Has_Self_Reference (Flag13-Sem)
3791 -- plus fields for expression
3793 --------------------------
3794 -- 4.3.2 Ancestor Part --
3795 --------------------------
3797 -- ANCESTOR_PART ::= EXPRESSION | SUBTYPE_MARK
3799 ----------------------------
3800 -- 4.3.3 Array Aggregate --
3801 ----------------------------
3803 -- ARRAY_AGGREGATE ::=
3804 -- POSITIONAL_ARRAY_AGGREGATE | NAMED_ARRAY_AGGREGATE
3806 ---------------------------------------
3807 -- 4.3.3 Positional Array Aggregate --
3808 ---------------------------------------
3810 -- POSITIONAL_ARRAY_AGGREGATE ::=
3811 -- (EXPRESSION, EXPRESSION {, EXPRESSION})
3812 -- | (EXPRESSION {, EXPRESSION}, others => EXPRESSION)
3814 -- See Record_Aggregate (4.3.1) for node structure
3816 ----------------------------------
3817 -- 4.3.3 Named Array Aggregate --
3818 ----------------------------------
3820 -- NAMED_ARRAY_AGGREGATE ::=
3821 -- | (ARRAY_COMPONENT_ASSOCIATION {, ARRAY_COMPONENT_ASSOCIATION})
3823 -- See Record_Aggregate (4.3.1) for node structure
3825 ----------------------------------------
3826 -- 4.3.3 Array Component Association --
3827 ----------------------------------------
3829 -- ARRAY_COMPONENT_ASSOCIATION ::=
3830 -- DISCRETE_CHOICE_LIST => EXPRESSION
3832 -- See Record_Component_Association (4.3.1) for node structure
3834 --------------------------------------------------
3835 -- 4.4 Expression/Relation/Term/Factor/Primary --
3836 --------------------------------------------------
3839 -- RELATION {LOGICAL_OPERATOR RELATION}
3841 -- CHOICE_EXPRESSION ::=
3842 -- CHOICE_RELATION {LOGICAL_OPERATOR CHOICE_RELATION}
3844 -- CHOICE_RELATION ::=
3845 -- SIMPLE_EXPRESSION [RELATIONAL_OPERATOR SIMPLE_EXPRESSION]
3848 -- SIMPLE_EXPRESSION [not] in MEMBERSHIP_CHOICE_LIST
3849 -- | RAISE_EXPRESSION
3851 -- MEMBERSHIP_CHOICE_LIST ::=
3852 -- MEMBERSHIP_CHOICE {'|' MEMBERSHIP CHOICE}
3854 -- MEMBERSHIP_CHOICE ::=
3855 -- CHOICE_EXPRESSION | RANGE | SUBTYPE_MARK
3857 -- LOGICAL_OPERATOR ::= and | and then | or | or else | xor
3859 -- SIMPLE_EXPRESSION ::=
3860 -- [UNARY_ADDING_OPERATOR] TERM {BINARY_ADDING_OPERATOR TERM}
3862 -- TERM ::= FACTOR {MULTIPLYING_OPERATOR FACTOR}
3864 -- FACTOR ::= PRIMARY [** PRIMARY] | abs PRIMARY | not PRIMARY
3866 -- No nodes are generated for any of these constructs. Instead, the
3867 -- node for the operator appears directly. When we refer to an
3868 -- expression in this description, we mean any of the possible
3869 -- constituent components of an expression (e.g. identifier is
3870 -- an example of an expression).
3872 -- Note: the above syntax is that Ada 2012 syntax which restricts
3873 -- choice relations to simple expressions to avoid ambiguities in
3874 -- some contexts with set membership notation. It has been decided
3875 -- that in retrospect, the Ada 95 change allowing general expressions
3876 -- in this context was a mistake, so we have reverted to the above
3877 -- syntax in Ada 95 and Ada 2005 modes (the restriction to simple
3878 -- expressions was there in Ada 83 from the start).
3885 -- NUMERIC_LITERAL | null
3886 -- | STRING_LITERAL | AGGREGATE
3887 -- | NAME | QUALIFIED_EXPRESSION
3888 -- | ALLOCATOR | (EXPRESSION)
3890 -- Usually there is no explicit node in the tree for primary. Instead
3891 -- the constituent (e.g. AGGREGATE) appears directly. There are two
3892 -- exceptions. First, there is an explicit node for a null primary.
3895 -- Sloc points to NULL
3896 -- plus fields for expression
3898 -- Second, the case of (EXPRESSION) is handled specially. Ada requires
3899 -- that the parser keep track of which subexpressions are enclosed
3900 -- in parentheses, and how many levels of parentheses are used. This
3901 -- information is required for optimization purposes, and also for
3902 -- some semantic checks (e.g. (((1))) in a procedure spec does not
3903 -- conform with ((((1)))) in the body).
3905 -- The parentheses are recorded by keeping a Paren_Count field in every
3906 -- subexpression node (it is actually present in all nodes, but only
3907 -- used in subexpression nodes). This count records the number of
3908 -- levels of parentheses. If the number of levels in the source exceeds
3909 -- the maximum accommodated by this count, then the count is simply left
3910 -- at the maximum value. This means that there are some pathological
3911 -- cases of failure to detect conformance failures (e.g. an expression
3912 -- with 500 levels of parens will conform with one with 501 levels),
3913 -- but we do not need to lose sleep over this.
3915 -- Historical note: in versions of GNAT prior to 1.75, there was a node
3916 -- type N_Parenthesized_Expression used to accurately record unlimited
3917 -- numbers of levels of parentheses. However, it turned out to be a
3918 -- real nuisance to have to take into account the possible presence of
3919 -- this node during semantic analysis, since basically parentheses have
3920 -- zero relevance to semantic analysis.
3922 -- Note: the level of parentheses always present in things like
3923 -- aggregates does not count, only the parentheses in the primary
3924 -- (EXPRESSION) affect the setting of the Paren_Count field.
3926 -- 2nd Note: the contents of the Expression field must be ignored (i.e.
3927 -- treated as though it were Empty) if No_Initialization is set True.
3929 --------------------------------------
3930 -- 4.5 Short Circuit Control Forms --
3931 --------------------------------------
3934 -- RELATION {and then RELATION} | RELATION {or else RELATION}
3936 -- Gigi restriction: For both these control forms, the operand and
3937 -- result types are always Standard.Boolean. The expander inserts the
3938 -- required conversion operations where needed to ensure this is the
3942 -- Sloc points to AND of AND THEN
3943 -- Left_Opnd (Node2)
3944 -- Right_Opnd (Node3)
3945 -- Actions (List1-Sem)
3946 -- plus fields for expression
3949 -- Sloc points to OR of OR ELSE
3950 -- Left_Opnd (Node2)
3951 -- Right_Opnd (Node3)
3952 -- Actions (List1-Sem)
3953 -- plus fields for expression
3955 -- Note: The Actions field is used to hold actions associated with
3956 -- the right hand operand. These have to be treated specially since
3957 -- they are not unconditionally executed. See Insert_Actions for a
3958 -- more detailed description of how these actions are handled.
3960 ---------------------------
3961 -- 4.5 Membership Tests --
3962 ---------------------------
3965 -- SIMPLE_EXPRESSION [not] in MEMBERSHIP_CHOICE_LIST
3967 -- MEMBERSHIP_CHOICE_LIST ::=
3968 -- MEMBERSHIP_CHOICE {'|' MEMBERSHIP CHOICE}
3970 -- MEMBERSHIP_CHOICE ::=
3971 -- CHOICE_EXPRESSION | RANGE | SUBTYPE_MARK
3973 -- Note: although the grammar above allows only a range or a subtype
3974 -- mark, the parser in fact will accept any simple expression in place
3975 -- of a subtype mark. This means that the semantic analyzer must be able
3976 -- to deal with, and diagnose a simple expression other than a name for
3977 -- the right operand. This simplifies error recovery in the parser.
3979 -- The Alternatives field below is present only if there is more
3980 -- than one Membership_Choice present (which is legitimate only in
3981 -- Ada 2012 mode) in which case Right_Opnd is Empty, and Alternatives
3982 -- contains the list of choices. In the tree passed to the back end,
3983 -- Alternatives is always No_List, and Right_Opnd is set (i.e. the
3984 -- expansion circuitry expands out the complex set membership case
3985 -- using simple membership operations).
3987 -- Should we rename Alternatives here to Membership_Choices ???
3990 -- Sloc points to IN
3991 -- Left_Opnd (Node2)
3992 -- Right_Opnd (Node3)
3993 -- Alternatives (List4) (set to No_List if only one set alternative)
3994 -- No_Minimize_Eliminate (Flag17)
3995 -- plus fields for expression
3998 -- Sloc points to NOT of NOT IN
3999 -- Left_Opnd (Node2)
4000 -- Right_Opnd (Node3)
4001 -- Alternatives (List4) (set to No_List if only one set alternative)
4002 -- No_Minimize_Eliminate (Flag17)
4003 -- plus fields for expression
4005 --------------------
4007 --------------------
4009 -- LOGICAL_OPERATOR ::= and | or | xor
4011 -- RELATIONAL_OPERATOR ::= = | /= | < | <= | > | >=
4013 -- BINARY_ADDING_OPERATOR ::= + | - | &
4015 -- UNARY_ADDING_OPERATOR ::= + | -
4017 -- MULTIPLYING_OPERATOR ::= * | / | mod | rem
4019 -- HIGHEST_PRECEDENCE_OPERATOR ::= ** | abs | not
4021 -- Sprint syntax if Treat_Fixed_As_Integer is set:
4028 -- Gigi restriction: For * / mod rem with fixed-point operands, Gigi
4029 -- will only be given nodes with the Treat_Fixed_As_Integer flag set.
4030 -- All handling of smalls for multiplication and division is handled
4031 -- by the front end (mod and rem result only from expansion). Gigi
4032 -- thus never needs to worry about small values (for other operators
4033 -- operating on fixed-point, e.g. addition, the small value does not
4034 -- have any semantic effect anyway, these are always integer operations.
4036 -- Gigi restriction: For all operators taking Boolean operands, the
4037 -- type is always Standard.Boolean. The expander inserts the required
4038 -- conversion operations where needed to ensure this is the case.
4041 -- Sloc points to AND
4042 -- Do_Length_Check (Flag4-Sem)
4043 -- plus fields for binary operator
4044 -- plus fields for expression
4047 -- Sloc points to OR
4048 -- Do_Length_Check (Flag4-Sem)
4049 -- plus fields for binary operator
4050 -- plus fields for expression
4053 -- Sloc points to XOR
4054 -- Do_Length_Check (Flag4-Sem)
4055 -- plus fields for binary operator
4056 -- plus fields for expression
4060 -- plus fields for binary operator
4061 -- plus fields for expression
4064 -- Sloc points to /=
4065 -- plus fields for binary operator
4066 -- plus fields for expression
4070 -- plus fields for binary operator
4071 -- plus fields for expression
4074 -- Sloc points to <=
4075 -- plus fields for binary operator
4076 -- plus fields for expression
4080 -- plus fields for binary operator
4081 -- plus fields for expression
4084 -- Sloc points to >=
4085 -- plus fields for binary operator
4086 -- plus fields for expression
4089 -- Sloc points to + (binary)
4090 -- plus fields for binary operator
4091 -- plus fields for expression
4094 -- Sloc points to - (binary)
4095 -- plus fields for binary operator
4096 -- plus fields for expression
4100 -- Is_Component_Left_Opnd (Flag13-Sem)
4101 -- Is_Component_Right_Opnd (Flag14-Sem)
4102 -- plus fields for binary operator
4103 -- plus fields for expression
4107 -- Treat_Fixed_As_Integer (Flag14-Sem)
4108 -- Rounded_Result (Flag18-Sem)
4109 -- plus fields for binary operator
4110 -- plus fields for expression
4114 -- Treat_Fixed_As_Integer (Flag14-Sem)
4115 -- Do_Division_Check (Flag13-Sem)
4116 -- Rounded_Result (Flag18-Sem)
4117 -- plus fields for binary operator
4118 -- plus fields for expression
4121 -- Sloc points to MOD
4122 -- Treat_Fixed_As_Integer (Flag14-Sem)
4123 -- Do_Division_Check (Flag13-Sem)
4124 -- plus fields for binary operator
4125 -- plus fields for expression
4128 -- Sloc points to REM
4129 -- Treat_Fixed_As_Integer (Flag14-Sem)
4130 -- Do_Division_Check (Flag13-Sem)
4131 -- plus fields for binary operator
4132 -- plus fields for expression
4135 -- Is_Power_Of_2_For_Shift (Flag13-Sem)
4136 -- Sloc points to **
4137 -- plus fields for binary operator
4138 -- plus fields for expression
4141 -- Sloc points to + (unary)
4142 -- plus fields for unary operator
4143 -- plus fields for expression
4146 -- Sloc points to - (unary)
4147 -- plus fields for unary operator
4148 -- plus fields for expression
4151 -- Sloc points to ABS
4152 -- plus fields for unary operator
4153 -- plus fields for expression
4156 -- Sloc points to NOT
4157 -- plus fields for unary operator
4158 -- plus fields for expression
4160 -- See also shift operators in section B.2
4162 -- Note on fixed-point operations passed to Gigi: For adding operators,
4163 -- the semantics is to treat these simply as integer operations, with
4164 -- the small values being ignored (the bounds are already stored in
4165 -- units of small, so that constraint checking works as usual). For the
4166 -- case of multiply/divide/rem/mod operations, Gigi will only see fixed
4167 -- point operands if the Treat_Fixed_As_Integer flag is set and will
4168 -- thus treat these nodes in identical manner, ignoring small values.
4170 -- Note on overflow handling: When the overflow checking mode is set to
4171 -- MINIMIZED or ELIMINATED, nodes for signed arithmetic operations may
4172 -- be modified to use a larger type for the operands and result. In
4173 -- the case where the computed range exceeds that of Long_Long_Integer,
4174 -- and we are running in ELIMINATED mode, the operator node will be
4175 -- changed to be a call to the appropriate routine in System.Bignums.
4177 -- Note: In Modify_Tree_For_C mode, we do not generate an N_Op_Mod node
4178 -- for signed integer types (since there is no equivalent operator in
4179 -- C). Instead we rewrite such an operation in terms of REM (which is
4180 -- % in C) and other C-available operators.
4182 ------------------------------------
4183 -- 4.5.7 Conditional Expressions --
4184 ------------------------------------
4186 -- CONDITIONAL_EXPRESSION ::= IF_EXPRESSION | CASE_EXPRESSION
4188 --------------------------
4189 -- 4.5.7 If Expression --
4190 ----------------------------
4192 -- IF_EXPRESSION ::=
4193 -- if CONDITION then DEPENDENT_EXPRESSION
4194 -- {elsif CONDITION then DEPENDENT_EXPRESSION}
4195 -- [else DEPENDENT_EXPRESSION]
4197 -- DEPENDENT_EXPRESSION ::= EXPRESSION
4199 -- Note: if we have (IF x1 THEN x2 ELSIF x3 THEN x4 ELSE x5) then it
4200 -- is represented as (IF x1 THEN x2 ELSE (IF x3 THEN x4 ELSE x5)) and
4201 -- the Is_Elsif flag is set on the inner if expression.
4204 -- Sloc points to IF or ELSIF keyword
4205 -- Expressions (List1)
4206 -- Then_Actions (List2-Sem)
4207 -- Else_Actions (List3-Sem)
4208 -- Is_Elsif (Flag13) (set if comes from ELSIF)
4209 -- Do_Overflow_Check (Flag17-Sem)
4210 -- plus fields for expression
4212 -- Expressions here is a three-element list, whose first element is the
4213 -- condition, the second element is the dependent expression after THEN
4214 -- and the third element is the dependent expression after the ELSE
4215 -- (explicitly set to True if missing).
4217 -- Note: the Then_Actions and Else_Actions fields are always set to
4218 -- No_List in the tree passed to Gigi. These fields are used only
4219 -- for temporary processing purposes in the expander.
4221 ----------------------------
4222 -- 4.5.7 Case Expression --
4223 ----------------------------
4225 -- CASE_EXPRESSION ::=
4226 -- case SELECTING_EXPRESSION is
4227 -- CASE_EXPRESSION_ALTERNATIVE
4228 -- {CASE_EXPRESSION_ALTERNATIVE}
4230 -- Note that the Alternatives cannot include pragmas (this contrasts
4231 -- with the situation of case statements where pragmas are allowed).
4233 -- N_Case_Expression
4234 -- Sloc points to CASE
4235 -- Expression (Node3) (the selecting expression)
4236 -- Alternatives (List4) (the case expression alternatives)
4237 -- Do_Overflow_Check (Flag17-Sem)
4239 ----------------------------------------
4240 -- 4.5.7 Case Expression Alternative --
4241 ----------------------------------------
4243 -- CASE_EXPRESSION_ALTERNATIVE ::=
4244 -- when DISCRETE_CHOICE_LIST =>
4245 -- DEPENDENT_EXPRESSION
4247 -- N_Case_Expression_Alternative
4248 -- Sloc points to WHEN
4250 -- Discrete_Choices (List4)
4251 -- Expression (Node3)
4252 -- Has_SP_Choice (Flag15-Sem)
4254 -- Note: The Actions field temporarily holds any actions associated with
4255 -- evaluation of the Expression. During expansion of the case expression
4256 -- these actions are wrapped into an N_Expressions_With_Actions node
4257 -- replacing the original expression.
4259 -- Note: this node never appears in the tree passed to the back end,
4260 -- since the expander converts case expressions into case statements.
4262 ---------------------------------
4263 -- 4.5.9 Quantified Expression --
4264 ---------------------------------
4266 -- QUANTIFIED_EXPRESSION ::=
4267 -- for QUANTIFIER LOOP_PARAMETER_SPECIFICATION => PREDICATE
4268 -- | for QUANTIFIER ITERATOR_SPECIFICATION => PREDICATE
4270 -- QUANTIFIER ::= all | some
4272 -- At most one of (Iterator_Specification, Loop_Parameter_Specification)
4273 -- is present at a time, in which case the other one is empty.
4275 -- N_Quantified_Expression
4276 -- Sloc points to FOR
4277 -- Iterator_Specification (Node2)
4278 -- Loop_Parameter_Specification (Node4)
4279 -- Condition (Node1)
4280 -- All_Present (Flag15)
4282 --------------------------
4283 -- 4.6 Type Conversion --
4284 --------------------------
4286 -- TYPE_CONVERSION ::=
4287 -- SUBTYPE_MARK (EXPRESSION) | SUBTYPE_MARK (NAME)
4289 -- In the (NAME) case, the name is stored as the expression
4291 -- Note: the parser never generates a type conversion node, since it
4292 -- looks like an indexed component which is generated by preference.
4293 -- The semantic pass must correct this misidentification.
4295 -- Gigi handles conversions that involve no change in the root type,
4296 -- and also all conversions from integer to floating-point types.
4297 -- Conversions from floating-point to integer are only handled in
4298 -- the case where Float_Truncate flag set. Other conversions from
4299 -- floating-point to integer (involving rounding) and all conversions
4300 -- involving fixed-point types are handled by the expander.
4302 -- Sprint syntax if Float_Truncate set: X^(Y)
4303 -- Sprint syntax if Conversion_OK set X?(Y)
4304 -- Sprint syntax if both flags set X?^(Y)
4306 -- Note: If either the operand or result type is fixed-point, Gigi will
4307 -- only see a type conversion node with Conversion_OK set. The front end
4308 -- takes care of all handling of small's for fixed-point conversions.
4310 -- N_Type_Conversion
4311 -- Sloc points to first token of subtype mark
4312 -- Subtype_Mark (Node4)
4313 -- Expression (Node3)
4314 -- Do_Discriminant_Check (Flag1-Sem)
4315 -- Do_Length_Check (Flag4-Sem)
4316 -- Float_Truncate (Flag11-Sem)
4317 -- Do_Tag_Check (Flag13-Sem)
4318 -- Conversion_OK (Flag14-Sem)
4319 -- Do_Overflow_Check (Flag17-Sem)
4320 -- Rounded_Result (Flag18-Sem)
4321 -- plus fields for expression
4323 -- Note: if a range check is required, then the Do_Range_Check flag
4324 -- is set in the Expression with the check being done against the
4325 -- target type range (after the base type conversion, if any).
4327 -------------------------------
4328 -- 4.7 Qualified Expression --
4329 -------------------------------
4331 -- QUALIFIED_EXPRESSION ::=
4332 -- SUBTYPE_MARK ' (EXPRESSION) | SUBTYPE_MARK ' AGGREGATE
4334 -- Note: the parentheses in the (EXPRESSION) case are deemed to enclose
4335 -- the expression, so the Expression field of this node always points
4336 -- to a parenthesized expression in this case (i.e. Paren_Count will
4337 -- always be non-zero for the referenced expression if it is not an
4340 -- N_Qualified_Expression
4341 -- Sloc points to apostrophe
4342 -- Subtype_Mark (Node4)
4343 -- Expression (Node3) expression or aggregate
4344 -- plus fields for expression
4346 --------------------
4348 --------------------
4351 -- new [SUBPOOL_SPECIFICATION] SUBTYPE_INDICATION
4352 -- | new [SUBPOOL_SPECIFICATION] QUALIFIED_EXPRESSION
4354 -- SUBPOOL_SPECIFICATION ::= (subpool_handle_NAME)
4356 -- Sprint syntax (when storage pool present)
4357 -- new xxx (storage_pool = pool)
4359 -- new (subpool) xxx (storage_pool = pool)
4362 -- Sloc points to NEW
4363 -- Expression (Node3) subtype indication or qualified expression
4364 -- Subpool_Handle_Name (Node4) (set to Empty if not present)
4365 -- Storage_Pool (Node1-Sem)
4366 -- Procedure_To_Call (Node2-Sem)
4367 -- Null_Exclusion_Present (Flag11)
4368 -- No_Initialization (Flag13-Sem)
4369 -- Is_Static_Coextension (Flag14-Sem)
4370 -- Do_Storage_Check (Flag17-Sem)
4371 -- Is_Dynamic_Coextension (Flag18-Sem)
4372 -- plus fields for expression
4374 -- Note: like all nodes, the N_Allocator has the Comes_From_Source flag.
4375 -- This flag has a special function in conjunction with the restriction
4376 -- No_Implicit_Heap_Allocations, which will be triggered if this flag
4377 -- is not set. This means that if a source allocator is replaced with
4378 -- a constructed allocator, the Comes_From_Source flag should be copied
4379 -- to the newly created allocator.
4381 ---------------------------------
4382 -- 5.1 Sequence Of Statements --
4383 ---------------------------------
4385 -- SEQUENCE_OF_STATEMENTS ::= STATEMENT {STATEMENT}
4387 -- Note: Although the parser will not accept a declaration as a
4388 -- statement, the semantic analyzer may insert declarations (e.g.
4389 -- declarations of implicit types needed for execution of other
4390 -- statements) into a sequence of statements, so the code generator
4391 -- should be prepared to accept a declaration where a statement is
4392 -- expected. Note also that pragmas can appear as statements.
4394 --------------------
4396 --------------------
4399 -- {LABEL} SIMPLE_STATEMENT | {LABEL} COMPOUND_STATEMENT
4401 -- There is no explicit node in the tree for a statement. Instead, the
4402 -- individual statement appears directly. Labels are treated as a
4403 -- kind of statement, i.e. they are linked into a statement list at
4404 -- the point they appear, so the labeled statement appears following
4405 -- the label or labels in the statement list.
4407 ---------------------------
4408 -- 5.1 Simple Statement --
4409 ---------------------------
4411 -- SIMPLE_STATEMENT ::= NULL_STATEMENT
4412 -- | ASSIGNMENT_STATEMENT | EXIT_STATEMENT
4413 -- | GOTO_STATEMENT | PROCEDURE_CALL_STATEMENT
4414 -- | SIMPLE_RETURN_STATEMENT | ENTRY_CALL_STATEMENT
4415 -- | REQUEUE_STATEMENT | DELAY_STATEMENT
4416 -- | ABORT_STATEMENT | RAISE_STATEMENT
4419 -----------------------------
4420 -- 5.1 Compound Statement --
4421 -----------------------------
4423 -- COMPOUND_STATEMENT ::=
4424 -- IF_STATEMENT | CASE_STATEMENT
4425 -- | LOOP_STATEMENT | BLOCK_STATEMENT
4426 -- | EXTENDED_RETURN_STATEMENT
4427 -- | ACCEPT_STATEMENT | SELECT_STATEMENT
4429 -------------------------
4430 -- 5.1 Null Statement --
4431 -------------------------
4433 -- NULL_STATEMENT ::= null;
4436 -- Sloc points to NULL
4442 -- LABEL ::= <<label_STATEMENT_IDENTIFIER>>
4444 -- Note that the occurrence of a label is not a defining identifier,
4445 -- but rather a referencing occurrence. The defining occurrence is
4446 -- in the implicit label declaration which occurs in the innermost
4450 -- Sloc points to <<
4451 -- Identifier (Node1) direct name of statement identifier
4452 -- Exception_Junk (Flag8-Sem)
4454 -- Note: Before Ada 2012, a label is always followed by a statement,
4455 -- and this is true in the tree even in Ada 2012 mode (the parser
4456 -- inserts a null statement marked with Comes_From_Source False).
4458 -------------------------------
4459 -- 5.1 Statement Identifier --
4460 -------------------------------
4462 -- STATEMENT_IDENTIFIER ::= DIRECT_NAME
4464 -- The IDENTIFIER of a STATEMENT_IDENTIFIER shall be an identifier
4465 -- (not an OPERATOR_SYMBOL)
4467 -------------------------------
4468 -- 5.2 Assignment Statement --
4469 -------------------------------
4471 -- ASSIGNMENT_STATEMENT ::=
4472 -- variable_NAME := EXPRESSION;
4474 -- N_Assignment_Statement
4475 -- Sloc points to :=
4477 -- Expression (Node3)
4478 -- Do_Discriminant_Check (Flag1-Sem)
4479 -- Do_Tag_Check (Flag13-Sem)
4480 -- Do_Length_Check (Flag4-Sem)
4481 -- Forwards_OK (Flag5-Sem)
4482 -- Backwards_OK (Flag6-Sem)
4483 -- No_Ctrl_Actions (Flag7-Sem)
4484 -- Componentwise_Assignment (Flag14-Sem)
4485 -- Suppress_Assignment_Checks (Flag18-Sem)
4487 -- Note: if a range check is required, then the Do_Range_Check flag
4488 -- is set in the Expression (right hand side), with the check being
4489 -- done against the type of the Name (left hand side).
4491 -- Note: the back end places some restrictions on the form of the
4492 -- Expression field. If the object being assigned to is Atomic, then
4493 -- the Expression may not have the form of an aggregate (since this
4494 -- might cause the back end to generate separate assignments). In this
4495 -- case the front end must generate an extra temporary and initialize
4496 -- this temporary as required (the temporary itself is not atomic).
4498 -----------------------
4499 -- 5.3 If Statement --
4500 -----------------------
4503 -- if CONDITION then
4504 -- SEQUENCE_OF_STATEMENTS
4505 -- {elsif CONDITION then
4506 -- SEQUENCE_OF_STATEMENTS}
4508 -- SEQUENCE_OF_STATEMENTS]
4511 -- Gigi restriction: This expander ensures that the type of the
4512 -- Condition fields is always Standard.Boolean, even if the type
4513 -- in the source is some non-standard boolean type.
4516 -- Sloc points to IF
4517 -- Condition (Node1)
4518 -- Then_Statements (List2)
4519 -- Elsif_Parts (List3) (set to No_List if none present)
4520 -- Else_Statements (List4) (set to No_List if no else part present)
4521 -- End_Span (Uint5) (set to Uint_0 if expander generated)
4524 -- Sloc points to ELSIF
4525 -- Condition (Node1)
4526 -- Then_Statements (List2)
4527 -- Condition_Actions (List3-Sem)
4529 --------------------
4531 --------------------
4533 -- CONDITION ::= boolean_EXPRESSION
4535 -------------------------
4536 -- 5.4 Case Statement --
4537 -------------------------
4539 -- CASE_STATEMENT ::=
4540 -- case EXPRESSION is
4541 -- CASE_STATEMENT_ALTERNATIVE
4542 -- {CASE_STATEMENT_ALTERNATIVE}
4545 -- Note: the Alternatives can contain pragmas. These only occur at
4546 -- the start of the list, since any pragmas occurring after the first
4547 -- alternative are absorbed into the corresponding statement sequence.
4550 -- Sloc points to CASE
4551 -- Expression (Node3)
4552 -- Alternatives (List4)
4553 -- End_Span (Uint5) (set to Uint_0 if expander generated)
4555 -- Note: Before Ada 2012, a pragma in a statement sequence is always
4556 -- followed by a statement, and this is true in the tree even in Ada
4557 -- 2012 mode (the parser inserts a null statement marked with the flag
4558 -- Comes_From_Source False).
4560 -------------------------------------
4561 -- 5.4 Case Statement Alternative --
4562 -------------------------------------
4564 -- CASE_STATEMENT_ALTERNATIVE ::=
4565 -- when DISCRETE_CHOICE_LIST =>
4566 -- SEQUENCE_OF_STATEMENTS
4568 -- N_Case_Statement_Alternative
4569 -- Sloc points to WHEN
4570 -- Discrete_Choices (List4)
4571 -- Statements (List3)
4572 -- Has_SP_Choice (Flag15-Sem)
4574 -- Note: in the list of Discrete_Choices, the tree passed to the back
4575 -- end does not have choice entries corresponding to names of statically
4576 -- predicated subtypes. Such entries are always expanded out to the list
4577 -- of equivalent values or ranges. The ASIS tree generated in -gnatct
4578 -- mode does not have this expansion, and has the original choices.
4580 -------------------------
4581 -- 5.5 Loop Statement --
4582 -------------------------
4584 -- LOOP_STATEMENT ::=
4585 -- [loop_STATEMENT_IDENTIFIER :]
4586 -- [ITERATION_SCHEME] loop
4587 -- SEQUENCE_OF_STATEMENTS
4588 -- end loop [loop_IDENTIFIER];
4590 -- Note: The occurrence of a loop label is not a defining identifier
4591 -- but rather a referencing occurrence. The defining occurrence is in
4592 -- the implicit label declaration which occurs in the innermost
4595 -- Note: there is always a loop statement identifier present in the
4596 -- tree, even if none was given in the source. In the case where no loop
4597 -- identifier is given in the source, the parser creates a name of the
4598 -- form _Loop_n, where n is a decimal integer (the two underlines ensure
4599 -- that the loop names created in this manner do not conflict with any
4600 -- user defined identifiers), and the flag Has_Created_Identifier is set
4601 -- to True. The only exception to the rule that all loop statement nodes
4602 -- have identifiers occurs for loops constructed by the expander, and
4603 -- the semantic analyzer will create and supply dummy loop identifiers
4607 -- Sloc points to LOOP
4608 -- Identifier (Node1) loop identifier (set to Empty if no identifier)
4609 -- Iteration_Scheme (Node2) (set to Empty if no iteration scheme)
4610 -- Statements (List3)
4611 -- End_Label (Node4)
4612 -- Has_Created_Identifier (Flag15)
4613 -- Is_Null_Loop (Flag16)
4614 -- Suppress_Loop_Warnings (Flag17)
4616 -- Note: the parser fills in the Identifier field if there is an
4617 -- explicit loop identifier. Otherwise the parser leaves this field
4618 -- set to Empty, and then the semantic processing for a loop statement
4619 -- creates an identifier, setting the Has_Created_Identifier flag to
4620 -- True. So after semantic analysis, the Identifier is always set,
4621 -- referencing an identifier whose entity has an Ekind of E_Loop.
4623 ---------------------------
4624 -- 5.5 Iteration Scheme --
4625 ---------------------------
4627 -- ITERATION_SCHEME ::=
4629 -- | for LOOP_PARAMETER_SPECIFICATION
4630 -- | for ITERATOR_SPECIFICATION
4632 -- At most one of (Iterator_Specification, Loop_Parameter_Specification)
4633 -- is present at a time, in which case the other one is empty. Both are
4634 -- empty in the case of a WHILE loop.
4636 -- Gigi restriction: The expander ensures that the type of the Condition
4637 -- field is always Standard.Boolean, even if the type in the source is
4638 -- some non-standard boolean type.
4640 -- N_Iteration_Scheme
4641 -- Sloc points to WHILE or FOR
4642 -- Condition (Node1) (set to Empty if FOR case)
4643 -- Condition_Actions (List3-Sem)
4644 -- Iterator_Specification (Node2) (set to Empty if WHILE case)
4645 -- Loop_Parameter_Specification (Node4) (set to Empty if WHILE case)
4647 ---------------------------------------
4648 -- 5.5 Loop Parameter Specification --
4649 ---------------------------------------
4651 -- LOOP_PARAMETER_SPECIFICATION ::=
4652 -- DEFINING_IDENTIFIER in [reverse] DISCRETE_SUBTYPE_DEFINITION
4654 -- N_Loop_Parameter_Specification
4655 -- Sloc points to first identifier
4656 -- Defining_Identifier (Node1)
4657 -- Reverse_Present (Flag15)
4658 -- Discrete_Subtype_Definition (Node4)
4660 -----------------------------------
4661 -- 5.5.1 Iterator Specification --
4662 -----------------------------------
4664 -- ITERATOR_SPECIFICATION ::=
4665 -- DEFINING_IDENTIFIER in [reverse] NAME
4666 -- | DEFINING_IDENTIFIER [: SUBTYPE_INDICATION] of [reverse] NAME
4668 -- N_Iterator_Specification
4669 -- Sloc points to defining identifier
4670 -- Defining_Identifier (Node1)
4672 -- Reverse_Present (Flag15)
4673 -- Of_Present (Flag16)
4674 -- Subtype_Indication (Node5)
4676 -- Note: The Of_Present flag distinguishes the two forms
4678 --------------------------
4679 -- 5.6 Block Statement --
4680 --------------------------
4682 -- BLOCK_STATEMENT ::=
4683 -- [block_STATEMENT_IDENTIFIER:]
4685 -- DECLARATIVE_PART]
4687 -- HANDLED_SEQUENCE_OF_STATEMENTS
4688 -- end [block_IDENTIFIER];
4690 -- Note that the occurrence of a block identifier is not a defining
4691 -- identifier, but rather a referencing occurrence. The defining
4692 -- occurrence is an E_Block entity declared by the implicit label
4693 -- declaration which occurs in the innermost enclosing block statement
4694 -- or body; the block identifier denotes that E_Block.
4696 -- For block statements that come from source code, there is always a
4697 -- block statement identifier present in the tree, denoting an E_Block.
4698 -- In the case where no block identifier is given in the source,
4699 -- the parser creates a name of the form B_n, where n is a decimal
4700 -- integer, and the flag Has_Created_Identifier is set to True. Blocks
4701 -- constructed by the expander usually have no identifier, and no
4702 -- corresponding entity.
4704 -- Note: the block statement created for an extended return statement
4705 -- has an entity, and this entity is an E_Return_Statement, rather than
4706 -- the usual E_Block.
4708 -- Note: Exception_Junk is set for the wrapping blocks created during
4709 -- local raise optimization (Exp_Ch11.Expand_Local_Exception_Handlers).
4711 -- Note: from a control flow viewpoint, a block statement defines an
4712 -- extended basic block, i.e. the entry of the block dominates every
4713 -- statement in the sequence. When generating new statements with
4714 -- exception handlers in the expander at the end of a sequence that
4715 -- comes from source code, it can be necessary to wrap them all in a
4716 -- block statement in order to expose the implicit control flow to
4717 -- gigi and thus prevent it from issuing bogus control flow warnings.
4719 -- N_Block_Statement
4720 -- Sloc points to DECLARE or BEGIN
4721 -- Identifier (Node1) block direct name (set to Empty if not present)
4722 -- Declarations (List2) (set to No_List if no DECLARE part)
4723 -- Handled_Statement_Sequence (Node4)
4724 -- Is_Task_Master (Flag5-Sem)
4725 -- Activation_Chain_Entity (Node3-Sem)
4726 -- Has_Created_Identifier (Flag15)
4727 -- Is_Task_Allocation_Block (Flag6)
4728 -- Is_Asynchronous_Call_Block (Flag7)
4729 -- Exception_Junk (Flag8-Sem)
4730 -- Is_Finalization_Wrapper (Flag9-Sem)
4732 -------------------------
4733 -- 5.7 Exit Statement --
4734 -------------------------
4736 -- EXIT_STATEMENT ::= exit [loop_NAME] [when CONDITION];
4738 -- Gigi restriction: The expander ensures that the type of the Condition
4739 -- field is always Standard.Boolean, even if the type in the source is
4740 -- some non-standard boolean type.
4743 -- Sloc points to EXIT
4744 -- Name (Node2) (set to Empty if no loop name present)
4745 -- Condition (Node1) (set to Empty if no WHEN part present)
4746 -- Next_Exit_Statement (Node3-Sem): Next exit on chain
4748 -------------------------
4749 -- 5.9 Goto Statement --
4750 -------------------------
4752 -- GOTO_STATEMENT ::= goto label_NAME;
4755 -- Sloc points to GOTO
4757 -- Exception_Junk (Flag8-Sem)
4759 ---------------------------------
4760 -- 6.1 Subprogram Declaration --
4761 ---------------------------------
4763 -- SUBPROGRAM_DECLARATION ::=
4764 -- SUBPROGRAM_SPECIFICATION
4765 -- [ASPECT_SPECIFICATIONS];
4767 -- N_Subprogram_Declaration
4768 -- Sloc points to FUNCTION or PROCEDURE
4769 -- Specification (Node1)
4770 -- Body_To_Inline (Node3-Sem)
4771 -- Corresponding_Body (Node5-Sem)
4772 -- Parent_Spec (Node4-Sem)
4774 ------------------------------------------
4775 -- 6.1 Abstract Subprogram Declaration --
4776 ------------------------------------------
4778 -- ABSTRACT_SUBPROGRAM_DECLARATION ::=
4779 -- SUBPROGRAM_SPECIFICATION is abstract
4780 -- [ASPECT_SPECIFICATIONS];
4782 -- N_Abstract_Subprogram_Declaration
4783 -- Sloc points to ABSTRACT
4784 -- Specification (Node1)
4786 -----------------------------------
4787 -- 6.1 Subprogram Specification --
4788 -----------------------------------
4790 -- SUBPROGRAM_SPECIFICATION ::=
4791 -- [[not] overriding]
4792 -- procedure DEFINING_PROGRAM_UNIT_NAME PARAMETER_PROFILE
4793 -- | [[not] overriding]
4794 -- function DEFINING_DESIGNATOR PARAMETER_AND_RESULT_PROFILE
4796 -- Note: there are no separate nodes for the profiles, instead the
4797 -- information appears directly in the following nodes.
4799 -- N_Function_Specification
4800 -- Sloc points to FUNCTION
4801 -- Defining_Unit_Name (Node1) (the designator)
4802 -- Elaboration_Boolean (Node2-Sem)
4803 -- Parameter_Specifications (List3) (set to No_List if no formal part)
4804 -- Null_Exclusion_Present (Flag11)
4805 -- Result_Definition (Node4) for result subtype
4806 -- Generic_Parent (Node5-Sem)
4807 -- Must_Override (Flag14) set if overriding indicator present
4808 -- Must_Not_Override (Flag15) set if not_overriding indicator present
4810 -- N_Procedure_Specification
4811 -- Sloc points to PROCEDURE
4812 -- Defining_Unit_Name (Node1)
4813 -- Elaboration_Boolean (Node2-Sem)
4814 -- Parameter_Specifications (List3) (set to No_List if no formal part)
4815 -- Generic_Parent (Node5-Sem)
4816 -- Null_Present (Flag13) set for null procedure case (Ada 2005 feature)
4817 -- Must_Override (Flag14) set if overriding indicator present
4818 -- Must_Not_Override (Flag15) set if not_overriding indicator present
4820 -- Note: overriding indicator is an Ada 2005 feature
4822 ---------------------
4823 -- 6.1 Designator --
4824 ---------------------
4827 -- [PARENT_UNIT_NAME .] IDENTIFIER | OPERATOR_SYMBOL
4829 -- Designators that are simply identifiers or operator symbols appear
4830 -- directly in the tree in this form. The following node is used only
4831 -- in the case where the designator has a parent unit name component.
4834 -- Sloc points to period
4835 -- Name (Node2) holds the parent unit name
4836 -- Identifier (Node1)
4838 -- Note: Name is always non-Empty, since this node is only used for the
4839 -- case where a parent library unit package name is present.
4841 -- Note that the identifier can also be an operator symbol here
4843 ------------------------------
4844 -- 6.1 Defining Designator --
4845 ------------------------------
4847 -- DEFINING_DESIGNATOR ::=
4848 -- DEFINING_PROGRAM_UNIT_NAME | DEFINING_OPERATOR_SYMBOL
4850 -------------------------------------
4851 -- 6.1 Defining Program Unit Name --
4852 -------------------------------------
4854 -- DEFINING_PROGRAM_UNIT_NAME ::=
4855 -- [PARENT_UNIT_NAME .] DEFINING_IDENTIFIER
4857 -- The parent unit name is present only in the case of a child unit name
4858 -- (permissible only for Ada 95 for a library level unit, i.e. a unit
4859 -- at scope level one). If no such name is present, the defining program
4860 -- unit name is represented simply as the defining identifier. In the
4861 -- child unit case, the following node is used to represent the child
4864 -- N_Defining_Program_Unit_Name
4865 -- Sloc points to period
4866 -- Name (Node2) holds the parent unit name
4867 -- Defining_Identifier (Node1)
4869 -- Note: Name is always non-Empty, since this node is only used for the
4870 -- case where a parent unit name is present.
4872 --------------------------
4873 -- 6.1 Operator Symbol --
4874 --------------------------
4876 -- OPERATOR_SYMBOL ::= STRING_LITERAL
4878 -- Note: the fields of the N_Operator_Symbol node are laid out to match
4879 -- the corresponding fields of an N_Character_Literal node. This allows
4880 -- easy conversion of the operator symbol node into a character literal
4881 -- node in the case where a string constant of the form of an operator
4882 -- symbol is scanned out as such, but turns out semantically to be a
4883 -- string literal that is not an operator. For details see Sinfo.CN.
4884 -- Change_Operator_Symbol_To_String_Literal.
4886 -- N_Operator_Symbol
4887 -- Sloc points to literal
4888 -- Chars (Name1) contains the Name_Id for the operator symbol
4889 -- Strval (Str3) Id of string value. This is used if the operator
4890 -- symbol turns out to be a normal string after all.
4891 -- Entity (Node4-Sem)
4892 -- Associated_Node (Node4-Sem)
4893 -- Has_Private_View (Flag11-Sem) set in generic units.
4894 -- Etype (Node5-Sem)
4896 -- Note: the Strval field may be set to No_String for generated
4897 -- operator symbols that are known not to be string literals
4900 -----------------------------------
4901 -- 6.1 Defining Operator Symbol --
4902 -----------------------------------
4904 -- DEFINING_OPERATOR_SYMBOL ::= OPERATOR_SYMBOL
4906 -- A defining operator symbol is an entity, which has additional
4907 -- fields depending on the setting of the Ekind field. These
4908 -- additional fields are defined (and access subprograms declared)
4909 -- in package Einfo.
4911 -- Note: N_Defining_Operator_Symbol is an extended node whose fields
4912 -- are deliberately layed out to match the layout of fields in an
4913 -- ordinary N_Operator_Symbol node allowing for easy alteration of
4914 -- an operator symbol node into a defining operator symbol node.
4915 -- See Sinfo.CN.Change_Operator_Symbol_To_Defining_Operator_Symbol
4916 -- for further details.
4918 -- N_Defining_Operator_Symbol
4919 -- Sloc points to literal
4920 -- Chars (Name1) contains the Name_Id for the operator symbol
4921 -- Next_Entity (Node2-Sem)
4922 -- Scope (Node3-Sem)
4923 -- Etype (Node5-Sem)
4925 ----------------------------
4926 -- 6.1 Parameter Profile --
4927 ----------------------------
4929 -- PARAMETER_PROFILE ::= [FORMAL_PART]
4931 ---------------------------------------
4932 -- 6.1 Parameter and Result Profile --
4933 ---------------------------------------
4935 -- PARAMETER_AND_RESULT_PROFILE ::=
4936 -- [FORMAL_PART] return [NULL_EXCLUSION] SUBTYPE_MARK
4937 -- | [FORMAL_PART] return ACCESS_DEFINITION
4939 -- There is no explicit node in the tree for a parameter and result
4940 -- profile. Instead the information appears directly in the parent.
4942 ----------------------
4943 -- 6.1 Formal Part --
4944 ----------------------
4947 -- (PARAMETER_SPECIFICATION {; PARAMETER_SPECIFICATION})
4949 ----------------------------------
4950 -- 6.1 Parameter Specification --
4951 ----------------------------------
4953 -- PARAMETER_SPECIFICATION ::=
4954 -- DEFINING_IDENTIFIER_LIST : [ALIASED] MODE [NULL_EXCLUSION]
4955 -- SUBTYPE_MARK [:= DEFAULT_EXPRESSION]
4956 -- | DEFINING_IDENTIFIER_LIST : ACCESS_DEFINITION
4957 -- [:= DEFAULT_EXPRESSION]
4959 -- Although the syntax allows multiple identifiers in the list, the
4960 -- semantics is as though successive specifications were given with
4961 -- identical type definition and expression components. To simplify
4962 -- semantic processing, the parser represents a multiple declaration
4963 -- case as a sequence of single Specifications, using the More_Ids and
4964 -- Prev_Ids flags to preserve the original source form as described
4965 -- in the section on "Handling of Defining Identifier Lists".
4967 -- ALIASED can only be present in Ada 2012 mode
4969 -- N_Parameter_Specification
4970 -- Sloc points to first identifier
4971 -- Defining_Identifier (Node1)
4972 -- Aliased_Present (Flag4)
4973 -- In_Present (Flag15)
4974 -- Out_Present (Flag17)
4975 -- Null_Exclusion_Present (Flag11)
4976 -- Parameter_Type (Node2) subtype mark or access definition
4977 -- Expression (Node3) (set to Empty if no default expression present)
4978 -- Do_Accessibility_Check (Flag13-Sem)
4979 -- More_Ids (Flag5) (set to False if no more identifiers in list)
4980 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
4981 -- Default_Expression (Node5-Sem)
4987 -- MODE ::= [in] | in out | out
4989 -- There is no explicit node in the tree for the Mode. Instead the
4990 -- In_Present and Out_Present flags are set in the parent node to
4991 -- record the presence of keywords specifying the mode.
4993 --------------------------
4994 -- 6.3 Subprogram Body --
4995 --------------------------
4997 -- SUBPROGRAM_BODY ::=
4998 -- SUBPROGRAM_SPECIFICATION [ASPECT_SPECIFICATIONS] is
5001 -- HANDLED_SEQUENCE_OF_STATEMENTS
5002 -- end [DESIGNATOR];
5004 -- N_Subprogram_Body
5005 -- Sloc points to FUNCTION or PROCEDURE
5006 -- Specification (Node1)
5007 -- Declarations (List2)
5008 -- Handled_Statement_Sequence (Node4)
5009 -- Activation_Chain_Entity (Node3-Sem)
5010 -- Corresponding_Spec (Node5-Sem)
5011 -- Acts_As_Spec (Flag4-Sem)
5012 -- Bad_Is_Detected (Flag15) used only by parser
5013 -- Do_Storage_Check (Flag17-Sem)
5014 -- Is_Protected_Subprogram_Body (Flag7-Sem)
5015 -- Is_Entry_Barrier_Function (Flag8-Sem)
5016 -- Is_Task_Master (Flag5-Sem)
5017 -- Was_Originally_Stub (Flag13-Sem)
5018 -- Has_Relative_Deadline_Pragma (Flag9-Sem)
5020 -------------------------
5021 -- Expression Function --
5022 -------------------------
5024 -- This is an Ada 2012 extension, we put it here for now, to be labeled
5025 -- and put in its proper section when we know exactly where that is.
5027 -- EXPRESSION_FUNCTION ::=
5028 -- FUNCTION SPECIFICATION IS (EXPRESSION)
5029 -- [ASPECT_SPECIFICATIONS];
5031 -- N_Expression_Function
5032 -- Sloc points to FUNCTION
5033 -- Specification (Node1)
5034 -- Expression (Node3)
5035 -- Corresponding_Spec (Node5-Sem)
5037 -----------------------------------
5038 -- 6.4 Procedure Call Statement --
5039 -----------------------------------
5041 -- PROCEDURE_CALL_STATEMENT ::=
5042 -- procedure_NAME; | procedure_PREFIX ACTUAL_PARAMETER_PART;
5044 -- Note: the reason that a procedure call has expression fields is that
5045 -- it semantically resembles an expression, e.g. overloading is allowed
5046 -- and a type is concocted for semantic processing purposes. Certain of
5047 -- these fields, such as Parens are not relevant, but it is easier to
5048 -- just supply all of them together.
5050 -- N_Procedure_Call_Statement
5051 -- Sloc points to first token of name or prefix
5052 -- Name (Node2) stores name or prefix
5053 -- Parameter_Associations (List3) (set to No_List if no
5054 -- actual parameter part)
5055 -- First_Named_Actual (Node4-Sem)
5056 -- Controlling_Argument (Node1-Sem) (set to Empty if not dispatching)
5057 -- Do_Tag_Check (Flag13-Sem)
5058 -- No_Elaboration_Check (Flag14-Sem)
5059 -- Parameter_List_Truncated (Flag17-Sem)
5060 -- ABE_Is_Certain (Flag18-Sem)
5061 -- plus fields for expression
5063 -- If any IN parameter requires a range check, then the corresponding
5064 -- argument expression has the Do_Range_Check flag set, and the range
5065 -- check is done against the formal type. Note that this argument
5066 -- expression may appear directly in the Parameter_Associations list,
5067 -- or may be a descendent of an N_Parameter_Association node that
5068 -- appears in this list.
5070 ------------------------
5071 -- 6.4 Function Call --
5072 ------------------------
5074 -- FUNCTION_CALL ::=
5075 -- function_NAME | function_PREFIX ACTUAL_PARAMETER_PART
5077 -- Note: the parser may generate an indexed component node or simply
5078 -- a name node instead of a function call node. The semantic pass must
5079 -- correct this misidentification.
5082 -- Sloc points to first token of name or prefix
5083 -- Name (Node2) stores name or prefix
5084 -- Parameter_Associations (List3) (set to No_List if no
5085 -- actual parameter part)
5086 -- First_Named_Actual (Node4-Sem)
5087 -- Controlling_Argument (Node1-Sem) (set to Empty if not dispatching)
5088 -- Is_Expanded_Build_In_Place_Call (Flag11-Sem)
5089 -- Do_Tag_Check (Flag13-Sem)
5090 -- No_Elaboration_Check (Flag14-Sem)
5091 -- Parameter_List_Truncated (Flag17-Sem)
5092 -- ABE_Is_Certain (Flag18-Sem)
5093 -- plus fields for expression
5095 --------------------------------
5096 -- 6.4 Actual Parameter Part --
5097 --------------------------------
5099 -- ACTUAL_PARAMETER_PART ::=
5100 -- (PARAMETER_ASSOCIATION {,PARAMETER_ASSOCIATION})
5102 --------------------------------
5103 -- 6.4 Parameter Association --
5104 --------------------------------
5106 -- PARAMETER_ASSOCIATION ::=
5107 -- [formal_parameter_SELECTOR_NAME =>] EXPLICIT_ACTUAL_PARAMETER
5109 -- Note: the N_Parameter_Association node is built only if a formal
5110 -- parameter selector name is present, otherwise the parameter
5111 -- association appears in the tree simply as the node for the
5112 -- explicit actual parameter.
5114 -- N_Parameter_Association
5115 -- Sloc points to formal parameter
5116 -- Selector_Name (Node2) (always non-Empty)
5117 -- Explicit_Actual_Parameter (Node3)
5118 -- Next_Named_Actual (Node4-Sem)
5119 -- Is_Accessibility_Actual (Flag13-Sem)
5121 ---------------------------
5122 -- 6.4 Actual Parameter --
5123 ---------------------------
5125 -- EXPLICIT_ACTUAL_PARAMETER ::= EXPRESSION | variable_NAME
5127 ---------------------------
5128 -- 6.5 Return Statement --
5129 ---------------------------
5131 -- SIMPLE_RETURN_STATEMENT ::= return [EXPRESSION];
5133 -- EXTENDED_RETURN_STATEMENT ::=
5134 -- return DEFINING_IDENTIFIER : [aliased] RETURN_SUBTYPE_INDICATION
5135 -- [:= EXPRESSION] [do
5136 -- HANDLED_SEQUENCE_OF_STATEMENTS
5139 -- RETURN_SUBTYPE_INDICATION ::= SUBTYPE_INDICATION | ACCESS_DEFINITION
5141 -- The term "return statement" is defined in 6.5 to mean either a
5142 -- SIMPLE_RETURN_STATEMENT or an EXTENDED_RETURN_STATEMENT. We avoid
5143 -- the use of this term, since it used to mean someting else in earlier
5146 -- N_Simple_Return_Statement
5147 -- Sloc points to RETURN
5148 -- Return_Statement_Entity (Node5-Sem)
5149 -- Expression (Node3) (set to Empty if no expression present)
5150 -- Storage_Pool (Node1-Sem)
5151 -- Procedure_To_Call (Node2-Sem)
5152 -- Do_Tag_Check (Flag13-Sem)
5153 -- By_Ref (Flag5-Sem)
5154 -- Comes_From_Extended_Return_Statement (Flag18-Sem)
5156 -- Note: Return_Statement_Entity points to an E_Return_Statement
5158 -- If a range check is required, then Do_Range_Check is set on the
5159 -- Expression. The check is against the return subtype of the function.
5161 -- N_Extended_Return_Statement
5162 -- Sloc points to RETURN
5163 -- Return_Statement_Entity (Node5-Sem)
5164 -- Return_Object_Declarations (List3)
5165 -- Handled_Statement_Sequence (Node4) (set to Empty if not present)
5166 -- Storage_Pool (Node1-Sem)
5167 -- Procedure_To_Call (Node2-Sem)
5168 -- Do_Tag_Check (Flag13-Sem)
5169 -- By_Ref (Flag5-Sem)
5171 -- Note: Return_Statement_Entity points to an E_Return_Statement.
5173 -- Note that Return_Object_Declarations is a list containing the
5174 -- N_Object_Declaration -- see comment on this field above.
5176 -- The declared object will have Is_Return_Object = True.
5178 -- There is no such syntactic category as return_object_declaration
5179 -- in the RM. Return_Object_Declarations represents this portion of
5180 -- the syntax for EXTENDED_RETURN_STATEMENT:
5181 -- DEFINING_IDENTIFIER : [aliased] RETURN_SUBTYPE_INDICATION
5184 -- There are two entities associated with an extended_return_statement:
5185 -- the Return_Statement_Entity represents the statement itself,
5186 -- and the Defining_Identifier of the Object_Declaration in
5187 -- Return_Object_Declarations represents the object being
5188 -- returned. N_Simple_Return_Statement has only the former.
5190 ------------------------------
5191 -- 7.1 Package Declaration --
5192 ------------------------------
5194 -- PACKAGE_DECLARATION ::=
5195 -- PACKAGE_SPECIFICATION;
5197 -- Note: the activation chain entity for a package spec is used for
5198 -- all tasks declared in the package spec, or in the package body.
5200 -- N_Package_Declaration
5201 -- Sloc points to PACKAGE
5202 -- Specification (Node1)
5203 -- Corresponding_Body (Node5-Sem)
5204 -- Parent_Spec (Node4-Sem)
5205 -- Activation_Chain_Entity (Node3-Sem)
5207 --------------------------------
5208 -- 7.1 Package Specification --
5209 --------------------------------
5211 -- PACKAGE_SPECIFICATION ::=
5212 -- package DEFINING_PROGRAM_UNIT_NAME
5213 -- [ASPECT_SPECIFICATIONS]
5215 -- {BASIC_DECLARATIVE_ITEM}
5217 -- {BASIC_DECLARATIVE_ITEM}]
5218 -- end [[PARENT_UNIT_NAME .] IDENTIFIER]
5220 -- N_Package_Specification
5221 -- Sloc points to PACKAGE
5222 -- Defining_Unit_Name (Node1)
5223 -- Visible_Declarations (List2)
5224 -- Private_Declarations (List3) (set to No_List if no private
5226 -- End_Label (Node4)
5227 -- Generic_Parent (Node5-Sem)
5228 -- Limited_View_Installed (Flag18-Sem)
5230 -----------------------
5231 -- 7.1 Package Body --
5232 -----------------------
5235 -- package body DEFINING_PROGRAM_UNIT_NAME
5236 -- [ASPECT_SPECIFICATIONS]
5240 -- HANDLED_SEQUENCE_OF_STATEMENTS]
5241 -- end [[PARENT_UNIT_NAME .] IDENTIFIER];
5244 -- Sloc points to PACKAGE
5245 -- Defining_Unit_Name (Node1)
5246 -- Declarations (List2)
5247 -- Handled_Statement_Sequence (Node4) (set to Empty if no HSS present)
5248 -- Corresponding_Spec (Node5-Sem)
5249 -- Was_Originally_Stub (Flag13-Sem)
5251 -- Note: if a source level package does not contain a handled sequence
5252 -- of statements, then the parser supplies a dummy one with a null
5253 -- sequence of statements. Comes_From_Source will be False in this
5254 -- constructed sequence. The reason we need this is for the End_Label
5255 -- field in the HSS.
5257 -----------------------------------
5258 -- 7.4 Private Type Declaration --
5259 -----------------------------------
5261 -- PRIVATE_TYPE_DECLARATION ::=
5262 -- type DEFINING_IDENTIFIER [DISCRIMINANT_PART]
5263 -- is [[abstract] tagged] [limited] private
5264 -- [ASPECT_SPECIFICATIONS];
5266 -- Note: TAGGED is not permitted in Ada 83 mode
5268 -- N_Private_Type_Declaration
5269 -- Sloc points to TYPE
5270 -- Defining_Identifier (Node1)
5271 -- Discriminant_Specifications (List4) (set to No_List if no
5272 -- discriminant part)
5273 -- Unknown_Discriminants_Present (Flag13) set if (<>) discriminant
5274 -- Abstract_Present (Flag4)
5275 -- Tagged_Present (Flag15)
5276 -- Limited_Present (Flag17)
5278 ----------------------------------------
5279 -- 7.4 Private Extension Declaration --
5280 ----------------------------------------
5282 -- PRIVATE_EXTENSION_DECLARATION ::=
5283 -- type DEFINING_IDENTIFIER [DISCRIMINANT_PART] is
5284 -- [abstract] [limited | synchronized]
5285 -- new ancestor_SUBTYPE_INDICATION [and INTERFACE_LIST]
5286 -- with private [ASPECT_SPECIFICATIONS];
5288 -- Note: LIMITED, and private extension declarations are not allowed
5291 -- N_Private_Extension_Declaration
5292 -- Sloc points to TYPE
5293 -- Defining_Identifier (Node1)
5294 -- Uninitialized_Variable (Node3-Sem)
5295 -- Discriminant_Specifications (List4) (set to No_List if no
5296 -- discriminant part)
5297 -- Unknown_Discriminants_Present (Flag13) set if (<>) discriminant
5298 -- Abstract_Present (Flag4)
5299 -- Limited_Present (Flag17)
5300 -- Synchronized_Present (Flag7)
5301 -- Subtype_Indication (Node5)
5302 -- Interface_List (List2) (set to No_List if none)
5304 ---------------------
5305 -- 8.4 Use Clause --
5306 ---------------------
5308 -- USE_CLAUSE ::= USE_PACKAGE_CLAUSE | USE_TYPE_CLAUSE
5310 -----------------------------
5311 -- 8.4 Use Package Clause --
5312 -----------------------------
5314 -- USE_PACKAGE_CLAUSE ::= use package_NAME {, package_NAME};
5316 -- N_Use_Package_Clause
5317 -- Sloc points to USE
5319 -- Next_Use_Clause (Node3-Sem)
5320 -- Hidden_By_Use_Clause (Elist4-Sem)
5322 --------------------------
5323 -- 8.4 Use Type Clause --
5324 --------------------------
5326 -- USE_TYPE_CLAUSE ::= use [ALL] type SUBTYPE_MARK {, SUBTYPE_MARK};
5328 -- Note: use type clause is not permitted in Ada 83 mode
5330 -- Note: the ALL keyword can appear only in Ada 2012 mode
5332 -- N_Use_Type_Clause
5333 -- Sloc points to USE
5334 -- Subtype_Marks (List2)
5335 -- Next_Use_Clause (Node3-Sem)
5336 -- Hidden_By_Use_Clause (Elist4-Sem)
5337 -- Used_Operations (Elist5-Sem)
5338 -- All_Present (Flag15)
5340 -------------------------------
5341 -- 8.5 Renaming Declaration --
5342 -------------------------------
5344 -- RENAMING_DECLARATION ::=
5345 -- OBJECT_RENAMING_DECLARATION
5346 -- | EXCEPTION_RENAMING_DECLARATION
5347 -- | PACKAGE_RENAMING_DECLARATION
5348 -- | SUBPROGRAM_RENAMING_DECLARATION
5349 -- | GENERIC_RENAMING_DECLARATION
5351 --------------------------------------
5352 -- 8.5 Object Renaming Declaration --
5353 --------------------------------------
5355 -- OBJECT_RENAMING_DECLARATION ::=
5356 -- DEFINING_IDENTIFIER :
5357 -- [NULL_EXCLUSION] SUBTYPE_MARK renames object_NAME
5358 -- [ASPECT_SPECIFICATIONS];
5359 -- | DEFINING_IDENTIFIER :
5360 -- ACCESS_DEFINITION renames object_NAME
5361 -- [ASPECT_SPECIFICATIONS];
5363 -- Note: Access_Definition is an optional field that gives support to
5364 -- Ada 2005 (AI-230). The parser generates nodes that have either the
5365 -- Subtype_Indication field or else the Access_Definition field.
5367 -- N_Object_Renaming_Declaration
5368 -- Sloc points to first identifier
5369 -- Defining_Identifier (Node1)
5370 -- Null_Exclusion_Present (Flag11) (set to False if not present)
5371 -- Subtype_Mark (Node4) (set to Empty if not present)
5372 -- Access_Definition (Node3) (set to Empty if not present)
5374 -- Corresponding_Generic_Association (Node5-Sem)
5376 -----------------------------------------
5377 -- 8.5 Exception Renaming Declaration --
5378 -----------------------------------------
5380 -- EXCEPTION_RENAMING_DECLARATION ::=
5381 -- DEFINING_IDENTIFIER : exception renames exception_NAME
5382 -- [ASPECT_SPECIFICATIONS];
5384 -- N_Exception_Renaming_Declaration
5385 -- Sloc points to first identifier
5386 -- Defining_Identifier (Node1)
5389 ---------------------------------------
5390 -- 8.5 Package Renaming Declaration --
5391 ---------------------------------------
5393 -- PACKAGE_RENAMING_DECLARATION ::=
5394 -- package DEFINING_PROGRAM_UNIT_NAME renames package_NAME
5395 -- [ASPECT_SPECIFICATIONS];
5397 -- N_Package_Renaming_Declaration
5398 -- Sloc points to PACKAGE
5399 -- Defining_Unit_Name (Node1)
5401 -- Parent_Spec (Node4-Sem)
5403 ------------------------------------------
5404 -- 8.5 Subprogram Renaming Declaration --
5405 ------------------------------------------
5407 -- SUBPROGRAM_RENAMING_DECLARATION ::=
5408 -- SUBPROGRAM_SPECIFICATION renames callable_entity_NAME
5409 -- [ASPECT_SPECIFICATIONS];
5411 -- N_Subprogram_Renaming_Declaration
5412 -- Sloc points to RENAMES
5413 -- Specification (Node1)
5415 -- Parent_Spec (Node4-Sem)
5416 -- Corresponding_Spec (Node5-Sem)
5417 -- Corresponding_Formal_Spec (Node3-Sem)
5418 -- From_Default (Flag6-Sem)
5420 -----------------------------------------
5421 -- 8.5.5 Generic Renaming Declaration --
5422 -----------------------------------------
5424 -- GENERIC_RENAMING_DECLARATION ::=
5425 -- generic package DEFINING_PROGRAM_UNIT_NAME
5426 -- renames generic_package_NAME
5427 -- [ASPECT_SPECIFICATIONS];
5428 -- | generic procedure DEFINING_PROGRAM_UNIT_NAME
5429 -- renames generic_procedure_NAME
5430 -- [ASPECT_SPECIFICATIONS];
5431 -- | generic function DEFINING_PROGRAM_UNIT_NAME
5432 -- renames generic_function_NAME
5433 -- [ASPECT_SPECIFICATIONS];
5435 -- N_Generic_Package_Renaming_Declaration
5436 -- Sloc points to GENERIC
5437 -- Defining_Unit_Name (Node1)
5439 -- Parent_Spec (Node4-Sem)
5441 -- N_Generic_Procedure_Renaming_Declaration
5442 -- Sloc points to GENERIC
5443 -- Defining_Unit_Name (Node1)
5445 -- Parent_Spec (Node4-Sem)
5447 -- N_Generic_Function_Renaming_Declaration
5448 -- Sloc points to GENERIC
5449 -- Defining_Unit_Name (Node1)
5451 -- Parent_Spec (Node4-Sem)
5453 --------------------------------
5454 -- 9.1 Task Type Declaration --
5455 --------------------------------
5457 -- TASK_TYPE_DECLARATION ::=
5458 -- task type DEFINING_IDENTIFIER [KNOWN_DISCRIMINANT_PART]
5459 -- [ASPECT_SPECIFICATIONS]
5460 -- [is [new INTERFACE_LIST with] TASK_DEFINITION];
5462 -- N_Task_Type_Declaration
5463 -- Sloc points to TASK
5464 -- Defining_Identifier (Node1)
5465 -- Discriminant_Specifications (List4) (set to No_List if no
5466 -- discriminant part)
5467 -- Interface_List (List2) (set to No_List if none)
5468 -- Task_Definition (Node3) (set to Empty if not present)
5469 -- Corresponding_Body (Node5-Sem)
5471 ----------------------------------
5472 -- 9.1 Single Task Declaration --
5473 ----------------------------------
5475 -- SINGLE_TASK_DECLARATION ::=
5476 -- task DEFINING_IDENTIFIER
5477 -- [ASPECT_SPECIFICATIONS]
5478 -- [is [new INTERFACE_LIST with] TASK_DEFINITION];
5480 -- N_Single_Task_Declaration
5481 -- Sloc points to TASK
5482 -- Defining_Identifier (Node1)
5483 -- Interface_List (List2) (set to No_List if none)
5484 -- Task_Definition (Node3) (set to Empty if not present)
5486 --------------------------
5487 -- 9.1 Task Definition --
5488 --------------------------
5490 -- TASK_DEFINITION ::=
5494 -- end [task_IDENTIFIER]
5496 -- Note: as a result of semantic analysis, the list of task items can
5497 -- include implicit type declarations resulting from entry families.
5499 -- N_Task_Definition
5500 -- Sloc points to first token of task definition
5501 -- Visible_Declarations (List2)
5502 -- Private_Declarations (List3) (set to No_List if no private part)
5503 -- End_Label (Node4)
5504 -- Has_Storage_Size_Pragma (Flag5-Sem)
5505 -- Has_Relative_Deadline_Pragma (Flag9-Sem)
5507 --------------------
5509 --------------------
5511 -- TASK_ITEM ::= ENTRY_DECLARATION | REPRESENTATION_CLAUSE
5513 --------------------
5515 --------------------
5518 -- task body task_DEFINING_IDENTIFIER
5519 -- [ASPECT_SPECIFICATIONS]
5523 -- HANDLED_SEQUENCE_OF_STATEMENTS
5524 -- end [task_IDENTIFIER];
5526 -- Gigi restriction: This node never appears
5529 -- Sloc points to TASK
5530 -- Defining_Identifier (Node1)
5531 -- Declarations (List2)
5532 -- Handled_Statement_Sequence (Node4)
5533 -- Is_Task_Master (Flag5-Sem)
5534 -- Activation_Chain_Entity (Node3-Sem)
5535 -- Corresponding_Spec (Node5-Sem)
5536 -- Was_Originally_Stub (Flag13-Sem)
5538 -------------------------------------
5539 -- 9.4 Protected Type Declaration --
5540 -------------------------------------
5542 -- PROTECTED_TYPE_DECLARATION ::=
5543 -- protected type DEFINING_IDENTIFIER [KNOWN_DISCRIMINANT_PART]
5544 -- [ASPECT_SPECIFICATIONS]
5545 -- is [new INTERFACE_LIST with] PROTECTED_DEFINITION;
5547 -- Note: protected type declarations are not permitted in Ada 83 mode
5549 -- N_Protected_Type_Declaration
5550 -- Sloc points to PROTECTED
5551 -- Defining_Identifier (Node1)
5552 -- Discriminant_Specifications (List4) (set to No_List if no
5553 -- discriminant part)
5554 -- Interface_List (List2) (set to No_List if none)
5555 -- Protected_Definition (Node3)
5556 -- Corresponding_Body (Node5-Sem)
5558 ---------------------------------------
5559 -- 9.4 Single Protected Declaration --
5560 ---------------------------------------
5562 -- SINGLE_PROTECTED_DECLARATION ::=
5563 -- protected DEFINING_IDENTIFIER
5564 -- [ASPECT_SPECIFICATIONS]
5565 -- is [new INTERFACE_LIST with] PROTECTED_DEFINITION;
5567 -- Note: single protected declarations are not allowed in Ada 83 mode
5569 -- N_Single_Protected_Declaration
5570 -- Sloc points to PROTECTED
5571 -- Defining_Identifier (Node1)
5572 -- Interface_List (List2) (set to No_List if none)
5573 -- Protected_Definition (Node3)
5575 -------------------------------
5576 -- 9.4 Protected Definition --
5577 -------------------------------
5579 -- PROTECTED_DEFINITION ::=
5580 -- {PROTECTED_OPERATION_DECLARATION}
5582 -- {PROTECTED_ELEMENT_DECLARATION}]
5583 -- end [protected_IDENTIFIER]
5585 -- N_Protected_Definition
5586 -- Sloc points to first token of protected definition
5587 -- Visible_Declarations (List2)
5588 -- Private_Declarations (List3) (set to No_List if no private part)
5589 -- End_Label (Node4)
5591 ------------------------------------------
5592 -- 9.4 Protected Operation Declaration --
5593 ------------------------------------------
5595 -- PROTECTED_OPERATION_DECLARATION ::=
5596 -- SUBPROGRAM_DECLARATION
5597 -- | ENTRY_DECLARATION
5598 -- | REPRESENTATION_CLAUSE
5600 ----------------------------------------
5601 -- 9.4 Protected Element Declaration --
5602 ----------------------------------------
5604 -- PROTECTED_ELEMENT_DECLARATION ::=
5605 -- PROTECTED_OPERATION_DECLARATION | COMPONENT_DECLARATION
5607 -------------------------
5608 -- 9.4 Protected Body --
5609 -------------------------
5611 -- PROTECTED_BODY ::=
5612 -- protected body DEFINING_IDENTIFIER
5613 -- [ASPECT_SPECIFICATIONS];
5615 -- {PROTECTED_OPERATION_ITEM}
5616 -- end [protected_IDENTIFIER];
5618 -- Note: protected bodies are not allowed in Ada 83 mode
5620 -- Gigi restriction: This node never appears
5623 -- Sloc points to PROTECTED
5624 -- Defining_Identifier (Node1)
5625 -- Declarations (List2) protected operation items (and pragmas)
5626 -- End_Label (Node4)
5627 -- Corresponding_Spec (Node5-Sem)
5628 -- Was_Originally_Stub (Flag13-Sem)
5630 -----------------------------------
5631 -- 9.4 Protected Operation Item --
5632 -----------------------------------
5634 -- PROTECTED_OPERATION_ITEM ::=
5635 -- SUBPROGRAM_DECLARATION
5636 -- | SUBPROGRAM_BODY
5638 -- | REPRESENTATION_CLAUSE
5640 ------------------------------
5641 -- 9.5.2 Entry Declaration --
5642 ------------------------------
5644 -- ENTRY_DECLARATION ::=
5645 -- [[not] overriding]
5646 -- entry DEFINING_IDENTIFIER
5647 -- [(DISCRETE_SUBTYPE_DEFINITION)] PARAMETER_PROFILE
5648 -- [ASPECT_SPECIFICATIONS];
5650 -- N_Entry_Declaration
5651 -- Sloc points to ENTRY
5652 -- Defining_Identifier (Node1)
5653 -- Discrete_Subtype_Definition (Node4) (set to Empty if not present)
5654 -- Parameter_Specifications (List3) (set to No_List if no formal part)
5655 -- Corresponding_Body (Node5-Sem)
5656 -- Must_Override (Flag14) set if overriding indicator present
5657 -- Must_Not_Override (Flag15) set if not_overriding indicator present
5659 -- Note: overriding indicator is an Ada 2005 feature
5661 -----------------------------
5662 -- 9.5.2 Accept statement --
5663 -----------------------------
5665 -- ACCEPT_STATEMENT ::=
5666 -- accept entry_DIRECT_NAME
5667 -- [(ENTRY_INDEX)] PARAMETER_PROFILE [do
5668 -- HANDLED_SEQUENCE_OF_STATEMENTS
5669 -- end [entry_IDENTIFIER]];
5671 -- Gigi restriction: This node never appears
5673 -- Note: there are no explicit declarations allowed in an accept
5674 -- statement. However, the implicit declarations for any statement
5675 -- identifiers (labels and block/loop identifiers) are declarations
5676 -- that belong logically to the accept statement, and that is why
5677 -- there is a Declarations field in this node.
5679 -- N_Accept_Statement
5680 -- Sloc points to ACCEPT
5681 -- Entry_Direct_Name (Node1)
5682 -- Entry_Index (Node5) (set to Empty if not present)
5683 -- Parameter_Specifications (List3) (set to No_List if no formal part)
5684 -- Handled_Statement_Sequence (Node4)
5685 -- Declarations (List2) (set to No_List if no declarations)
5687 ------------------------
5688 -- 9.5.2 Entry Index --
5689 ------------------------
5691 -- ENTRY_INDEX ::= EXPRESSION
5693 -----------------------
5694 -- 9.5.2 Entry Body --
5695 -----------------------
5698 -- entry DEFINING_IDENTIFIER ENTRY_BODY_FORMAL_PART ENTRY_BARRIER is
5701 -- HANDLED_SEQUENCE_OF_STATEMENTS
5702 -- end [entry_IDENTIFIER];
5704 -- ENTRY_BARRIER ::= when CONDITION
5706 -- Note: we store the CONDITION of the ENTRY_BARRIER in the node for
5707 -- the ENTRY_BODY_FORMAL_PART to avoid the N_Entry_Body node getting
5708 -- too full (it would otherwise have too many fields)
5710 -- Gigi restriction: This node never appears
5713 -- Sloc points to ENTRY
5714 -- Defining_Identifier (Node1)
5715 -- Entry_Body_Formal_Part (Node5)
5716 -- Declarations (List2)
5717 -- Handled_Statement_Sequence (Node4)
5718 -- Activation_Chain_Entity (Node3-Sem)
5720 -----------------------------------
5721 -- 9.5.2 Entry Body Formal Part --
5722 -----------------------------------
5724 -- ENTRY_BODY_FORMAL_PART ::=
5725 -- [(ENTRY_INDEX_SPECIFICATION)] PARAMETER_PROFILE
5727 -- Note that an entry body formal part node is present even if it is
5728 -- empty. This reflects the grammar, in which it is the components of
5729 -- the entry body formal part that are optional, not the entry body
5730 -- formal part itself. Also this means that the barrier condition
5731 -- always has somewhere to be stored.
5733 -- Gigi restriction: This node never appears
5735 -- N_Entry_Body_Formal_Part
5736 -- Sloc points to first token
5737 -- Entry_Index_Specification (Node4) (set to Empty if not present)
5738 -- Parameter_Specifications (List3) (set to No_List if no formal part)
5739 -- Condition (Node1) from entry barrier of entry body
5741 --------------------------
5742 -- 9.5.2 Entry Barrier --
5743 --------------------------
5745 -- ENTRY_BARRIER ::= when CONDITION
5747 --------------------------------------
5748 -- 9.5.2 Entry Index Specification --
5749 --------------------------------------
5751 -- ENTRY_INDEX_SPECIFICATION ::=
5752 -- for DEFINING_IDENTIFIER in DISCRETE_SUBTYPE_DEFINITION
5754 -- Gigi restriction: This node never appears
5756 -- N_Entry_Index_Specification
5757 -- Sloc points to FOR
5758 -- Defining_Identifier (Node1)
5759 -- Discrete_Subtype_Definition (Node4)
5761 ---------------------------------
5762 -- 9.5.3 Entry Call Statement --
5763 ---------------------------------
5765 -- ENTRY_CALL_STATEMENT ::= entry_NAME [ACTUAL_PARAMETER_PART];
5767 -- The parser may generate a procedure call for this construct. The
5768 -- semantic pass must correct this misidentification where needed.
5770 -- Gigi restriction: This node never appears
5772 -- N_Entry_Call_Statement
5773 -- Sloc points to first token of name
5775 -- Parameter_Associations (List3) (set to No_List if no
5776 -- actual parameter part)
5777 -- First_Named_Actual (Node4-Sem)
5779 ------------------------------
5780 -- 9.5.4 Requeue Statement --
5781 ------------------------------
5783 -- REQUEUE_STATEMENT ::= requeue entry_NAME [with abort];
5785 -- Note: requeue statements are not permitted in Ada 83 mode
5787 -- Gigi restriction: This node never appears
5789 -- N_Requeue_Statement
5790 -- Sloc points to REQUEUE
5792 -- Abort_Present (Flag15)
5794 --------------------------
5795 -- 9.6 Delay Statement --
5796 --------------------------
5798 -- DELAY_STATEMENT ::=
5799 -- DELAY_UNTIL_STATEMENT
5800 -- | DELAY_RELATIVE_STATEMENT
5802 --------------------------------
5803 -- 9.6 Delay Until Statement --
5804 --------------------------------
5806 -- DELAY_UNTIL_STATEMENT ::= delay until delay_EXPRESSION;
5808 -- Note: delay until statements are not permitted in Ada 83 mode
5810 -- Gigi restriction: This node never appears
5812 -- N_Delay_Until_Statement
5813 -- Sloc points to DELAY
5814 -- Expression (Node3)
5816 -----------------------------------
5817 -- 9.6 Delay Relative Statement --
5818 -----------------------------------
5820 -- DELAY_RELATIVE_STATEMENT ::= delay delay_EXPRESSION;
5822 -- Gigi restriction: This node never appears
5824 -- N_Delay_Relative_Statement
5825 -- Sloc points to DELAY
5826 -- Expression (Node3)
5828 ---------------------------
5829 -- 9.7 Select Statement --
5830 ---------------------------
5832 -- SELECT_STATEMENT ::=
5834 -- | TIMED_ENTRY_CALL
5835 -- | CONDITIONAL_ENTRY_CALL
5836 -- | ASYNCHRONOUS_SELECT
5838 -----------------------------
5839 -- 9.7.1 Selective Accept --
5840 -----------------------------
5842 -- SELECTIVE_ACCEPT ::=
5845 -- SELECT_ALTERNATIVE
5848 -- SELECT_ALTERNATIVE}
5850 -- SEQUENCE_OF_STATEMENTS]
5853 -- Gigi restriction: This node never appears
5855 -- Note: the guard expression, if present, appears in the node for
5856 -- the select alternative.
5858 -- N_Selective_Accept
5859 -- Sloc points to SELECT
5860 -- Select_Alternatives (List1)
5861 -- Else_Statements (List4) (set to No_List if no else part)
5867 -- GUARD ::= when CONDITION =>
5869 -- As noted above, the CONDITION that is part of a GUARD is included
5870 -- in the node for the select alternative for convenience.
5872 -------------------------------
5873 -- 9.7.1 Select Alternative --
5874 -------------------------------
5876 -- SELECT_ALTERNATIVE ::=
5877 -- ACCEPT_ALTERNATIVE
5878 -- | DELAY_ALTERNATIVE
5879 -- | TERMINATE_ALTERNATIVE
5881 -------------------------------
5882 -- 9.7.1 Accept Alternative --
5883 -------------------------------
5885 -- ACCEPT_ALTERNATIVE ::=
5886 -- ACCEPT_STATEMENT [SEQUENCE_OF_STATEMENTS]
5888 -- Gigi restriction: This node never appears
5890 -- N_Accept_Alternative
5891 -- Sloc points to ACCEPT
5892 -- Accept_Statement (Node2)
5893 -- Condition (Node1) from the guard (set to Empty if no guard present)
5894 -- Statements (List3) (set to Empty_List if no statements)
5895 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
5896 -- Accept_Handler_Records (List5-Sem)
5898 ------------------------------
5899 -- 9.7.1 Delay Alternative --
5900 ------------------------------
5902 -- DELAY_ALTERNATIVE ::=
5903 -- DELAY_STATEMENT [SEQUENCE_OF_STATEMENTS]
5905 -- Gigi restriction: This node never appears
5907 -- N_Delay_Alternative
5908 -- Sloc points to DELAY
5909 -- Delay_Statement (Node2)
5910 -- Condition (Node1) from the guard (set to Empty if no guard present)
5911 -- Statements (List3) (set to Empty_List if no statements)
5912 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
5914 ----------------------------------
5915 -- 9.7.1 Terminate Alternative --
5916 ----------------------------------
5918 -- TERMINATE_ALTERNATIVE ::= terminate;
5920 -- Gigi restriction: This node never appears
5922 -- N_Terminate_Alternative
5923 -- Sloc points to TERMINATE
5924 -- Condition (Node1) from the guard (set to Empty if no guard present)
5925 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
5926 -- Pragmas_After (List5) pragmas after alt (set to No_List if none)
5928 -----------------------------
5929 -- 9.7.2 Timed Entry Call --
5930 -----------------------------
5932 -- TIMED_ENTRY_CALL ::=
5934 -- ENTRY_CALL_ALTERNATIVE
5936 -- DELAY_ALTERNATIVE
5939 -- Gigi restriction: This node never appears
5941 -- N_Timed_Entry_Call
5942 -- Sloc points to SELECT
5943 -- Entry_Call_Alternative (Node1)
5944 -- Delay_Alternative (Node4)
5946 -----------------------------------
5947 -- 9.7.2 Entry Call Alternative --
5948 -----------------------------------
5950 -- ENTRY_CALL_ALTERNATIVE ::=
5951 -- PROCEDURE_OR_ENTRY_CALL [SEQUENCE_OF_STATEMENTS]
5953 -- PROCEDURE_OR_ENTRY_CALL ::=
5954 -- PROCEDURE_CALL_STATEMENT | ENTRY_CALL_STATEMENT
5956 -- Gigi restriction: This node never appears
5958 -- N_Entry_Call_Alternative
5959 -- Sloc points to first token of entry call statement
5960 -- Entry_Call_Statement (Node1)
5961 -- Statements (List3) (set to Empty_List if no statements)
5962 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
5964 -----------------------------------
5965 -- 9.7.3 Conditional Entry Call --
5966 -----------------------------------
5968 -- CONDITIONAL_ENTRY_CALL ::=
5970 -- ENTRY_CALL_ALTERNATIVE
5972 -- SEQUENCE_OF_STATEMENTS
5975 -- Gigi restriction: This node never appears
5977 -- N_Conditional_Entry_Call
5978 -- Sloc points to SELECT
5979 -- Entry_Call_Alternative (Node1)
5980 -- Else_Statements (List4)
5982 --------------------------------
5983 -- 9.7.4 Asynchronous Select --
5984 --------------------------------
5986 -- ASYNCHRONOUS_SELECT ::=
5988 -- TRIGGERING_ALTERNATIVE
5993 -- Note: asynchronous select is not permitted in Ada 83 mode
5995 -- Gigi restriction: This node never appears
5997 -- N_Asynchronous_Select
5998 -- Sloc points to SELECT
5999 -- Triggering_Alternative (Node1)
6000 -- Abortable_Part (Node2)
6002 -----------------------------------
6003 -- 9.7.4 Triggering Alternative --
6004 -----------------------------------
6006 -- TRIGGERING_ALTERNATIVE ::=
6007 -- TRIGGERING_STATEMENT [SEQUENCE_OF_STATEMENTS]
6009 -- Gigi restriction: This node never appears
6011 -- N_Triggering_Alternative
6012 -- Sloc points to first token of triggering statement
6013 -- Triggering_Statement (Node1)
6014 -- Statements (List3) (set to Empty_List if no statements)
6015 -- Pragmas_Before (List4) pragmas before alt (set to No_List if none)
6017 ---------------------------------
6018 -- 9.7.4 Triggering Statement --
6019 ---------------------------------
6021 -- TRIGGERING_STATEMENT ::= PROCEDURE_OR_ENTRY_CALL | DELAY_STATEMENT
6023 ---------------------------
6024 -- 9.7.4 Abortable Part --
6025 ---------------------------
6027 -- ABORTABLE_PART ::= SEQUENCE_OF_STATEMENTS
6029 -- Gigi restriction: This node never appears
6032 -- Sloc points to ABORT
6033 -- Statements (List3)
6035 --------------------------
6036 -- 9.8 Abort Statement --
6037 --------------------------
6039 -- ABORT_STATEMENT ::= abort task_NAME {, task_NAME};
6041 -- Gigi restriction: This node never appears
6043 -- N_Abort_Statement
6044 -- Sloc points to ABORT
6047 -------------------------
6048 -- 10.1.1 Compilation --
6049 -------------------------
6051 -- COMPILATION ::= {COMPILATION_UNIT}
6053 -- There is no explicit node in the tree for a compilation, since in
6054 -- general the compiler is processing only a single compilation unit
6055 -- at a time. It is possible to parse multiple units in syntax check
6056 -- only mode, but the trees are discarded in that case.
6058 ------------------------------
6059 -- 10.1.1 Compilation Unit --
6060 ------------------------------
6062 -- COMPILATION_UNIT ::=
6063 -- CONTEXT_CLAUSE LIBRARY_ITEM
6064 -- | CONTEXT_CLAUSE SUBUNIT
6066 -- The N_Compilation_Unit node itself represents the above syntax.
6067 -- However, there are two additional items not reflected in the above
6068 -- syntax. First we have the global declarations that are added by the
6069 -- code generator. These are outer level declarations (so they cannot
6070 -- be represented as being inside the units). An example is the wrapper
6071 -- subprograms that are created to do ABE checking. As always a list of
6072 -- declarations can contain actions as well (i.e. statements), and such
6073 -- statements are executed as part of the elaboration of the unit. Note
6074 -- that all such declarations are elaborated before the library unit.
6076 -- Similarly, certain actions need to be elaborated at the completion
6077 -- of elaboration of the library unit (notably the statement that sets
6078 -- the Boolean flag indicating that elaboration is complete).
6080 -- The third item not reflected in the syntax is pragmas that appear
6081 -- after the compilation unit. As always pragmas are a problem since
6082 -- they are not part of the formal syntax, but can be stuck into the
6083 -- source following a set of ad hoc rules, and we have to find an ad
6084 -- hoc way of sticking them into the tree. For pragmas that appear
6085 -- before the library unit, we just consider them to be part of the
6086 -- context clause, and pragmas can appear in the Context_Items list
6087 -- of the compilation unit. However, pragmas can also appear after
6088 -- the library item.
6090 -- To deal with all these problems, we create an auxiliary node for
6091 -- a compilation unit, referenced from the N_Compilation_Unit node,
6092 -- that contains these items.
6094 -- N_Compilation_Unit
6095 -- Sloc points to first token of defining unit name
6096 -- Library_Unit (Node4-Sem) corresponding/parent spec/body
6097 -- Context_Items (List1) context items and pragmas preceding unit
6098 -- Private_Present (Flag15) set if library unit has private keyword
6099 -- Unit (Node2) library item or subunit
6100 -- Aux_Decls_Node (Node5) points to the N_Compilation_Unit_Aux node
6101 -- Has_No_Elaboration_Code (Flag17-Sem)
6102 -- Body_Required (Flag13-Sem) set for spec if body is required
6103 -- Acts_As_Spec (Flag4-Sem) flag for subprogram body with no spec
6104 -- Context_Pending (Flag16-Sem)
6105 -- First_Inlined_Subprogram (Node3-Sem)
6106 -- Has_Pragma_Suppress_All (Flag14-Sem)
6108 -- N_Compilation_Unit_Aux
6109 -- Sloc is a copy of the Sloc from the N_Compilation_Unit node
6110 -- Declarations (List2) (set to No_List if no global declarations)
6111 -- Actions (List1) (set to No_List if no actions)
6112 -- Pragmas_After (List5) pragmas after unit (set to No_List if none)
6113 -- Config_Pragmas (List4) config pragmas (set to Empty_List if none)
6114 -- Default_Storage_Pool (Node3-Sem)
6116 --------------------------
6117 -- 10.1.1 Library Item --
6118 --------------------------
6121 -- [private] LIBRARY_UNIT_DECLARATION
6122 -- | LIBRARY_UNIT_BODY
6123 -- | [private] LIBRARY_UNIT_RENAMING_DECLARATION
6125 -- Note: PRIVATE is not allowed in Ada 83 mode
6127 -- There is no explicit node in the tree for library item, instead
6128 -- the declaration or body, and the flag for private if present,
6129 -- appear in the N_Compilation_Unit node.
6131 --------------------------------------
6132 -- 10.1.1 Library Unit Declaration --
6133 --------------------------------------
6135 -- LIBRARY_UNIT_DECLARATION ::=
6136 -- SUBPROGRAM_DECLARATION | PACKAGE_DECLARATION
6137 -- | GENERIC_DECLARATION | GENERIC_INSTANTIATION
6139 -----------------------------------------------
6140 -- 10.1.1 Library Unit Renaming Declaration --
6141 -----------------------------------------------
6143 -- LIBRARY_UNIT_RENAMING_DECLARATION ::=
6144 -- PACKAGE_RENAMING_DECLARATION
6145 -- | GENERIC_RENAMING_DECLARATION
6146 -- | SUBPROGRAM_RENAMING_DECLARATION
6148 -------------------------------
6149 -- 10.1.1 Library unit body --
6150 -------------------------------
6152 -- LIBRARY_UNIT_BODY ::= SUBPROGRAM_BODY | PACKAGE_BODY
6154 ------------------------------
6155 -- 10.1.1 Parent Unit Name --
6156 ------------------------------
6158 -- PARENT_UNIT_NAME ::= NAME
6160 ----------------------------
6161 -- 10.1.2 Context clause --
6162 ----------------------------
6164 -- CONTEXT_CLAUSE ::= {CONTEXT_ITEM}
6166 -- The context clause can include pragmas, and any pragmas that appear
6167 -- before the context clause proper (i.e. all configuration pragmas,
6168 -- also appear at the front of this list).
6170 --------------------------
6171 -- 10.1.2 Context_Item --
6172 --------------------------
6174 -- CONTEXT_ITEM ::= WITH_CLAUSE | USE_CLAUSE | WITH_TYPE_CLAUSE
6176 -------------------------
6177 -- 10.1.2 With clause --
6178 -------------------------
6181 -- with library_unit_NAME {,library_unit_NAME};
6183 -- A separate With clause is built for each name, so that we have
6184 -- a Corresponding_Spec field for each with'ed spec. The flags
6185 -- First_Name and Last_Name are used to reconstruct the exact
6186 -- source form. When a list of names appears in one with clause,
6187 -- the first name in the list has First_Name set, and the last
6188 -- has Last_Name set. If the with clause has only one name, then
6189 -- both of the flags First_Name and Last_Name are set in this name.
6191 -- Note: in the case of implicit with's that are installed by the
6192 -- Rtsfind routine, Implicit_With is set, and the Sloc is typically
6193 -- set to Standard_Location, but it is incorrect to test the Sloc
6194 -- to find out if a with clause is implicit, test the flag instead.
6197 -- Sloc points to first token of library unit name
6198 -- Withed_Body (Node1-Sem)
6200 -- Next_Implicit_With (Node3-Sem)
6201 -- Library_Unit (Node4-Sem)
6202 -- Corresponding_Spec (Node5-Sem)
6203 -- First_Name (Flag5) (set to True if first name or only one name)
6204 -- Last_Name (Flag6) (set to True if last name or only one name)
6205 -- Context_Installed (Flag13-Sem)
6206 -- Elaborate_Present (Flag4-Sem)
6207 -- Elaborate_All_Present (Flag14-Sem)
6208 -- Elaborate_All_Desirable (Flag9-Sem)
6209 -- Elaborate_Desirable (Flag11-Sem)
6210 -- Private_Present (Flag15) set if with_clause has private keyword
6211 -- Implicit_With (Flag16-Sem)
6212 -- Implicit_With_From_Instantiation (Flag12-Sem)
6213 -- Limited_Present (Flag17) set if LIMITED is present
6214 -- Limited_View_Installed (Flag18-Sem)
6215 -- Unreferenced_In_Spec (Flag7-Sem)
6216 -- No_Entities_Ref_In_Spec (Flag8-Sem)
6218 -- Note: Limited_Present and Limited_View_Installed are used to support
6219 -- the implementation of Ada 2005 (AI-50217).
6221 -- Similarly, Private_Present is used to support the implementation of
6222 -- Ada 2005 (AI-50262).
6224 ----------------------
6225 -- With_Type clause --
6226 ----------------------
6228 -- This is a GNAT extension, used to implement mutually recursive
6229 -- types declared in different packages.
6231 -- Note: this is now obsolete. The functionality of this construct
6232 -- is now implemented by the Ada 2005 limited_with_clause.
6234 ---------------------
6235 -- 10.2 Body stub --
6236 ---------------------
6239 -- SUBPROGRAM_BODY_STUB
6240 -- | PACKAGE_BODY_STUB
6242 -- | PROTECTED_BODY_STUB
6244 ----------------------------------
6245 -- 10.1.3 Subprogram Body Stub --
6246 ----------------------------------
6248 -- SUBPROGRAM_BODY_STUB ::=
6249 -- SUBPROGRAM_SPECIFICATION is separate
6250 -- [ASPECT_SPECIFICATION];
6252 -- N_Subprogram_Body_Stub
6253 -- Sloc points to FUNCTION or PROCEDURE
6254 -- Specification (Node1)
6255 -- Corresponding_Spec_Of_Stub (Node2-Sem)
6256 -- Library_Unit (Node4-Sem) points to the subunit
6257 -- Corresponding_Body (Node5-Sem)
6259 -------------------------------
6260 -- 10.1.3 Package Body Stub --
6261 -------------------------------
6263 -- PACKAGE_BODY_STUB ::=
6264 -- package body DEFINING_IDENTIFIER is separate
6265 -- [ASPECT_SPECIFICATION];
6267 -- N_Package_Body_Stub
6268 -- Sloc points to PACKAGE
6269 -- Defining_Identifier (Node1)
6270 -- Corresponding_Spec_Of_Stub (Node2-Sem)
6271 -- Library_Unit (Node4-Sem) points to the subunit
6272 -- Corresponding_Body (Node5-Sem)
6274 ----------------------------
6275 -- 10.1.3 Task Body Stub --
6276 ----------------------------
6278 -- TASK_BODY_STUB ::=
6279 -- task body DEFINING_IDENTIFIER is separate
6280 -- [ASPECT_SPECIFICATION];
6283 -- Sloc points to TASK
6284 -- Defining_Identifier (Node1)
6285 -- Corresponding_Spec_Of_Stub (Node2-Sem)
6286 -- Library_Unit (Node4-Sem) points to the subunit
6287 -- Corresponding_Body (Node5-Sem)
6289 ---------------------------------
6290 -- 10.1.3 Protected Body Stub --
6291 ---------------------------------
6293 -- PROTECTED_BODY_STUB ::=
6294 -- protected body DEFINING_IDENTIFIER is separate
6295 -- [ASPECT_SPECIFICATION];
6297 -- Note: protected body stubs are not allowed in Ada 83 mode
6299 -- N_Protected_Body_Stub
6300 -- Sloc points to PROTECTED
6301 -- Defining_Identifier (Node1)
6302 -- Corresponding_Spec_Of_Stub (Node2-Sem)
6303 -- Library_Unit (Node4-Sem) points to the subunit
6304 -- Corresponding_Body (Node5-Sem)
6306 ---------------------
6307 -- 10.1.3 Subunit --
6308 ---------------------
6310 -- SUBUNIT ::= separate (PARENT_UNIT_NAME) PROPER_BODY
6313 -- Sloc points to SEPARATE
6314 -- Name (Node2) is the name of the parent unit
6315 -- Proper_Body (Node1) is the subunit body
6316 -- Corresponding_Stub (Node3-Sem) is the stub declaration for the unit.
6318 ---------------------------------
6319 -- 11.1 Exception Declaration --
6320 ---------------------------------
6322 -- EXCEPTION_DECLARATION ::= DEFINING_IDENTIFIER_LIST : exception
6323 -- [ASPECT_SPECIFICATIONS];
6325 -- For consistency with object declarations etc., the parser converts
6326 -- the case of multiple identifiers being declared to a series of
6327 -- declarations in which the expression is copied, using the More_Ids
6328 -- and Prev_Ids flags to remember the source form as described in the
6329 -- section on "Handling of Defining Identifier Lists".
6331 -- N_Exception_Declaration
6332 -- Sloc points to EXCEPTION
6333 -- Defining_Identifier (Node1)
6334 -- Expression (Node3-Sem)
6335 -- Renaming_Exception (Node2-Sem)
6336 -- More_Ids (Flag5) (set to False if no more identifiers in list)
6337 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
6339 ------------------------------------------
6340 -- 11.2 Handled Sequence Of Statements --
6341 ------------------------------------------
6343 -- HANDLED_SEQUENCE_OF_STATEMENTS ::=
6344 -- SEQUENCE_OF_STATEMENTS
6346 -- EXCEPTION_HANDLER
6347 -- {EXCEPTION_HANDLER}]
6349 -- cleanup_procedure_call (param, param, param, ...);]
6351 -- The AT END phrase is a GNAT extension to provide for cleanups. It is
6352 -- used only internally currently, but is considered to be syntactic.
6353 -- At the moment, the only cleanup action allowed is a single call to
6354 -- a parameterless procedure, and the Identifier field of the node is
6355 -- the procedure to be called. The cleanup action occurs whenever the
6356 -- sequence of statements is left for any reason. The possible reasons
6358 -- 1. reaching the end of the sequence
6359 -- 2. exit, return, or goto
6360 -- 3. exception or abort
6361 -- For some back ends, such as gcc with ZCX, "at end" is implemented
6362 -- entirely in the back end. In this case, a handled sequence of
6363 -- statements with an "at end" cannot also have exception handlers.
6364 -- For other back ends, such as gcc with SJLJ and .NET, the
6365 -- implementation is split between the front end and back end; the front
6366 -- end implements 3, and the back end implements 1 and 2. In this case,
6367 -- if there is an "at end", the front end inserts the appropriate
6368 -- exception handler, and this handler takes precedence over "at end"
6369 -- in case of exception.
6371 -- The inserted exception handler is of the form:
6373 -- when all others =>
6377 -- where cleanup is the procedure to be called. The reason we do this is
6378 -- so that the front end can handle the necessary entries in the
6379 -- exception tables, and other exception handler actions required as
6380 -- part of the normal handling for exception handlers.
6382 -- The AT END cleanup handler protects only the sequence of statements
6383 -- (not the associated declarations of the parent), just like exception
6384 -- handlers. The big difference is that the cleanup procedure is called
6385 -- on either a normal or an abnormal exit from the statement sequence.
6387 -- Note: the list of Exception_Handlers can contain pragmas as well
6388 -- as actual handlers. In practice these pragmas can only occur at
6389 -- the start of the list, since any pragmas occurring later on will
6390 -- be included in the statement list of the corresponding handler.
6392 -- Note: although in the Ada syntax, the sequence of statements in
6393 -- a handled sequence of statements can only contain statements, we
6394 -- allow free mixing of declarations and statements in the resulting
6395 -- expanded tree. This is for example used to deal with the case of
6396 -- a cleanup procedure that must handle declarations as well as the
6397 -- statements of a block.
6399 -- N_Handled_Sequence_Of_Statements
6400 -- Sloc points to first token of first statement
6401 -- Statements (List3)
6402 -- End_Label (Node4) (set to Empty if expander generated)
6403 -- Exception_Handlers (List5) (set to No_List if none present)
6404 -- At_End_Proc (Node1) (set to Empty if no clean up procedure)
6405 -- First_Real_Statement (Node2-Sem)
6407 -- Note: the parent always contains a Declarations field which contains
6408 -- declarations associated with the handled sequence of statements. This
6409 -- is true even in the case of an accept statement (see description of
6410 -- the N_Accept_Statement node).
6412 -- End_Label refers to the containing construct
6414 -----------------------------
6415 -- 11.2 Exception Handler --
6416 -----------------------------
6418 -- EXCEPTION_HANDLER ::=
6419 -- when [CHOICE_PARAMETER_SPECIFICATION :]
6420 -- EXCEPTION_CHOICE {| EXCEPTION_CHOICE} =>
6421 -- SEQUENCE_OF_STATEMENTS
6423 -- Note: choice parameter specification is not allowed in Ada 83 mode
6425 -- N_Exception_Handler
6426 -- Sloc points to WHEN
6427 -- Choice_Parameter (Node2) (set to Empty if not present)
6428 -- Exception_Choices (List4)
6429 -- Statements (List3)
6430 -- Exception_Label (Node5-Sem) (set to Empty of not present)
6431 -- Local_Raise_Statements (Elist1-Sem) (set to No_Elist if not present)
6432 -- Local_Raise_Not_OK (Flag7-Sem)
6433 -- Has_Local_Raise (Flag8-Sem)
6435 ------------------------------------------
6436 -- 11.2 Choice parameter specification --
6437 ------------------------------------------
6439 -- CHOICE_PARAMETER_SPECIFICATION ::= DEFINING_IDENTIFIER
6441 ----------------------------
6442 -- 11.2 Exception Choice --
6443 ----------------------------
6445 -- EXCEPTION_CHOICE ::= exception_NAME | others
6447 -- Except in the case of OTHERS, no explicit node appears in the tree
6448 -- for exception choice. Instead the exception name appears directly.
6449 -- An OTHERS choice is represented by a N_Others_Choice node (see
6452 -- Note: for the exception choice created for an at end handler, the
6453 -- exception choice is an N_Others_Choice node with All_Others set.
6455 ---------------------------
6456 -- 11.3 Raise Statement --
6457 ---------------------------
6459 -- RAISE_STATEMENT ::= raise [exception_NAME];
6461 -- In Ada 2005, we have
6463 -- RAISE_STATEMENT ::=
6464 -- raise; | raise exception_NAME [with string_EXPRESSION];
6466 -- N_Raise_Statement
6467 -- Sloc points to RAISE
6468 -- Name (Node2) (set to Empty if no exception name present)
6469 -- Expression (Node3) (set to Empty if no expression present)
6470 -- From_At_End (Flag4-Sem)
6472 ----------------------------
6473 -- 11.3 Raise Expression --
6474 ----------------------------
6476 -- RAISE_EXPRESSION ::= raise exception_NAME [with string_EXPRESSION]
6478 -- N_Raise_Expression
6479 -- Sloc points to RAISE
6480 -- Name (Node2) (always present)
6481 -- Expression (Node3) (set to Empty if no expression present)
6482 -- Convert_To_Return_False (Flag13-Sem)
6483 -- plus fields for expression
6485 -------------------------------
6486 -- 12.1 Generic Declaration --
6487 -------------------------------
6489 -- GENERIC_DECLARATION ::=
6490 -- GENERIC_SUBPROGRAM_DECLARATION | GENERIC_PACKAGE_DECLARATION
6492 ------------------------------------------
6493 -- 12.1 Generic Subprogram Declaration --
6494 ------------------------------------------
6496 -- GENERIC_SUBPROGRAM_DECLARATION ::=
6497 -- GENERIC_FORMAL_PART SUBPROGRAM_SPECIFICATION
6498 -- [ASPECT_SPECIFICATIONS];
6500 -- Note: Generic_Formal_Declarations can include pragmas
6502 -- N_Generic_Subprogram_Declaration
6503 -- Sloc points to GENERIC
6504 -- Specification (Node1) subprogram specification
6505 -- Corresponding_Body (Node5-Sem)
6506 -- Generic_Formal_Declarations (List2) from generic formal part
6507 -- Parent_Spec (Node4-Sem)
6509 ---------------------------------------
6510 -- 12.1 Generic Package Declaration --
6511 ---------------------------------------
6513 -- GENERIC_PACKAGE_DECLARATION ::=
6514 -- GENERIC_FORMAL_PART PACKAGE_SPECIFICATION
6515 -- [ASPECT_SPECIFICATIONS];
6517 -- Note: when we do generics right, the Activation_Chain_Entity entry
6518 -- for this node can be removed (since the expander won't see generic
6519 -- units any more)???.
6521 -- Note: Generic_Formal_Declarations can include pragmas
6523 -- N_Generic_Package_Declaration
6524 -- Sloc points to GENERIC
6525 -- Specification (Node1) package specification
6526 -- Corresponding_Body (Node5-Sem)
6527 -- Generic_Formal_Declarations (List2) from generic formal part
6528 -- Parent_Spec (Node4-Sem)
6529 -- Activation_Chain_Entity (Node3-Sem)
6531 -------------------------------
6532 -- 12.1 Generic Formal Part --
6533 -------------------------------
6535 -- GENERIC_FORMAL_PART ::=
6536 -- generic {GENERIC_FORMAL_PARAMETER_DECLARATION | USE_CLAUSE}
6538 ------------------------------------------------
6539 -- 12.1 Generic Formal Parameter Declaration --
6540 ------------------------------------------------
6542 -- GENERIC_FORMAL_PARAMETER_DECLARATION ::=
6543 -- FORMAL_OBJECT_DECLARATION
6544 -- | FORMAL_TYPE_DECLARATION
6545 -- | FORMAL_SUBPROGRAM_DECLARATION
6546 -- | FORMAL_PACKAGE_DECLARATION
6548 ---------------------------------
6549 -- 12.3 Generic Instantiation --
6550 ---------------------------------
6552 -- GENERIC_INSTANTIATION ::=
6553 -- package DEFINING_PROGRAM_UNIT_NAME is
6554 -- new generic_package_NAME [GENERIC_ACTUAL_PART]
6555 -- [ASPECT_SPECIFICATIONS];
6556 -- | [[not] overriding]
6557 -- procedure DEFINING_PROGRAM_UNIT_NAME is
6558 -- new generic_procedure_NAME [GENERIC_ACTUAL_PART]
6559 -- [ASPECT_SPECIFICATIONS];
6560 -- | [[not] overriding]
6561 -- function DEFINING_DESIGNATOR is
6562 -- new generic_function_NAME [GENERIC_ACTUAL_PART]
6563 -- [ASPECT_SPECIFICATIONS];
6565 -- N_Package_Instantiation
6566 -- Sloc points to PACKAGE
6567 -- Defining_Unit_Name (Node1)
6569 -- Generic_Associations (List3) (set to No_List if no
6570 -- generic actual part)
6571 -- Parent_Spec (Node4-Sem)
6572 -- Instance_Spec (Node5-Sem)
6573 -- ABE_Is_Certain (Flag18-Sem)
6575 -- N_Procedure_Instantiation
6576 -- Sloc points to PROCEDURE
6577 -- Defining_Unit_Name (Node1)
6579 -- Parent_Spec (Node4-Sem)
6580 -- Generic_Associations (List3) (set to No_List if no
6581 -- generic actual part)
6582 -- Instance_Spec (Node5-Sem)
6583 -- Must_Override (Flag14) set if overriding indicator present
6584 -- Must_Not_Override (Flag15) set if not_overriding indicator present
6585 -- ABE_Is_Certain (Flag18-Sem)
6587 -- N_Function_Instantiation
6588 -- Sloc points to FUNCTION
6589 -- Defining_Unit_Name (Node1)
6591 -- Generic_Associations (List3) (set to No_List if no
6592 -- generic actual part)
6593 -- Parent_Spec (Node4-Sem)
6594 -- Instance_Spec (Node5-Sem)
6595 -- Must_Override (Flag14) set if overriding indicator present
6596 -- Must_Not_Override (Flag15) set if not_overriding indicator present
6597 -- ABE_Is_Certain (Flag18-Sem)
6599 -- Note: overriding indicator is an Ada 2005 feature
6601 -------------------------------
6602 -- 12.3 Generic Actual Part --
6603 -------------------------------
6605 -- GENERIC_ACTUAL_PART ::=
6606 -- (GENERIC_ASSOCIATION {, GENERIC_ASSOCIATION})
6608 -------------------------------
6609 -- 12.3 Generic Association --
6610 -------------------------------
6612 -- GENERIC_ASSOCIATION ::=
6613 -- [generic_formal_parameter_SELECTOR_NAME =>]
6615 -- Note: unlike the procedure call case, a generic association node
6616 -- is generated for every association, even if no formal parameter
6617 -- selector name is present. In this case the parser will leave the
6618 -- Selector_Name field set to Empty, to be filled in later by the
6621 -- In Ada 2005, a formal may be associated with a box, if the
6622 -- association is part of the list of actuals for a formal package.
6623 -- If the association is given by OTHERS => <>, the association is
6624 -- an N_Others_Choice.
6626 -- N_Generic_Association
6627 -- Sloc points to first token of generic association
6628 -- Selector_Name (Node2) (set to Empty if no formal
6629 -- parameter selector name)
6630 -- Explicit_Generic_Actual_Parameter (Node1) (Empty if box present)
6631 -- Box_Present (Flag15) (for formal_package associations with a box)
6633 ---------------------------------------------
6634 -- 12.3 Explicit Generic Actual Parameter --
6635 ---------------------------------------------
6637 -- EXPLICIT_GENERIC_ACTUAL_PARAMETER ::=
6638 -- EXPRESSION | variable_NAME | subprogram_NAME
6639 -- | entry_NAME | SUBTYPE_MARK | package_instance_NAME
6641 -------------------------------------
6642 -- 12.4 Formal Object Declaration --
6643 -------------------------------------
6645 -- FORMAL_OBJECT_DECLARATION ::=
6646 -- DEFINING_IDENTIFIER_LIST :
6647 -- MODE [NULL_EXCLUSION] SUBTYPE_MARK [:= DEFAULT_EXPRESSION]
6648 -- [ASPECT_SPECIFICATIONS];
6649 -- | DEFINING_IDENTIFIER_LIST :
6650 -- MODE ACCESS_DEFINITION [:= DEFAULT_EXPRESSION]
6651 -- [ASPECT_SPECIFICATIONS];
6653 -- Although the syntax allows multiple identifiers in the list, the
6654 -- semantics is as though successive declarations were given with
6655 -- identical type definition and expression components. To simplify
6656 -- semantic processing, the parser represents a multiple declaration
6657 -- case as a sequence of single declarations, using the More_Ids and
6658 -- Prev_Ids flags to preserve the original source form as described
6659 -- in the section on "Handling of Defining Identifier Lists".
6661 -- N_Formal_Object_Declaration
6662 -- Sloc points to first identifier
6663 -- Defining_Identifier (Node1)
6664 -- In_Present (Flag15)
6665 -- Out_Present (Flag17)
6666 -- Null_Exclusion_Present (Flag11) (set to False if not present)
6667 -- Subtype_Mark (Node4) (set to Empty if not present)
6668 -- Access_Definition (Node3) (set to Empty if not present)
6669 -- Default_Expression (Node5) (set to Empty if no default expression)
6670 -- More_Ids (Flag5) (set to False if no more identifiers in list)
6671 -- Prev_Ids (Flag6) (set to False if no previous identifiers in list)
6673 -----------------------------------
6674 -- 12.5 Formal Type Declaration --
6675 -----------------------------------
6677 -- FORMAL_TYPE_DECLARATION ::=
6678 -- type DEFINING_IDENTIFIER [DISCRIMINANT_PART]
6679 -- is FORMAL_TYPE_DEFINITION
6680 -- [ASPECT_SPECIFICATIONS];
6681 -- | type DEFINING_IDENTIFIER [DISCRIMINANT_PART] [is tagged]
6683 -- N_Formal_Type_Declaration
6684 -- Sloc points to TYPE
6685 -- Defining_Identifier (Node1)
6686 -- Formal_Type_Definition (Node3)
6687 -- Discriminant_Specifications (List4) (set to No_List if no
6688 -- discriminant part)
6689 -- Unknown_Discriminants_Present (Flag13) set if (<>) discriminant
6691 ----------------------------------
6692 -- 12.5 Formal type definition --
6693 ----------------------------------
6695 -- FORMAL_TYPE_DEFINITION ::=
6696 -- FORMAL_PRIVATE_TYPE_DEFINITION
6697 -- | FORMAL_DERIVED_TYPE_DEFINITION
6698 -- | FORMAL_DISCRETE_TYPE_DEFINITION
6699 -- | FORMAL_SIGNED_INTEGER_TYPE_DEFINITION
6700 -- | FORMAL_MODULAR_TYPE_DEFINITION
6701 -- | FORMAL_FLOATING_POINT_DEFINITION
6702 -- | FORMAL_ORDINARY_FIXED_POINT_DEFINITION
6703 -- | FORMAL_DECIMAL_FIXED_POINT_DEFINITION
6704 -- | FORMAL_ARRAY_TYPE_DEFINITION
6705 -- | FORMAL_ACCESS_TYPE_DEFINITION
6706 -- | FORMAL_INTERFACE_TYPE_DEFINITION
6707 -- | FORMAL_INCOMPLETE_TYPE_DEFINITION
6709 -- The Ada 2012 syntax introduces two new non-terminals:
6710 -- Formal_{Complete,Incomplete}_Type_Declaration just to introduce
6711 -- the latter category. Here we introduce an incomplete type definition
6712 -- in order to preserve as much as possible the existing structure.
6714 ---------------------------------------------
6715 -- 12.5.1 Formal Private Type Definition --
6716 ---------------------------------------------
6718 -- FORMAL_PRIVATE_TYPE_DEFINITION ::=
6719 -- [[abstract] tagged] [limited] private
6721 -- Note: TAGGED is not allowed in Ada 83 mode
6723 -- N_Formal_Private_Type_Definition
6724 -- Sloc points to PRIVATE
6725 -- Uninitialized_Variable (Node3-Sem)
6726 -- Abstract_Present (Flag4)
6727 -- Tagged_Present (Flag15)
6728 -- Limited_Present (Flag17)
6730 --------------------------------------------
6731 -- 12.5.1 Formal Derived Type Definition --
6732 --------------------------------------------
6734 -- FORMAL_DERIVED_TYPE_DEFINITION ::=
6735 -- [abstract] [limited | synchronized]
6736 -- new SUBTYPE_MARK [[and INTERFACE_LIST] with private]
6737 -- Note: this construct is not allowed in Ada 83 mode
6739 -- N_Formal_Derived_Type_Definition
6740 -- Sloc points to NEW
6741 -- Subtype_Mark (Node4)
6742 -- Private_Present (Flag15)
6743 -- Abstract_Present (Flag4)
6744 -- Limited_Present (Flag17)
6745 -- Synchronized_Present (Flag7)
6746 -- Interface_List (List2) (set to No_List if none)
6748 -----------------------------------------------
6749 -- 12.5.1 Formal Incomplete Type Definition --
6750 -----------------------------------------------
6752 -- FORMAL_INCOMPLETE_TYPE_DEFINITION ::= [tagged]
6754 -- N_Formal_Incomplete_Type_Definition
6755 -- Sloc points to identifier of parent
6756 -- Tagged_Present (Flag15)
6758 ---------------------------------------------
6759 -- 12.5.2 Formal Discrete Type Definition --
6760 ---------------------------------------------
6762 -- FORMAL_DISCRETE_TYPE_DEFINITION ::= (<>)
6764 -- N_Formal_Discrete_Type_Definition
6767 ---------------------------------------------------
6768 -- 12.5.2 Formal Signed Integer Type Definition --
6769 ---------------------------------------------------
6771 -- FORMAL_SIGNED_INTEGER_TYPE_DEFINITION ::= range <>
6773 -- N_Formal_Signed_Integer_Type_Definition
6774 -- Sloc points to RANGE
6776 --------------------------------------------
6777 -- 12.5.2 Formal Modular Type Definition --
6778 --------------------------------------------
6780 -- FORMAL_MODULAR_TYPE_DEFINITION ::= mod <>
6782 -- N_Formal_Modular_Type_Definition
6783 -- Sloc points to MOD
6785 ----------------------------------------------
6786 -- 12.5.2 Formal Floating Point Definition --
6787 ----------------------------------------------
6789 -- FORMAL_FLOATING_POINT_DEFINITION ::= digits <>
6791 -- N_Formal_Floating_Point_Definition
6792 -- Sloc points to DIGITS
6794 ----------------------------------------------------
6795 -- 12.5.2 Formal Ordinary Fixed Point Definition --
6796 ----------------------------------------------------
6798 -- FORMAL_ORDINARY_FIXED_POINT_DEFINITION ::= delta <>
6800 -- N_Formal_Ordinary_Fixed_Point_Definition
6801 -- Sloc points to DELTA
6803 ---------------------------------------------------
6804 -- 12.5.2 Formal Decimal Fixed Point Definition --
6805 ---------------------------------------------------
6807 -- FORMAL_DECIMAL_FIXED_POINT_DEFINITION ::= delta <> digits <>
6809 -- Note: formal decimal fixed point definition not allowed in Ada 83
6811 -- N_Formal_Decimal_Fixed_Point_Definition
6812 -- Sloc points to DELTA
6814 ------------------------------------------
6815 -- 12.5.3 Formal Array Type Definition --
6816 ------------------------------------------
6818 -- FORMAL_ARRAY_TYPE_DEFINITION ::= ARRAY_TYPE_DEFINITION
6820 -------------------------------------------
6821 -- 12.5.4 Formal Access Type Definition --
6822 -------------------------------------------
6824 -- FORMAL_ACCESS_TYPE_DEFINITION ::= ACCESS_TYPE_DEFINITION
6826 ----------------------------------------------
6827 -- 12.5.5 Formal Interface Type Definition --
6828 ----------------------------------------------
6830 -- FORMAL_INTERFACE_TYPE_DEFINITION ::= INTERFACE_TYPE_DEFINITION
6832 -----------------------------------------
6833 -- 12.6 Formal Subprogram Declaration --
6834 -----------------------------------------
6836 -- FORMAL_SUBPROGRAM_DECLARATION ::=
6837 -- FORMAL_CONCRETE_SUBPROGRAM_DECLARATION
6838 -- | FORMAL_ABSTRACT_SUBPROGRAM_DECLARATION
6840 --------------------------------------------------
6841 -- 12.6 Formal Concrete Subprogram Declaration --
6842 --------------------------------------------------
6844 -- FORMAL_CONCRETE_SUBPROGRAM_DECLARATION ::=
6845 -- with SUBPROGRAM_SPECIFICATION [is SUBPROGRAM_DEFAULT]
6846 -- [ASPECT_SPECIFICATIONS];
6848 -- N_Formal_Concrete_Subprogram_Declaration
6849 -- Sloc points to WITH
6850 -- Specification (Node1)
6851 -- Default_Name (Node2) (set to Empty if no subprogram default)
6852 -- Box_Present (Flag15)
6854 -- Note: if no subprogram default is present, then Name is set
6855 -- to Empty, and Box_Present is False.
6857 --------------------------------------------------
6858 -- 12.6 Formal Abstract Subprogram Declaration --
6859 --------------------------------------------------
6861 -- FORMAL_ABSTRACT_SUBPROGRAM_DECLARATION ::=
6862 -- with SUBPROGRAM_SPECIFICATION is abstract [SUBPROGRAM_DEFAULT]
6863 -- [ASPECT_SPECIFICATIONS];
6865 -- N_Formal_Abstract_Subprogram_Declaration
6866 -- Sloc points to WITH
6867 -- Specification (Node1)
6868 -- Default_Name (Node2) (set to Empty if no subprogram default)
6869 -- Box_Present (Flag15)
6871 -- Note: if no subprogram default is present, then Name is set
6872 -- to Empty, and Box_Present is False.
6874 ------------------------------
6875 -- 12.6 Subprogram Default --
6876 ------------------------------
6878 -- SUBPROGRAM_DEFAULT ::= DEFAULT_NAME | <>
6880 -- There is no separate node in the tree for a subprogram default.
6881 -- Instead the parent (N_Formal_Concrete_Subprogram_Declaration
6882 -- or N_Formal_Abstract_Subprogram_Declaration) node contains the
6883 -- default name or box indication, as needed.
6885 ------------------------
6886 -- 12.6 Default Name --
6887 ------------------------
6889 -- DEFAULT_NAME ::= NAME
6891 --------------------------------------
6892 -- 12.7 Formal Package Declaration --
6893 --------------------------------------
6895 -- FORMAL_PACKAGE_DECLARATION ::=
6896 -- with package DEFINING_IDENTIFIER
6897 -- is new generic_package_NAME FORMAL_PACKAGE_ACTUAL_PART
6898 -- [ASPECT_SPECIFICATIONS];
6900 -- Note: formal package declarations not allowed in Ada 83 mode
6902 -- N_Formal_Package_Declaration
6903 -- Sloc points to WITH
6904 -- Defining_Identifier (Node1)
6906 -- Generic_Associations (List3) (set to No_List if (<>) case or
6907 -- empty generic actual part)
6908 -- Box_Present (Flag15)
6909 -- Instance_Spec (Node5-Sem)
6910 -- ABE_Is_Certain (Flag18-Sem)
6912 --------------------------------------
6913 -- 12.7 Formal Package Actual Part --
6914 --------------------------------------
6916 -- FORMAL_PACKAGE_ACTUAL_PART ::=
6918 -- | [GENERIC_ACTUAL_PART]
6919 -- (FORMAL_PACKAGE_ASSOCIATION {. FORMAL_PACKAGE_ASSOCIATION}
6921 -- FORMAL_PACKAGE_ASSOCIATION ::=
6922 -- GENERIC_ASSOCIATION
6923 -- | GENERIC_FORMAL_PARAMETER_SELECTOR_NAME => <>
6925 -- There is no explicit node in the tree for a formal package actual
6926 -- part. Instead the information appears in the parent node (i.e. the
6927 -- formal package declaration node itself).
6929 -- There is no explicit node for a formal package association. All of
6930 -- them are represented either by a generic association, possibly with
6931 -- Box_Present, or by an N_Others_Choice.
6933 ---------------------------------
6934 -- 13.1 Representation clause --
6935 ---------------------------------
6937 -- REPRESENTATION_CLAUSE ::=
6938 -- ATTRIBUTE_DEFINITION_CLAUSE
6939 -- | ENUMERATION_REPRESENTATION_CLAUSE
6940 -- | RECORD_REPRESENTATION_CLAUSE
6943 ----------------------
6944 -- 13.1 Local Name --
6945 ----------------------
6949 -- | DIRECT_NAME'ATTRIBUTE_DESIGNATOR
6950 -- | library_unit_NAME
6952 -- The construct DIRECT_NAME'ATTRIBUTE_DESIGNATOR appears in the tree
6953 -- as an attribute reference, which has essentially the same form.
6955 ---------------------------------------
6956 -- 13.3 Attribute definition clause --
6957 ---------------------------------------
6959 -- ATTRIBUTE_DEFINITION_CLAUSE ::=
6960 -- for LOCAL_NAME'ATTRIBUTE_DESIGNATOR use EXPRESSION;
6961 -- | for LOCAL_NAME'ATTRIBUTE_DESIGNATOR use NAME;
6963 -- In Ada 83, the expression must be a simple expression and the
6964 -- local name must be a direct name.
6966 -- Note: the only attribute definition clause that is processed by
6967 -- gigi is an address clause. For all other cases, the information
6968 -- is extracted by the front end and either results in setting entity
6969 -- information, e.g. Esize for the Size clause, or in appropriate
6970 -- expansion actions (e.g. in the case of Storage_Size).
6972 -- For an address clause, Gigi constructs the appropriate addressing
6973 -- code. It also ensures that no aliasing optimizations are made
6974 -- for the object for which the address clause appears.
6976 -- Note: for an address clause used to achieve an overlay:
6980 -- for B'Address use A'Address;
6982 -- the above rule means that Gigi will ensure that no optimizations
6983 -- will be made for B that would violate the implementation advice
6984 -- of RM 13.3(19). However, this advice applies only to B and not
6985 -- to A, which seems unfortunate. The GNAT front end will mark the
6986 -- object A as volatile to also prevent unwanted optimization
6987 -- assumptions based on no aliasing being made for B.
6989 -- N_Attribute_Definition_Clause
6990 -- Sloc points to FOR
6991 -- Name (Node2) the local name
6992 -- Chars (Name1) the identifier name from the attribute designator
6993 -- Expression (Node3) the expression or name
6994 -- Entity (Node4-Sem)
6995 -- Next_Rep_Item (Node5-Sem)
6996 -- From_At_Mod (Flag4-Sem)
6997 -- Check_Address_Alignment (Flag11-Sem)
6998 -- From_Aspect_Specification (Flag13-Sem)
6999 -- Is_Delayed_Aspect (Flag14-Sem)
7000 -- Address_Warning_Posted (Flag18-Sem)
7002 -- Note: if From_Aspect_Specification is set, then Sloc points to the
7003 -- aspect name, and Entity is resolved already to reference the entity
7004 -- to which the aspect applies.
7006 -----------------------------------
7007 -- 13.3.1 Aspect Specifications --
7008 -----------------------------------
7010 -- We modify the RM grammar here, the RM grammar is:
7012 -- ASPECT_SPECIFICATION ::=
7013 -- with ASPECT_MARK [=> ASPECT_DEFINITION] {,
7014 -- ASPECT_MARK [=> ASPECT_DEFINITION] }
7016 -- ASPECT_MARK ::= aspect_IDENTIFIER['Class]
7018 -- ASPECT_DEFINITION ::= NAME | EXPRESSION
7020 -- That's inconvenient, since there is no non-terminal name for a single
7021 -- entry in the list of aspects. So we use this grammar instead:
7023 -- ASPECT_SPECIFICATIONS ::=
7024 -- with ASPECT_SPECIFICATION {, ASPECT_SPECIFICATION}
7026 -- ASPECT_SPECIFICATION =>
7027 -- ASPECT_MARK [=> ASPECT_DEFINITION]
7029 -- ASPECT_MARK ::= aspect_IDENTIFIER['Class]
7031 -- ASPECT_DEFINITION ::= NAME | EXPRESSION
7033 -- See separate package Aspects for details on the incorporation of
7034 -- these nodes into the tree, and how aspect specifications for a given
7035 -- declaration node are associated with that node.
7037 -- N_Aspect_Specification
7038 -- Sloc points to aspect identifier
7039 -- Identifier (Node1) aspect identifier
7040 -- Aspect_Rep_Item (Node2-Sem)
7041 -- Expression (Node3) Aspect_Definition (set to Empty if none)
7042 -- Entity (Node4-Sem) entity to which the aspect applies
7043 -- Class_Present (Flag6) Set if 'Class present
7044 -- Next_Rep_Item (Node5-Sem)
7045 -- Split_PPC (Flag17) Set if split pre/post attribute
7046 -- Is_Boolean_Aspect (Flag16-Sem)
7047 -- Is_Checked (Flag11-Sem)
7048 -- Is_Delayed_Aspect (Flag14-Sem)
7049 -- Is_Disabled (Flag15-Sem)
7050 -- Is_Ignored (Flag9-Sem)
7052 -- Note: Aspect_Specification is an Ada 2012 feature
7054 -- Note: The Identifier serves to identify the aspect involved (it
7055 -- is the aspect whose name corresponds to the Chars field). This
7056 -- means that the other fields of this identifier are unused, and
7057 -- in particular we use the Entity field of this identifier to save
7058 -- a copy of the expression for visibility analysis, see spec of
7059 -- Sem_Ch13 for full details of this usage.
7061 -- In the case of aspects of the form xxx'Class, the aspect identifier
7062 -- is for xxx, and Class_Present is set to True.
7064 -- Note: When a Pre or Post aspect specification is processed, it is
7065 -- broken into AND THEN sections. The left most section has Split_PPC
7066 -- set to False, indicating that it is the original specification (e.g.
7067 -- for posting errors). For the other sections, Split_PPC is set True.
7069 ---------------------------------------------
7070 -- 13.4 Enumeration representation clause --
7071 ---------------------------------------------
7073 -- ENUMERATION_REPRESENTATION_CLAUSE ::=
7074 -- for first_subtype_LOCAL_NAME use ENUMERATION_AGGREGATE;
7076 -- In Ada 83, the name must be a direct name
7078 -- N_Enumeration_Representation_Clause
7079 -- Sloc points to FOR
7080 -- Identifier (Node1) direct name
7081 -- Array_Aggregate (Node3)
7082 -- Next_Rep_Item (Node5-Sem)
7084 ---------------------------------
7085 -- 13.4 Enumeration aggregate --
7086 ---------------------------------
7088 -- ENUMERATION_AGGREGATE ::= ARRAY_AGGREGATE
7090 ------------------------------------------
7091 -- 13.5.1 Record representation clause --
7092 ------------------------------------------
7094 -- RECORD_REPRESENTATION_CLAUSE ::=
7095 -- for first_subtype_LOCAL_NAME use
7096 -- record [MOD_CLAUSE]
7097 -- {COMPONENT_CLAUSE}
7100 -- Gigi restriction: Mod_Clause is always Empty (if present it is
7101 -- replaced by a corresponding Alignment attribute definition clause).
7103 -- Note: Component_Clauses can include pragmas
7105 -- N_Record_Representation_Clause
7106 -- Sloc points to FOR
7107 -- Identifier (Node1) direct name
7108 -- Mod_Clause (Node2) (set to Empty if no mod clause present)
7109 -- Component_Clauses (List3)
7110 -- Next_Rep_Item (Node5-Sem)
7112 ------------------------------
7113 -- 13.5.1 Component clause --
7114 ------------------------------
7116 -- COMPONENT_CLAUSE ::=
7117 -- component_LOCAL_NAME at POSITION
7118 -- range FIRST_BIT .. LAST_BIT;
7120 -- N_Component_Clause
7121 -- Sloc points to AT
7122 -- Component_Name (Node1) points to Name or Attribute_Reference
7124 -- First_Bit (Node3)
7127 ----------------------
7128 -- 13.5.1 Position --
7129 ----------------------
7131 -- POSITION ::= static_EXPRESSION
7133 -----------------------
7134 -- 13.5.1 First_Bit --
7135 -----------------------
7137 -- FIRST_BIT ::= static_SIMPLE_EXPRESSION
7139 ----------------------
7140 -- 13.5.1 Last_Bit --
7141 ----------------------
7143 -- LAST_BIT ::= static_SIMPLE_EXPRESSION
7145 --------------------------
7146 -- 13.8 Code statement --
7147 --------------------------
7149 -- CODE_STATEMENT ::= QUALIFIED_EXPRESSION;
7151 -- Note: in GNAT, the qualified expression has the form
7153 -- Asm_Insn'(Asm (...));
7155 -- See package System.Machine_Code in file s-maccod.ads for details on
7156 -- the allowed parameters to Asm. There are two ways this node can
7157 -- arise, as a code statement, in which case the expression is the
7158 -- qualified expression, or as a result of the expansion of an intrinsic
7159 -- call to the Asm or Asm_Input procedure.
7162 -- Sloc points to first token of the expression
7163 -- Expression (Node3)
7165 -- Note: package Exp_Code contains an abstract functional interface
7166 -- for use by Gigi in accessing the data from N_Code_Statement nodes.
7168 ------------------------
7169 -- 13.12 Restriction --
7170 ------------------------
7173 -- restriction_IDENTIFIER
7174 -- | restriction_parameter_IDENTIFIER => EXPRESSION
7176 -- There is no explicit node for restrictions. Instead the restriction
7177 -- appears in normal pragma syntax as a pragma argument association,
7178 -- which has the same syntactic form.
7180 --------------------------
7181 -- B.2 Shift Operators --
7182 --------------------------
7184 -- Calls to the intrinsic shift functions are converted to one of
7185 -- the following shift nodes, which have the form of normal binary
7186 -- operator names. Note that for a given shift operation, one node
7187 -- covers all possible types, as for normal operators.
7189 -- Note: it is perfectly permissible for the expander to generate
7190 -- shift operation nodes directly, in which case they will be analyzed
7191 -- and parsed in the usual manner.
7193 -- Sprint syntax: shift-function-name!(expr, count)
7195 -- Note: the Left_Opnd field holds the first argument (the value to
7196 -- be shifted). The Right_Opnd field holds the second argument (the
7197 -- shift count). The Chars field is the name of the intrinsic function.
7200 -- Sloc points to the function name
7201 -- plus fields for binary operator
7202 -- plus fields for expression
7203 -- Shift_Count_OK (Flag4-Sem)
7205 -- N_Op_Rotate_Right
7206 -- Sloc points to the function name
7207 -- plus fields for binary operator
7208 -- plus fields for expression
7209 -- Shift_Count_OK (Flag4-Sem)
7212 -- Sloc points to the function name
7213 -- plus fields for binary operator
7214 -- plus fields for expression
7215 -- Shift_Count_OK (Flag4-Sem)
7217 -- N_Op_Shift_Right_Arithmetic
7218 -- Sloc points to the function name
7219 -- plus fields for binary operator
7220 -- plus fields for expression
7221 -- Shift_Count_OK (Flag4-Sem)
7224 -- Sloc points to the function name
7225 -- plus fields for binary operator
7226 -- plus fields for expression
7227 -- Shift_Count_OK (Flag4-Sem)
7229 -- Note: N_Op_Rotate_Left, N_Op_Rotate_Right, N_Shift_Right_Arithmetic
7230 -- never appear in the expanded tree if Modify_Tree_For_C mode is set.
7232 -- Note: For N_Op_Shift_Left and N_Op_Shift_Right, the right operand is
7233 -- always less than the word size if Modify_Tree_For_C mode is set.
7235 --------------------------
7236 -- Obsolescent Features --
7237 --------------------------
7239 -- The syntax descriptions and tree nodes for obsolescent features are
7240 -- grouped together, corresponding to their location in appendix I in
7241 -- the RM. However, parsing and semantic analysis for these constructs
7242 -- is located in an appropriate chapter (see individual notes).
7244 ---------------------------
7245 -- J.3 Delta Constraint --
7246 ---------------------------
7248 -- Note: the parse routine for this construct is located in section
7249 -- 3.5.9 of Par-Ch3, and semantic analysis is in Sem_Ch3, which is
7250 -- where delta constraint logically belongs.
7252 -- DELTA_CONSTRAINT ::= DELTA static_EXPRESSION [RANGE_CONSTRAINT]
7254 -- N_Delta_Constraint
7255 -- Sloc points to DELTA
7256 -- Delta_Expression (Node3)
7257 -- Range_Constraint (Node4) (set to Empty if not present)
7259 --------------------
7261 --------------------
7263 -- AT_CLAUSE ::= for DIRECT_NAME use at EXPRESSION;
7265 -- Note: the parse routine for this construct is located in Par-Ch13,
7266 -- and the semantic analysis is in Sem_Ch13, where at clause logically
7267 -- belongs if it were not obsolescent.
7269 -- Note: in Ada 83 the expression must be a simple expression
7271 -- Gigi restriction: This node never appears, it is rewritten as an
7272 -- address attribute definition clause.
7275 -- Sloc points to FOR
7276 -- Identifier (Node1)
7277 -- Expression (Node3)
7279 ---------------------
7280 -- J.8 Mod clause --
7281 ---------------------
7283 -- MOD_CLAUSE ::= at mod static_EXPRESSION;
7285 -- Note: the parse routine for this construct is located in Par-Ch13,
7286 -- and the semantic analysis is in Sem_Ch13, where mod clause logically
7287 -- belongs if it were not obsolescent.
7289 -- Note: in Ada 83, the expression must be a simple expression
7291 -- Gigi restriction: this node never appears. It is replaced
7292 -- by a corresponding Alignment attribute definition clause.
7294 -- Note: pragmas can appear before and after the MOD_CLAUSE since
7295 -- its name has "clause" in it. This is rather strange, but is quite
7296 -- definitely specified. The pragmas before are collected in the
7297 -- Pragmas_Before field of the mod clause node itself, and pragmas
7298 -- after are simply swallowed up in the list of component clauses.
7301 -- Sloc points to AT
7302 -- Expression (Node3)
7303 -- Pragmas_Before (List4) Pragmas before mod clause (No_List if none)
7305 --------------------
7306 -- Semantic Nodes --
7307 --------------------
7309 -- These semantic nodes are used to hold additional semantic information.
7310 -- They are inserted into the tree as a result of semantic processing.
7311 -- Although there are no legitimate source syntax constructions that
7312 -- correspond directly to these nodes, we need a source syntax for the
7313 -- reconstructed tree printed by Sprint, and the node descriptions here
7314 -- show this syntax.
7316 ------------------------
7317 -- Compound Statement --
7318 ------------------------
7320 -- This node is created by the analyzer/expander to handle some
7321 -- expansion cases where a sequence of actions needs to be captured
7322 -- within a single node (which acts as a container and allows the
7323 -- entire list of actions to be moved around as a whole) appearing
7324 -- in a sequence of statements.
7326 -- This is the statement counterpart to expression node N_Expression_
7329 -- The required semantics is that the set of actions is executed in
7330 -- the order in which it appears, as though they appeared by themselves
7331 -- in the enclosing list of declarations of statements. Unlike what
7332 -- happens when using an N_Block_Statement, no new scope is introduced.
7334 -- Note: for the time being, this is used only as a transient
7335 -- representation during expansion, and all compound statement nodes
7336 -- must be exploded back to their constituent statements before handing
7337 -- the tree to the back end.
7339 -- Sprint syntax: do
7346 -- N_Compound_Statement
7353 -- This node is used to hold the various parts of an entry, subprogram
7354 -- [body] or package [body] contract, in particular:
7355 -- Abstract states declared by a package declaration
7356 -- Contract cases that apply to a subprogram
7357 -- Dependency relations of inputs and output of a subprogram
7358 -- Global annotations classifying data as input or output
7359 -- Initialization sequences for a package declaration
7360 -- Pre- and postconditions that apply to a subprogram
7362 -- The node appears in an entry and [generic] subprogram [body] entity.
7364 -- Sprint syntax: <none> as the node should not appear in the tree, but
7365 -- only attached to an entry or [generic] subprogram
7369 -- Sloc points to the subprogram's name
7370 -- Pre_Post_Conditions (Node1) (set to Empty if none)
7371 -- Contract_Test_Cases (Node2) (set to Empty if none)
7372 -- Classifications (Node3) (set to Empty if none)
7374 -- Pre_Post_Conditions contains a collection of pragmas that correspond
7375 -- to pre- and postconditions associated with an entry or a subprogram
7376 -- [body or stub]. The pragmas can either come from source or be the
7377 -- byproduct of aspect expansion. Currently the following pragmas appear
7384 -- The ordering in the list is in LIFO fashion.
7386 -- Note that there might be multiple preconditions or postconditions
7387 -- in this list, either because they come from separate pragmas in the
7388 -- source, or because a Pre (resp. Post) aspect specification has been
7389 -- broken into AND THEN sections. See Split_PPC for details.
7391 -- Contract_Test_Cases contains a collection of pragmas that correspond
7392 -- to aspects/pragmas Contract_Cases and Test_Case. The ordering in the
7393 -- list is in LIFO fashion.
7395 -- Classifications contains pragmas that either declare, categorize or
7396 -- establish dependencies between subprogram or package inputs and
7397 -- outputs. Currently the following pragmas appear in this list:
7405 -- Initial_Condition
7411 -- The ordering is in LIFO fashion.
7417 -- The N_Expanded_Name node is used to represent a selected component
7418 -- name that has been resolved to an expanded name. The semantic phase
7419 -- replaces N_Selected_Component nodes that represent names by the use
7420 -- of this node, leaving the N_Selected_Component node used only when
7421 -- the prefix is a record or protected type.
7423 -- The fields of the N_Expanded_Name node are layed out identically
7424 -- to those of the N_Selected_Component node, allowing conversion of
7425 -- an expanded name node to a selected component node to be done
7426 -- easily, see Sinfo.CN.Change_Selected_Component_To_Expanded_Name.
7428 -- There is no special sprint syntax for an expanded name
7431 -- Sloc points to the period
7432 -- Chars (Name1) copy of Chars field of selector name
7434 -- Selector_Name (Node2)
7435 -- Entity (Node4-Sem)
7436 -- Associated_Node (Node4-Sem)
7437 -- Has_Private_View (Flag11-Sem) set in generic units.
7438 -- Redundant_Use (Flag13-Sem)
7439 -- Atomic_Sync_Required (Flag14-Sem)
7440 -- plus fields for expression
7442 -----------------------------
7443 -- Expression With Actions --
7444 -----------------------------
7446 -- This node is created by the analyzer/expander to handle some
7447 -- expansion cases, notably short circuit forms where there are
7448 -- actions associated with the right-hand side operand.
7450 -- The N_Expression_With_Actions node represents an expression with
7451 -- an associated set of actions (which are executable statements and
7452 -- declarations, as might occur in a handled statement sequence).
7454 -- The required semantics is that the set of actions is executed in
7455 -- the order in which it appears just before the expression is
7456 -- evaluated (and these actions must only be executed if the value
7457 -- of the expression is evaluated). The node is considered to be
7458 -- a subexpression, whose value is the value of the Expression after
7459 -- executing all the actions.
7461 -- If the actions contain declarations, then these declarations may
7462 -- be referenced within the expression. However note that there is
7463 -- no proper scope associated with the expression-with-action, so the
7464 -- back-end will elaborate them in the context of the enclosing scope.
7466 -- Sprint syntax: do
7471 -- in expression end
7473 -- N_Expression_With_Actions
7475 -- Expression (Node3)
7476 -- plus fields for expression
7478 -- Note: In the final generated tree presented to the code generator,
7479 -- the actions list is always non-null, since there is no point in this
7480 -- node if the actions are Empty. During semantic analysis there are
7481 -- cases where it is convenient to temporarily generate an empty actions
7482 -- list. This arises in cases where we create such an empty actions
7483 -- list, and it may or may not end up being a place where additional
7484 -- actions are inserted. The expander removes such empty cases after
7485 -- the expression of the node is fully analyzed and expanded, at which
7486 -- point it is safe to remove it, since no more actions can be inserted.
7488 -- Note: In Modify_Tree_For_C, we never generate any declarations in
7489 -- the action list, which can contain only non-declarative statements.
7491 --------------------
7492 -- Free Statement --
7493 --------------------
7495 -- The N_Free_Statement node is generated as a result of a call to an
7496 -- instantiation of Unchecked_Deallocation. The instantiation of this
7497 -- generic is handled specially and generates this node directly.
7499 -- Sprint syntax: free expression
7502 -- Sloc is copied from the unchecked deallocation call
7503 -- Expression (Node3) argument to unchecked deallocation call
7504 -- Storage_Pool (Node1-Sem)
7505 -- Procedure_To_Call (Node2-Sem)
7506 -- Actual_Designated_Subtype (Node4-Sem)
7508 -- Note: in the case where a debug source file is generated, the Sloc
7509 -- for this node points to the FREE keyword in the Sprint file output.
7515 -- This node marks the point in a declarative part at which an entity
7516 -- declared therein becomes frozen. The expander places initialization
7517 -- procedures for types at those points. Gigi uses the freezing point
7518 -- to elaborate entities that may depend on previous private types.
7520 -- See the section in Einfo "Delayed Freezing and Elaboration" for
7521 -- a full description of the use of this node.
7523 -- The Entity field points back to the entity for the type (whose
7524 -- Freeze_Node field points back to this freeze node).
7526 -- The Actions field contains a list of declarations and statements
7527 -- generated by the expander which are associated with the freeze
7528 -- node, and are elaborated as though the freeze node were replaced
7529 -- by this sequence of actions.
7531 -- Note: the Sloc field in the freeze node references a construct
7532 -- associated with the freezing point. This is used for posting
7533 -- messages in some error/warning situations, e.g. the case where
7534 -- a primitive operation of a tagged type is declared too late.
7536 -- Sprint syntax: freeze entity-name [
7541 -- Sloc points near freeze point (see above special note)
7542 -- Entity (Node4-Sem)
7543 -- Access_Types_To_Process (Elist2-Sem) (set to No_Elist if none)
7544 -- TSS_Elist (Elist3-Sem) (set to No_Elist if no associated TSS's)
7545 -- Actions (List1) (set to No_List if no freeze actions)
7546 -- First_Subtype_Link (Node5-Sem) (set to Empty if no link)
7548 -- The Actions field holds actions associated with the freeze. These
7549 -- actions are elaborated at the point where the type is frozen.
7551 -- Note: in the case where a debug source file is generated, the Sloc
7552 -- for this node points to the FREEZE keyword in the Sprint file output.
7554 ---------------------------
7555 -- Freeze Generic Entity --
7556 ---------------------------
7558 -- The freeze point of an entity indicates the point at which the
7559 -- information needed to generate code for the entity is complete.
7560 -- The freeze node for an entity triggers expander activities, such as
7561 -- build initialization procedures, and backend activities, such as
7562 -- completing the elaboration of packages.
7564 -- For entities declared within a generic unit, for which no code is
7565 -- generated, the freeze point is not equally meaningful. However, in
7566 -- Ada 2012 several semantic checks on declarations must be delayed to
7567 -- the freeze point, and we need to include such a mark in the tree to
7568 -- trigger these checks. The Freeze_Generic_Entity node plays no other
7569 -- role, and is ignored by the expander and the back-end.
7571 -- Sprint syntax: freeze_generic entity-name
7573 -- N_Freeze_Generic_Entity
7574 -- Sloc points near freeze point
7575 -- Entity (Node4-Sem)
7577 --------------------------------
7578 -- Implicit Label Declaration --
7579 --------------------------------
7581 -- An implicit label declaration is created for every occurrence of a
7582 -- label on a statement or a label on a block or loop. It is chained
7583 -- in the declarations of the innermost enclosing block as specified
7584 -- in RM section 5.1 (3).
7586 -- The Defining_Identifier is the actual identifier for the statement
7587 -- identifier. Note that the occurrence of the label is a reference, NOT
7588 -- the defining occurrence. The defining occurrence occurs at the head
7589 -- of the innermost enclosing block, and is represented by this node.
7591 -- Note: from the grammar, this might better be called an implicit
7592 -- statement identifier declaration, but the term we choose seems
7593 -- friendlier, since at least informally statement identifiers are
7594 -- called labels in both cases (i.e. when used in labels, and when
7595 -- used as the identifiers of blocks and loops).
7597 -- Note: although this is logically a semantic node, since it does not
7598 -- correspond directly to a source syntax construction, these nodes are
7599 -- actually created by the parser in a post pass done just after parsing
7600 -- is complete, before semantic analysis is started (see Par.Labl).
7602 -- Sprint syntax: labelname : label;
7604 -- N_Implicit_Label_Declaration
7605 -- Sloc points to the << token for a statement identifier, or to the
7606 -- LOOP, DECLARE, or BEGIN token for a loop or block identifier
7607 -- Defining_Identifier (Node1)
7608 -- Label_Construct (Node2-Sem)
7610 -- Note: in the case where a debug source file is generated, the Sloc
7611 -- for this node points to the label name in the generated declaration.
7613 ---------------------
7614 -- Itype Reference --
7615 ---------------------
7617 -- This node is used to create a reference to an Itype. The only purpose
7618 -- is to make sure the Itype is defined if this is the first reference.
7620 -- A typical use of this node is when an Itype is to be referenced in
7621 -- two branches of an IF statement. In this case it is important that
7622 -- the first use of the Itype not be inside the conditional, since then
7623 -- it might not be defined if the other branch of the IF is taken, in
7624 -- the case where the definition generates elaboration code.
7626 -- The Itype field points to the referenced Itype
7628 -- Sprint syntax: reference itype-name
7630 -- N_Itype_Reference
7631 -- Sloc points to the node generating the reference
7632 -- Itype (Node1-Sem)
7634 -- Note: in the case where a debug source file is generated, the Sloc
7635 -- for this node points to the REFERENCE keyword in the file output.
7637 ---------------------
7638 -- Raise xxx Error --
7639 ---------------------
7641 -- One of these nodes is created during semantic analysis to replace
7642 -- a node for an expression that is determined to definitely raise
7643 -- the corresponding exception.
7645 -- The N_Raise_xxx_Error node may also stand alone in place
7646 -- of a declaration or statement, in which case it simply causes
7647 -- the exception to be raised (i.e. it is equivalent to a raise
7648 -- statement that raises the corresponding exception). This use
7649 -- is distinguished by the fact that the Etype in this case is
7650 -- Standard_Void_Type; in the subexpression case, the Etype is the
7651 -- same as the type of the subexpression which it replaces.
7653 -- If Condition is empty, then the raise is unconditional. If the
7654 -- Condition field is non-empty, it is a boolean expression which
7655 -- is first evaluated, and the exception is raised only if the
7656 -- value of the expression is True. In the unconditional case, the
7657 -- creation of this node is usually accompanied by a warning message
7658 -- error. The creation of this node will usually be accompanied by a
7659 -- message (unless it appears within the right operand of a short
7660 -- circuit form whose left argument is static and decisively
7661 -- eliminates elaboration of the raise operation. The condition field
7662 -- can ONLY be present when the node is used as a statement form, it
7663 -- may NOT be present in the case where the node appears within an
7666 -- The exception is generated with a message that contains the
7667 -- file name and line number, and then appended text. The Reason
7668 -- code shows the text to be added. The Reason code is an element
7669 -- of the type Types.RT_Exception_Code, and indicates both the
7670 -- message to be added, and the exception to be raised (which must
7671 -- match the node type). The value is stored by storing a Uint which
7672 -- is the Pos value of the enumeration element in this type.
7674 -- Gigi restriction: This expander ensures that the type of the
7675 -- Condition field is always Standard.Boolean, even if the type
7676 -- in the source is some non-standard boolean type.
7678 -- Sprint syntax: [xxx_error "msg"]
7679 -- or: [xxx_error when condition "msg"]
7681 -- N_Raise_Constraint_Error
7682 -- Sloc references related construct
7683 -- Condition (Node1) (set to Empty if no condition)
7685 -- plus fields for expression
7687 -- N_Raise_Program_Error
7688 -- Sloc references related construct
7689 -- Condition (Node1) (set to Empty if no condition)
7691 -- plus fields for expression
7693 -- N_Raise_Storage_Error
7694 -- Sloc references related construct
7695 -- Condition (Node1) (set to Empty if no condition)
7697 -- plus fields for expression
7699 -- Note: Sloc is copied from the expression generating the exception.
7700 -- In the case where a debug source file is generated, the Sloc for
7701 -- this node points to the left bracket in the Sprint file output.
7703 -- Note: the back end may be required to translate these nodes into
7704 -- appropriate goto statements. See description of N_Push/Pop_xxx_Label.
7706 ---------------------------------------------
7707 -- Optimization of Exception Raise to Goto --
7708 ---------------------------------------------
7710 -- In some cases, the front end will determine that any exception raised
7711 -- by the back end for a certain exception should be transformed into a
7714 -- There are three kinds of exceptions raised by the back end (note that
7715 -- for this purpose we consider gigi to be part of the back end in the
7718 -- 1. Exceptions resulting from N_Raise_xxx_Error nodes
7719 -- 2. Exceptions from checks triggered by Do_xxx_Check flags
7720 -- 3. Other cases not specifically marked by the front end
7722 -- Normally all such exceptions are translated into calls to the proper
7723 -- Rcheck_xx procedure, where xx encodes both the exception to be raised
7724 -- and the exception message.
7726 -- The front end may determine that for a particular sequence of code,
7727 -- exceptions in any of these three categories for a particular builtin
7728 -- exception should result in a goto, rather than a call to Rcheck_xx.
7729 -- The exact sequence to be generated is:
7731 -- Local_Raise (exception'Identity);
7734 -- The front end marks such a sequence of code by bracketing it with
7735 -- push and pop nodes:
7737 -- N_Push_xxx_Label (referencing the label)
7739 -- (code where transformation is expected for exception xxx)
7743 -- The use of push/pop reflects the fact that such regions can properly
7744 -- nest, and one special case is a subregion in which no transformation
7745 -- is allowed. Such a region is marked by a N_Push_xxx_Label node whose
7746 -- Exception_Label field is Empty.
7748 -- N_Push_Constraint_Error_Label
7749 -- Sloc references first statement in region covered
7750 -- Exception_Label (Node5-Sem)
7752 -- N_Push_Program_Error_Label
7753 -- Sloc references first statement in region covered
7754 -- Exception_Label (Node5-Sem)
7756 -- N_Push_Storage_Error_Label
7757 -- Sloc references first statement in region covered
7758 -- Exception_Label (Node5-Sem)
7760 -- N_Pop_Constraint_Error_Label
7761 -- Sloc references last statement in region covered
7763 -- N_Pop_Program_Error_Label
7764 -- Sloc references last statement in region covered
7766 -- N_Pop_Storage_Error_Label
7767 -- Sloc references last statement in region covered
7773 -- For a number of purposes, we need to construct references to objects.
7774 -- These references are subsequently treated as normal access values.
7775 -- An example is the construction of the parameter block passed to a
7776 -- task entry. The N_Reference node is provided for this purpose. It is
7777 -- similar in effect to the use of the Unrestricted_Access attribute,
7778 -- and like Unrestricted_Access can be applied to objects which would
7779 -- not be valid prefixes for the Unchecked_Access attribute (e.g.
7780 -- objects which are not aliased, and slices). In addition it can be
7781 -- applied to composite type values as well as objects, including string
7782 -- values and aggregates.
7784 -- Note: we use the Prefix field for this expression so that the
7785 -- resulting node can be treated using common code with the attribute
7786 -- nodes for the 'Access and related attributes. Logically it would make
7787 -- more sense to call it an Expression field, but then we would have to
7788 -- special case the treatment of the N_Reference node.
7790 -- Note: evaluating a N_Reference node is guaranteed to yield a non-null
7791 -- value at run time. Therefore, it is valid to set Is_Known_Non_Null on
7792 -- a temporary initialized to a N_Reference node in order to eliminate
7793 -- superfluous access checks.
7795 -- Sprint syntax: prefix'reference
7798 -- Sloc is copied from the expression
7800 -- plus fields for expression
7802 -- Note: in the case where a debug source file is generated, the Sloc
7803 -- for this node points to the quote in the Sprint file output.
7809 -- SCIL nodes are special nodes added to the tree when the CodePeer
7810 -- mode is active. They help the CodePeer backend to locate nodes that
7811 -- require special processing. They are only generated if SCIL
7812 -- generation is enabled. A standard tree-walk will not encounter
7813 -- these nodes even if they are present; these nodes are only
7814 -- accessible via the function SCIL_LL.Get_SCIL_Node.
7816 -- N_SCIL_Dispatch_Table_Tag_Init
7817 -- Sloc references a node for a tag initialization
7818 -- SCIL_Entity (Node4-Sem)
7820 -- An N_SCIL_Dispatch_Table_Tag_Init node may be associated (via
7821 -- Get_SCIL_Node) with the N_Object_Declaration node corresponding to
7822 -- the declaration of the dispatch table for a tagged type.
7824 -- N_SCIL_Dispatching_Call
7825 -- Sloc references the node of a dispatching call
7826 -- SCIL_Target_Prim (Node2-Sem)
7827 -- SCIL_Entity (Node4-Sem)
7828 -- SCIL_Controlling_Tag (Node5-Sem)
7830 -- An N_Scil_Dispatching call node may be associated (via Get_SCIL_Node)
7831 -- with the N_Procedure_Call or N_Function_Call node (or a rewriting
7832 -- thereof) corresponding to a dispatching call.
7834 -- N_SCIL_Membership_Test
7835 -- Sloc references the node of a membership test
7836 -- SCIL_Tag_Value (Node5-Sem)
7837 -- SCIL_Entity (Node4-Sem)
7839 -- An N_Scil_Membership_Test node may be associated (via Get_SCIL_Node)
7840 -- with the N_In node (or a rewriting thereof) corresponding to a
7841 -- classwide membership test.
7843 --------------------------
7844 -- Unchecked Expression --
7845 --------------------------
7847 -- An unchecked expression is one that must be analyzed and resolved
7848 -- with all checks off, regardless of the current setting of scope
7851 -- Sprint syntax: `(expression)
7853 -- Note: this node is always removed from the tree (and replaced by
7854 -- its constituent expression) on completion of analysis, so it only
7855 -- appears in intermediate trees, and will never be seen by Gigi.
7857 -- N_Unchecked_Expression
7858 -- Sloc is a copy of the Sloc of the expression
7859 -- Expression (Node3)
7860 -- plus fields for expression
7862 -- Note: in the case where a debug source file is generated, the Sloc
7863 -- for this node points to the back quote in the Sprint file output.
7865 -------------------------------
7866 -- Unchecked Type Conversion --
7867 -------------------------------
7869 -- An unchecked type conversion node represents the semantic action
7870 -- corresponding to a call to an instantiation of Unchecked_Conversion.
7871 -- It is generated as a result of actual use of Unchecked_Conversion
7872 -- and also the expander generates unchecked type conversion nodes
7873 -- directly for expansion of complex semantic actions.
7875 -- Note: an unchecked type conversion is a variable as far as the
7876 -- semantics are concerned, which is convenient for the expander.
7877 -- This does not change what Ada source programs are legal, since
7878 -- clearly a function call to an instantiation of Unchecked_Conversion
7879 -- is not a variable in any case.
7881 -- Sprint syntax: subtype-mark!(expression)
7883 -- N_Unchecked_Type_Conversion
7884 -- Sloc points to related node in source
7885 -- Subtype_Mark (Node4)
7886 -- Expression (Node3)
7887 -- Kill_Range_Check (Flag11-Sem)
7888 -- No_Truncation (Flag17-Sem)
7889 -- plus fields for expression
7891 -- Note: in the case where a debug source file is generated, the Sloc
7892 -- for this node points to the exclamation in the Sprint file output.
7894 -----------------------------------
7895 -- Validate_Unchecked_Conversion --
7896 -----------------------------------
7898 -- The front end does most of the validation of unchecked conversion,
7899 -- including checking sizes (this is done after the back end is called
7900 -- to take advantage of back-annotation of calculated sizes).
7902 -- The front end also deals with specific cases that are not allowed
7903 -- e.g. involving unconstrained array types.
7905 -- For the case of the standard gigi backend, this means that all
7906 -- checks are done in the front end.
7908 -- However, in the case of specialized back-ends, notably the JVM
7909 -- backend for JGNAT, additional requirements and restrictions apply
7910 -- to unchecked conversion, and these are most conveniently performed
7911 -- in the specialized back-end.
7913 -- To accommodate this requirement, for such back ends, the following
7914 -- special node is generated recording an unchecked conversion that
7915 -- needs to be validated. The back end should post an appropriate
7916 -- error message if the unchecked conversion is invalid or warrants
7917 -- a special warning message.
7919 -- Source_Type and Target_Type point to the entities for the two
7920 -- types involved in the unchecked conversion instantiation that
7921 -- is to be validated.
7923 -- Sprint syntax: validate Unchecked_Conversion (source, target);
7925 -- N_Validate_Unchecked_Conversion
7926 -- Sloc points to instantiation (location for warning message)
7927 -- Source_Type (Node1-Sem)
7928 -- Target_Type (Node2-Sem)
7930 -- Note: in the case where a debug source file is generated, the Sloc
7931 -- for this node points to the VALIDATE keyword in the file output.
7937 -- Used as the contents of the Nkind field of the dummy Empty node
7938 -- and in some other situations to indicate an uninitialized value.
7941 -- Chars (Name1) is set to No_Name
7947 -- Used as the contents of the Nkind field of the dummy Error node.
7948 -- Has an Etype field, which gets set to Any_Type later on, to help
7949 -- error recovery (Error_Posted is also set in the Error node).
7952 -- Chars (Name1) is set to Error_Name
7953 -- Etype (Node5-Sem)
7955 --------------------------
7956 -- Node Type Definition --
7957 --------------------------
7959 -- The following is the definition of the Node_Kind type. As previously
7960 -- discussed, this is separated off to allow rearrangement of the order to
7961 -- facilitate definition of subtype ranges. The comments show the subtype
7962 -- classes which apply to each set of node kinds. The first entry in the
7963 -- comment characterizes the following list of nodes.
7968 -- N_Representation_Clause
7972 N_Enumeration_Representation_Clause,
7974 N_Record_Representation_Clause,
7976 -- N_Representation_Clause, N_Has_Chars
7978 N_Attribute_Definition_Clause,
7983 N_Pragma_Argument_Association,
7985 -- N_Has_Etype, N_Has_Chars
7987 -- Note: of course N_Error does not really have Etype or Chars fields,
7988 -- and any attempt to access these fields in N_Error will cause an
7989 -- error, but historically this always has been positioned so that an
7990 -- "in N_Has_Chars" or "in N_Has_Etype" test yields true for N_Error.
7991 -- Most likely this makes coding easier somewhere but still seems
7992 -- undesirable. To be investigated some time ???
7996 -- N_Entity, N_Has_Etype, N_Has_Chars
7998 N_Defining_Character_Literal,
7999 N_Defining_Identifier,
8000 N_Defining_Operator_Symbol,
8002 -- N_Subexpr, N_Has_Etype, N_Has_Chars, N_Has_Entity
8006 -- N_Direct_Name, N_Subexpr, N_Has_Etype,
8007 -- N_Has_Chars, N_Has_Entity
8012 -- N_Direct_Name, N_Subexpr, N_Has_Etype,
8013 -- N_Has_Chars, N_Has_Entity
8015 N_Character_Literal,
8017 -- N_Binary_Op, N_Op, N_Subexpr,
8018 -- N_Has_Etype, N_Has_Chars, N_Has_Entity
8025 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Treat_Fixed_As_Integer
8026 -- N_Has_Etype, N_Has_Chars, N_Has_Entity, N_Multiplying_Operator
8033 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Etype
8034 -- N_Has_Entity, N_Has_Chars, N_Op_Boolean
8038 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Etype
8039 -- N_Has_Entity, N_Has_Chars, N_Op_Boolean, N_Op_Compare
8048 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Etype
8049 -- N_Has_Entity, N_Has_Chars, N_Op_Boolean
8054 -- N_Binary_Op, N_Op, N_Subexpr, N_Has_Etype,
8055 -- N_Op_Shift, N_Has_Chars, N_Has_Entity
8061 N_Op_Shift_Right_Arithmetic,
8063 -- N_Unary_Op, N_Op, N_Subexpr, N_Has_Etype,
8064 -- N_Has_Chars, N_Has_Entity
8071 -- N_Subexpr, N_Has_Etype, N_Has_Entity
8073 N_Attribute_Reference,
8075 -- N_Subexpr, N_Has_Etype, N_Membership_Test
8080 -- N_Subexpr, N_Has_Etype, N_Short_Circuit
8085 -- N_Subexpr, N_Has_Etype, N_Subprogram_Call
8088 N_Procedure_Call_Statement,
8090 -- N_Subexpr, N_Has_Etype, N_Raise_xxx_Error
8092 N_Raise_Constraint_Error,
8093 N_Raise_Program_Error,
8094 N_Raise_Storage_Error,
8096 -- N_Subexpr, N_Has_Etype, N_Numeric_Or_String_Literal
8102 -- N_Subexpr, N_Has_Etype
8104 N_Explicit_Dereference,
8105 N_Expression_With_Actions,
8107 N_Indexed_Component,
8109 N_Qualified_Expression,
8110 N_Quantified_Expression,
8114 N_Extension_Aggregate,
8118 N_Selected_Component,
8121 N_Unchecked_Expression,
8122 N_Unchecked_Type_Conversion,
8126 N_Subtype_Indication,
8130 N_Component_Declaration,
8131 N_Entry_Declaration,
8132 N_Expression_Function,
8133 N_Formal_Object_Declaration,
8134 N_Formal_Type_Declaration,
8135 N_Full_Type_Declaration,
8136 N_Incomplete_Type_Declaration,
8137 N_Iterator_Specification,
8138 N_Loop_Parameter_Specification,
8139 N_Object_Declaration,
8140 N_Protected_Type_Declaration,
8141 N_Private_Extension_Declaration,
8142 N_Private_Type_Declaration,
8143 N_Subtype_Declaration,
8145 -- N_Subprogram_Specification, N_Declaration
8147 N_Function_Specification,
8148 N_Procedure_Specification,
8150 -- N_Access_To_Subprogram_Definition
8152 N_Access_Function_Definition,
8153 N_Access_Procedure_Definition,
8155 -- N_Later_Decl_Item
8157 N_Task_Type_Declaration,
8159 -- N_Body_Stub, N_Later_Decl_Item
8161 N_Package_Body_Stub,
8162 N_Protected_Body_Stub,
8163 N_Subprogram_Body_Stub,
8166 -- N_Generic_Instantiation, N_Later_Decl_Item
8167 -- N_Subprogram_Instantiation
8169 N_Function_Instantiation,
8170 N_Procedure_Instantiation,
8172 -- N_Generic_Instantiation, N_Later_Decl_Item
8174 N_Package_Instantiation,
8176 -- N_Unit_Body, N_Later_Decl_Item, N_Proper_Body
8181 -- N_Later_Decl_Item, N_Proper_Body
8186 -- N_Later_Decl_Item
8188 N_Implicit_Label_Declaration,
8189 N_Package_Declaration,
8190 N_Single_Task_Declaration,
8191 N_Subprogram_Declaration,
8192 N_Use_Package_Clause,
8194 -- N_Generic_Declaration, N_Later_Decl_Item
8196 N_Generic_Package_Declaration,
8197 N_Generic_Subprogram_Declaration,
8199 -- N_Array_Type_Definition
8201 N_Constrained_Array_Definition,
8202 N_Unconstrained_Array_Definition,
8204 -- N_Renaming_Declaration
8206 N_Exception_Renaming_Declaration,
8207 N_Object_Renaming_Declaration,
8208 N_Package_Renaming_Declaration,
8209 N_Subprogram_Renaming_Declaration,
8211 -- N_Generic_Renaming_Declaration, N_Renaming_Declaration
8213 N_Generic_Function_Renaming_Declaration,
8214 N_Generic_Package_Renaming_Declaration,
8215 N_Generic_Procedure_Renaming_Declaration,
8217 -- N_Statement_Other_Than_Procedure_Call
8221 N_Assignment_Statement,
8222 N_Asynchronous_Select,
8226 N_Compound_Statement,
8227 N_Conditional_Entry_Call,
8229 -- N_Statement_Other_Than_Procedure_Call, N_Delay_Statement
8231 N_Delay_Relative_Statement,
8232 N_Delay_Until_Statement,
8234 -- N_Statement_Other_Than_Procedure_Call
8236 N_Entry_Call_Statement,
8242 N_Requeue_Statement,
8243 N_Simple_Return_Statement,
8244 N_Extended_Return_Statement,
8248 -- N_Statement_Other_Than_Procedure_Call, N_Has_Condition
8255 N_Accept_Alternative,
8256 N_Delay_Alternative,
8258 N_Entry_Body_Formal_Part,
8260 N_Terminate_Alternative,
8262 -- N_Formal_Subprogram_Declaration
8264 N_Formal_Abstract_Subprogram_Declaration,
8265 N_Formal_Concrete_Subprogram_Declaration,
8267 -- N_Push_xxx_Label, N_Push_Pop_xxx_Label
8269 N_Push_Constraint_Error_Label,
8270 N_Push_Program_Error_Label,
8271 N_Push_Storage_Error_Label,
8273 -- N_Pop_xxx_Label, N_Push_Pop_xxx_Label
8275 N_Pop_Constraint_Error_Label,
8276 N_Pop_Program_Error_Label,
8277 N_Pop_Storage_Error_Label,
8281 N_SCIL_Dispatch_Table_Tag_Init,
8282 N_SCIL_Dispatching_Call,
8283 N_SCIL_Membership_Test,
8285 -- Other nodes (not part of any subtype class)
8288 N_Abstract_Subprogram_Declaration,
8289 N_Access_Definition,
8290 N_Access_To_Object_Definition,
8291 N_Aspect_Specification,
8292 N_Case_Expression_Alternative,
8293 N_Case_Statement_Alternative,
8295 N_Compilation_Unit_Aux,
8296 N_Component_Association,
8297 N_Component_Definition,
8300 N_Derived_Type_Definition,
8301 N_Decimal_Fixed_Point_Definition,
8302 N_Defining_Program_Unit_Name,
8305 N_Digits_Constraint,
8306 N_Discriminant_Association,
8307 N_Discriminant_Specification,
8308 N_Enumeration_Type_Definition,
8310 N_Entry_Call_Alternative,
8311 N_Entry_Index_Specification,
8312 N_Exception_Declaration,
8313 N_Exception_Handler,
8314 N_Floating_Point_Definition,
8315 N_Formal_Decimal_Fixed_Point_Definition,
8316 N_Formal_Derived_Type_Definition,
8317 N_Formal_Discrete_Type_Definition,
8318 N_Formal_Floating_Point_Definition,
8319 N_Formal_Modular_Type_Definition,
8320 N_Formal_Ordinary_Fixed_Point_Definition,
8321 N_Formal_Package_Declaration,
8322 N_Formal_Private_Type_Definition,
8323 N_Formal_Incomplete_Type_Definition,
8324 N_Formal_Signed_Integer_Type_Definition,
8326 N_Freeze_Generic_Entity,
8327 N_Generic_Association,
8328 N_Handled_Sequence_Of_Statements,
8329 N_Index_Or_Discriminant_Constraint,
8332 N_Modular_Type_Definition,
8333 N_Number_Declaration,
8334 N_Ordinary_Fixed_Point_Definition,
8336 N_Package_Specification,
8337 N_Parameter_Association,
8338 N_Parameter_Specification,
8340 N_Protected_Definition,
8342 N_Real_Range_Specification,
8343 N_Record_Definition,
8344 N_Signed_Integer_Type_Definition,
8345 N_Single_Protected_Declaration,
8348 N_Triggering_Alternative,
8350 N_Validate_Unchecked_Conversion,
8356 for Node_Kind'Size use 8;
8357 -- The data structures in Atree assume this
8359 ----------------------------
8360 -- Node Class Definitions --
8361 ----------------------------
8363 subtype N_Access_To_Subprogram_Definition is Node_Kind range
8364 N_Access_Function_Definition ..
8365 N_Access_Procedure_Definition;
8367 subtype N_Array_Type_Definition is Node_Kind range
8368 N_Constrained_Array_Definition ..
8369 N_Unconstrained_Array_Definition;
8371 subtype N_Binary_Op is Node_Kind range
8373 N_Op_Shift_Right_Arithmetic;
8375 subtype N_Body_Stub is Node_Kind range
8376 N_Package_Body_Stub ..
8379 subtype N_Declaration is Node_Kind range
8380 N_Component_Declaration ..
8381 N_Procedure_Specification;
8382 -- Note: this includes all constructs normally thought of as declarations
8383 -- except those which are separately grouped as later declarations.
8385 subtype N_Delay_Statement is Node_Kind range
8386 N_Delay_Relative_Statement ..
8387 N_Delay_Until_Statement;
8389 subtype N_Direct_Name is Node_Kind range
8391 N_Character_Literal;
8393 subtype N_Entity is Node_Kind range
8394 N_Defining_Character_Literal ..
8395 N_Defining_Operator_Symbol;
8397 subtype N_Formal_Subprogram_Declaration is Node_Kind range
8398 N_Formal_Abstract_Subprogram_Declaration ..
8399 N_Formal_Concrete_Subprogram_Declaration;
8401 subtype N_Generic_Declaration is Node_Kind range
8402 N_Generic_Package_Declaration ..
8403 N_Generic_Subprogram_Declaration;
8405 subtype N_Generic_Instantiation is Node_Kind range
8406 N_Function_Instantiation ..
8407 N_Package_Instantiation;
8409 subtype N_Generic_Renaming_Declaration is Node_Kind range
8410 N_Generic_Function_Renaming_Declaration ..
8411 N_Generic_Procedure_Renaming_Declaration;
8413 subtype N_Has_Chars is Node_Kind range
8414 N_Attribute_Definition_Clause ..
8417 subtype N_Has_Entity is Node_Kind range
8419 N_Attribute_Reference;
8420 -- Nodes that have Entity fields
8421 -- Warning: DOES NOT INCLUDE N_Freeze_Entity, N_Freeze_Generic_Entity,
8422 -- N_Aspect_Specification, or N_Attribute_Definition_Clause.
8424 subtype N_Has_Etype is Node_Kind range
8426 N_Subtype_Indication;
8428 subtype N_Has_Treat_Fixed_As_Integer is Node_Kind range
8432 subtype N_Multiplying_Operator is Node_Kind range
8436 subtype N_Later_Decl_Item is Node_Kind range
8437 N_Task_Type_Declaration ..
8438 N_Generic_Subprogram_Declaration;
8439 -- Note: this is Ada 83 relevant only (see Ada 83 RM 3.9 (2)) and includes
8440 -- only those items which can appear as later declarative items. This also
8441 -- includes N_Implicit_Label_Declaration which is not specifically in the
8442 -- grammar but may appear as a valid later declarative items. It does NOT
8443 -- include N_Pragma which can also appear among later declarative items.
8444 -- It does however include N_Protected_Body, which is a bit peculiar, but
8445 -- harmless since this cannot appear in Ada 83 mode anyway.
8447 subtype N_Membership_Test is Node_Kind range
8451 subtype N_Numeric_Or_String_Literal is Node_Kind range
8452 N_Integer_Literal ..
8455 subtype N_Op is Node_Kind range
8459 subtype N_Op_Boolean is Node_Kind range
8462 -- Binary operators which take operands of a boolean type, and yield
8463 -- a result of a boolean type.
8465 subtype N_Op_Compare is Node_Kind range
8469 subtype N_Op_Shift is Node_Kind range
8471 N_Op_Shift_Right_Arithmetic;
8473 subtype N_Proper_Body is Node_Kind range
8477 subtype N_Push_xxx_Label is Node_Kind range
8478 N_Push_Constraint_Error_Label ..
8479 N_Push_Storage_Error_Label;
8481 subtype N_Pop_xxx_Label is Node_Kind range
8482 N_Pop_Constraint_Error_Label ..
8483 N_Pop_Storage_Error_Label;
8485 subtype N_Push_Pop_xxx_Label is Node_Kind range
8486 N_Push_Constraint_Error_Label ..
8487 N_Pop_Storage_Error_Label;
8489 subtype N_Raise_xxx_Error is Node_Kind range
8490 N_Raise_Constraint_Error ..
8491 N_Raise_Storage_Error;
8493 subtype N_Renaming_Declaration is Node_Kind range
8494 N_Exception_Renaming_Declaration ..
8495 N_Generic_Procedure_Renaming_Declaration;
8497 subtype N_Representation_Clause is Node_Kind range
8499 N_Attribute_Definition_Clause;
8501 subtype N_Short_Circuit is Node_Kind range
8505 subtype N_SCIL_Node is Node_Kind range
8506 N_SCIL_Dispatch_Table_Tag_Init ..
8507 N_SCIL_Membership_Test;
8509 subtype N_Statement_Other_Than_Procedure_Call is Node_Kind range
8510 N_Abort_Statement ..
8512 -- Note that this includes all statement types except for the cases of the
8513 -- N_Procedure_Call_Statement which is considered to be a subexpression
8514 -- (since overloading is possible, so it needs to go through the normal
8515 -- overloading resolution for expressions).
8517 subtype N_Subprogram_Call is Node_Kind range
8519 N_Procedure_Call_Statement;
8521 subtype N_Subprogram_Instantiation is Node_Kind range
8522 N_Function_Instantiation ..
8523 N_Procedure_Instantiation;
8525 subtype N_Has_Condition is Node_Kind range
8527 N_Terminate_Alternative;
8528 -- Nodes with condition fields (does not include N_Raise_xxx_Error)
8530 subtype N_Subexpr is Node_Kind range
8532 N_Unchecked_Type_Conversion;
8533 -- Nodes with expression fields
8535 subtype N_Subprogram_Specification is Node_Kind range
8536 N_Function_Specification ..
8537 N_Procedure_Specification;
8539 subtype N_Unary_Op is Node_Kind range
8543 subtype N_Unit_Body is Node_Kind range
8547 ---------------------------
8548 -- Node Access Functions --
8549 ---------------------------
8551 -- The following functions return the contents of the indicated field of
8552 -- the node referenced by the argument, which is a Node_Id. They provide
8553 -- logical access to fields in the node which could be accessed using the
8554 -- Atree.Unchecked_Access package, but the idea is always to use these
8555 -- higher level routines which preserve strong typing. In debug mode,
8556 -- these routines check that they are being applied to an appropriate
8557 -- node, as well as checking that the node is in range.
8559 function ABE_Is_Certain
8560 (N : Node_Id) return Boolean; -- Flag18
8562 function Abort_Present
8563 (N : Node_Id) return Boolean; -- Flag15
8565 function Abortable_Part
8566 (N : Node_Id) return Node_Id; -- Node2
8568 function Abstract_Present
8569 (N : Node_Id) return Boolean; -- Flag4
8571 function Accept_Handler_Records
8572 (N : Node_Id) return List_Id; -- List5
8574 function Accept_Statement
8575 (N : Node_Id) return Node_Id; -- Node2
8577 function Access_Definition
8578 (N : Node_Id) return Node_Id; -- Node3
8580 function Access_To_Subprogram_Definition
8581 (N : Node_Id) return Node_Id; -- Node3
8583 function Access_Types_To_Process
8584 (N : Node_Id) return Elist_Id; -- Elist2
8587 (N : Node_Id) return List_Id; -- List1
8589 function Activation_Chain_Entity
8590 (N : Node_Id) return Node_Id; -- Node3
8592 function Acts_As_Spec
8593 (N : Node_Id) return Boolean; -- Flag4
8595 function Actual_Designated_Subtype
8596 (N : Node_Id) return Node_Id; -- Node4
8598 function Address_Warning_Posted
8599 (N : Node_Id) return Boolean; -- Flag18
8601 function Aggregate_Bounds
8602 (N : Node_Id) return Node_Id; -- Node3
8604 function Aliased_Present
8605 (N : Node_Id) return Boolean; -- Flag4
8608 (N : Node_Id) return Boolean; -- Flag11
8610 function All_Present
8611 (N : Node_Id) return Boolean; -- Flag15
8613 function Alternatives
8614 (N : Node_Id) return List_Id; -- List4
8616 function Ancestor_Part
8617 (N : Node_Id) return Node_Id; -- Node3
8619 function Atomic_Sync_Required
8620 (N : Node_Id) return Boolean; -- Flag14
8622 function Array_Aggregate
8623 (N : Node_Id) return Node_Id; -- Node3
8625 function Aspect_Rep_Item
8626 (N : Node_Id) return Node_Id; -- Node2
8628 function Assignment_OK
8629 (N : Node_Id) return Boolean; -- Flag15
8631 function Associated_Node
8632 (N : Node_Id) return Node_Id; -- Node4
8634 function At_End_Proc
8635 (N : Node_Id) return Node_Id; -- Node1
8637 function Attribute_Name
8638 (N : Node_Id) return Name_Id; -- Name2
8640 function Aux_Decls_Node
8641 (N : Node_Id) return Node_Id; -- Node5
8643 function Backwards_OK
8644 (N : Node_Id) return Boolean; -- Flag6
8646 function Bad_Is_Detected
8647 (N : Node_Id) return Boolean; -- Flag15
8650 (N : Node_Id) return Boolean; -- Flag5
8652 function Body_Required
8653 (N : Node_Id) return Boolean; -- Flag13
8655 function Body_To_Inline
8656 (N : Node_Id) return Node_Id; -- Node3
8658 function Box_Present
8659 (N : Node_Id) return Boolean; -- Flag15
8661 function Char_Literal_Value
8662 (N : Node_Id) return Uint; -- Uint2
8665 (N : Node_Id) return Name_Id; -- Name1
8667 function Check_Address_Alignment
8668 (N : Node_Id) return Boolean; -- Flag11
8670 function Choice_Parameter
8671 (N : Node_Id) return Node_Id; -- Node2
8674 (N : Node_Id) return List_Id; -- List1
8676 function Class_Present
8677 (N : Node_Id) return Boolean; -- Flag6
8679 function Classifications
8680 (N : Node_Id) return Node_Id; -- Node3
8682 function Comes_From_Extended_Return_Statement
8683 (N : Node_Id) return Boolean; -- Flag18
8685 function Compile_Time_Known_Aggregate
8686 (N : Node_Id) return Boolean; -- Flag18
8688 function Component_Associations
8689 (N : Node_Id) return List_Id; -- List2
8691 function Component_Clauses
8692 (N : Node_Id) return List_Id; -- List3
8694 function Component_Definition
8695 (N : Node_Id) return Node_Id; -- Node4
8697 function Component_Items
8698 (N : Node_Id) return List_Id; -- List3
8700 function Component_List
8701 (N : Node_Id) return Node_Id; -- Node1
8703 function Component_Name
8704 (N : Node_Id) return Node_Id; -- Node1
8706 function Componentwise_Assignment
8707 (N : Node_Id) return Boolean; -- Flag14
8710 (N : Node_Id) return Node_Id; -- Node1
8712 function Condition_Actions
8713 (N : Node_Id) return List_Id; -- List3
8715 function Config_Pragmas
8716 (N : Node_Id) return List_Id; -- List4
8718 function Constant_Present
8719 (N : Node_Id) return Boolean; -- Flag17
8722 (N : Node_Id) return Node_Id; -- Node3
8724 function Constraints
8725 (N : Node_Id) return List_Id; -- List1
8727 function Context_Installed
8728 (N : Node_Id) return Boolean; -- Flag13
8730 function Context_Pending
8731 (N : Node_Id) return Boolean; -- Flag16
8733 function Context_Items
8734 (N : Node_Id) return List_Id; -- List1
8736 function Contract_Test_Cases
8737 (N : Node_Id) return Node_Id; -- Node2
8739 function Controlling_Argument
8740 (N : Node_Id) return Node_Id; -- Node1
8742 function Conversion_OK
8743 (N : Node_Id) return Boolean; -- Flag14
8745 function Convert_To_Return_False
8746 (N : Node_Id) return Boolean; -- Flag13
8748 function Corresponding_Aspect
8749 (N : Node_Id) return Node_Id; -- Node3
8751 function Corresponding_Body
8752 (N : Node_Id) return Node_Id; -- Node5
8754 function Corresponding_Formal_Spec
8755 (N : Node_Id) return Node_Id; -- Node3
8757 function Corresponding_Generic_Association
8758 (N : Node_Id) return Node_Id; -- Node5
8760 function Corresponding_Integer_Value
8761 (N : Node_Id) return Uint; -- Uint4
8763 function Corresponding_Spec
8764 (N : Node_Id) return Node_Id; -- Node5
8766 function Corresponding_Spec_Of_Stub
8767 (N : Node_Id) return Node_Id; -- Node2
8769 function Corresponding_Stub
8770 (N : Node_Id) return Node_Id; -- Node3
8772 function Dcheck_Function
8773 (N : Node_Id) return Entity_Id; -- Node5
8775 function Declarations
8776 (N : Node_Id) return List_Id; -- List2
8778 function Default_Expression
8779 (N : Node_Id) return Node_Id; -- Node5
8781 function Default_Storage_Pool
8782 (N : Node_Id) return Node_Id; -- Node3
8784 function Default_Name
8785 (N : Node_Id) return Node_Id; -- Node2
8787 function Defining_Identifier
8788 (N : Node_Id) return Entity_Id; -- Node1
8790 function Defining_Unit_Name
8791 (N : Node_Id) return Node_Id; -- Node1
8793 function Delay_Alternative
8794 (N : Node_Id) return Node_Id; -- Node4
8796 function Delay_Statement
8797 (N : Node_Id) return Node_Id; -- Node2
8799 function Delta_Expression
8800 (N : Node_Id) return Node_Id; -- Node3
8802 function Digits_Expression
8803 (N : Node_Id) return Node_Id; -- Node2
8805 function Discr_Check_Funcs_Built
8806 (N : Node_Id) return Boolean; -- Flag11
8808 function Discrete_Choices
8809 (N : Node_Id) return List_Id; -- List4
8811 function Discrete_Range
8812 (N : Node_Id) return Node_Id; -- Node4
8814 function Discrete_Subtype_Definition
8815 (N : Node_Id) return Node_Id; -- Node4
8817 function Discrete_Subtype_Definitions
8818 (N : Node_Id) return List_Id; -- List2
8820 function Discriminant_Specifications
8821 (N : Node_Id) return List_Id; -- List4
8823 function Discriminant_Type
8824 (N : Node_Id) return Node_Id; -- Node5
8826 function Do_Accessibility_Check
8827 (N : Node_Id) return Boolean; -- Flag13
8829 function Do_Discriminant_Check
8830 (N : Node_Id) return Boolean; -- Flag1
8832 function Do_Division_Check
8833 (N : Node_Id) return Boolean; -- Flag13
8835 function Do_Length_Check
8836 (N : Node_Id) return Boolean; -- Flag4
8838 function Do_Overflow_Check
8839 (N : Node_Id) return Boolean; -- Flag17
8841 function Do_Range_Check
8842 (N : Node_Id) return Boolean; -- Flag9
8844 function Do_Storage_Check
8845 (N : Node_Id) return Boolean; -- Flag17
8847 function Do_Tag_Check
8848 (N : Node_Id) return Boolean; -- Flag13
8850 function Elaborate_All_Desirable
8851 (N : Node_Id) return Boolean; -- Flag9
8853 function Elaborate_All_Present
8854 (N : Node_Id) return Boolean; -- Flag14
8856 function Elaborate_Desirable
8857 (N : Node_Id) return Boolean; -- Flag11
8859 function Elaborate_Present
8860 (N : Node_Id) return Boolean; -- Flag4
8862 function Elaboration_Boolean
8863 (N : Node_Id) return Node_Id; -- Node2
8865 function Else_Actions
8866 (N : Node_Id) return List_Id; -- List3
8868 function Else_Statements
8869 (N : Node_Id) return List_Id; -- List4
8871 function Elsif_Parts
8872 (N : Node_Id) return List_Id; -- List3
8874 function Enclosing_Variant
8875 (N : Node_Id) return Node_Id; -- Node2
8878 (N : Node_Id) return Node_Id; -- Node4
8881 (N : Node_Id) return Uint; -- Uint5
8884 (N : Node_Id) return Node_Id; -- Node4
8886 function Entity_Or_Associated_Node
8887 (N : Node_Id) return Node_Id; -- Node4
8889 function Entry_Body_Formal_Part
8890 (N : Node_Id) return Node_Id; -- Node5
8892 function Entry_Call_Alternative
8893 (N : Node_Id) return Node_Id; -- Node1
8895 function Entry_Call_Statement
8896 (N : Node_Id) return Node_Id; -- Node1
8898 function Entry_Direct_Name
8899 (N : Node_Id) return Node_Id; -- Node1
8901 function Entry_Index
8902 (N : Node_Id) return Node_Id; -- Node5
8904 function Entry_Index_Specification
8905 (N : Node_Id) return Node_Id; -- Node4
8908 (N : Node_Id) return Node_Id; -- Node5
8910 function Exception_Choices
8911 (N : Node_Id) return List_Id; -- List4
8913 function Exception_Handlers
8914 (N : Node_Id) return List_Id; -- List5
8916 function Exception_Junk
8917 (N : Node_Id) return Boolean; -- Flag8
8919 function Exception_Label
8920 (N : Node_Id) return Node_Id; -- Node5
8922 function Explicit_Actual_Parameter
8923 (N : Node_Id) return Node_Id; -- Node3
8925 function Expansion_Delayed
8926 (N : Node_Id) return Boolean; -- Flag11
8928 function Explicit_Generic_Actual_Parameter
8929 (N : Node_Id) return Node_Id; -- Node1
8932 (N : Node_Id) return Node_Id; -- Node3
8934 function Expressions
8935 (N : Node_Id) return List_Id; -- List1
8938 (N : Node_Id) return Node_Id; -- Node3
8940 function First_Inlined_Subprogram
8941 (N : Node_Id) return Entity_Id; -- Node3
8944 (N : Node_Id) return Boolean; -- Flag5
8946 function First_Named_Actual
8947 (N : Node_Id) return Node_Id; -- Node4
8949 function First_Real_Statement
8950 (N : Node_Id) return Node_Id; -- Node2
8952 function First_Subtype_Link
8953 (N : Node_Id) return Entity_Id; -- Node5
8955 function Float_Truncate
8956 (N : Node_Id) return Boolean; -- Flag11
8958 function Formal_Type_Definition
8959 (N : Node_Id) return Node_Id; -- Node3
8961 function Forwards_OK
8962 (N : Node_Id) return Boolean; -- Flag5
8964 function From_Aspect_Specification
8965 (N : Node_Id) return Boolean; -- Flag13
8967 function From_At_End
8968 (N : Node_Id) return Boolean; -- Flag4
8970 function From_At_Mod
8971 (N : Node_Id) return Boolean; -- Flag4
8973 function From_Default
8974 (N : Node_Id) return Boolean; -- Flag6
8976 function Generalized_Indexing
8977 (N : Node_Id) return Node_Id; -- Node4
8978 function Generic_Associations
8979 (N : Node_Id) return List_Id; -- List3
8981 function Generic_Formal_Declarations
8982 (N : Node_Id) return List_Id; -- List2
8984 function Generic_Parent
8985 (N : Node_Id) return Node_Id; -- Node5
8987 function Generic_Parent_Type
8988 (N : Node_Id) return Node_Id; -- Node4
8990 function Handled_Statement_Sequence
8991 (N : Node_Id) return Node_Id; -- Node4
8993 function Handler_List_Entry
8994 (N : Node_Id) return Node_Id; -- Node2
8996 function Has_Created_Identifier
8997 (N : Node_Id) return Boolean; -- Flag15
8999 function Has_Dereference_Action
9000 (N : Node_Id) return Boolean; -- Flag13
9002 function Has_Dynamic_Length_Check
9003 (N : Node_Id) return Boolean; -- Flag10
9005 function Has_Dynamic_Range_Check
9006 (N : Node_Id) return Boolean; -- Flag12
9008 function Has_Init_Expression
9009 (N : Node_Id) return Boolean; -- Flag14
9011 function Has_Local_Raise
9012 (N : Node_Id) return Boolean; -- Flag8
9014 function Has_No_Elaboration_Code
9015 (N : Node_Id) return Boolean; -- Flag17
9017 function Has_Pragma_Suppress_All
9018 (N : Node_Id) return Boolean; -- Flag14
9020 function Has_Private_View
9021 (N : Node_Id) return Boolean; -- Flag11
9023 function Has_Relative_Deadline_Pragma
9024 (N : Node_Id) return Boolean; -- Flag9
9026 function Has_Self_Reference
9027 (N : Node_Id) return Boolean; -- Flag13
9029 function Has_SP_Choice
9030 (N : Node_Id) return Boolean; -- Flag15
9032 function Has_Storage_Size_Pragma
9033 (N : Node_Id) return Boolean; -- Flag5
9035 function Has_Wide_Character
9036 (N : Node_Id) return Boolean; -- Flag11
9038 function Has_Wide_Wide_Character
9039 (N : Node_Id) return Boolean; -- Flag13
9041 function Header_Size_Added
9042 (N : Node_Id) return Boolean; -- Flag11
9044 function Hidden_By_Use_Clause
9045 (N : Node_Id) return Elist_Id; -- Elist4
9048 (N : Node_Id) return Node_Id; -- Node2
9051 (N : Node_Id) return Node_Id; -- Node1
9053 function Interface_List
9054 (N : Node_Id) return List_Id; -- List2
9056 function Interface_Present
9057 (N : Node_Id) return Boolean; -- Flag16
9059 function Implicit_With
9060 (N : Node_Id) return Boolean; -- Flag16
9062 function Implicit_With_From_Instantiation
9063 (N : Node_Id) return Boolean; -- Flag12
9065 function Import_Interface_Present
9066 (N : Node_Id) return Boolean; -- Flag16
9069 (N : Node_Id) return Boolean; -- Flag15
9071 function Includes_Infinities
9072 (N : Node_Id) return Boolean; -- Flag11
9074 function Inherited_Discriminant
9075 (N : Node_Id) return Boolean; -- Flag13
9077 function Instance_Spec
9078 (N : Node_Id) return Node_Id; -- Node5
9081 (N : Node_Id) return Uint; -- Uint3
9083 function Is_Accessibility_Actual
9084 (N : Node_Id) return Boolean; -- Flag13
9086 function Is_Asynchronous_Call_Block
9087 (N : Node_Id) return Boolean; -- Flag7
9089 function Is_Boolean_Aspect
9090 (N : Node_Id) return Boolean; -- Flag16
9093 (N : Node_Id) return Boolean; -- Flag11
9095 function Is_Component_Left_Opnd
9096 (N : Node_Id) return Boolean; -- Flag13
9098 function Is_Component_Right_Opnd
9099 (N : Node_Id) return Boolean; -- Flag14
9101 function Is_Controlling_Actual
9102 (N : Node_Id) return Boolean; -- Flag16
9104 function Is_Delayed_Aspect
9105 (N : Node_Id) return Boolean; -- Flag14
9107 function Is_Disabled
9108 (N : Node_Id) return Boolean; -- Flag15
9110 function Is_Dynamic_Coextension
9111 (N : Node_Id) return Boolean; -- Flag18
9114 (N : Node_Id) return Boolean; -- Flag13
9116 function Is_Entry_Barrier_Function
9117 (N : Node_Id) return Boolean; -- Flag8
9119 function Is_Expanded_Build_In_Place_Call
9120 (N : Node_Id) return Boolean; -- Flag11
9122 function Is_Finalization_Wrapper
9123 (N : Node_Id) return Boolean; -- Flag9
9125 function Is_Folded_In_Parser
9126 (N : Node_Id) return Boolean; -- Flag4
9129 (N : Node_Id) return Boolean; -- Flag9
9131 function Is_In_Discriminant_Check
9132 (N : Node_Id) return Boolean; -- Flag11
9134 function Is_Machine_Number
9135 (N : Node_Id) return Boolean; -- Flag11
9137 function Is_Null_Loop
9138 (N : Node_Id) return Boolean; -- Flag16
9140 function Is_Overloaded
9141 (N : Node_Id) return Boolean; -- Flag5
9143 function Is_Power_Of_2_For_Shift
9144 (N : Node_Id) return Boolean; -- Flag13
9146 function Is_Prefixed_Call
9147 (N : Node_Id) return Boolean; -- Flag17
9149 function Is_Protected_Subprogram_Body
9150 (N : Node_Id) return Boolean; -- Flag7
9152 function Is_Static_Coextension
9153 (N : Node_Id) return Boolean; -- Flag14
9155 function Is_Static_Expression
9156 (N : Node_Id) return Boolean; -- Flag6
9158 function Is_Subprogram_Descriptor
9159 (N : Node_Id) return Boolean; -- Flag16
9161 function Is_Task_Allocation_Block
9162 (N : Node_Id) return Boolean; -- Flag6
9164 function Is_Task_Master
9165 (N : Node_Id) return Boolean; -- Flag5
9167 function Iteration_Scheme
9168 (N : Node_Id) return Node_Id; -- Node2
9170 function Iterator_Specification
9171 (N : Node_Id) return Node_Id; -- Node2
9174 (N : Node_Id) return Entity_Id; -- Node1
9176 function Kill_Range_Check
9177 (N : Node_Id) return Boolean; -- Flag11
9179 function Label_Construct
9180 (N : Node_Id) return Node_Id; -- Node2
9183 (N : Node_Id) return Node_Id; -- Node2
9186 (N : Node_Id) return Node_Id; -- Node4
9189 (N : Node_Id) return Boolean; -- Flag6
9191 function Library_Unit
9192 (N : Node_Id) return Node_Id; -- Node4
9194 function Limited_View_Installed
9195 (N : Node_Id) return Boolean; -- Flag18
9197 function Limited_Present
9198 (N : Node_Id) return Boolean; -- Flag17
9201 (N : Node_Id) return List_Id; -- List1
9203 function Local_Raise_Not_OK
9204 (N : Node_Id) return Boolean; -- Flag7
9206 function Local_Raise_Statements
9207 (N : Node_Id) return Elist_Id; -- Elist1
9209 function Loop_Actions
9210 (N : Node_Id) return List_Id; -- List2
9212 function Loop_Parameter_Specification
9213 (N : Node_Id) return Node_Id; -- Node4
9216 (N : Node_Id) return Node_Id; -- Node1
9219 (N : Node_Id) return Node_Id; -- Node2
9222 (N : Node_Id) return Boolean; -- Flag5
9224 function Must_Be_Byte_Aligned
9225 (N : Node_Id) return Boolean; -- Flag14
9227 function Must_Not_Freeze
9228 (N : Node_Id) return Boolean; -- Flag8
9230 function Must_Not_Override
9231 (N : Node_Id) return Boolean; -- Flag15
9233 function Must_Override
9234 (N : Node_Id) return Boolean; -- Flag14
9237 (N : Node_Id) return Node_Id; -- Node2
9240 (N : Node_Id) return List_Id; -- List2
9242 function Next_Entity
9243 (N : Node_Id) return Node_Id; -- Node2
9245 function Next_Exit_Statement
9246 (N : Node_Id) return Node_Id; -- Node3
9248 function Next_Implicit_With
9249 (N : Node_Id) return Node_Id; -- Node3
9251 function Next_Named_Actual
9252 (N : Node_Id) return Node_Id; -- Node4
9254 function Next_Pragma
9255 (N : Node_Id) return Node_Id; -- Node1
9257 function Next_Rep_Item
9258 (N : Node_Id) return Node_Id; -- Node5
9260 function Next_Use_Clause
9261 (N : Node_Id) return Node_Id; -- Node3
9263 function No_Ctrl_Actions
9264 (N : Node_Id) return Boolean; -- Flag7
9266 function No_Elaboration_Check
9267 (N : Node_Id) return Boolean; -- Flag14
9269 function No_Entities_Ref_In_Spec
9270 (N : Node_Id) return Boolean; -- Flag8
9272 function No_Initialization
9273 (N : Node_Id) return Boolean; -- Flag13
9275 function No_Minimize_Eliminate
9276 (N : Node_Id) return Boolean; -- Flag17
9278 function No_Truncation
9279 (N : Node_Id) return Boolean; -- Flag17
9281 function Non_Aliased_Prefix
9282 (N : Node_Id) return Boolean; -- Flag18
9284 function Null_Present
9285 (N : Node_Id) return Boolean; -- Flag13
9287 function Null_Exclusion_Present
9288 (N : Node_Id) return Boolean; -- Flag11
9290 function Null_Exclusion_In_Return_Present
9291 (N : Node_Id) return Boolean; -- Flag14
9293 function Null_Record_Present
9294 (N : Node_Id) return Boolean; -- Flag17
9296 function Object_Definition
9297 (N : Node_Id) return Node_Id; -- Node4
9300 (N : Node_Id) return Boolean; -- Flag16
9302 function Original_Discriminant
9303 (N : Node_Id) return Node_Id; -- Node2
9305 function Original_Entity
9306 (N : Node_Id) return Entity_Id; -- Node2
9308 function Others_Discrete_Choices
9309 (N : Node_Id) return List_Id; -- List1
9311 function Out_Present
9312 (N : Node_Id) return Boolean; -- Flag17
9314 function Parameter_Associations
9315 (N : Node_Id) return List_Id; -- List3
9317 function Parameter_List_Truncated
9318 (N : Node_Id) return Boolean; -- Flag17
9320 function Parameter_Specifications
9321 (N : Node_Id) return List_Id; -- List3
9323 function Parameter_Type
9324 (N : Node_Id) return Node_Id; -- Node2
9326 function Parent_Spec
9327 (N : Node_Id) return Node_Id; -- Node4
9330 (N : Node_Id) return Node_Id; -- Node2
9332 function Pragma_Argument_Associations
9333 (N : Node_Id) return List_Id; -- List2
9335 function Pragma_Identifier
9336 (N : Node_Id) return Node_Id; -- Node4
9338 function Pragmas_After
9339 (N : Node_Id) return List_Id; -- List5
9341 function Pragmas_Before
9342 (N : Node_Id) return List_Id; -- List4
9344 function Pre_Post_Conditions
9345 (N : Node_Id) return Node_Id; -- Node1
9348 (N : Node_Id) return Node_Id; -- Node3
9350 function Premature_Use
9351 (N : Node_Id) return Node_Id; -- Node5
9353 function Present_Expr
9354 (N : Node_Id) return Uint; -- Uint3
9357 (N : Node_Id) return Boolean; -- Flag6
9359 function Print_In_Hex
9360 (N : Node_Id) return Boolean; -- Flag13
9362 function Private_Declarations
9363 (N : Node_Id) return List_Id; -- List3
9365 function Private_Present
9366 (N : Node_Id) return Boolean; -- Flag15
9368 function Procedure_To_Call
9369 (N : Node_Id) return Node_Id; -- Node2
9371 function Proper_Body
9372 (N : Node_Id) return Node_Id; -- Node1
9374 function Protected_Definition
9375 (N : Node_Id) return Node_Id; -- Node3
9377 function Protected_Present
9378 (N : Node_Id) return Boolean; -- Flag6
9380 function Raises_Constraint_Error
9381 (N : Node_Id) return Boolean; -- Flag7
9383 function Range_Constraint
9384 (N : Node_Id) return Node_Id; -- Node4
9386 function Range_Expression
9387 (N : Node_Id) return Node_Id; -- Node4
9389 function Real_Range_Specification
9390 (N : Node_Id) return Node_Id; -- Node4
9393 (N : Node_Id) return Ureal; -- Ureal3
9396 (N : Node_Id) return Uint; -- Uint3
9398 function Record_Extension_Part
9399 (N : Node_Id) return Node_Id; -- Node3
9401 function Redundant_Use
9402 (N : Node_Id) return Boolean; -- Flag13
9404 function Renaming_Exception
9405 (N : Node_Id) return Node_Id; -- Node2
9407 function Result_Definition
9408 (N : Node_Id) return Node_Id; -- Node4
9410 function Return_Object_Declarations
9411 (N : Node_Id) return List_Id; -- List3
9413 function Return_Statement_Entity
9414 (N : Node_Id) return Node_Id; -- Node5
9416 function Reverse_Present
9417 (N : Node_Id) return Boolean; -- Flag15
9420 (N : Node_Id) return Node_Id; -- Node3
9422 function Rounded_Result
9423 (N : Node_Id) return Boolean; -- Flag18
9425 function SCIL_Controlling_Tag
9426 (N : Node_Id) return Node_Id; -- Node5
9428 function SCIL_Entity
9429 (N : Node_Id) return Node_Id; -- Node4
9431 function SCIL_Tag_Value
9432 (N : Node_Id) return Node_Id; -- Node5
9434 function SCIL_Target_Prim
9435 (N : Node_Id) return Node_Id; -- Node2
9438 (N : Node_Id) return Node_Id; -- Node3
9440 function Select_Alternatives
9441 (N : Node_Id) return List_Id; -- List1
9443 function Selector_Name
9444 (N : Node_Id) return Node_Id; -- Node2
9446 function Selector_Names
9447 (N : Node_Id) return List_Id; -- List1
9449 function Shift_Count_OK
9450 (N : Node_Id) return Boolean; -- Flag4
9452 function Source_Type
9453 (N : Node_Id) return Entity_Id; -- Node1
9455 function Specification
9456 (N : Node_Id) return Node_Id; -- Node1
9459 (N : Node_Id) return Boolean; -- Flag17
9462 (N : Node_Id) return List_Id; -- List3
9464 function Storage_Pool
9465 (N : Node_Id) return Node_Id; -- Node1
9467 function Subpool_Handle_Name
9468 (N : Node_Id) return Node_Id; -- Node4
9471 (N : Node_Id) return String_Id; -- Str3
9473 function Subtype_Indication
9474 (N : Node_Id) return Node_Id; -- Node5
9476 function Subtype_Mark
9477 (N : Node_Id) return Node_Id; -- Node4
9479 function Subtype_Marks
9480 (N : Node_Id) return List_Id; -- List2
9482 function Suppress_Assignment_Checks
9483 (N : Node_Id) return Boolean; -- Flag18
9485 function Suppress_Loop_Warnings
9486 (N : Node_Id) return Boolean; -- Flag17
9488 function Synchronized_Present
9489 (N : Node_Id) return Boolean; -- Flag7
9491 function Tagged_Present
9492 (N : Node_Id) return Boolean; -- Flag15
9494 function Target_Type
9495 (N : Node_Id) return Entity_Id; -- Node2
9497 function Task_Definition
9498 (N : Node_Id) return Node_Id; -- Node3
9500 function Task_Present
9501 (N : Node_Id) return Boolean; -- Flag5
9503 function Then_Actions
9504 (N : Node_Id) return List_Id; -- List2
9506 function Then_Statements
9507 (N : Node_Id) return List_Id; -- List2
9509 function Treat_Fixed_As_Integer
9510 (N : Node_Id) return Boolean; -- Flag14
9512 function Triggering_Alternative
9513 (N : Node_Id) return Node_Id; -- Node1
9515 function Triggering_Statement
9516 (N : Node_Id) return Node_Id; -- Node1
9519 (N : Node_Id) return Elist_Id; -- Elist3
9521 function Type_Definition
9522 (N : Node_Id) return Node_Id; -- Node3
9525 (N : Node_Id) return Node_Id; -- Node2
9527 function Unknown_Discriminants_Present
9528 (N : Node_Id) return Boolean; -- Flag13
9530 function Unreferenced_In_Spec
9531 (N : Node_Id) return Boolean; -- Flag7
9533 function Variant_Part
9534 (N : Node_Id) return Node_Id; -- Node4
9537 (N : Node_Id) return List_Id; -- List1
9539 function Visible_Declarations
9540 (N : Node_Id) return List_Id; -- List2
9542 function Uninitialized_Variable
9543 (N : Node_Id) return Node_Id; -- Node3
9545 function Used_Operations
9546 (N : Node_Id) return Elist_Id; -- Elist5
9548 function Was_Originally_Stub
9549 (N : Node_Id) return Boolean; -- Flag13
9551 function Withed_Body
9552 (N : Node_Id) return Node_Id; -- Node1
9554 -- End functions (note used by xsinfo utility program to end processing)
9556 ----------------------------
9557 -- Node Update Procedures --
9558 ----------------------------
9560 -- These are the corresponding node update routines, which again provide
9561 -- a high level logical access with type checking. In addition to setting
9562 -- the indicated field of the node N to the given Val, in the case of
9563 -- tree pointers (List1-4), the parent pointer of the Val node is set to
9564 -- point back to node N. This automates the setting of the parent pointer.
9566 procedure Set_ABE_Is_Certain
9567 (N : Node_Id; Val : Boolean := True); -- Flag18
9569 procedure Set_Abort_Present
9570 (N : Node_Id; Val : Boolean := True); -- Flag15
9572 procedure Set_Abortable_Part
9573 (N : Node_Id; Val : Node_Id); -- Node2
9575 procedure Set_Abstract_Present
9576 (N : Node_Id; Val : Boolean := True); -- Flag4
9578 procedure Set_Accept_Handler_Records
9579 (N : Node_Id; Val : List_Id); -- List5
9581 procedure Set_Accept_Statement
9582 (N : Node_Id; Val : Node_Id); -- Node2
9584 procedure Set_Access_Definition
9585 (N : Node_Id; Val : Node_Id); -- Node3
9587 procedure Set_Access_To_Subprogram_Definition
9588 (N : Node_Id; Val : Node_Id); -- Node3
9590 procedure Set_Access_Types_To_Process
9591 (N : Node_Id; Val : Elist_Id); -- Elist2
9593 procedure Set_Actions
9594 (N : Node_Id; Val : List_Id); -- List1
9596 procedure Set_Activation_Chain_Entity
9597 (N : Node_Id; Val : Node_Id); -- Node3
9599 procedure Set_Acts_As_Spec
9600 (N : Node_Id; Val : Boolean := True); -- Flag4
9602 procedure Set_Actual_Designated_Subtype
9603 (N : Node_Id; Val : Node_Id); -- Node4
9605 procedure Set_Address_Warning_Posted
9606 (N : Node_Id; Val : Boolean := True); -- Flag18
9608 procedure Set_Aggregate_Bounds
9609 (N : Node_Id; Val : Node_Id); -- Node3
9611 procedure Set_Aliased_Present
9612 (N : Node_Id; Val : Boolean := True); -- Flag4
9614 procedure Set_All_Others
9615 (N : Node_Id; Val : Boolean := True); -- Flag11
9617 procedure Set_All_Present
9618 (N : Node_Id; Val : Boolean := True); -- Flag15
9620 procedure Set_Alternatives
9621 (N : Node_Id; Val : List_Id); -- List4
9623 procedure Set_Ancestor_Part
9624 (N : Node_Id; Val : Node_Id); -- Node3
9626 procedure Set_Atomic_Sync_Required
9627 (N : Node_Id; Val : Boolean := True); -- Flag14
9629 procedure Set_Array_Aggregate
9630 (N : Node_Id; Val : Node_Id); -- Node3
9632 procedure Set_Aspect_Rep_Item
9633 (N : Node_Id; Val : Node_Id); -- Node2
9635 procedure Set_Assignment_OK
9636 (N : Node_Id; Val : Boolean := True); -- Flag15
9638 procedure Set_Associated_Node
9639 (N : Node_Id; Val : Node_Id); -- Node4
9641 procedure Set_Attribute_Name
9642 (N : Node_Id; Val : Name_Id); -- Name2
9644 procedure Set_At_End_Proc
9645 (N : Node_Id; Val : Node_Id); -- Node1
9647 procedure Set_Aux_Decls_Node
9648 (N : Node_Id; Val : Node_Id); -- Node5
9650 procedure Set_Backwards_OK
9651 (N : Node_Id; Val : Boolean := True); -- Flag6
9653 procedure Set_Bad_Is_Detected
9654 (N : Node_Id; Val : Boolean := True); -- Flag15
9656 procedure Set_Body_Required
9657 (N : Node_Id; Val : Boolean := True); -- Flag13
9659 procedure Set_Body_To_Inline
9660 (N : Node_Id; Val : Node_Id); -- Node3
9662 procedure Set_Box_Present
9663 (N : Node_Id; Val : Boolean := True); -- Flag15
9665 procedure Set_By_Ref
9666 (N : Node_Id; Val : Boolean := True); -- Flag5
9668 procedure Set_Char_Literal_Value
9669 (N : Node_Id; Val : Uint); -- Uint2
9672 (N : Node_Id; Val : Name_Id); -- Name1
9674 procedure Set_Check_Address_Alignment
9675 (N : Node_Id; Val : Boolean := True); -- Flag11
9677 procedure Set_Choice_Parameter
9678 (N : Node_Id; Val : Node_Id); -- Node2
9680 procedure Set_Choices
9681 (N : Node_Id; Val : List_Id); -- List1
9683 procedure Set_Class_Present
9684 (N : Node_Id; Val : Boolean := True); -- Flag6
9686 procedure Set_Classifications
9687 (N : Node_Id; Val : Node_Id); -- Node3
9689 procedure Set_Comes_From_Extended_Return_Statement
9690 (N : Node_Id; Val : Boolean := True); -- Flag18
9692 procedure Set_Compile_Time_Known_Aggregate
9693 (N : Node_Id; Val : Boolean := True); -- Flag18
9695 procedure Set_Component_Associations
9696 (N : Node_Id; Val : List_Id); -- List2
9698 procedure Set_Component_Clauses
9699 (N : Node_Id; Val : List_Id); -- List3
9701 procedure Set_Component_Definition
9702 (N : Node_Id; Val : Node_Id); -- Node4
9704 procedure Set_Component_Items
9705 (N : Node_Id; Val : List_Id); -- List3
9707 procedure Set_Component_List
9708 (N : Node_Id; Val : Node_Id); -- Node1
9710 procedure Set_Component_Name
9711 (N : Node_Id; Val : Node_Id); -- Node1
9713 procedure Set_Componentwise_Assignment
9714 (N : Node_Id; Val : Boolean := True); -- Flag14
9716 procedure Set_Condition
9717 (N : Node_Id; Val : Node_Id); -- Node1
9719 procedure Set_Condition_Actions
9720 (N : Node_Id; Val : List_Id); -- List3
9722 procedure Set_Config_Pragmas
9723 (N : Node_Id; Val : List_Id); -- List4
9725 procedure Set_Constant_Present
9726 (N : Node_Id; Val : Boolean := True); -- Flag17
9728 procedure Set_Constraint
9729 (N : Node_Id; Val : Node_Id); -- Node3
9731 procedure Set_Constraints
9732 (N : Node_Id; Val : List_Id); -- List1
9734 procedure Set_Context_Installed
9735 (N : Node_Id; Val : Boolean := True); -- Flag13
9737 procedure Set_Context_Items
9738 (N : Node_Id; Val : List_Id); -- List1
9740 procedure Set_Context_Pending
9741 (N : Node_Id; Val : Boolean := True); -- Flag16
9743 procedure Set_Contract_Test_Cases
9744 (N : Node_Id; Val : Node_Id); -- Node2
9746 procedure Set_Controlling_Argument
9747 (N : Node_Id; Val : Node_Id); -- Node1
9749 procedure Set_Conversion_OK
9750 (N : Node_Id; Val : Boolean := True); -- Flag14
9752 procedure Set_Convert_To_Return_False
9753 (N : Node_Id; Val : Boolean := True); -- Flag13
9755 procedure Set_Corresponding_Aspect
9756 (N : Node_Id; Val : Node_Id); -- Node3
9758 procedure Set_Corresponding_Body
9759 (N : Node_Id; Val : Node_Id); -- Node5
9761 procedure Set_Corresponding_Formal_Spec
9762 (N : Node_Id; Val : Node_Id); -- Node3
9764 procedure Set_Corresponding_Generic_Association
9765 (N : Node_Id; Val : Node_Id); -- Node5
9767 procedure Set_Corresponding_Integer_Value
9768 (N : Node_Id; Val : Uint); -- Uint4
9770 procedure Set_Corresponding_Spec
9771 (N : Node_Id; Val : Node_Id); -- Node5
9773 procedure Set_Corresponding_Spec_Of_Stub
9774 (N : Node_Id; Val : Node_Id); -- Node2
9776 procedure Set_Corresponding_Stub
9777 (N : Node_Id; Val : Node_Id); -- Node3
9779 procedure Set_Dcheck_Function
9780 (N : Node_Id; Val : Entity_Id); -- Node5
9782 procedure Set_Declarations
9783 (N : Node_Id; Val : List_Id); -- List2
9785 procedure Set_Default_Expression
9786 (N : Node_Id; Val : Node_Id); -- Node5
9788 procedure Set_Default_Storage_Pool
9789 (N : Node_Id; Val : Node_Id); -- Node3
9791 procedure Set_Default_Name
9792 (N : Node_Id; Val : Node_Id); -- Node2
9794 procedure Set_Defining_Identifier
9795 (N : Node_Id; Val : Entity_Id); -- Node1
9797 procedure Set_Defining_Unit_Name
9798 (N : Node_Id; Val : Node_Id); -- Node1
9800 procedure Set_Delay_Alternative
9801 (N : Node_Id; Val : Node_Id); -- Node4
9803 procedure Set_Delay_Statement
9804 (N : Node_Id; Val : Node_Id); -- Node2
9806 procedure Set_Delta_Expression
9807 (N : Node_Id; Val : Node_Id); -- Node3
9809 procedure Set_Digits_Expression
9810 (N : Node_Id; Val : Node_Id); -- Node2
9812 procedure Set_Discr_Check_Funcs_Built
9813 (N : Node_Id; Val : Boolean := True); -- Flag11
9815 procedure Set_Discrete_Choices
9816 (N : Node_Id; Val : List_Id); -- List4
9818 procedure Set_Discrete_Range
9819 (N : Node_Id; Val : Node_Id); -- Node4
9821 procedure Set_Discrete_Subtype_Definition
9822 (N : Node_Id; Val : Node_Id); -- Node4
9824 procedure Set_Discrete_Subtype_Definitions
9825 (N : Node_Id; Val : List_Id); -- List2
9827 procedure Set_Discriminant_Specifications
9828 (N : Node_Id; Val : List_Id); -- List4
9830 procedure Set_Discriminant_Type
9831 (N : Node_Id; Val : Node_Id); -- Node5
9833 procedure Set_Do_Accessibility_Check
9834 (N : Node_Id; Val : Boolean := True); -- Flag13
9836 procedure Set_Do_Discriminant_Check
9837 (N : Node_Id; Val : Boolean := True); -- Flag1
9839 procedure Set_Do_Division_Check
9840 (N : Node_Id; Val : Boolean := True); -- Flag13
9842 procedure Set_Do_Length_Check
9843 (N : Node_Id; Val : Boolean := True); -- Flag4
9845 procedure Set_Do_Overflow_Check
9846 (N : Node_Id; Val : Boolean := True); -- Flag17
9848 procedure Set_Do_Range_Check
9849 (N : Node_Id; Val : Boolean := True); -- Flag9
9851 procedure Set_Do_Storage_Check
9852 (N : Node_Id; Val : Boolean := True); -- Flag17
9854 procedure Set_Do_Tag_Check
9855 (N : Node_Id; Val : Boolean := True); -- Flag13
9857 procedure Set_Elaborate_All_Desirable
9858 (N : Node_Id; Val : Boolean := True); -- Flag9
9860 procedure Set_Elaborate_All_Present
9861 (N : Node_Id; Val : Boolean := True); -- Flag14
9863 procedure Set_Elaborate_Desirable
9864 (N : Node_Id; Val : Boolean := True); -- Flag11
9866 procedure Set_Elaborate_Present
9867 (N : Node_Id; Val : Boolean := True); -- Flag4
9869 procedure Set_Elaboration_Boolean
9870 (N : Node_Id; Val : Node_Id); -- Node2
9872 procedure Set_Else_Actions
9873 (N : Node_Id; Val : List_Id); -- List3
9875 procedure Set_Else_Statements
9876 (N : Node_Id; Val : List_Id); -- List4
9878 procedure Set_Elsif_Parts
9879 (N : Node_Id; Val : List_Id); -- List3
9881 procedure Set_Enclosing_Variant
9882 (N : Node_Id; Val : Node_Id); -- Node2
9884 procedure Set_End_Label
9885 (N : Node_Id; Val : Node_Id); -- Node4
9887 procedure Set_End_Span
9888 (N : Node_Id; Val : Uint); -- Uint5
9890 procedure Set_Entity
9891 (N : Node_Id; Val : Node_Id); -- Node4
9893 procedure Set_Entry_Body_Formal_Part
9894 (N : Node_Id; Val : Node_Id); -- Node5
9896 procedure Set_Entry_Call_Alternative
9897 (N : Node_Id; Val : Node_Id); -- Node1
9899 procedure Set_Entry_Call_Statement
9900 (N : Node_Id; Val : Node_Id); -- Node1
9902 procedure Set_Entry_Direct_Name
9903 (N : Node_Id; Val : Node_Id); -- Node1
9905 procedure Set_Entry_Index
9906 (N : Node_Id; Val : Node_Id); -- Node5
9908 procedure Set_Entry_Index_Specification
9909 (N : Node_Id; Val : Node_Id); -- Node4
9912 (N : Node_Id; Val : Node_Id); -- Node5
9914 procedure Set_Exception_Choices
9915 (N : Node_Id; Val : List_Id); -- List4
9917 procedure Set_Exception_Handlers
9918 (N : Node_Id; Val : List_Id); -- List5
9920 procedure Set_Exception_Junk
9921 (N : Node_Id; Val : Boolean := True); -- Flag8
9923 procedure Set_Exception_Label
9924 (N : Node_Id; Val : Node_Id); -- Node5
9926 procedure Set_Expansion_Delayed
9927 (N : Node_Id; Val : Boolean := True); -- Flag11
9929 procedure Set_Explicit_Actual_Parameter
9930 (N : Node_Id; Val : Node_Id); -- Node3
9932 procedure Set_Explicit_Generic_Actual_Parameter
9933 (N : Node_Id; Val : Node_Id); -- Node1
9935 procedure Set_Expression
9936 (N : Node_Id; Val : Node_Id); -- Node3
9938 procedure Set_Expressions
9939 (N : Node_Id; Val : List_Id); -- List1
9941 procedure Set_First_Bit
9942 (N : Node_Id; Val : Node_Id); -- Node3
9944 procedure Set_First_Inlined_Subprogram
9945 (N : Node_Id; Val : Entity_Id); -- Node3
9947 procedure Set_First_Name
9948 (N : Node_Id; Val : Boolean := True); -- Flag5
9950 procedure Set_First_Named_Actual
9951 (N : Node_Id; Val : Node_Id); -- Node4
9953 procedure Set_First_Real_Statement
9954 (N : Node_Id; Val : Node_Id); -- Node2
9956 procedure Set_First_Subtype_Link
9957 (N : Node_Id; Val : Entity_Id); -- Node5
9959 procedure Set_Float_Truncate
9960 (N : Node_Id; Val : Boolean := True); -- Flag11
9962 procedure Set_Formal_Type_Definition
9963 (N : Node_Id; Val : Node_Id); -- Node3
9965 procedure Set_Forwards_OK
9966 (N : Node_Id; Val : Boolean := True); -- Flag5
9968 procedure Set_From_At_Mod
9969 (N : Node_Id; Val : Boolean := True); -- Flag4
9971 procedure Set_From_Aspect_Specification
9972 (N : Node_Id; Val : Boolean := True); -- Flag13
9974 procedure Set_From_At_End
9975 (N : Node_Id; Val : Boolean := True); -- Flag4
9977 procedure Set_From_Default
9978 (N : Node_Id; Val : Boolean := True); -- Flag6
9980 procedure Set_Generalized_Indexing
9981 (N : Node_Id; Val : Node_Id); -- Node4
9983 procedure Set_Generic_Associations
9984 (N : Node_Id; Val : List_Id); -- List3
9986 procedure Set_Generic_Formal_Declarations
9987 (N : Node_Id; Val : List_Id); -- List2
9989 procedure Set_Generic_Parent
9990 (N : Node_Id; Val : Node_Id); -- Node5
9992 procedure Set_Generic_Parent_Type
9993 (N : Node_Id; Val : Node_Id); -- Node4
9995 procedure Set_Handled_Statement_Sequence
9996 (N : Node_Id; Val : Node_Id); -- Node4
9998 procedure Set_Handler_List_Entry
9999 (N : Node_Id; Val : Node_Id); -- Node2
10001 procedure Set_Has_Created_Identifier
10002 (N : Node_Id; Val : Boolean := True); -- Flag15
10004 procedure Set_Has_Dereference_Action
10005 (N : Node_Id; Val : Boolean := True); -- Flag13
10007 procedure Set_Has_Dynamic_Length_Check
10008 (N : Node_Id; Val : Boolean := True); -- Flag10
10010 procedure Set_Has_Dynamic_Range_Check
10011 (N : Node_Id; Val : Boolean := True); -- Flag12
10013 procedure Set_Has_Init_Expression
10014 (N : Node_Id; Val : Boolean := True); -- Flag14
10016 procedure Set_Has_Local_Raise
10017 (N : Node_Id; Val : Boolean := True); -- Flag8
10019 procedure Set_Has_No_Elaboration_Code
10020 (N : Node_Id; Val : Boolean := True); -- Flag17
10022 procedure Set_Has_Pragma_Suppress_All
10023 (N : Node_Id; Val : Boolean := True); -- Flag14
10025 procedure Set_Has_Private_View
10026 (N : Node_Id; Val : Boolean := True); -- Flag11
10028 procedure Set_Has_Relative_Deadline_Pragma
10029 (N : Node_Id; Val : Boolean := True); -- Flag9
10031 procedure Set_Has_Self_Reference
10032 (N : Node_Id; Val : Boolean := True); -- Flag13
10034 procedure Set_Has_SP_Choice
10035 (N : Node_Id; Val : Boolean := True); -- Flag15
10037 procedure Set_Has_Storage_Size_Pragma
10038 (N : Node_Id; Val : Boolean := True); -- Flag5
10040 procedure Set_Has_Wide_Character
10041 (N : Node_Id; Val : Boolean := True); -- Flag11
10043 procedure Set_Has_Wide_Wide_Character
10044 (N : Node_Id; Val : Boolean := True); -- Flag13
10046 procedure Set_Header_Size_Added
10047 (N : Node_Id; Val : Boolean := True); -- Flag11
10049 procedure Set_Hidden_By_Use_Clause
10050 (N : Node_Id; Val : Elist_Id); -- Elist4
10052 procedure Set_High_Bound
10053 (N : Node_Id; Val : Node_Id); -- Node2
10055 procedure Set_Identifier
10056 (N : Node_Id; Val : Node_Id); -- Node1
10058 procedure Set_Interface_List
10059 (N : Node_Id; Val : List_Id); -- List2
10061 procedure Set_Interface_Present
10062 (N : Node_Id; Val : Boolean := True); -- Flag16
10064 procedure Set_Implicit_With
10065 (N : Node_Id; Val : Boolean := True); -- Flag16
10067 procedure Set_Implicit_With_From_Instantiation
10068 (N : Node_Id; Val : Boolean := True); -- Flag12
10070 procedure Set_Import_Interface_Present
10071 (N : Node_Id; Val : Boolean := True); -- Flag16
10073 procedure Set_In_Present
10074 (N : Node_Id; Val : Boolean := True); -- Flag15
10076 procedure Set_Includes_Infinities
10077 (N : Node_Id; Val : Boolean := True); -- Flag11
10079 procedure Set_Inherited_Discriminant
10080 (N : Node_Id; Val : Boolean := True); -- Flag13
10082 procedure Set_Instance_Spec
10083 (N : Node_Id; Val : Node_Id); -- Node5
10085 procedure Set_Intval
10086 (N : Node_Id; Val : Uint); -- Uint3
10088 procedure Set_Is_Accessibility_Actual
10089 (N : Node_Id; Val : Boolean := True); -- Flag13
10091 procedure Set_Is_Asynchronous_Call_Block
10092 (N : Node_Id; Val : Boolean := True); -- Flag7
10094 procedure Set_Is_Boolean_Aspect
10095 (N : Node_Id; Val : Boolean := True); -- Flag16
10097 procedure Set_Is_Checked
10098 (N : Node_Id; Val : Boolean := True); -- Flag11
10100 procedure Set_Is_Component_Left_Opnd
10101 (N : Node_Id; Val : Boolean := True); -- Flag13
10103 procedure Set_Is_Component_Right_Opnd
10104 (N : Node_Id; Val : Boolean := True); -- Flag14
10106 procedure Set_Is_Controlling_Actual
10107 (N : Node_Id; Val : Boolean := True); -- Flag16
10109 procedure Set_Is_Delayed_Aspect
10110 (N : Node_Id; Val : Boolean := True); -- Flag14
10112 procedure Set_Is_Disabled
10113 (N : Node_Id; Val : Boolean := True); -- Flag15
10115 procedure Set_Is_Ignored
10116 (N : Node_Id; Val : Boolean := True); -- Flag9
10118 procedure Set_Is_Dynamic_Coextension
10119 (N : Node_Id; Val : Boolean := True); -- Flag18
10121 procedure Set_Is_Elsif
10122 (N : Node_Id; Val : Boolean := True); -- Flag13
10124 procedure Set_Is_Entry_Barrier_Function
10125 (N : Node_Id; Val : Boolean := True); -- Flag8
10127 procedure Set_Is_Expanded_Build_In_Place_Call
10128 (N : Node_Id; Val : Boolean := True); -- Flag11
10130 procedure Set_Is_Finalization_Wrapper
10131 (N : Node_Id; Val : Boolean := True); -- Flag9
10133 procedure Set_Is_Folded_In_Parser
10134 (N : Node_Id; Val : Boolean := True); -- Flag4
10136 procedure Set_Is_In_Discriminant_Check
10137 (N : Node_Id; Val : Boolean := True); -- Flag11
10139 procedure Set_Is_Machine_Number
10140 (N : Node_Id; Val : Boolean := True); -- Flag11
10142 procedure Set_Is_Null_Loop
10143 (N : Node_Id; Val : Boolean := True); -- Flag16
10145 procedure Set_Is_Overloaded
10146 (N : Node_Id; Val : Boolean := True); -- Flag5
10148 procedure Set_Is_Power_Of_2_For_Shift
10149 (N : Node_Id; Val : Boolean := True); -- Flag13
10151 procedure Set_Is_Prefixed_Call
10152 (N : Node_Id; Val : Boolean := True); -- Flag17
10154 procedure Set_Is_Protected_Subprogram_Body
10155 (N : Node_Id; Val : Boolean := True); -- Flag7
10157 procedure Set_Is_Static_Coextension
10158 (N : Node_Id; Val : Boolean := True); -- Flag14
10160 procedure Set_Is_Static_Expression
10161 (N : Node_Id; Val : Boolean := True); -- Flag6
10163 procedure Set_Is_Subprogram_Descriptor
10164 (N : Node_Id; Val : Boolean := True); -- Flag16
10166 procedure Set_Is_Task_Allocation_Block
10167 (N : Node_Id; Val : Boolean := True); -- Flag6
10169 procedure Set_Is_Task_Master
10170 (N : Node_Id; Val : Boolean := True); -- Flag5
10172 procedure Set_Iteration_Scheme
10173 (N : Node_Id; Val : Node_Id); -- Node2
10175 procedure Set_Iterator_Specification
10176 (N : Node_Id; Val : Node_Id); -- Node2
10178 procedure Set_Itype
10179 (N : Node_Id; Val : Entity_Id); -- Node1
10181 procedure Set_Kill_Range_Check
10182 (N : Node_Id; Val : Boolean := True); -- Flag11
10184 procedure Set_Last_Bit
10185 (N : Node_Id; Val : Node_Id); -- Node4
10187 procedure Set_Last_Name
10188 (N : Node_Id; Val : Boolean := True); -- Flag6
10190 procedure Set_Library_Unit
10191 (N : Node_Id; Val : Node_Id); -- Node4
10193 procedure Set_Label_Construct
10194 (N : Node_Id; Val : Node_Id); -- Node2
10196 procedure Set_Left_Opnd
10197 (N : Node_Id; Val : Node_Id); -- Node2
10199 procedure Set_Limited_View_Installed
10200 (N : Node_Id; Val : Boolean := True); -- Flag18
10202 procedure Set_Limited_Present
10203 (N : Node_Id; Val : Boolean := True); -- Flag17
10205 procedure Set_Literals
10206 (N : Node_Id; Val : List_Id); -- List1
10208 procedure Set_Local_Raise_Not_OK
10209 (N : Node_Id; Val : Boolean := True); -- Flag7
10211 procedure Set_Local_Raise_Statements
10212 (N : Node_Id; Val : Elist_Id); -- Elist1
10214 procedure Set_Loop_Actions
10215 (N : Node_Id; Val : List_Id); -- List2
10217 procedure Set_Loop_Parameter_Specification
10218 (N : Node_Id; Val : Node_Id); -- Node4
10220 procedure Set_Low_Bound
10221 (N : Node_Id; Val : Node_Id); -- Node1
10223 procedure Set_Mod_Clause
10224 (N : Node_Id; Val : Node_Id); -- Node2
10226 procedure Set_More_Ids
10227 (N : Node_Id; Val : Boolean := True); -- Flag5
10229 procedure Set_Must_Be_Byte_Aligned
10230 (N : Node_Id; Val : Boolean := True); -- Flag14
10232 procedure Set_Must_Not_Freeze
10233 (N : Node_Id; Val : Boolean := True); -- Flag8
10235 procedure Set_Must_Not_Override
10236 (N : Node_Id; Val : Boolean := True); -- Flag15
10238 procedure Set_Must_Override
10239 (N : Node_Id; Val : Boolean := True); -- Flag14
10242 (N : Node_Id; Val : Node_Id); -- Node2
10244 procedure Set_Names
10245 (N : Node_Id; Val : List_Id); -- List2
10247 procedure Set_Next_Entity
10248 (N : Node_Id; Val : Node_Id); -- Node2
10250 procedure Set_Next_Exit_Statement
10251 (N : Node_Id; Val : Node_Id); -- Node3
10253 procedure Set_Next_Implicit_With
10254 (N : Node_Id; Val : Node_Id); -- Node3
10256 procedure Set_Next_Named_Actual
10257 (N : Node_Id; Val : Node_Id); -- Node4
10259 procedure Set_Next_Pragma
10260 (N : Node_Id; Val : Node_Id); -- Node1
10262 procedure Set_Next_Rep_Item
10263 (N : Node_Id; Val : Node_Id); -- Node5
10265 procedure Set_Next_Use_Clause
10266 (N : Node_Id; Val : Node_Id); -- Node3
10268 procedure Set_No_Ctrl_Actions
10269 (N : Node_Id; Val : Boolean := True); -- Flag7
10271 procedure Set_No_Elaboration_Check
10272 (N : Node_Id; Val : Boolean := True); -- Flag14
10274 procedure Set_No_Entities_Ref_In_Spec
10275 (N : Node_Id; Val : Boolean := True); -- Flag8
10277 procedure Set_No_Initialization
10278 (N : Node_Id; Val : Boolean := True); -- Flag13
10280 procedure Set_No_Minimize_Eliminate
10281 (N : Node_Id; Val : Boolean := True); -- Flag17
10283 procedure Set_No_Truncation
10284 (N : Node_Id; Val : Boolean := True); -- Flag17
10286 procedure Set_Non_Aliased_Prefix
10287 (N : Node_Id; Val : Boolean := True); -- Flag18
10289 procedure Set_Null_Present
10290 (N : Node_Id; Val : Boolean := True); -- Flag13
10292 procedure Set_Null_Exclusion_Present
10293 (N : Node_Id; Val : Boolean := True); -- Flag11
10295 procedure Set_Null_Exclusion_In_Return_Present
10296 (N : Node_Id; Val : Boolean := True); -- Flag14
10298 procedure Set_Null_Record_Present
10299 (N : Node_Id; Val : Boolean := True); -- Flag17
10301 procedure Set_Object_Definition
10302 (N : Node_Id; Val : Node_Id); -- Node4
10304 procedure Set_Of_Present
10305 (N : Node_Id; Val : Boolean := True); -- Flag16
10307 procedure Set_Original_Discriminant
10308 (N : Node_Id; Val : Node_Id); -- Node2
10310 procedure Set_Original_Entity
10311 (N : Node_Id; Val : Entity_Id); -- Node2
10313 procedure Set_Others_Discrete_Choices
10314 (N : Node_Id; Val : List_Id); -- List1
10316 procedure Set_Out_Present
10317 (N : Node_Id; Val : Boolean := True); -- Flag17
10319 procedure Set_Parameter_Associations
10320 (N : Node_Id; Val : List_Id); -- List3
10322 procedure Set_Parameter_List_Truncated
10323 (N : Node_Id; Val : Boolean := True); -- Flag17
10325 procedure Set_Parameter_Specifications
10326 (N : Node_Id; Val : List_Id); -- List3
10328 procedure Set_Parameter_Type
10329 (N : Node_Id; Val : Node_Id); -- Node2
10331 procedure Set_Parent_Spec
10332 (N : Node_Id; Val : Node_Id); -- Node4
10334 procedure Set_Position
10335 (N : Node_Id; Val : Node_Id); -- Node2
10337 procedure Set_Pragma_Argument_Associations
10338 (N : Node_Id; Val : List_Id); -- List2
10340 procedure Set_Pragma_Identifier
10341 (N : Node_Id; Val : Node_Id); -- Node4
10343 procedure Set_Pragmas_After
10344 (N : Node_Id; Val : List_Id); -- List5
10346 procedure Set_Pragmas_Before
10347 (N : Node_Id; Val : List_Id); -- List4
10349 procedure Set_Pre_Post_Conditions
10350 (N : Node_Id; Val : Node_Id); -- Node1
10352 procedure Set_Prefix
10353 (N : Node_Id; Val : Node_Id); -- Node3
10355 procedure Set_Premature_Use
10356 (N : Node_Id; Val : Node_Id); -- Node5
10358 procedure Set_Present_Expr
10359 (N : Node_Id; Val : Uint); -- Uint3
10361 procedure Set_Prev_Ids
10362 (N : Node_Id; Val : Boolean := True); -- Flag6
10364 procedure Set_Print_In_Hex
10365 (N : Node_Id; Val : Boolean := True); -- Flag13
10367 procedure Set_Private_Declarations
10368 (N : Node_Id; Val : List_Id); -- List3
10370 procedure Set_Private_Present
10371 (N : Node_Id; Val : Boolean := True); -- Flag15
10373 procedure Set_Procedure_To_Call
10374 (N : Node_Id; Val : Node_Id); -- Node2
10376 procedure Set_Proper_Body
10377 (N : Node_Id; Val : Node_Id); -- Node1
10379 procedure Set_Protected_Definition
10380 (N : Node_Id; Val : Node_Id); -- Node3
10382 procedure Set_Protected_Present
10383 (N : Node_Id; Val : Boolean := True); -- Flag6
10385 procedure Set_Raises_Constraint_Error
10386 (N : Node_Id; Val : Boolean := True); -- Flag7
10388 procedure Set_Range_Constraint
10389 (N : Node_Id; Val : Node_Id); -- Node4
10391 procedure Set_Range_Expression
10392 (N : Node_Id; Val : Node_Id); -- Node4
10394 procedure Set_Real_Range_Specification
10395 (N : Node_Id; Val : Node_Id); -- Node4
10397 procedure Set_Realval
10398 (N : Node_Id; Val : Ureal); -- Ureal3
10400 procedure Set_Reason
10401 (N : Node_Id; Val : Uint); -- Uint3
10403 procedure Set_Record_Extension_Part
10404 (N : Node_Id; Val : Node_Id); -- Node3
10406 procedure Set_Redundant_Use
10407 (N : Node_Id; Val : Boolean := True); -- Flag13
10409 procedure Set_Renaming_Exception
10410 (N : Node_Id; Val : Node_Id); -- Node2
10412 procedure Set_Result_Definition
10413 (N : Node_Id; Val : Node_Id); -- Node4
10415 procedure Set_Return_Object_Declarations
10416 (N : Node_Id; Val : List_Id); -- List3
10418 procedure Set_Return_Statement_Entity
10419 (N : Node_Id; Val : Node_Id); -- Node5
10421 procedure Set_Reverse_Present
10422 (N : Node_Id; Val : Boolean := True); -- Flag15
10424 procedure Set_Right_Opnd
10425 (N : Node_Id; Val : Node_Id); -- Node3
10427 procedure Set_Rounded_Result
10428 (N : Node_Id; Val : Boolean := True); -- Flag18
10430 procedure Set_SCIL_Controlling_Tag
10431 (N : Node_Id; Val : Node_Id); -- Node5
10433 procedure Set_SCIL_Entity
10434 (N : Node_Id; Val : Node_Id); -- Node4
10436 procedure Set_SCIL_Tag_Value
10437 (N : Node_Id; Val : Node_Id); -- Node5
10439 procedure Set_SCIL_Target_Prim
10440 (N : Node_Id; Val : Node_Id); -- Node2
10442 procedure Set_Scope
10443 (N : Node_Id; Val : Node_Id); -- Node3
10445 procedure Set_Select_Alternatives
10446 (N : Node_Id; Val : List_Id); -- List1
10448 procedure Set_Selector_Name
10449 (N : Node_Id; Val : Node_Id); -- Node2
10451 procedure Set_Selector_Names
10452 (N : Node_Id; Val : List_Id); -- List1
10454 procedure Set_Shift_Count_OK
10455 (N : Node_Id; Val : Boolean := True); -- Flag4
10457 procedure Set_Source_Type
10458 (N : Node_Id; Val : Entity_Id); -- Node1
10460 procedure Set_Specification
10461 (N : Node_Id; Val : Node_Id); -- Node1
10463 procedure Set_Split_PPC
10464 (N : Node_Id; Val : Boolean); -- Flag17
10466 procedure Set_Statements
10467 (N : Node_Id; Val : List_Id); -- List3
10469 procedure Set_Storage_Pool
10470 (N : Node_Id; Val : Node_Id); -- Node1
10472 procedure Set_Subpool_Handle_Name
10473 (N : Node_Id; Val : Node_Id); -- Node4
10475 procedure Set_Strval
10476 (N : Node_Id; Val : String_Id); -- Str3
10478 procedure Set_Subtype_Indication
10479 (N : Node_Id; Val : Node_Id); -- Node5
10481 procedure Set_Subtype_Mark
10482 (N : Node_Id; Val : Node_Id); -- Node4
10484 procedure Set_Subtype_Marks
10485 (N : Node_Id; Val : List_Id); -- List2
10487 procedure Set_Suppress_Assignment_Checks
10488 (N : Node_Id; Val : Boolean := True); -- Flag18
10490 procedure Set_Suppress_Loop_Warnings
10491 (N : Node_Id; Val : Boolean := True); -- Flag17
10493 procedure Set_Synchronized_Present
10494 (N : Node_Id; Val : Boolean := True); -- Flag7
10496 procedure Set_Tagged_Present
10497 (N : Node_Id; Val : Boolean := True); -- Flag15
10499 procedure Set_Target_Type
10500 (N : Node_Id; Val : Entity_Id); -- Node2
10502 procedure Set_Task_Definition
10503 (N : Node_Id; Val : Node_Id); -- Node3
10505 procedure Set_Task_Present
10506 (N : Node_Id; Val : Boolean := True); -- Flag5
10508 procedure Set_Then_Actions
10509 (N : Node_Id; Val : List_Id); -- List2
10511 procedure Set_Then_Statements
10512 (N : Node_Id; Val : List_Id); -- List2
10514 procedure Set_Treat_Fixed_As_Integer
10515 (N : Node_Id; Val : Boolean := True); -- Flag14
10517 procedure Set_Triggering_Alternative
10518 (N : Node_Id; Val : Node_Id); -- Node1
10520 procedure Set_Triggering_Statement
10521 (N : Node_Id; Val : Node_Id); -- Node1
10523 procedure Set_TSS_Elist
10524 (N : Node_Id; Val : Elist_Id); -- Elist3
10526 procedure Set_Type_Definition
10527 (N : Node_Id; Val : Node_Id); -- Node3
10530 (N : Node_Id; Val : Node_Id); -- Node2
10532 procedure Set_Unknown_Discriminants_Present
10533 (N : Node_Id; Val : Boolean := True); -- Flag13
10535 procedure Set_Unreferenced_In_Spec
10536 (N : Node_Id; Val : Boolean := True); -- Flag7
10538 procedure Set_Variant_Part
10539 (N : Node_Id; Val : Node_Id); -- Node4
10541 procedure Set_Variants
10542 (N : Node_Id; Val : List_Id); -- List1
10544 procedure Set_Visible_Declarations
10545 (N : Node_Id; Val : List_Id); -- List2
10547 procedure Set_Uninitialized_Variable
10548 (N : Node_Id; Val : Node_Id); -- Node3
10550 procedure Set_Used_Operations
10551 (N : Node_Id; Val : Elist_Id); -- Elist5
10553 procedure Set_Was_Originally_Stub
10554 (N : Node_Id; Val : Boolean := True); -- Flag13
10556 procedure Set_Withed_Body
10557 (N : Node_Id; Val : Node_Id); -- Node1
10559 -------------------------
10560 -- Iterator Procedures --
10561 -------------------------
10563 -- The call to Next_xxx (N) is equivalent to N := Next_xxx (N)
10565 procedure Next_Entity (N : in out Node_Id);
10566 procedure Next_Named_Actual (N : in out Node_Id);
10567 procedure Next_Rep_Item (N : in out Node_Id);
10568 procedure Next_Use_Clause (N : in out Node_Id);
10570 -------------------------------------------
10571 -- Miscellaneous Tree Access Subprograms --
10572 -------------------------------------------
10574 function End_Location (N : Node_Id) return Source_Ptr;
10575 -- N is an N_If_Statement or N_Case_Statement node, and this function
10576 -- returns the location of the IF token in the END IF sequence by
10577 -- translating the value of the End_Span field.
10579 procedure Set_End_Location (N : Node_Id; S : Source_Ptr);
10580 -- N is an N_If_Statement or N_Case_Statement node. This procedure sets
10581 -- the End_Span field to correspond to the given value S. In other words,
10582 -- End_Span is set to the difference between S and Sloc (N), the starting
10585 function Get_Pragma_Arg (Arg : Node_Id) return Node_Id;
10586 -- Given an argument to a pragma Arg, this function returns the expression
10587 -- for the argument. This is Arg itself, or, in the case where Arg is a
10588 -- pragma argument association node, the expression from this node.
10590 --------------------------------
10591 -- Node_Kind Membership Tests --
10592 --------------------------------
10594 -- The following functions allow a convenient notation for testing whether
10595 -- a Node_Kind value matches any one of a list of possible values. In each
10596 -- case True is returned if the given T argument is equal to any of the V
10597 -- arguments. Note that there is a similar set of functions defined in
10598 -- Atree where the first argument is a Node_Id whose Nkind field is tested.
10603 V2 : Node_Kind) return Boolean;
10609 V3 : Node_Kind) return Boolean;
10616 V4 : Node_Kind) return Boolean;
10624 V5 : Node_Kind) return Boolean;
10633 V6 : Node_Kind) return Boolean;
10643 V7 : Node_Kind) return Boolean;
10654 V8 : Node_Kind) return Boolean;
10666 V9 : Node_Kind) return Boolean;
10668 pragma Inline (Nkind_In);
10669 -- Inline all above functions
10671 -----------------------
10672 -- Utility Functions --
10673 -----------------------
10675 function Pragma_Name (N : Node_Id) return Name_Id;
10676 pragma Inline (Pragma_Name);
10677 -- Convenient function to obtain Chars field of Pragma_Identifier
10679 -----------------------------
10680 -- Syntactic Parent Tables --
10681 -----------------------------
10683 -- These tables show for each node, and for each of the five fields,
10684 -- whether the corresponding field is syntactic (True) or semantic (False).
10685 -- Unused entries are also set to False.
10687 subtype Field_Num is Natural range 1 .. 5;
10689 Is_Syntactic_Field : constant array (Node_Kind, Field_Num) of Boolean := (
10691 -- Following entries can be built automatically from the sinfo sources
10692 -- using the makeisf utility (currently this program is in spitbol).
10695 (1 => True, -- Chars (Name1)
10696 2 => False, -- Original_Discriminant (Node2-Sem)
10697 3 => False, -- unused
10698 4 => False, -- Entity (Node4-Sem)
10699 5 => False), -- Etype (Node5-Sem)
10701 N_Integer_Literal =>
10702 (1 => False, -- unused
10703 2 => False, -- Original_Entity (Node2-Sem)
10704 3 => True, -- Intval (Uint3)
10705 4 => False, -- unused
10706 5 => False), -- Etype (Node5-Sem)
10709 (1 => False, -- unused
10710 2 => False, -- Original_Entity (Node2-Sem)
10711 3 => True, -- Realval (Ureal3)
10712 4 => False, -- Corresponding_Integer_Value (Uint4-Sem)
10713 5 => False), -- Etype (Node5-Sem)
10715 N_Character_Literal =>
10716 (1 => True, -- Chars (Name1)
10717 2 => True, -- Char_Literal_Value (Uint2)
10718 3 => False, -- unused
10719 4 => False, -- Entity (Node4-Sem)
10720 5 => False), -- Etype (Node5-Sem)
10722 N_String_Literal =>
10723 (1 => False, -- unused
10724 2 => False, -- unused
10725 3 => True, -- Strval (Str3)
10726 4 => False, -- unused
10727 5 => False), -- Etype (Node5-Sem)
10730 (1 => False, -- Next_Pragma (Node1-Sem)
10731 2 => True, -- Pragma_Argument_Associations (List2)
10732 3 => False, -- unused
10733 4 => True, -- Pragma_Identifier (Node4)
10734 5 => False), -- Next_Rep_Item (Node5-Sem)
10736 N_Pragma_Argument_Association =>
10737 (1 => True, -- Chars (Name1)
10738 2 => False, -- unused
10739 3 => True, -- Expression (Node3)
10740 4 => False, -- unused
10741 5 => False), -- unused
10743 N_Defining_Identifier =>
10744 (1 => True, -- Chars (Name1)
10745 2 => False, -- Next_Entity (Node2-Sem)
10746 3 => False, -- Scope (Node3-Sem)
10747 4 => False, -- unused
10748 5 => False), -- Etype (Node5-Sem)
10750 N_Full_Type_Declaration =>
10751 (1 => True, -- Defining_Identifier (Node1)
10752 2 => False, -- unused
10753 3 => True, -- Type_Definition (Node3)
10754 4 => True, -- Discriminant_Specifications (List4)
10755 5 => False), -- unused
10757 N_Subtype_Declaration =>
10758 (1 => True, -- Defining_Identifier (Node1)
10759 2 => False, -- unused
10760 3 => False, -- unused
10761 4 => False, -- Generic_Parent_Type (Node4-Sem)
10762 5 => True), -- Subtype_Indication (Node5)
10764 N_Subtype_Indication =>
10765 (1 => False, -- unused
10766 2 => False, -- unused
10767 3 => True, -- Constraint (Node3)
10768 4 => True, -- Subtype_Mark (Node4)
10769 5 => False), -- Etype (Node5-Sem)
10771 N_Object_Declaration =>
10772 (1 => True, -- Defining_Identifier (Node1)
10773 2 => False, -- Handler_List_Entry (Node2-Sem)
10774 3 => True, -- Expression (Node3)
10775 4 => True, -- Object_Definition (Node4)
10776 5 => False), -- Corresponding_Generic_Association (Node5-Sem)
10778 N_Number_Declaration =>
10779 (1 => True, -- Defining_Identifier (Node1)
10780 2 => False, -- unused
10781 3 => True, -- Expression (Node3)
10782 4 => False, -- unused
10783 5 => False), -- unused
10785 N_Derived_Type_Definition =>
10786 (1 => False, -- unused
10787 2 => True, -- Interface_List (List2)
10788 3 => True, -- Record_Extension_Part (Node3)
10789 4 => False, -- unused
10790 5 => True), -- Subtype_Indication (Node5)
10792 N_Range_Constraint =>
10793 (1 => False, -- unused
10794 2 => False, -- unused
10795 3 => False, -- unused
10796 4 => True, -- Range_Expression (Node4)
10797 5 => False), -- unused
10800 (1 => True, -- Low_Bound (Node1)
10801 2 => True, -- High_Bound (Node2)
10802 3 => False, -- unused
10803 4 => False, -- unused
10804 5 => False), -- Etype (Node5-Sem)
10806 N_Enumeration_Type_Definition =>
10807 (1 => True, -- Literals (List1)
10808 2 => False, -- unused
10809 3 => False, -- unused
10810 4 => True, -- End_Label (Node4)
10811 5 => False), -- unused
10813 N_Defining_Character_Literal =>
10814 (1 => True, -- Chars (Name1)
10815 2 => False, -- Next_Entity (Node2-Sem)
10816 3 => False, -- Scope (Node3-Sem)
10817 4 => False, -- unused
10818 5 => False), -- Etype (Node5-Sem)
10820 N_Signed_Integer_Type_Definition =>
10821 (1 => True, -- Low_Bound (Node1)
10822 2 => True, -- High_Bound (Node2)
10823 3 => False, -- unused
10824 4 => False, -- unused
10825 5 => False), -- unused
10827 N_Modular_Type_Definition =>
10828 (1 => False, -- unused
10829 2 => False, -- unused
10830 3 => True, -- Expression (Node3)
10831 4 => False, -- unused
10832 5 => False), -- unused
10834 N_Floating_Point_Definition =>
10835 (1 => False, -- unused
10836 2 => True, -- Digits_Expression (Node2)
10837 3 => False, -- unused
10838 4 => True, -- Real_Range_Specification (Node4)
10839 5 => False), -- unused
10841 N_Real_Range_Specification =>
10842 (1 => True, -- Low_Bound (Node1)
10843 2 => True, -- High_Bound (Node2)
10844 3 => False, -- unused
10845 4 => False, -- unused
10846 5 => False), -- unused
10848 N_Ordinary_Fixed_Point_Definition =>
10849 (1 => False, -- unused
10850 2 => False, -- unused
10851 3 => True, -- Delta_Expression (Node3)
10852 4 => True, -- Real_Range_Specification (Node4)
10853 5 => False), -- unused
10855 N_Decimal_Fixed_Point_Definition =>
10856 (1 => False, -- unused
10857 2 => True, -- Digits_Expression (Node2)
10858 3 => True, -- Delta_Expression (Node3)
10859 4 => True, -- Real_Range_Specification (Node4)
10860 5 => False), -- unused
10862 N_Digits_Constraint =>
10863 (1 => False, -- unused
10864 2 => True, -- Digits_Expression (Node2)
10865 3 => False, -- unused
10866 4 => True, -- Range_Constraint (Node4)
10867 5 => False), -- unused
10869 N_Unconstrained_Array_Definition =>
10870 (1 => False, -- unused
10871 2 => True, -- Subtype_Marks (List2)
10872 3 => False, -- unused
10873 4 => True, -- Component_Definition (Node4)
10874 5 => False), -- unused
10876 N_Constrained_Array_Definition =>
10877 (1 => False, -- unused
10878 2 => True, -- Discrete_Subtype_Definitions (List2)
10879 3 => False, -- unused
10880 4 => True, -- Component_Definition (Node4)
10881 5 => False), -- unused
10883 N_Component_Definition =>
10884 (1 => False, -- unused
10885 2 => False, -- unused
10886 3 => True, -- Access_Definition (Node3)
10887 4 => False, -- unused
10888 5 => True), -- Subtype_Indication (Node5)
10890 N_Discriminant_Specification =>
10891 (1 => True, -- Defining_Identifier (Node1)
10892 2 => False, -- unused
10893 3 => True, -- Expression (Node3)
10894 4 => False, -- unused
10895 5 => True), -- Discriminant_Type (Node5)
10897 N_Index_Or_Discriminant_Constraint =>
10898 (1 => True, -- Constraints (List1)
10899 2 => False, -- unused
10900 3 => False, -- unused
10901 4 => False, -- unused
10902 5 => False), -- unused
10904 N_Discriminant_Association =>
10905 (1 => True, -- Selector_Names (List1)
10906 2 => False, -- unused
10907 3 => True, -- Expression (Node3)
10908 4 => False, -- unused
10909 5 => False), -- unused
10911 N_Record_Definition =>
10912 (1 => True, -- Component_List (Node1)
10913 2 => True, -- Interface_List (List2)
10914 3 => False, -- unused
10915 4 => True, -- End_Label (Node4)
10916 5 => False), -- unused
10918 N_Component_List =>
10919 (1 => False, -- unused
10920 2 => False, -- unused
10921 3 => True, -- Component_Items (List3)
10922 4 => True, -- Variant_Part (Node4)
10923 5 => False), -- unused
10925 N_Component_Declaration =>
10926 (1 => True, -- Defining_Identifier (Node1)
10927 2 => False, -- unused
10928 3 => True, -- Expression (Node3)
10929 4 => True, -- Component_Definition (Node4)
10930 5 => False), -- unused
10933 (1 => True, -- Variants (List1)
10934 2 => True, -- Name (Node2)
10935 3 => False, -- unused
10936 4 => False, -- unused
10937 5 => False), -- unused
10940 (1 => True, -- Component_List (Node1)
10941 2 => False, -- Enclosing_Variant (Node2-Sem)
10942 3 => False, -- Present_Expr (Uint3-Sem)
10943 4 => True, -- Discrete_Choices (List4)
10944 5 => False), -- Dcheck_Function (Node5-Sem)
10947 (1 => False, -- Others_Discrete_Choices (List1-Sem)
10948 2 => False, -- unused
10949 3 => False, -- unused
10950 4 => False, -- unused
10951 5 => False), -- unused
10953 N_Access_To_Object_Definition =>
10954 (1 => False, -- unused
10955 2 => False, -- unused
10956 3 => False, -- unused
10957 4 => False, -- unused
10958 5 => True), -- Subtype_Indication (Node5)
10960 N_Access_Function_Definition =>
10961 (1 => False, -- unused
10962 2 => False, -- unused
10963 3 => True, -- Parameter_Specifications (List3)
10964 4 => True, -- Result_Definition (Node4)
10965 5 => False), -- unused
10967 N_Access_Procedure_Definition =>
10968 (1 => False, -- unused
10969 2 => False, -- unused
10970 3 => True, -- Parameter_Specifications (List3)
10971 4 => False, -- unused
10972 5 => False), -- unused
10974 N_Access_Definition =>
10975 (1 => False, -- unused
10976 2 => False, -- unused
10977 3 => True, -- Access_To_Subprogram_Definition (Node3)
10978 4 => True, -- Subtype_Mark (Node4)
10979 5 => False), -- unused
10981 N_Incomplete_Type_Declaration =>
10982 (1 => True, -- Defining_Identifier (Node1)
10983 2 => False, -- unused
10984 3 => False, -- unused
10985 4 => True, -- Discriminant_Specifications (List4)
10986 5 => False), -- Premature_Use
10988 N_Explicit_Dereference =>
10989 (1 => False, -- unused
10990 2 => False, -- unused
10991 3 => True, -- Prefix (Node3)
10992 4 => False, -- Actual_Designated_Subtype (Node4-Sem)
10993 5 => False), -- Etype (Node5-Sem)
10995 N_Indexed_Component =>
10996 (1 => True, -- Expressions (List1)
10997 2 => False, -- unused
10998 3 => True, -- Prefix (Node3)
10999 4 => False, -- Generalized_Indexing (Node4-Sem)
11000 5 => False), -- Etype (Node5-Sem)
11003 (1 => False, -- unused
11004 2 => False, -- unused
11005 3 => True, -- Prefix (Node3)
11006 4 => True, -- Discrete_Range (Node4)
11007 5 => False), -- Etype (Node5-Sem)
11009 N_Selected_Component =>
11010 (1 => False, -- unused
11011 2 => True, -- Selector_Name (Node2)
11012 3 => True, -- Prefix (Node3)
11013 4 => False, -- unused
11014 5 => False), -- Etype (Node5-Sem)
11016 N_Attribute_Reference =>
11017 (1 => True, -- Expressions (List1)
11018 2 => True, -- Attribute_Name (Name2)
11019 3 => True, -- Prefix (Node3)
11020 4 => False, -- Entity (Node4-Sem)
11021 5 => False), -- Etype (Node5-Sem)
11024 (1 => True, -- Expressions (List1)
11025 2 => True, -- Component_Associations (List2)
11026 3 => False, -- Aggregate_Bounds (Node3-Sem)
11027 4 => False, -- unused
11028 5 => False), -- Etype (Node5-Sem)
11030 N_Component_Association =>
11031 (1 => True, -- Choices (List1)
11032 2 => False, -- Loop_Actions (List2-Sem)
11033 3 => True, -- Expression (Node3)
11034 4 => False, -- unused
11035 5 => False), -- unused
11037 N_Extension_Aggregate =>
11038 (1 => True, -- Expressions (List1)
11039 2 => True, -- Component_Associations (List2)
11040 3 => True, -- Ancestor_Part (Node3)
11041 4 => False, -- unused
11042 5 => False), -- Etype (Node5-Sem)
11045 (1 => False, -- unused
11046 2 => False, -- unused
11047 3 => False, -- unused
11048 4 => False, -- unused
11049 5 => False), -- Etype (Node5-Sem)
11052 (1 => False, -- Actions (List1-Sem)
11053 2 => True, -- Left_Opnd (Node2)
11054 3 => True, -- Right_Opnd (Node3)
11055 4 => False, -- unused
11056 5 => False), -- Etype (Node5-Sem)
11059 (1 => False, -- Actions (List1-Sem)
11060 2 => True, -- Left_Opnd (Node2)
11061 3 => True, -- Right_Opnd (Node3)
11062 4 => False, -- unused
11063 5 => False), -- Etype (Node5-Sem)
11066 (1 => False, -- unused
11067 2 => True, -- Left_Opnd (Node2)
11068 3 => True, -- Right_Opnd (Node3)
11069 4 => True, -- Alternatives (List4)
11070 5 => False), -- Etype (Node5-Sem)
11073 (1 => False, -- unused
11074 2 => True, -- Left_Opnd (Node2)
11075 3 => True, -- Right_Opnd (Node3)
11076 4 => True, -- Alternatives (List4)
11077 5 => False), -- Etype (Node5-Sem)
11080 (1 => True, -- Chars (Name1)
11081 2 => True, -- Left_Opnd (Node2)
11082 3 => True, -- Right_Opnd (Node3)
11083 4 => False, -- Entity (Node4-Sem)
11084 5 => False), -- Etype (Node5-Sem)
11087 (1 => True, -- Chars (Name1)
11088 2 => True, -- Left_Opnd (Node2)
11089 3 => True, -- Right_Opnd (Node3)
11090 4 => False, -- Entity (Node4-Sem)
11091 5 => False), -- Etype (Node5-Sem)
11094 (1 => True, -- Chars (Name1)
11095 2 => True, -- Left_Opnd (Node2)
11096 3 => True, -- Right_Opnd (Node3)
11097 4 => False, -- Entity (Node4-Sem)
11098 5 => False), -- Etype (Node5-Sem)
11101 (1 => True, -- Chars (Name1)
11102 2 => True, -- Left_Opnd (Node2)
11103 3 => True, -- Right_Opnd (Node3)
11104 4 => False, -- Entity (Node4-Sem)
11105 5 => False), -- Etype (Node5-Sem)
11108 (1 => True, -- Chars (Name1)
11109 2 => True, -- Left_Opnd (Node2)
11110 3 => True, -- Right_Opnd (Node3)
11111 4 => False, -- Entity (Node4-Sem)
11112 5 => False), -- Etype (Node5-Sem)
11115 (1 => True, -- Chars (Name1)
11116 2 => True, -- Left_Opnd (Node2)
11117 3 => True, -- Right_Opnd (Node3)
11118 4 => False, -- Entity (Node4-Sem)
11119 5 => False), -- Etype (Node5-Sem)
11122 (1 => True, -- Chars (Name1)
11123 2 => True, -- Left_Opnd (Node2)
11124 3 => True, -- Right_Opnd (Node3)
11125 4 => False, -- Entity (Node4-Sem)
11126 5 => False), -- Etype (Node5-Sem)
11129 (1 => True, -- Chars (Name1)
11130 2 => True, -- Left_Opnd (Node2)
11131 3 => True, -- Right_Opnd (Node3)
11132 4 => False, -- Entity (Node4-Sem)
11133 5 => False), -- Etype (Node5-Sem)
11136 (1 => True, -- Chars (Name1)
11137 2 => True, -- Left_Opnd (Node2)
11138 3 => True, -- Right_Opnd (Node3)
11139 4 => False, -- Entity (Node4-Sem)
11140 5 => False), -- Etype (Node5-Sem)
11143 (1 => True, -- Chars (Name1)
11144 2 => True, -- Left_Opnd (Node2)
11145 3 => True, -- Right_Opnd (Node3)
11146 4 => False, -- Entity (Node4-Sem)
11147 5 => False), -- Etype (Node5-Sem)
11150 (1 => True, -- Chars (Name1)
11151 2 => True, -- Left_Opnd (Node2)
11152 3 => True, -- Right_Opnd (Node3)
11153 4 => False, -- Entity (Node4-Sem)
11154 5 => False), -- Etype (Node5-Sem)
11157 (1 => True, -- Chars (Name1)
11158 2 => True, -- Left_Opnd (Node2)
11159 3 => True, -- Right_Opnd (Node3)
11160 4 => False, -- Entity (Node4-Sem)
11161 5 => False), -- Etype (Node5-Sem)
11164 (1 => True, -- Chars (Name1)
11165 2 => True, -- Left_Opnd (Node2)
11166 3 => True, -- Right_Opnd (Node3)
11167 4 => False, -- Entity (Node4-Sem)
11168 5 => False), -- Etype (Node5-Sem)
11171 (1 => True, -- Chars (Name1)
11172 2 => True, -- Left_Opnd (Node2)
11173 3 => True, -- Right_Opnd (Node3)
11174 4 => False, -- Entity (Node4-Sem)
11175 5 => False), -- Etype (Node5-Sem)
11178 (1 => True, -- Chars (Name1)
11179 2 => True, -- Left_Opnd (Node2)
11180 3 => True, -- Right_Opnd (Node3)
11181 4 => False, -- Entity (Node4-Sem)
11182 5 => False), -- Etype (Node5-Sem)
11185 (1 => True, -- Chars (Name1)
11186 2 => True, -- Left_Opnd (Node2)
11187 3 => True, -- Right_Opnd (Node3)
11188 4 => False, -- Entity (Node4-Sem)
11189 5 => False), -- Etype (Node5-Sem)
11192 (1 => True, -- Chars (Name1)
11193 2 => True, -- Left_Opnd (Node2)
11194 3 => True, -- Right_Opnd (Node3)
11195 4 => False, -- Entity (Node4-Sem)
11196 5 => False), -- Etype (Node5-Sem)
11199 (1 => True, -- Chars (Name1)
11200 2 => False, -- unused
11201 3 => True, -- Right_Opnd (Node3)
11202 4 => False, -- Entity (Node4-Sem)
11203 5 => False), -- Etype (Node5-Sem)
11206 (1 => True, -- Chars (Name1)
11207 2 => False, -- unused
11208 3 => True, -- Right_Opnd (Node3)
11209 4 => False, -- Entity (Node4-Sem)
11210 5 => False), -- Etype (Node5-Sem)
11213 (1 => True, -- Chars (Name1)
11214 2 => False, -- unused
11215 3 => True, -- Right_Opnd (Node3)
11216 4 => False, -- Entity (Node4-Sem)
11217 5 => False), -- Etype (Node5-Sem)
11220 (1 => True, -- Chars (Name1)
11221 2 => False, -- unused
11222 3 => True, -- Right_Opnd (Node3)
11223 4 => False, -- Entity (Node4-Sem)
11224 5 => False), -- Etype (Node5-Sem)
11226 N_Type_Conversion =>
11227 (1 => False, -- unused
11228 2 => False, -- unused
11229 3 => True, -- Expression (Node3)
11230 4 => True, -- Subtype_Mark (Node4)
11231 5 => False), -- Etype (Node5-Sem)
11233 N_Qualified_Expression =>
11234 (1 => False, -- unused
11235 2 => False, -- unused
11236 3 => True, -- Expression (Node3)
11237 4 => True, -- Subtype_Mark (Node4)
11238 5 => False), -- Etype (Node5-Sem)
11240 N_Quantified_Expression =>
11241 (1 => True, -- Condition (Node1)
11242 2 => True, -- Iterator_Specification
11243 3 => False, -- unused
11244 4 => True, -- Loop_Parameter_Specification (Node4)
11245 5 => False), -- Etype (Node5-Sem)
11248 (1 => False, -- Storage_Pool (Node1-Sem)
11249 2 => False, -- Procedure_To_Call (Node2-Sem)
11250 3 => True, -- Expression (Node3)
11251 4 => True, -- Subpool_Handle_Name (Node4)
11252 5 => False), -- Etype (Node5-Sem)
11254 N_Null_Statement =>
11255 (1 => False, -- unused
11256 2 => False, -- unused
11257 3 => False, -- unused
11258 4 => False, -- unused
11259 5 => False), -- unused
11262 (1 => True, -- Identifier (Node1)
11263 2 => False, -- unused
11264 3 => False, -- unused
11265 4 => False, -- unused
11266 5 => False), -- unused
11268 N_Assignment_Statement =>
11269 (1 => False, -- unused
11270 2 => True, -- Name (Node2)
11271 3 => True, -- Expression (Node3)
11272 4 => False, -- unused
11273 5 => False), -- unused
11276 (1 => True, -- Condition (Node1)
11277 2 => True, -- Then_Statements (List2)
11278 3 => True, -- Elsif_Parts (List3)
11279 4 => True, -- Else_Statements (List4)
11280 5 => True), -- End_Span (Uint5)
11283 (1 => True, -- Condition (Node1)
11284 2 => True, -- Then_Statements (List2)
11285 3 => False, -- Condition_Actions (List3-Sem)
11286 4 => False, -- unused
11287 5 => False), -- unused
11289 N_Case_Expression =>
11290 (1 => False, -- unused
11291 2 => False, -- unused
11292 3 => True, -- Expression (Node3)
11293 4 => True, -- Alternatives (List4)
11294 5 => False), -- unused
11296 N_Case_Expression_Alternative =>
11297 (1 => False, -- Actions (List1-Sem)
11298 2 => False, -- unused
11299 3 => True, -- Statements (List3)
11300 4 => True, -- Expression (Node4)
11301 5 => False), -- unused
11303 N_Case_Statement =>
11304 (1 => False, -- unused
11305 2 => False, -- unused
11306 3 => True, -- Expression (Node3)
11307 4 => True, -- Alternatives (List4)
11308 5 => True), -- End_Span (Uint5)
11310 N_Case_Statement_Alternative =>
11311 (1 => False, -- unused
11312 2 => False, -- unused
11313 3 => True, -- Statements (List3)
11314 4 => True, -- Discrete_Choices (List4)
11315 5 => False), -- unused
11317 N_Loop_Statement =>
11318 (1 => True, -- Identifier (Node1)
11319 2 => True, -- Iteration_Scheme (Node2)
11320 3 => True, -- Statements (List3)
11321 4 => True, -- End_Label (Node4)
11322 5 => False), -- unused
11324 N_Iteration_Scheme =>
11325 (1 => True, -- Condition (Node1)
11326 2 => True, -- Iterator_Specification (Node2)
11327 3 => False, -- Condition_Actions (List3-Sem)
11328 4 => True, -- Loop_Parameter_Specification (Node4)
11329 5 => False), -- unused
11331 N_Loop_Parameter_Specification =>
11332 (1 => True, -- Defining_Identifier (Node1)
11333 2 => False, -- unused
11334 3 => False, -- unused
11335 4 => True, -- Discrete_Subtype_Definition (Node4)
11336 5 => False), -- unused
11338 N_Iterator_Specification =>
11339 (1 => True, -- Defining_Identifier (Node1)
11340 2 => True, -- Name (Node2)
11341 3 => False, -- Unused
11342 4 => False, -- Unused
11343 5 => True), -- Subtype_Indication (Node5)
11345 N_Block_Statement =>
11346 (1 => True, -- Identifier (Node1)
11347 2 => True, -- Declarations (List2)
11348 3 => False, -- Activation_Chain_Entity (Node3-Sem)
11349 4 => True, -- Handled_Statement_Sequence (Node4)
11350 5 => False), -- unused
11352 N_Exit_Statement =>
11353 (1 => True, -- Condition (Node1)
11354 2 => True, -- Name (Node2)
11355 3 => False, -- unused
11356 4 => False, -- unused
11357 5 => False), -- unused
11359 N_Goto_Statement =>
11360 (1 => False, -- unused
11361 2 => True, -- Name (Node2)
11362 3 => False, -- unused
11363 4 => False, -- unused
11364 5 => False), -- unused
11366 N_Subprogram_Declaration =>
11367 (1 => True, -- Specification (Node1)
11368 2 => False, -- unused
11369 3 => False, -- Body_To_Inline (Node3-Sem)
11370 4 => False, -- Parent_Spec (Node4-Sem)
11371 5 => False), -- Corresponding_Body (Node5-Sem)
11373 N_Abstract_Subprogram_Declaration =>
11374 (1 => True, -- Specification (Node1)
11375 2 => False, -- unused
11376 3 => False, -- unused
11377 4 => False, -- unused
11378 5 => False), -- unused
11380 N_Function_Specification =>
11381 (1 => True, -- Defining_Unit_Name (Node1)
11382 2 => False, -- Elaboration_Boolean (Node2-Sem)
11383 3 => True, -- Parameter_Specifications (List3)
11384 4 => True, -- Result_Definition (Node4)
11385 5 => False), -- Generic_Parent (Node5-Sem)
11387 N_Procedure_Specification =>
11388 (1 => True, -- Defining_Unit_Name (Node1)
11389 2 => False, -- Elaboration_Boolean (Node2-Sem)
11390 3 => True, -- Parameter_Specifications (List3)
11391 4 => False, -- unused
11392 5 => False), -- Generic_Parent (Node5-Sem)
11395 (1 => True, -- Identifier (Node1)
11396 2 => True, -- Name (Node2)
11397 3 => False, -- unused
11398 4 => False, -- unused
11399 5 => False), -- unused
11401 N_Defining_Program_Unit_Name =>
11402 (1 => True, -- Defining_Identifier (Node1)
11403 2 => True, -- Name (Node2)
11404 3 => False, -- unused
11405 4 => False, -- unused
11406 5 => False), -- unused
11408 N_Operator_Symbol =>
11409 (1 => True, -- Chars (Name1)
11410 2 => False, -- unused
11411 3 => True, -- Strval (Str3)
11412 4 => False, -- Entity (Node4-Sem)
11413 5 => False), -- Etype (Node5-Sem)
11415 N_Defining_Operator_Symbol =>
11416 (1 => True, -- Chars (Name1)
11417 2 => False, -- Next_Entity (Node2-Sem)
11418 3 => False, -- Scope (Node3-Sem)
11419 4 => False, -- unused
11420 5 => False), -- Etype (Node5-Sem)
11422 N_Parameter_Specification =>
11423 (1 => True, -- Defining_Identifier (Node1)
11424 2 => True, -- Parameter_Type (Node2)
11425 3 => True, -- Expression (Node3)
11426 4 => False, -- unused
11427 5 => False), -- Default_Expression (Node5-Sem)
11429 N_Subprogram_Body =>
11430 (1 => True, -- Specification (Node1)
11431 2 => True, -- Declarations (List2)
11432 3 => False, -- Activation_Chain_Entity (Node3-Sem)
11433 4 => True, -- Handled_Statement_Sequence (Node4)
11434 5 => False), -- Corresponding_Spec (Node5-Sem)
11436 N_Expression_Function =>
11437 (1 => True, -- Specification (Node1)
11438 2 => False, -- unused
11439 3 => True, -- Expression (Node3)
11440 4 => False, -- unused
11441 5 => False), -- unused
11443 N_Procedure_Call_Statement =>
11444 (1 => False, -- Controlling_Argument (Node1-Sem)
11445 2 => True, -- Name (Node2)
11446 3 => True, -- Parameter_Associations (List3)
11447 4 => False, -- First_Named_Actual (Node4-Sem)
11448 5 => False), -- Etype (Node5-Sem)
11451 (1 => False, -- Controlling_Argument (Node1-Sem)
11452 2 => True, -- Name (Node2)
11453 3 => True, -- Parameter_Associations (List3)
11454 4 => False, -- First_Named_Actual (Node4-Sem)
11455 5 => False), -- Etype (Node5-Sem)
11457 N_Parameter_Association =>
11458 (1 => False, -- unused
11459 2 => True, -- Selector_Name (Node2)
11460 3 => True, -- Explicit_Actual_Parameter (Node3)
11461 4 => False, -- Next_Named_Actual (Node4-Sem)
11462 5 => False), -- unused
11464 N_Simple_Return_Statement =>
11465 (1 => False, -- Storage_Pool (Node1-Sem)
11466 2 => False, -- Procedure_To_Call (Node2-Sem)
11467 3 => True, -- Expression (Node3)
11468 4 => False, -- unused
11469 5 => False), -- Return_Statement_Entity (Node5-Sem)
11471 N_Extended_Return_Statement =>
11472 (1 => False, -- Storage_Pool (Node1-Sem)
11473 2 => False, -- Procedure_To_Call (Node2-Sem)
11474 3 => True, -- Return_Object_Declarations (List3)
11475 4 => True, -- Handled_Statement_Sequence (Node4)
11476 5 => False), -- Return_Statement_Entity (Node5-Sem)
11478 N_Package_Declaration =>
11479 (1 => True, -- Specification (Node1)
11480 2 => False, -- unused
11481 3 => False, -- Activation_Chain_Entity (Node3-Sem)
11482 4 => False, -- Parent_Spec (Node4-Sem)
11483 5 => False), -- Corresponding_Body (Node5-Sem)
11485 N_Package_Specification =>
11486 (1 => True, -- Defining_Unit_Name (Node1)
11487 2 => True, -- Visible_Declarations (List2)
11488 3 => True, -- Private_Declarations (List3)
11489 4 => True, -- End_Label (Node4)
11490 5 => False), -- Generic_Parent (Node5-Sem)
11493 (1 => True, -- Defining_Unit_Name (Node1)
11494 2 => True, -- Declarations (List2)
11495 3 => False, -- unused
11496 4 => True, -- Handled_Statement_Sequence (Node4)
11497 5 => False), -- Corresponding_Spec (Node5-Sem)
11499 N_Private_Type_Declaration =>
11500 (1 => True, -- Defining_Identifier (Node1)
11501 2 => False, -- unused
11502 3 => False, -- unused
11503 4 => True, -- Discriminant_Specifications (List4)
11504 5 => False), -- unused
11506 N_Private_Extension_Declaration =>
11507 (1 => True, -- Defining_Identifier (Node1)
11508 2 => True, -- Interface_List (List2)
11509 3 => False, -- unused
11510 4 => True, -- Discriminant_Specifications (List4)
11511 5 => True), -- Subtype_Indication (Node5)
11513 N_Use_Package_Clause =>
11514 (1 => False, -- unused
11515 2 => True, -- Names (List2)
11516 3 => False, -- Next_Use_Clause (Node3-Sem)
11517 4 => False, -- Hidden_By_Use_Clause (Elist4-Sem)
11518 5 => False), -- unused
11520 N_Use_Type_Clause =>
11521 (1 => False, -- unused
11522 2 => True, -- Subtype_Marks (List2)
11523 3 => False, -- Next_Use_Clause (Node3-Sem)
11524 4 => False, -- Hidden_By_Use_Clause (Elist4-Sem)
11525 5 => False), -- unused
11527 N_Object_Renaming_Declaration =>
11528 (1 => True, -- Defining_Identifier (Node1)
11529 2 => True, -- Name (Node2)
11530 3 => True, -- Access_Definition (Node3)
11531 4 => True, -- Subtype_Mark (Node4)
11532 5 => False), -- Corresponding_Generic_Association (Node5-Sem)
11534 N_Exception_Renaming_Declaration =>
11535 (1 => True, -- Defining_Identifier (Node1)
11536 2 => True, -- Name (Node2)
11537 3 => False, -- unused
11538 4 => False, -- unused
11539 5 => False), -- unused
11541 N_Package_Renaming_Declaration =>
11542 (1 => True, -- Defining_Unit_Name (Node1)
11543 2 => True, -- Name (Node2)
11544 3 => False, -- unused
11545 4 => False, -- Parent_Spec (Node4-Sem)
11546 5 => False), -- unused
11548 N_Subprogram_Renaming_Declaration =>
11549 (1 => True, -- Specification (Node1)
11550 2 => True, -- Name (Node2)
11551 3 => False, -- Corresponding_Formal_Spec (Node3-Sem)
11552 4 => False, -- Parent_Spec (Node4-Sem)
11553 5 => False), -- Corresponding_Spec (Node5-Sem)
11555 N_Generic_Package_Renaming_Declaration =>
11556 (1 => True, -- Defining_Unit_Name (Node1)
11557 2 => True, -- Name (Node2)
11558 3 => False, -- unused
11559 4 => False, -- Parent_Spec (Node4-Sem)
11560 5 => False), -- unused
11562 N_Generic_Procedure_Renaming_Declaration =>
11563 (1 => True, -- Defining_Unit_Name (Node1)
11564 2 => True, -- Name (Node2)
11565 3 => False, -- unused
11566 4 => False, -- Parent_Spec (Node4-Sem)
11567 5 => False), -- unused
11569 N_Generic_Function_Renaming_Declaration =>
11570 (1 => True, -- Defining_Unit_Name (Node1)
11571 2 => True, -- Name (Node2)
11572 3 => False, -- unused
11573 4 => False, -- Parent_Spec (Node4-Sem)
11574 5 => False), -- unused
11576 N_Task_Type_Declaration =>
11577 (1 => True, -- Defining_Identifier (Node1)
11578 2 => True, -- Interface_List (List2)
11579 3 => True, -- Task_Definition (Node3)
11580 4 => True, -- Discriminant_Specifications (List4)
11581 5 => False), -- Corresponding_Body (Node5-Sem)
11583 N_Single_Task_Declaration =>
11584 (1 => True, -- Defining_Identifier (Node1)
11585 2 => True, -- Interface_List (List2)
11586 3 => True, -- Task_Definition (Node3)
11587 4 => False, -- unused
11588 5 => False), -- unused
11590 N_Task_Definition =>
11591 (1 => False, -- unused
11592 2 => True, -- Visible_Declarations (List2)
11593 3 => True, -- Private_Declarations (List3)
11594 4 => True, -- End_Label (Node4)
11595 5 => False), -- unused
11598 (1 => True, -- Defining_Identifier (Node1)
11599 2 => True, -- Declarations (List2)
11600 3 => False, -- Activation_Chain_Entity (Node3-Sem)
11601 4 => True, -- Handled_Statement_Sequence (Node4)
11602 5 => False), -- Corresponding_Spec (Node5-Sem)
11604 N_Protected_Type_Declaration =>
11605 (1 => True, -- Defining_Identifier (Node1)
11606 2 => True, -- Interface_List (List2)
11607 3 => True, -- Protected_Definition (Node3)
11608 4 => True, -- Discriminant_Specifications (List4)
11609 5 => False), -- Corresponding_Body (Node5-Sem)
11611 N_Single_Protected_Declaration =>
11612 (1 => True, -- Defining_Identifier (Node1)
11613 2 => True, -- Interface_List (List2)
11614 3 => True, -- Protected_Definition (Node3)
11615 4 => False, -- unused
11616 5 => False), -- unused
11618 N_Protected_Definition =>
11619 (1 => False, -- unused
11620 2 => True, -- Visible_Declarations (List2)
11621 3 => True, -- Private_Declarations (List3)
11622 4 => True, -- End_Label (Node4)
11623 5 => False), -- unused
11625 N_Protected_Body =>
11626 (1 => True, -- Defining_Identifier (Node1)
11627 2 => True, -- Declarations (List2)
11628 3 => False, -- unused
11629 4 => True, -- End_Label (Node4)
11630 5 => False), -- Corresponding_Spec (Node5-Sem)
11632 N_Entry_Declaration =>
11633 (1 => True, -- Defining_Identifier (Node1)
11634 2 => False, -- unused
11635 3 => True, -- Parameter_Specifications (List3)
11636 4 => True, -- Discrete_Subtype_Definition (Node4)
11637 5 => False), -- Corresponding_Body (Node5-Sem)
11639 N_Accept_Statement =>
11640 (1 => True, -- Entry_Direct_Name (Node1)
11641 2 => True, -- Declarations (List2)
11642 3 => True, -- Parameter_Specifications (List3)
11643 4 => True, -- Handled_Statement_Sequence (Node4)
11644 5 => True), -- Entry_Index (Node5)
11647 (1 => True, -- Defining_Identifier (Node1)
11648 2 => True, -- Declarations (List2)
11649 3 => False, -- Activation_Chain_Entity (Node3-Sem)
11650 4 => True, -- Handled_Statement_Sequence (Node4)
11651 5 => True), -- Entry_Body_Formal_Part (Node5)
11653 N_Entry_Body_Formal_Part =>
11654 (1 => True, -- Condition (Node1)
11655 2 => False, -- unused
11656 3 => True, -- Parameter_Specifications (List3)
11657 4 => True, -- Entry_Index_Specification (Node4)
11658 5 => False), -- unused
11660 N_Entry_Index_Specification =>
11661 (1 => True, -- Defining_Identifier (Node1)
11662 2 => False, -- unused
11663 3 => False, -- unused
11664 4 => True, -- Discrete_Subtype_Definition (Node4)
11665 5 => False), -- unused
11667 N_Entry_Call_Statement =>
11668 (1 => False, -- unused
11669 2 => True, -- Name (Node2)
11670 3 => True, -- Parameter_Associations (List3)
11671 4 => False, -- First_Named_Actual (Node4-Sem)
11672 5 => False), -- unused
11674 N_Requeue_Statement =>
11675 (1 => False, -- unused
11676 2 => True, -- Name (Node2)
11677 3 => False, -- unused
11678 4 => False, -- unused
11679 5 => False), -- unused
11681 N_Delay_Until_Statement =>
11682 (1 => False, -- unused
11683 2 => False, -- unused
11684 3 => True, -- Expression (Node3)
11685 4 => False, -- unused
11686 5 => False), -- unused
11688 N_Delay_Relative_Statement =>
11689 (1 => False, -- unused
11690 2 => False, -- unused
11691 3 => True, -- Expression (Node3)
11692 4 => False, -- unused
11693 5 => False), -- unused
11695 N_Selective_Accept =>
11696 (1 => True, -- Select_Alternatives (List1)
11697 2 => False, -- unused
11698 3 => False, -- unused
11699 4 => True, -- Else_Statements (List4)
11700 5 => False), -- unused
11702 N_Accept_Alternative =>
11703 (1 => True, -- Condition (Node1)
11704 2 => True, -- Accept_Statement (Node2)
11705 3 => True, -- Statements (List3)
11706 4 => True, -- Pragmas_Before (List4)
11707 5 => False), -- Accept_Handler_Records (List5-Sem)
11709 N_Delay_Alternative =>
11710 (1 => True, -- Condition (Node1)
11711 2 => True, -- Delay_Statement (Node2)
11712 3 => True, -- Statements (List3)
11713 4 => True, -- Pragmas_Before (List4)
11714 5 => False), -- unused
11716 N_Terminate_Alternative =>
11717 (1 => True, -- Condition (Node1)
11718 2 => False, -- unused
11719 3 => False, -- unused
11720 4 => True, -- Pragmas_Before (List4)
11721 5 => True), -- Pragmas_After (List5)
11723 N_Timed_Entry_Call =>
11724 (1 => True, -- Entry_Call_Alternative (Node1)
11725 2 => False, -- unused
11726 3 => False, -- unused
11727 4 => True, -- Delay_Alternative (Node4)
11728 5 => False), -- unused
11730 N_Entry_Call_Alternative =>
11731 (1 => True, -- Entry_Call_Statement (Node1)
11732 2 => False, -- unused
11733 3 => True, -- Statements (List3)
11734 4 => True, -- Pragmas_Before (List4)
11735 5 => False), -- unused
11737 N_Conditional_Entry_Call =>
11738 (1 => True, -- Entry_Call_Alternative (Node1)
11739 2 => False, -- unused
11740 3 => False, -- unused
11741 4 => True, -- Else_Statements (List4)
11742 5 => False), -- unused
11744 N_Asynchronous_Select =>
11745 (1 => True, -- Triggering_Alternative (Node1)
11746 2 => True, -- Abortable_Part (Node2)
11747 3 => False, -- unused
11748 4 => False, -- unused
11749 5 => False), -- unused
11751 N_Triggering_Alternative =>
11752 (1 => True, -- Triggering_Statement (Node1)
11753 2 => False, -- unused
11754 3 => True, -- Statements (List3)
11755 4 => True, -- Pragmas_Before (List4)
11756 5 => False), -- unused
11758 N_Abortable_Part =>
11759 (1 => False, -- unused
11760 2 => False, -- unused
11761 3 => True, -- Statements (List3)
11762 4 => False, -- unused
11763 5 => False), -- unused
11765 N_Abort_Statement =>
11766 (1 => False, -- unused
11767 2 => True, -- Names (List2)
11768 3 => False, -- unused
11769 4 => False, -- unused
11770 5 => False), -- unused
11772 N_Compilation_Unit =>
11773 (1 => True, -- Context_Items (List1)
11774 2 => True, -- Unit (Node2)
11775 3 => False, -- First_Inlined_Subprogram (Node3-Sem)
11776 4 => False, -- Library_Unit (Node4-Sem)
11777 5 => True), -- Aux_Decls_Node (Node5)
11779 N_Compilation_Unit_Aux =>
11780 (1 => True, -- Actions (List1)
11781 2 => True, -- Declarations (List2)
11782 3 => False, -- Default_Storage_Pool (Node3)
11783 4 => True, -- Config_Pragmas (List4)
11784 5 => True), -- Pragmas_After (List5)
11787 (1 => False, -- unused
11788 2 => True, -- Name (Node2)
11789 3 => False, -- unused
11790 4 => False, -- Library_Unit (Node4-Sem)
11791 5 => False), -- Corresponding_Spec (Node5-Sem)
11793 N_Subprogram_Body_Stub =>
11794 (1 => True, -- Specification (Node1)
11795 2 => False, -- Corresponding_Spec_Of_Stub (Node2-Sem)
11796 3 => False, -- unused
11797 4 => False, -- Library_Unit (Node4-Sem)
11798 5 => False), -- Corresponding_Body (Node5-Sem)
11800 N_Package_Body_Stub =>
11801 (1 => True, -- Defining_Identifier (Node1)
11802 2 => False, -- Corresponding_Spec_Of_Stub (Node2-Sem)
11803 3 => False, -- unused
11804 4 => False, -- Library_Unit (Node4-Sem)
11805 5 => False), -- Corresponding_Body (Node5-Sem)
11807 N_Task_Body_Stub =>
11808 (1 => True, -- Defining_Identifier (Node1)
11809 2 => False, -- Corresponding_Spec_Of_Stub (Node2-Sem)
11810 3 => False, -- unused
11811 4 => False, -- Library_Unit (Node4-Sem)
11812 5 => False), -- Corresponding_Body (Node5-Sem)
11814 N_Protected_Body_Stub =>
11815 (1 => True, -- Defining_Identifier (Node1)
11816 2 => False, -- Corresponding_Spec_Of_Stub (Node2-Sem)
11817 3 => False, -- unused
11818 4 => False, -- Library_Unit (Node4-Sem)
11819 5 => False), -- Corresponding_Body (Node5-Sem)
11822 (1 => True, -- Proper_Body (Node1)
11823 2 => True, -- Name (Node2)
11824 3 => False, -- Corresponding_Stub (Node3-Sem)
11825 4 => False, -- unused
11826 5 => False), -- unused
11828 N_Exception_Declaration =>
11829 (1 => True, -- Defining_Identifier (Node1)
11830 2 => False, -- unused
11831 3 => False, -- Expression (Node3-Sem)
11832 4 => False, -- unused
11833 5 => False), -- unused
11835 N_Handled_Sequence_Of_Statements =>
11836 (1 => True, -- At_End_Proc (Node1)
11837 2 => False, -- First_Real_Statement (Node2-Sem)
11838 3 => True, -- Statements (List3)
11839 4 => True, -- End_Label (Node4)
11840 5 => True), -- Exception_Handlers (List5)
11842 N_Exception_Handler =>
11843 (1 => False, -- Local_Raise_Statements (Elist1)
11844 2 => True, -- Choice_Parameter (Node2)
11845 3 => True, -- Statements (List3)
11846 4 => True, -- Exception_Choices (List4)
11847 5 => False), -- Exception_Label (Node5)
11849 N_Raise_Statement =>
11850 (1 => False, -- unused
11851 2 => True, -- Name (Node2)
11852 3 => True, -- Expression (Node3)
11853 4 => False, -- unused
11854 5 => False), -- unused
11856 N_Raise_Expression =>
11857 (1 => False, -- unused
11858 2 => True, -- Name (Node2)
11859 3 => True, -- Expression (Node3)
11860 4 => False, -- unused
11861 5 => False), -- Etype (Node5-Sem)
11863 N_Generic_Subprogram_Declaration =>
11864 (1 => True, -- Specification (Node1)
11865 2 => True, -- Generic_Formal_Declarations (List2)
11866 3 => False, -- unused
11867 4 => False, -- Parent_Spec (Node4-Sem)
11868 5 => False), -- Corresponding_Body (Node5-Sem)
11870 N_Generic_Package_Declaration =>
11871 (1 => True, -- Specification (Node1)
11872 2 => True, -- Generic_Formal_Declarations (List2)
11873 3 => False, -- Activation_Chain_Entity (Node3-Sem)
11874 4 => False, -- Parent_Spec (Node4-Sem)
11875 5 => False), -- Corresponding_Body (Node5-Sem)
11877 N_Package_Instantiation =>
11878 (1 => True, -- Defining_Unit_Name (Node1)
11879 2 => True, -- Name (Node2)
11880 3 => True, -- Generic_Associations (List3)
11881 4 => False, -- Parent_Spec (Node4-Sem)
11882 5 => False), -- Instance_Spec (Node5-Sem)
11884 N_Procedure_Instantiation =>
11885 (1 => True, -- Defining_Unit_Name (Node1)
11886 2 => True, -- Name (Node2)
11887 3 => True, -- Generic_Associations (List3)
11888 4 => False, -- Parent_Spec (Node4-Sem)
11889 5 => False), -- Instance_Spec (Node5-Sem)
11891 N_Function_Instantiation =>
11892 (1 => True, -- Defining_Unit_Name (Node1)
11893 2 => True, -- Name (Node2)
11894 3 => True, -- Generic_Associations (List3)
11895 4 => False, -- Parent_Spec (Node4-Sem)
11896 5 => False), -- Instance_Spec (Node5-Sem)
11898 N_Generic_Association =>
11899 (1 => True, -- Explicit_Generic_Actual_Parameter (Node1)
11900 2 => True, -- Selector_Name (Node2)
11901 3 => False, -- unused
11902 4 => False, -- unused
11903 5 => False), -- unused
11905 N_Formal_Object_Declaration =>
11906 (1 => True, -- Defining_Identifier (Node1)
11907 2 => False, -- unused
11908 3 => True, -- Access_Definition (Node3)
11909 4 => True, -- Subtype_Mark (Node4)
11910 5 => True), -- Default_Expression (Node5)
11912 N_Formal_Type_Declaration =>
11913 (1 => True, -- Defining_Identifier (Node1)
11914 2 => False, -- unused
11915 3 => True, -- Formal_Type_Definition (Node3)
11916 4 => True, -- Discriminant_Specifications (List4)
11917 5 => False), -- unused
11919 N_Formal_Private_Type_Definition =>
11920 (1 => False, -- unused
11921 2 => False, -- unused
11922 3 => False, -- unused
11923 4 => False, -- unused
11924 5 => False), -- unused
11926 N_Formal_Incomplete_Type_Definition =>
11927 (1 => False, -- unused
11928 2 => False, -- unused
11929 3 => False, -- unused
11930 4 => False, -- unused
11931 5 => False), -- unused
11933 N_Formal_Derived_Type_Definition =>
11934 (1 => False, -- unused
11935 2 => True, -- Interface_List (List2)
11936 3 => False, -- unused
11937 4 => True, -- Subtype_Mark (Node4)
11938 5 => False), -- unused
11940 N_Formal_Discrete_Type_Definition =>
11941 (1 => False, -- unused
11942 2 => False, -- unused
11943 3 => False, -- unused
11944 4 => False, -- unused
11945 5 => False), -- unused
11947 N_Formal_Signed_Integer_Type_Definition =>
11948 (1 => False, -- unused
11949 2 => False, -- unused
11950 3 => False, -- unused
11951 4 => False, -- unused
11952 5 => False), -- unused
11954 N_Formal_Modular_Type_Definition =>
11955 (1 => False, -- unused
11956 2 => False, -- unused
11957 3 => False, -- unused
11958 4 => False, -- unused
11959 5 => False), -- unused
11961 N_Formal_Floating_Point_Definition =>
11962 (1 => False, -- unused
11963 2 => False, -- unused
11964 3 => False, -- unused
11965 4 => False, -- unused
11966 5 => False), -- unused
11968 N_Formal_Ordinary_Fixed_Point_Definition =>
11969 (1 => False, -- unused
11970 2 => False, -- unused
11971 3 => False, -- unused
11972 4 => False, -- unused
11973 5 => False), -- unused
11975 N_Formal_Decimal_Fixed_Point_Definition =>
11976 (1 => False, -- unused
11977 2 => False, -- unused
11978 3 => False, -- unused
11979 4 => False, -- unused
11980 5 => False), -- unused
11982 N_Formal_Concrete_Subprogram_Declaration =>
11983 (1 => True, -- Specification (Node1)
11984 2 => True, -- Default_Name (Node2)
11985 3 => False, -- unused
11986 4 => False, -- unused
11987 5 => False), -- unused
11989 N_Formal_Abstract_Subprogram_Declaration =>
11990 (1 => True, -- Specification (Node1)
11991 2 => True, -- Default_Name (Node2)
11992 3 => False, -- unused
11993 4 => False, -- unused
11994 5 => False), -- unused
11996 N_Formal_Package_Declaration =>
11997 (1 => True, -- Defining_Identifier (Node1)
11998 2 => True, -- Name (Node2)
11999 3 => True, -- Generic_Associations (List3)
12000 4 => False, -- unused
12001 5 => False), -- Instance_Spec (Node5-Sem)
12003 N_Attribute_Definition_Clause =>
12004 (1 => True, -- Chars (Name1)
12005 2 => True, -- Name (Node2)
12006 3 => True, -- Expression (Node3)
12007 4 => False, -- unused
12008 5 => False), -- Next_Rep_Item (Node5-Sem)
12010 N_Aspect_Specification =>
12011 (1 => True, -- Identifier (Node1)
12012 2 => False, -- Aspect_Rep_Item (Node2-Sem)
12013 3 => True, -- Expression (Node3)
12014 4 => False, -- Entity (Node4-Sem)
12015 5 => False), -- Next_Rep_Item (Node5-Sem)
12017 N_Enumeration_Representation_Clause =>
12018 (1 => True, -- Identifier (Node1)
12019 2 => False, -- unused
12020 3 => True, -- Array_Aggregate (Node3)
12021 4 => False, -- unused
12022 5 => False), -- Next_Rep_Item (Node5-Sem)
12024 N_Record_Representation_Clause =>
12025 (1 => True, -- Identifier (Node1)
12026 2 => True, -- Mod_Clause (Node2)
12027 3 => True, -- Component_Clauses (List3)
12028 4 => False, -- unused
12029 5 => False), -- Next_Rep_Item (Node5-Sem)
12031 N_Component_Clause =>
12032 (1 => True, -- Component_Name (Node1)
12033 2 => True, -- Position (Node2)
12034 3 => True, -- First_Bit (Node3)
12035 4 => True, -- Last_Bit (Node4)
12036 5 => False), -- unused
12038 N_Code_Statement =>
12039 (1 => False, -- unused
12040 2 => False, -- unused
12041 3 => True, -- Expression (Node3)
12042 4 => False, -- unused
12043 5 => False), -- unused
12045 N_Op_Rotate_Left =>
12046 (1 => True, -- Chars (Name1)
12047 2 => True, -- Left_Opnd (Node2)
12048 3 => True, -- Right_Opnd (Node3)
12049 4 => False, -- Entity (Node4-Sem)
12050 5 => False), -- Etype (Node5-Sem)
12052 N_Op_Rotate_Right =>
12053 (1 => True, -- Chars (Name1)
12054 2 => True, -- Left_Opnd (Node2)
12055 3 => True, -- Right_Opnd (Node3)
12056 4 => False, -- Entity (Node4-Sem)
12057 5 => False), -- Etype (Node5-Sem)
12060 (1 => True, -- Chars (Name1)
12061 2 => True, -- Left_Opnd (Node2)
12062 3 => True, -- Right_Opnd (Node3)
12063 4 => False, -- Entity (Node4-Sem)
12064 5 => False), -- Etype (Node5-Sem)
12066 N_Op_Shift_Right_Arithmetic =>
12067 (1 => True, -- Chars (Name1)
12068 2 => True, -- Left_Opnd (Node2)
12069 3 => True, -- Right_Opnd (Node3)
12070 4 => False, -- Entity (Node4-Sem)
12071 5 => False), -- Etype (Node5-Sem)
12073 N_Op_Shift_Right =>
12074 (1 => True, -- Chars (Name1)
12075 2 => True, -- Left_Opnd (Node2)
12076 3 => True, -- Right_Opnd (Node3)
12077 4 => False, -- Entity (Node4-Sem)
12078 5 => False), -- Etype (Node5-Sem)
12080 N_Delta_Constraint =>
12081 (1 => False, -- unused
12082 2 => False, -- unused
12083 3 => True, -- Delta_Expression (Node3)
12084 4 => True, -- Range_Constraint (Node4)
12085 5 => False), -- unused
12088 (1 => True, -- Identifier (Node1)
12089 2 => False, -- unused
12090 3 => True, -- Expression (Node3)
12091 4 => False, -- unused
12092 5 => False), -- unused
12095 (1 => False, -- unused
12096 2 => False, -- unused
12097 3 => True, -- Expression (Node3)
12098 4 => True, -- Pragmas_Before (List4)
12099 5 => False), -- unused
12102 (1 => True, -- Expressions (List1)
12103 2 => False, -- Then_Actions (List2-Sem)
12104 3 => False, -- Else_Actions (List3-Sem)
12105 4 => False, -- unused
12106 5 => False), -- Etype (Node5-Sem)
12108 N_Compound_Statement =>
12109 (1 => True, -- Actions (List1)
12110 2 => False, -- unused
12111 3 => False, -- unused
12112 4 => False, -- unused
12113 5 => False), -- unused
12116 (1 => False, -- Pre_Post_Conditions (Node1)
12117 2 => False, -- Contract_Test_Cases (Node2)
12118 3 => False, -- Classifications (Node3)
12119 4 => False, -- unused
12120 5 => False), -- unused
12123 (1 => True, -- Chars (Name1)
12124 2 => True, -- Selector_Name (Node2)
12125 3 => True, -- Prefix (Node3)
12126 4 => False, -- Entity (Node4-Sem)
12127 5 => False), -- Etype (Node5-Sem)
12129 N_Expression_With_Actions =>
12130 (1 => True, -- Actions (List1)
12131 2 => False, -- unused
12132 3 => True, -- Expression (Node3)
12133 4 => False, -- unused
12134 5 => False), -- unused
12136 N_Free_Statement =>
12137 (1 => False, -- Storage_Pool (Node1-Sem)
12138 2 => False, -- Procedure_To_Call (Node2-Sem)
12139 3 => True, -- Expression (Node3)
12140 4 => False, -- Actual_Designated_Subtype (Node4-Sem)
12141 5 => False), -- unused
12144 (1 => True, -- Actions (List1)
12145 2 => False, -- Access_Types_To_Process (Elist2-Sem)
12146 3 => False, -- TSS_Elist (Elist3-Sem)
12147 4 => False, -- Entity (Node4-Sem)
12148 5 => False), -- First_Subtype_Link (Node5-Sem)
12150 N_Freeze_Generic_Entity =>
12151 (1 => False, -- unused
12152 2 => False, -- unused
12153 3 => False, -- unused
12154 4 => False, -- Entity (Node4-Sem)
12155 5 => False), -- unused
12157 N_Implicit_Label_Declaration =>
12158 (1 => True, -- Defining_Identifier (Node1)
12159 2 => False, -- Label_Construct (Node2-Sem)
12160 3 => False, -- unused
12161 4 => False, -- unused
12162 5 => False), -- unused
12164 N_Itype_Reference =>
12165 (1 => False, -- Itype (Node1-Sem)
12166 2 => False, -- unused
12167 3 => False, -- unused
12168 4 => False, -- unused
12169 5 => False), -- unused
12171 N_Raise_Constraint_Error =>
12172 (1 => True, -- Condition (Node1)
12173 2 => False, -- unused
12174 3 => True, -- Reason (Uint3)
12175 4 => False, -- unused
12176 5 => False), -- Etype (Node5-Sem)
12178 N_Raise_Program_Error =>
12179 (1 => True, -- Condition (Node1)
12180 2 => False, -- unused
12181 3 => True, -- Reason (Uint3)
12182 4 => False, -- unused
12183 5 => False), -- Etype (Node5-Sem)
12185 N_Raise_Storage_Error =>
12186 (1 => True, -- Condition (Node1)
12187 2 => False, -- unused
12188 3 => True, -- Reason (Uint3)
12189 4 => False, -- unused
12190 5 => False), -- Etype (Node5-Sem)
12192 N_Push_Constraint_Error_Label =>
12193 (1 => False, -- unused
12194 2 => False, -- unused
12195 3 => False, -- unused
12196 4 => False, -- unused
12197 5 => False), -- unused
12199 N_Push_Program_Error_Label =>
12200 (1 => False, -- Exception_Label
12201 2 => False, -- unused
12202 3 => False, -- unused
12203 4 => False, -- unused
12204 5 => False), -- Exception_Label
12206 N_Push_Storage_Error_Label =>
12207 (1 => False, -- Exception_Label
12208 2 => False, -- unused
12209 3 => False, -- unused
12210 4 => False, -- unused
12211 5 => False), -- Exception_Label
12213 N_Pop_Constraint_Error_Label =>
12214 (1 => False, -- unused
12215 2 => False, -- unused
12216 3 => False, -- unused
12217 4 => False, -- unused
12218 5 => False), -- unused
12220 N_Pop_Program_Error_Label =>
12221 (1 => False, -- unused
12222 2 => False, -- unused
12223 3 => False, -- unused
12224 4 => False, -- unused
12225 5 => False), -- unused
12227 N_Pop_Storage_Error_Label =>
12228 (1 => False, -- unused
12229 2 => False, -- unused
12230 3 => False, -- unused
12231 4 => False, -- unused
12232 5 => False), -- unused
12235 (1 => False, -- unused
12236 2 => False, -- unused
12237 3 => True, -- Prefix (Node3)
12238 4 => False, -- unused
12239 5 => False), -- Etype (Node5-Sem)
12241 N_Unchecked_Expression =>
12242 (1 => False, -- unused
12243 2 => False, -- unused
12244 3 => True, -- Expression (Node3)
12245 4 => False, -- unused
12246 5 => False), -- Etype (Node5-Sem)
12248 N_Unchecked_Type_Conversion =>
12249 (1 => False, -- unused
12250 2 => False, -- unused
12251 3 => True, -- Expression (Node3)
12252 4 => True, -- Subtype_Mark (Node4)
12253 5 => False), -- Etype (Node5-Sem)
12255 N_Validate_Unchecked_Conversion =>
12256 (1 => False, -- Source_Type (Node1-Sem)
12257 2 => False, -- Target_Type (Node2-Sem)
12258 3 => False, -- unused
12259 4 => False, -- unused
12260 5 => False), -- unused
12262 -- Entries for SCIL nodes
12264 N_SCIL_Dispatch_Table_Tag_Init =>
12265 (1 => False, -- unused
12266 2 => False, -- unused
12267 3 => False, -- unused
12268 4 => False, -- SCIL_Entity (Node4-Sem)
12269 5 => False), -- unused
12271 N_SCIL_Dispatching_Call =>
12272 (1 => False, -- unused
12273 2 => False, -- SCIL_Target_Prim (Node2-Sem)
12274 3 => False, -- unused
12275 4 => False, -- SCIL_Entity (Node4-Sem)
12276 5 => False), -- SCIL_Controlling_Tag (Node5-Sem)
12278 N_SCIL_Membership_Test =>
12279 (1 => False, -- unused
12280 2 => False, -- unused
12281 3 => False, -- unused
12282 4 => False, -- SCIL_Entity (Node4-Sem)
12283 5 => False), -- SCIL_Tag_Value (Node5-Sem)
12285 -- Entries for Empty, Error and Unused. Even thought these have a Chars
12286 -- field for debugging purposes, they are not really syntactic fields, so
12287 -- we mark all fields as unused.
12290 (1 => False, -- unused
12291 2 => False, -- unused
12292 3 => False, -- unused
12293 4 => False, -- unused
12294 5 => False), -- unused
12297 (1 => False, -- unused
12298 2 => False, -- unused
12299 3 => False, -- unused
12300 4 => False, -- unused
12301 5 => False), -- unused
12303 N_Unused_At_Start =>
12304 (1 => False, -- unused
12305 2 => False, -- unused
12306 3 => False, -- unused
12307 4 => False, -- unused
12308 5 => False), -- unused
12311 (1 => False, -- unused
12312 2 => False, -- unused
12313 3 => False, -- unused
12314 4 => False, -- unused
12315 5 => False)); -- unused
12317 --------------------
12318 -- Inline Pragmas --
12319 --------------------
12321 pragma Inline (ABE_Is_Certain);
12322 pragma Inline (Abort_Present);
12323 pragma Inline (Abortable_Part);
12324 pragma Inline (Abstract_Present);
12325 pragma Inline (Accept_Handler_Records);
12326 pragma Inline (Accept_Statement);
12327 pragma Inline (Access_Definition);
12328 pragma Inline (Access_To_Subprogram_Definition);
12329 pragma Inline (Access_Types_To_Process);
12330 pragma Inline (Actions);
12331 pragma Inline (Activation_Chain_Entity);
12332 pragma Inline (Acts_As_Spec);
12333 pragma Inline (Actual_Designated_Subtype);
12334 pragma Inline (Address_Warning_Posted);
12335 pragma Inline (Aggregate_Bounds);
12336 pragma Inline (Aliased_Present);
12337 pragma Inline (All_Others);
12338 pragma Inline (All_Present);
12339 pragma Inline (Alternatives);
12340 pragma Inline (Ancestor_Part);
12341 pragma Inline (Atomic_Sync_Required);
12342 pragma Inline (Array_Aggregate);
12343 pragma Inline (Aspect_Rep_Item);
12344 pragma Inline (Assignment_OK);
12345 pragma Inline (Associated_Node);
12346 pragma Inline (At_End_Proc);
12347 pragma Inline (Attribute_Name);
12348 pragma Inline (Aux_Decls_Node);
12349 pragma Inline (Backwards_OK);
12350 pragma Inline (Bad_Is_Detected);
12351 pragma Inline (Body_To_Inline);
12352 pragma Inline (Body_Required);
12353 pragma Inline (By_Ref);
12354 pragma Inline (Box_Present);
12355 pragma Inline (Char_Literal_Value);
12356 pragma Inline (Chars);
12357 pragma Inline (Check_Address_Alignment);
12358 pragma Inline (Choice_Parameter);
12359 pragma Inline (Choices);
12360 pragma Inline (Class_Present);
12361 pragma Inline (Classifications);
12362 pragma Inline (Comes_From_Extended_Return_Statement);
12363 pragma Inline (Compile_Time_Known_Aggregate);
12364 pragma Inline (Component_Associations);
12365 pragma Inline (Component_Clauses);
12366 pragma Inline (Component_Definition);
12367 pragma Inline (Component_Items);
12368 pragma Inline (Component_List);
12369 pragma Inline (Component_Name);
12370 pragma Inline (Componentwise_Assignment);
12371 pragma Inline (Condition);
12372 pragma Inline (Condition_Actions);
12373 pragma Inline (Config_Pragmas);
12374 pragma Inline (Constant_Present);
12375 pragma Inline (Constraint);
12376 pragma Inline (Constraints);
12377 pragma Inline (Context_Installed);
12378 pragma Inline (Context_Items);
12379 pragma Inline (Context_Pending);
12380 pragma Inline (Contract_Test_Cases);
12381 pragma Inline (Controlling_Argument);
12382 pragma Inline (Convert_To_Return_False);
12383 pragma Inline (Conversion_OK);
12384 pragma Inline (Corresponding_Aspect);
12385 pragma Inline (Corresponding_Body);
12386 pragma Inline (Corresponding_Formal_Spec);
12387 pragma Inline (Corresponding_Generic_Association);
12388 pragma Inline (Corresponding_Integer_Value);
12389 pragma Inline (Corresponding_Spec);
12390 pragma Inline (Corresponding_Spec_Of_Stub);
12391 pragma Inline (Corresponding_Stub);
12392 pragma Inline (Dcheck_Function);
12393 pragma Inline (Declarations);
12394 pragma Inline (Default_Expression);
12395 pragma Inline (Default_Storage_Pool);
12396 pragma Inline (Default_Name);
12397 pragma Inline (Defining_Identifier);
12398 pragma Inline (Defining_Unit_Name);
12399 pragma Inline (Delay_Alternative);
12400 pragma Inline (Delay_Statement);
12401 pragma Inline (Delta_Expression);
12402 pragma Inline (Digits_Expression);
12403 pragma Inline (Discr_Check_Funcs_Built);
12404 pragma Inline (Discrete_Choices);
12405 pragma Inline (Discrete_Range);
12406 pragma Inline (Discrete_Subtype_Definition);
12407 pragma Inline (Discrete_Subtype_Definitions);
12408 pragma Inline (Discriminant_Specifications);
12409 pragma Inline (Discriminant_Type);
12410 pragma Inline (Do_Accessibility_Check);
12411 pragma Inline (Do_Discriminant_Check);
12412 pragma Inline (Do_Length_Check);
12413 pragma Inline (Do_Division_Check);
12414 pragma Inline (Do_Overflow_Check);
12415 pragma Inline (Do_Range_Check);
12416 pragma Inline (Do_Storage_Check);
12417 pragma Inline (Do_Tag_Check);
12418 pragma Inline (Elaborate_Present);
12419 pragma Inline (Elaborate_All_Desirable);
12420 pragma Inline (Elaborate_All_Present);
12421 pragma Inline (Elaborate_Desirable);
12422 pragma Inline (Elaboration_Boolean);
12423 pragma Inline (Else_Actions);
12424 pragma Inline (Else_Statements);
12425 pragma Inline (Elsif_Parts);
12426 pragma Inline (Enclosing_Variant);
12427 pragma Inline (End_Label);
12428 pragma Inline (End_Span);
12429 pragma Inline (Entity);
12430 pragma Inline (Entity_Or_Associated_Node);
12431 pragma Inline (Entry_Body_Formal_Part);
12432 pragma Inline (Entry_Call_Alternative);
12433 pragma Inline (Entry_Call_Statement);
12434 pragma Inline (Entry_Direct_Name);
12435 pragma Inline (Entry_Index);
12436 pragma Inline (Entry_Index_Specification);
12437 pragma Inline (Etype);
12438 pragma Inline (Exception_Choices);
12439 pragma Inline (Exception_Handlers);
12440 pragma Inline (Exception_Junk);
12441 pragma Inline (Exception_Label);
12442 pragma Inline (Expansion_Delayed);
12443 pragma Inline (Explicit_Actual_Parameter);
12444 pragma Inline (Explicit_Generic_Actual_Parameter);
12445 pragma Inline (Expression);
12446 pragma Inline (Expressions);
12447 pragma Inline (First_Bit);
12448 pragma Inline (First_Inlined_Subprogram);
12449 pragma Inline (First_Name);
12450 pragma Inline (First_Named_Actual);
12451 pragma Inline (First_Real_Statement);
12452 pragma Inline (First_Subtype_Link);
12453 pragma Inline (Float_Truncate);
12454 pragma Inline (Formal_Type_Definition);
12455 pragma Inline (Forwards_OK);
12456 pragma Inline (From_Aspect_Specification);
12457 pragma Inline (From_At_End);
12458 pragma Inline (From_At_Mod);
12459 pragma Inline (From_Default);
12460 pragma Inline (Generalized_Indexing);
12461 pragma Inline (Generic_Associations);
12462 pragma Inline (Generic_Formal_Declarations);
12463 pragma Inline (Generic_Parent);
12464 pragma Inline (Generic_Parent_Type);
12465 pragma Inline (Handled_Statement_Sequence);
12466 pragma Inline (Handler_List_Entry);
12467 pragma Inline (Has_Created_Identifier);
12468 pragma Inline (Has_Dereference_Action);
12469 pragma Inline (Has_Dynamic_Length_Check);
12470 pragma Inline (Has_Dynamic_Range_Check);
12471 pragma Inline (Has_Init_Expression);
12472 pragma Inline (Has_Local_Raise);
12473 pragma Inline (Has_Self_Reference);
12474 pragma Inline (Has_SP_Choice);
12475 pragma Inline (Has_No_Elaboration_Code);
12476 pragma Inline (Has_Pragma_Suppress_All);
12477 pragma Inline (Has_Private_View);
12478 pragma Inline (Has_Relative_Deadline_Pragma);
12479 pragma Inline (Has_Storage_Size_Pragma);
12480 pragma Inline (Has_Wide_Character);
12481 pragma Inline (Has_Wide_Wide_Character);
12482 pragma Inline (Header_Size_Added);
12483 pragma Inline (Hidden_By_Use_Clause);
12484 pragma Inline (High_Bound);
12485 pragma Inline (Identifier);
12486 pragma Inline (Implicit_With);
12487 pragma Inline (Implicit_With_From_Instantiation);
12488 pragma Inline (Interface_List);
12489 pragma Inline (Interface_Present);
12490 pragma Inline (Includes_Infinities);
12491 pragma Inline (Import_Interface_Present);
12492 pragma Inline (In_Present);
12493 pragma Inline (Inherited_Discriminant);
12494 pragma Inline (Instance_Spec);
12495 pragma Inline (Intval);
12496 pragma Inline (Iterator_Specification);
12497 pragma Inline (Is_Accessibility_Actual);
12498 pragma Inline (Is_Asynchronous_Call_Block);
12499 pragma Inline (Is_Boolean_Aspect);
12500 pragma Inline (Is_Checked);
12501 pragma Inline (Is_Component_Left_Opnd);
12502 pragma Inline (Is_Component_Right_Opnd);
12503 pragma Inline (Is_Controlling_Actual);
12504 pragma Inline (Is_Delayed_Aspect);
12505 pragma Inline (Is_Disabled);
12506 pragma Inline (Is_Dynamic_Coextension);
12507 pragma Inline (Is_Elsif);
12508 pragma Inline (Is_Entry_Barrier_Function);
12509 pragma Inline (Is_Expanded_Build_In_Place_Call);
12510 pragma Inline (Is_Finalization_Wrapper);
12511 pragma Inline (Is_Folded_In_Parser);
12512 pragma Inline (Is_Ignored);
12513 pragma Inline (Is_In_Discriminant_Check);
12514 pragma Inline (Is_Machine_Number);
12515 pragma Inline (Is_Null_Loop);
12516 pragma Inline (Is_Overloaded);
12517 pragma Inline (Is_Power_Of_2_For_Shift);
12518 pragma Inline (Is_Prefixed_Call);
12519 pragma Inline (Is_Protected_Subprogram_Body);
12520 pragma Inline (Is_Static_Coextension);
12521 pragma Inline (Is_Static_Expression);
12522 pragma Inline (Is_Subprogram_Descriptor);
12523 pragma Inline (Is_Task_Allocation_Block);
12524 pragma Inline (Is_Task_Master);
12525 pragma Inline (Iteration_Scheme);
12526 pragma Inline (Itype);
12527 pragma Inline (Kill_Range_Check);
12528 pragma Inline (Last_Bit);
12529 pragma Inline (Last_Name);
12530 pragma Inline (Library_Unit);
12531 pragma Inline (Label_Construct);
12532 pragma Inline (Left_Opnd);
12533 pragma Inline (Limited_View_Installed);
12534 pragma Inline (Limited_Present);
12535 pragma Inline (Literals);
12536 pragma Inline (Local_Raise_Not_OK);
12537 pragma Inline (Local_Raise_Statements);
12538 pragma Inline (Loop_Actions);
12539 pragma Inline (Loop_Parameter_Specification);
12540 pragma Inline (Low_Bound);
12541 pragma Inline (Mod_Clause);
12542 pragma Inline (More_Ids);
12543 pragma Inline (Must_Be_Byte_Aligned);
12544 pragma Inline (Must_Not_Freeze);
12545 pragma Inline (Must_Not_Override);
12546 pragma Inline (Must_Override);
12547 pragma Inline (Name);
12548 pragma Inline (Names);
12549 pragma Inline (Next_Entity);
12550 pragma Inline (Next_Exit_Statement);
12551 pragma Inline (Next_Implicit_With);
12552 pragma Inline (Next_Named_Actual);
12553 pragma Inline (Next_Pragma);
12554 pragma Inline (Next_Rep_Item);
12555 pragma Inline (Next_Use_Clause);
12556 pragma Inline (No_Ctrl_Actions);
12557 pragma Inline (No_Elaboration_Check);
12558 pragma Inline (No_Entities_Ref_In_Spec);
12559 pragma Inline (No_Initialization);
12560 pragma Inline (No_Minimize_Eliminate);
12561 pragma Inline (No_Truncation);
12562 pragma Inline (Non_Aliased_Prefix);
12563 pragma Inline (Null_Present);
12564 pragma Inline (Null_Exclusion_Present);
12565 pragma Inline (Null_Exclusion_In_Return_Present);
12566 pragma Inline (Null_Record_Present);
12567 pragma Inline (Object_Definition);
12568 pragma Inline (Of_Present);
12569 pragma Inline (Original_Discriminant);
12570 pragma Inline (Original_Entity);
12571 pragma Inline (Others_Discrete_Choices);
12572 pragma Inline (Out_Present);
12573 pragma Inline (Parameter_Associations);
12574 pragma Inline (Parameter_Specifications);
12575 pragma Inline (Parameter_List_Truncated);
12576 pragma Inline (Parameter_Type);
12577 pragma Inline (Parent_Spec);
12578 pragma Inline (Position);
12579 pragma Inline (Pragma_Argument_Associations);
12580 pragma Inline (Pragma_Identifier);
12581 pragma Inline (Pragmas_After);
12582 pragma Inline (Pragmas_Before);
12583 pragma Inline (Pre_Post_Conditions);
12584 pragma Inline (Prefix);
12585 pragma Inline (Premature_Use);
12586 pragma Inline (Present_Expr);
12587 pragma Inline (Prev_Ids);
12588 pragma Inline (Print_In_Hex);
12589 pragma Inline (Private_Declarations);
12590 pragma Inline (Private_Present);
12591 pragma Inline (Procedure_To_Call);
12592 pragma Inline (Proper_Body);
12593 pragma Inline (Protected_Definition);
12594 pragma Inline (Protected_Present);
12595 pragma Inline (Raises_Constraint_Error);
12596 pragma Inline (Range_Constraint);
12597 pragma Inline (Range_Expression);
12598 pragma Inline (Real_Range_Specification);
12599 pragma Inline (Realval);
12600 pragma Inline (Reason);
12601 pragma Inline (Record_Extension_Part);
12602 pragma Inline (Redundant_Use);
12603 pragma Inline (Renaming_Exception);
12604 pragma Inline (Result_Definition);
12605 pragma Inline (Return_Object_Declarations);
12606 pragma Inline (Return_Statement_Entity);
12607 pragma Inline (Reverse_Present);
12608 pragma Inline (Right_Opnd);
12609 pragma Inline (Rounded_Result);
12610 pragma Inline (SCIL_Controlling_Tag);
12611 pragma Inline (SCIL_Entity);
12612 pragma Inline (SCIL_Tag_Value);
12613 pragma Inline (SCIL_Target_Prim);
12614 pragma Inline (Scope);
12615 pragma Inline (Select_Alternatives);
12616 pragma Inline (Selector_Name);
12617 pragma Inline (Selector_Names);
12618 pragma Inline (Shift_Count_OK);
12619 pragma Inline (Source_Type);
12620 pragma Inline (Specification);
12621 pragma Inline (Split_PPC);
12622 pragma Inline (Statements);
12623 pragma Inline (Storage_Pool);
12624 pragma Inline (Subpool_Handle_Name);
12625 pragma Inline (Strval);
12626 pragma Inline (Subtype_Indication);
12627 pragma Inline (Subtype_Mark);
12628 pragma Inline (Subtype_Marks);
12629 pragma Inline (Suppress_Assignment_Checks);
12630 pragma Inline (Suppress_Loop_Warnings);
12631 pragma Inline (Synchronized_Present);
12632 pragma Inline (Tagged_Present);
12633 pragma Inline (Target_Type);
12634 pragma Inline (Task_Definition);
12635 pragma Inline (Task_Present);
12636 pragma Inline (Then_Actions);
12637 pragma Inline (Then_Statements);
12638 pragma Inline (Triggering_Alternative);
12639 pragma Inline (Triggering_Statement);
12640 pragma Inline (Treat_Fixed_As_Integer);
12641 pragma Inline (TSS_Elist);
12642 pragma Inline (Type_Definition);
12643 pragma Inline (Unit);
12644 pragma Inline (Uninitialized_Variable);
12645 pragma Inline (Unknown_Discriminants_Present);
12646 pragma Inline (Unreferenced_In_Spec);
12647 pragma Inline (Variant_Part);
12648 pragma Inline (Variants);
12649 pragma Inline (Visible_Declarations);
12650 pragma Inline (Used_Operations);
12651 pragma Inline (Was_Originally_Stub);
12652 pragma Inline (Withed_Body);
12654 pragma Inline (Set_ABE_Is_Certain);
12655 pragma Inline (Set_Abort_Present);
12656 pragma Inline (Set_Abortable_Part);
12657 pragma Inline (Set_Abstract_Present);
12658 pragma Inline (Set_Accept_Handler_Records);
12659 pragma Inline (Set_Accept_Statement);
12660 pragma Inline (Set_Access_Definition);
12661 pragma Inline (Set_Access_To_Subprogram_Definition);
12662 pragma Inline (Set_Access_Types_To_Process);
12663 pragma Inline (Set_Actions);
12664 pragma Inline (Set_Activation_Chain_Entity);
12665 pragma Inline (Set_Acts_As_Spec);
12666 pragma Inline (Set_Actual_Designated_Subtype);
12667 pragma Inline (Set_Address_Warning_Posted);
12668 pragma Inline (Set_Aggregate_Bounds);
12669 pragma Inline (Set_Aliased_Present);
12670 pragma Inline (Set_All_Others);
12671 pragma Inline (Set_All_Present);
12672 pragma Inline (Set_Alternatives);
12673 pragma Inline (Set_Ancestor_Part);
12674 pragma Inline (Set_Array_Aggregate);
12675 pragma Inline (Set_Aspect_Rep_Item);
12676 pragma Inline (Set_Assignment_OK);
12677 pragma Inline (Set_Associated_Node);
12678 pragma Inline (Set_At_End_Proc);
12679 pragma Inline (Set_Atomic_Sync_Required);
12680 pragma Inline (Set_Attribute_Name);
12681 pragma Inline (Set_Aux_Decls_Node);
12682 pragma Inline (Set_Backwards_OK);
12683 pragma Inline (Set_Bad_Is_Detected);
12684 pragma Inline (Set_Body_Required);
12685 pragma Inline (Set_Body_To_Inline);
12686 pragma Inline (Set_Box_Present);
12687 pragma Inline (Set_By_Ref);
12688 pragma Inline (Set_Char_Literal_Value);
12689 pragma Inline (Set_Chars);
12690 pragma Inline (Set_Check_Address_Alignment);
12691 pragma Inline (Set_Choice_Parameter);
12692 pragma Inline (Set_Choices);
12693 pragma Inline (Set_Class_Present);
12694 pragma Inline (Set_Classifications);
12695 pragma Inline (Set_Comes_From_Extended_Return_Statement);
12696 pragma Inline (Set_Compile_Time_Known_Aggregate);
12697 pragma Inline (Set_Component_Associations);
12698 pragma Inline (Set_Component_Clauses);
12699 pragma Inline (Set_Component_Definition);
12700 pragma Inline (Set_Component_Items);
12701 pragma Inline (Set_Component_List);
12702 pragma Inline (Set_Component_Name);
12703 pragma Inline (Set_Componentwise_Assignment);
12704 pragma Inline (Set_Condition);
12705 pragma Inline (Set_Condition_Actions);
12706 pragma Inline (Set_Config_Pragmas);
12707 pragma Inline (Set_Constant_Present);
12708 pragma Inline (Set_Constraint);
12709 pragma Inline (Set_Constraints);
12710 pragma Inline (Set_Context_Installed);
12711 pragma Inline (Set_Context_Items);
12712 pragma Inline (Set_Context_Pending);
12713 pragma Inline (Set_Contract_Test_Cases);
12714 pragma Inline (Set_Controlling_Argument);
12715 pragma Inline (Set_Conversion_OK);
12716 pragma Inline (Set_Convert_To_Return_False);
12717 pragma Inline (Set_Corresponding_Aspect);
12718 pragma Inline (Set_Corresponding_Body);
12719 pragma Inline (Set_Corresponding_Formal_Spec);
12720 pragma Inline (Set_Corresponding_Generic_Association);
12721 pragma Inline (Set_Corresponding_Integer_Value);
12722 pragma Inline (Set_Corresponding_Spec);
12723 pragma Inline (Set_Corresponding_Spec_Of_Stub);
12724 pragma Inline (Set_Corresponding_Stub);
12725 pragma Inline (Set_Dcheck_Function);
12726 pragma Inline (Set_Declarations);
12727 pragma Inline (Set_Default_Expression);
12728 pragma Inline (Set_Default_Name);
12729 pragma Inline (Set_Default_Storage_Pool);
12730 pragma Inline (Set_Defining_Identifier);
12731 pragma Inline (Set_Defining_Unit_Name);
12732 pragma Inline (Set_Delay_Alternative);
12733 pragma Inline (Set_Delay_Statement);
12734 pragma Inline (Set_Delta_Expression);
12735 pragma Inline (Set_Digits_Expression);
12736 pragma Inline (Set_Discr_Check_Funcs_Built);
12737 pragma Inline (Set_Discrete_Choices);
12738 pragma Inline (Set_Discrete_Range);
12739 pragma Inline (Set_Discrete_Subtype_Definition);
12740 pragma Inline (Set_Discrete_Subtype_Definitions);
12741 pragma Inline (Set_Discriminant_Specifications);
12742 pragma Inline (Set_Discriminant_Type);
12743 pragma Inline (Set_Do_Accessibility_Check);
12744 pragma Inline (Set_Do_Discriminant_Check);
12745 pragma Inline (Set_Do_Division_Check);
12746 pragma Inline (Set_Do_Length_Check);
12747 pragma Inline (Set_Do_Overflow_Check);
12748 pragma Inline (Set_Do_Range_Check);
12749 pragma Inline (Set_Do_Storage_Check);
12750 pragma Inline (Set_Do_Tag_Check);
12751 pragma Inline (Set_Elaborate_All_Desirable);
12752 pragma Inline (Set_Elaborate_All_Present);
12753 pragma Inline (Set_Elaborate_Desirable);
12754 pragma Inline (Set_Elaborate_Present);
12755 pragma Inline (Set_Elaboration_Boolean);
12756 pragma Inline (Set_Else_Actions);
12757 pragma Inline (Set_Else_Statements);
12758 pragma Inline (Set_Elsif_Parts);
12759 pragma Inline (Set_Enclosing_Variant);
12760 pragma Inline (Set_End_Label);
12761 pragma Inline (Set_End_Span);
12762 pragma Inline (Set_Entity);
12763 pragma Inline (Set_Entry_Body_Formal_Part);
12764 pragma Inline (Set_Entry_Call_Alternative);
12765 pragma Inline (Set_Entry_Call_Statement);
12766 pragma Inline (Set_Entry_Direct_Name);
12767 pragma Inline (Set_Entry_Index);
12768 pragma Inline (Set_Entry_Index_Specification);
12769 pragma Inline (Set_Etype);
12770 pragma Inline (Set_Exception_Choices);
12771 pragma Inline (Set_Exception_Handlers);
12772 pragma Inline (Set_Exception_Junk);
12773 pragma Inline (Set_Exception_Label);
12774 pragma Inline (Set_Expansion_Delayed);
12775 pragma Inline (Set_Explicit_Actual_Parameter);
12776 pragma Inline (Set_Explicit_Generic_Actual_Parameter);
12777 pragma Inline (Set_Expression);
12778 pragma Inline (Set_Expressions);
12779 pragma Inline (Set_First_Bit);
12780 pragma Inline (Set_First_Inlined_Subprogram);
12781 pragma Inline (Set_First_Name);
12782 pragma Inline (Set_First_Named_Actual);
12783 pragma Inline (Set_First_Real_Statement);
12784 pragma Inline (Set_First_Subtype_Link);
12785 pragma Inline (Set_Float_Truncate);
12786 pragma Inline (Set_Formal_Type_Definition);
12787 pragma Inline (Set_Forwards_OK);
12788 pragma Inline (Set_From_Aspect_Specification);
12789 pragma Inline (Set_From_At_End);
12790 pragma Inline (Set_From_At_Mod);
12791 pragma Inline (Set_From_Default);
12792 pragma Inline (Set_Generalized_Indexing);
12793 pragma Inline (Set_Generic_Associations);
12794 pragma Inline (Set_Generic_Formal_Declarations);
12795 pragma Inline (Set_Generic_Parent);
12796 pragma Inline (Set_Generic_Parent_Type);
12797 pragma Inline (Set_Handled_Statement_Sequence);
12798 pragma Inline (Set_Handler_List_Entry);
12799 pragma Inline (Set_Has_Created_Identifier);
12800 pragma Inline (Set_Has_Dereference_Action);
12801 pragma Inline (Set_Has_Dynamic_Length_Check);
12802 pragma Inline (Set_Has_Dynamic_Range_Check);
12803 pragma Inline (Set_Has_Init_Expression);
12804 pragma Inline (Set_Has_Local_Raise);
12805 pragma Inline (Set_Has_No_Elaboration_Code);
12806 pragma Inline (Set_Has_Pragma_Suppress_All);
12807 pragma Inline (Set_Has_Private_View);
12808 pragma Inline (Set_Has_Relative_Deadline_Pragma);
12809 pragma Inline (Set_Has_Self_Reference);
12810 pragma Inline (Set_Has_SP_Choice);
12811 pragma Inline (Set_Has_Storage_Size_Pragma);
12812 pragma Inline (Set_Has_Wide_Character);
12813 pragma Inline (Set_Has_Wide_Wide_Character);
12814 pragma Inline (Set_Header_Size_Added);
12815 pragma Inline (Set_Hidden_By_Use_Clause);
12816 pragma Inline (Set_High_Bound);
12817 pragma Inline (Set_Identifier);
12818 pragma Inline (Set_Implicit_With);
12819 pragma Inline (Set_Import_Interface_Present);
12820 pragma Inline (Set_In_Present);
12821 pragma Inline (Set_Includes_Infinities);
12822 pragma Inline (Set_Inherited_Discriminant);
12823 pragma Inline (Set_Instance_Spec);
12824 pragma Inline (Set_Interface_List);
12825 pragma Inline (Set_Interface_Present);
12826 pragma Inline (Set_Intval);
12827 pragma Inline (Set_Is_Accessibility_Actual);
12828 pragma Inline (Set_Is_Asynchronous_Call_Block);
12829 pragma Inline (Set_Is_Boolean_Aspect);
12830 pragma Inline (Set_Is_Checked);
12831 pragma Inline (Set_Is_Component_Left_Opnd);
12832 pragma Inline (Set_Is_Component_Right_Opnd);
12833 pragma Inline (Set_Is_Controlling_Actual);
12834 pragma Inline (Set_Is_Delayed_Aspect);
12835 pragma Inline (Set_Is_Disabled);
12836 pragma Inline (Set_Is_Dynamic_Coextension);
12837 pragma Inline (Set_Is_Elsif);
12838 pragma Inline (Set_Is_Entry_Barrier_Function);
12839 pragma Inline (Set_Is_Expanded_Build_In_Place_Call);
12840 pragma Inline (Set_Is_Finalization_Wrapper);
12841 pragma Inline (Set_Is_Folded_In_Parser);
12842 pragma Inline (Set_Is_Ignored);
12843 pragma Inline (Set_Is_In_Discriminant_Check);
12844 pragma Inline (Set_Is_Machine_Number);
12845 pragma Inline (Set_Is_Null_Loop);
12846 pragma Inline (Set_Is_Overloaded);
12847 pragma Inline (Set_Is_Power_Of_2_For_Shift);
12848 pragma Inline (Set_Is_Prefixed_Call);
12849 pragma Inline (Set_Is_Protected_Subprogram_Body);
12850 pragma Inline (Set_Is_Static_Coextension);
12851 pragma Inline (Set_Is_Static_Expression);
12852 pragma Inline (Set_Is_Subprogram_Descriptor);
12853 pragma Inline (Set_Is_Task_Allocation_Block);
12854 pragma Inline (Set_Is_Task_Master);
12855 pragma Inline (Set_Iteration_Scheme);
12856 pragma Inline (Set_Iterator_Specification);
12857 pragma Inline (Set_Itype);
12858 pragma Inline (Set_Kill_Range_Check);
12859 pragma Inline (Set_Label_Construct);
12860 pragma Inline (Set_Last_Bit);
12861 pragma Inline (Set_Last_Name);
12862 pragma Inline (Set_Left_Opnd);
12863 pragma Inline (Set_Library_Unit);
12864 pragma Inline (Set_Limited_Present);
12865 pragma Inline (Set_Limited_View_Installed);
12866 pragma Inline (Set_Literals);
12867 pragma Inline (Set_Local_Raise_Not_OK);
12868 pragma Inline (Set_Local_Raise_Statements);
12869 pragma Inline (Set_Loop_Actions);
12870 pragma Inline (Set_Loop_Parameter_Specification);
12871 pragma Inline (Set_Low_Bound);
12872 pragma Inline (Set_Mod_Clause);
12873 pragma Inline (Set_More_Ids);
12874 pragma Inline (Set_Must_Be_Byte_Aligned);
12875 pragma Inline (Set_Must_Not_Freeze);
12876 pragma Inline (Set_Must_Not_Override);
12877 pragma Inline (Set_Must_Override);
12878 pragma Inline (Set_Name);
12879 pragma Inline (Set_Names);
12880 pragma Inline (Set_Next_Entity);
12881 pragma Inline (Set_Next_Exit_Statement);
12882 pragma Inline (Set_Next_Implicit_With);
12883 pragma Inline (Set_Next_Named_Actual);
12884 pragma Inline (Set_Next_Pragma);
12885 pragma Inline (Set_Next_Rep_Item);
12886 pragma Inline (Set_Next_Use_Clause);
12887 pragma Inline (Set_No_Ctrl_Actions);
12888 pragma Inline (Set_No_Elaboration_Check);
12889 pragma Inline (Set_No_Entities_Ref_In_Spec);
12890 pragma Inline (Set_No_Initialization);
12891 pragma Inline (Set_No_Minimize_Eliminate);
12892 pragma Inline (Set_No_Truncation);
12893 pragma Inline (Set_Non_Aliased_Prefix);
12894 pragma Inline (Set_Null_Exclusion_Present);
12895 pragma Inline (Set_Null_Exclusion_In_Return_Present);
12896 pragma Inline (Set_Null_Present);
12897 pragma Inline (Set_Null_Record_Present);
12898 pragma Inline (Set_Object_Definition);
12899 pragma Inline (Set_Of_Present);
12900 pragma Inline (Set_Original_Discriminant);
12901 pragma Inline (Set_Original_Entity);
12902 pragma Inline (Set_Others_Discrete_Choices);
12903 pragma Inline (Set_Out_Present);
12904 pragma Inline (Set_Parameter_Associations);
12905 pragma Inline (Set_Parameter_List_Truncated);
12906 pragma Inline (Set_Parameter_Specifications);
12907 pragma Inline (Set_Parameter_Type);
12908 pragma Inline (Set_Parent_Spec);
12909 pragma Inline (Set_Position);
12910 pragma Inline (Set_Pragma_Argument_Associations);
12911 pragma Inline (Set_Pragma_Identifier);
12912 pragma Inline (Set_Pragmas_After);
12913 pragma Inline (Set_Pragmas_Before);
12914 pragma Inline (Set_Pre_Post_Conditions);
12915 pragma Inline (Set_Prefix);
12916 pragma Inline (Set_Premature_Use);
12917 pragma Inline (Set_Present_Expr);
12918 pragma Inline (Set_Prev_Ids);
12919 pragma Inline (Set_Print_In_Hex);
12920 pragma Inline (Set_Private_Declarations);
12921 pragma Inline (Set_Private_Present);
12922 pragma Inline (Set_Procedure_To_Call);
12923 pragma Inline (Set_Proper_Body);
12924 pragma Inline (Set_Protected_Definition);
12925 pragma Inline (Set_Protected_Present);
12926 pragma Inline (Set_Raises_Constraint_Error);
12927 pragma Inline (Set_Range_Constraint);
12928 pragma Inline (Set_Range_Expression);
12929 pragma Inline (Set_Real_Range_Specification);
12930 pragma Inline (Set_Realval);
12931 pragma Inline (Set_Reason);
12932 pragma Inline (Set_Record_Extension_Part);
12933 pragma Inline (Set_Redundant_Use);
12934 pragma Inline (Set_Renaming_Exception);
12935 pragma Inline (Set_Result_Definition);
12936 pragma Inline (Set_Return_Object_Declarations);
12937 pragma Inline (Set_Reverse_Present);
12938 pragma Inline (Set_Right_Opnd);
12939 pragma Inline (Set_Rounded_Result);
12940 pragma Inline (Set_SCIL_Controlling_Tag);
12941 pragma Inline (Set_SCIL_Entity);
12942 pragma Inline (Set_SCIL_Tag_Value);
12943 pragma Inline (Set_SCIL_Target_Prim);
12944 pragma Inline (Set_Scope);
12945 pragma Inline (Set_Select_Alternatives);
12946 pragma Inline (Set_Selector_Name);
12947 pragma Inline (Set_Selector_Names);
12948 pragma Inline (Set_Shift_Count_OK);
12949 pragma Inline (Set_Source_Type);
12950 pragma Inline (Set_Split_PPC);
12951 pragma Inline (Set_Statements);
12952 pragma Inline (Set_Storage_Pool);
12953 pragma Inline (Set_Strval);
12954 pragma Inline (Set_Subpool_Handle_Name);
12955 pragma Inline (Set_Subtype_Indication);
12956 pragma Inline (Set_Subtype_Mark);
12957 pragma Inline (Set_Subtype_Marks);
12958 pragma Inline (Set_Suppress_Assignment_Checks);
12959 pragma Inline (Set_Suppress_Loop_Warnings);
12960 pragma Inline (Set_Synchronized_Present);
12961 pragma Inline (Set_TSS_Elist);
12962 pragma Inline (Set_Tagged_Present);
12963 pragma Inline (Set_Target_Type);
12964 pragma Inline (Set_Task_Definition);
12965 pragma Inline (Set_Task_Present);
12966 pragma Inline (Set_Then_Actions);
12967 pragma Inline (Set_Then_Statements);
12968 pragma Inline (Set_Treat_Fixed_As_Integer);
12969 pragma Inline (Set_Triggering_Alternative);
12970 pragma Inline (Set_Triggering_Statement);
12971 pragma Inline (Set_Type_Definition);
12972 pragma Inline (Set_Unit);
12973 pragma Inline (Set_Uninitialized_Variable);
12974 pragma Inline (Set_Unknown_Discriminants_Present);
12975 pragma Inline (Set_Unreferenced_In_Spec);
12976 pragma Inline (Set_Used_Operations);
12977 pragma Inline (Set_Variant_Part);
12978 pragma Inline (Set_Variants);
12979 pragma Inline (Set_Visible_Declarations);
12980 pragma Inline (Set_Was_Originally_Stub);
12981 pragma Inline (Set_Withed_Body);