This section is intended to be useful to Ada programmers who have previously used an Ada compiler implementing the traditional Ada library model, as described in the Ada 95 Languages Reference Manual. If you have not used such a system, please go on to the next section.
In XGC Ada, there no library in the normal sense. Instead, the set of source files themselves acts as the library. Compiling Ada programs does not generate any centralized information, but rather an object file and a ALI file, which are of interest only to the binder and linker. In a traditional system, the compiler reads information not only from the source file being compiled, but also from the centralized library. This means that the effect of a compilation depends on what has been previously compiled. In particular:
When a unit is with'ed, the unit seen by the compiler corresponds to the version of the unit most recently compiled into the library.
Inlining is effective only if the necessary body has already been compiled into the library.
Compiling a unit may obsolete other units in the library.
In XGC Ada, compiling one unit never affects the compilation of any other units because the compiler reads only source files. Only changes to source files can affect the results of a compilation. In particular:
When a unit is with'ed, the unit seen by the compiler corresponds to the source version of the unit that is currently accessible to the compiler.
Inlining requires the appropriate source files for the package or subprogram bodies to be available to the compiler. Inlining is always effective, independent of the order in which units are complied.
Compiling a unit never affects any other compilations. The editing of sources may cause previous compilations to be out of date if they depended on the source file being modified.
The important result of these differences are that order of compilation is never significant in XGC Ada. There is no situation in which you are required to do one compilation before another. What shows up as order of compilation requirements in the traditional Ada library becomes, in XGC Ada, simple source dependencies; in other words, it shows up as a set of rules saying what source files must be present when a file is compiled.