2.6. Section 10: Program Structure and Compilation Issues

The information in this section relates to Annex M paragraphs 28 to 38.

Q: M.(28)
Q: M.(29)
Q: M.(30)
Q: M.(31)
Q: M.(32)
Q: M.(33)
Q: M.(34)
Q: M.(35)
Q: M.(36)
Q: M.(37)
Q: M.(38)

Q: M.(28)

The representation for a compilation. See 10.1(2).

A: A compilation is represented by a sequence of files presented to the compiler in a single invocation of the gcc command.

Q: M.(29)

Any restrictions on compilations that contain multiple compilation_units. See 10.1(4).

A: No single file can contain more than one compilation unit, but any sequence of files can be presented to the compiler as a single compilation.

Q: M.(30)

The mechanisms for creating an environment and for adding and replacing compilation units. See 10.1.4(3).

A: See separate section on compilation model.

Q: M.(31)

The manner of explicitly assigning library units to a partition. See 10.2(2).

A: Partitions are not supported.

Q: M.(32)

The implementation-defined means, if any, of specifying which compilation units are needed by a given compilation unit. See 10.2(2).

A: See separate section on compilation units.

Q: M.(33)

The manner of designating the main subprogram of a partition. See 10.2(7).

A: The main program is designated by providing the name of the corresponding .ali file as the input parameter to the binder.

Q: M.(34)

The order of elaboration of library_items. See 10.2(18).

A: The first constraint on ordering is that it meets the requirements of chapter 10 of the Ada 95 Reference Manual. This still leaves some implementation dependent choices, which are resolved by first elaborating bodies as early as possible (i.e. in preference to specs where there is a choice), and second by evaluating the immediate with clauses of a unit to determine the probably best choice, and third by elaborating in alphabetical order of unit names where a choice still remains.

Q: M.(35)

Parameter passing and function return for the main subprogram. See 10.2(21).

A: The main program has no parameters. It may be a procedure, or a function returning an integer type. In the latter case, the returned integer value is the return code of the program.

Q: M.(36)

The mechanisms for building and running partitions. See 10.2(24).

A: ERC32 Ada itself supports programs with only a single partition. You may use operating systems such as APEX to support multiple partitions.

Q: M.(37)

The details of program execution, including program termination. See 10.2(25).

A: See separate section on compilation model.

Q: M.(38)

The semantics of any non-active partitions supported by the implementation. See 10.2(28).

A: Passive partitions are not supported.