-gnatd`x'
debug.adb
.
-gnatG[=`nn']
The optional parameter nn if present after -gnatG specifies an alternative maximum line length that overrides the normal default of 72. This value is in the range 40-999999, values less than 40 being silently reset to 40. The equal sign is optional.
The format of the output is very similar to standard Ada source, and is
easily understood by an Ada programmer. The following special syntactic
additions correspond to low level features used in the generated code that
do not have any exact analogies in pure Ada source form. The following
is a partial list of these special constructions. See the spec
of package Sprint in file sprint.ads
for a full list.
If the switch `-gnatL' is used in conjunction with `-gnatG', then the original source lines are interspersed in the expanded source (as comment lines with the original line number).
new `xxx' [storage_pool = `yyy']
at end `procedure-name';
(if `expr' then `expr' else `expr')
`target'^(`source')
`target'?(`source')
`target'?^(`source')
`x' #/ `y'
`x' #mod `y'
`x' # `y'
`x' #rem `y'
free `expr' [storage_pool = `xxx']
[subtype or type declaration]
freeze `type-name' [`actions']
reference `itype'
`function-name'! (`arg', `arg', `arg')
`label-name' : label
#$ `subprogram-name'
`expr' && `expr' && `expr' ... && `expr'
[constraint_error]
`expression''reference
`target-type'!(`source-expression')
[`numerator'/`denominator']
-gnatD[=nn]
xxx.dg
, where xxx
is the normal file name,
instead of to the standard output file. For
example, if the source file name is hello.adb
, then a file
hello.adb.dg
will be written. The debugging
information generated by the `gcc' `-g' switch
will refer to the generated xxx.dg
file. This allows
you to do source level debugging using the generated code which is
sometimes useful for complex code, for example to find out exactly
which part of a complex construction raised an exception. This switch
also suppress generation of cross-reference information (see
`-gnatx') since otherwise the cross-reference information
would refer to the .dg
file, which would cause
confusion since this is not the original source file.
Note that `-gnatD' actually implies `-gnatG' automatically, so it is not necessary to give both options. In other words `-gnatD' is equivalent to `-gnatDG').
If the switch `-gnatL' is used in conjunction with `-gnatDG', then the original source lines are interspersed in the expanded source (as comment lines with the original line number).
The optional parameter nn if present after -gnatD specifies an alternative maximum line length that overrides the normal default of 72. This value is in the range 40-999999, values less than 40 being silently reset to 40. The equal sign is optional.
-gnatr
-gnatR[0|1|2|3[s]]
Finally `-gnatR3' includes symbolic
expressions for values that are computed at run time for
variant records. These symbolic expressions have a mostly obvious
format with #n being used to represent the value of the n'th
discriminant. See source files repinfo.ads/adb
in the
GNAT sources for full details on the format of `-gnatR3'
output. If the switch is followed by an s (e.g., `-gnatR2s'), then
the output is to a file with the name file.rep
where
file is the name of the corresponding source file.
-gnatRm[s]
Note that it is possible for record components to have zero size. In this case, the component clause uses an obvious extension of permitted Ada syntax, for example at 0 range 0 .. -1.
Representation information requires that code be generated (since it is the code generator that lays out complex data structures). If an attempt is made to output representation information when no code is generated, for example when a subunit is compiled on its own, then no information can be generated and the compiler outputs a message to this effect.
-gnatS
-gnatx
ALI
file. This information is used by a number of tools,
including gnatfind and gnatxref. The `-gnatx' switch
suppresses this information. This saves some space and may slightly
speed up compilation, but means that these tools cannot be used.