TAL Reference Manual
Compiler Directives
TAL Reference Manual—526371-001
16-76
Usage Considerations
Saving Global Data Declarations
When you compile with SAVEGLOBALS, the compiler saves the global data
declarations in a file. If you make no changes in the global data declarations, you can
use the saved declarations in subsequent compilations and reduce the compilation
time.
Other guidelines for saving global data declarations include the following:
•
If the global data declarations contain any syntax errors, correct the errors and
recreate the global declarations file by using SAVEGLOBALS.
•
SAVEGLOBALS does not save EXTERNAL or FORWARD procedure declarations.
•
You must recompile these declarations in the USEGLOBALS compilation.
•
If SAVEGLOBALS and USEGLOBALS appear in the same compilation unit, the
compiler issues an error message and complies with only the first of the two
directives.
•
If SAVEGLOBALS appears in a compilation unit you submit to the stand-alone
Crossref product, the compiler ignores the SAVEGLOBALS directive.
•
Whenever you switch to a different version of the compiler, you must create a new
global declarations file by using SAVEGLOBALS. Otherwise, an error message
occurs in the USEGLOBALS compilation. C20, D10, and D20, for example, are
different versions of the compiler.
If SAVEGLOBALS is in effect, the compiler takes the following actions when it
encounters the first procedure declaration:
•
The compiler stores the global data declarations in the specified file. Global data
declarations include all global data identifiers and their attributes (such as data
type and kind of variable) but not their initializations.
•
The compiler stores the initialization values in the object code. Initialization values
include addresses and constant lists.