COBOL Manual for TNS and TNS/R Programs
Program Compilation
HP COBOL Manual for TNS and TNS/R Programs—522555-006
11-65
CROSSREF and NOCROSSREF
The classes marked with an asterisk in the preceding table are, by default,
selected for inclusion, but reporting of cross-reference information about them
is suspended until a CROSSREF directive is encountered.
NOCROSSREF
switches collection off but leaves the class list as it is. A subsequent CROSSREF
directive can switch collection back on without respecifying the list.
Here are some examples of CROSSREF directives in use:
•
CROSSREF by itself as the only cross-referencing directive applied to a program
unit causes the collection of cross-reference information about all identifiers and
the reporting of information about those identifiers in the default class list.
•
CROSSREF at the beginning of a program unit, followed by CROSSREF
INCLUDE LITERALS at the beginning of the Procedure Division, causes cross-
reference information about all classes to be collected and causes reporting of all
the default classes plus literals for the entire program (not just for the Procedure
Division).
•
CROSSREF EXCLUDE MNEMONICS starts (or continues) collecting cross-
reference information for all classes, but removes the MNEMONIC class from the
current class list and establishes reporting of the classes in the revised class list.
•
CROSSREF PROCNAMES removes all classes from the current class list, installs
PROCNAMES as the only class, and starts the collection of information for all
classes and the reporting of only PROCNAMES.
PROCNAMES (or LABELS) * Procedure-names (paragraph-names, section-
names)
PROGRAMS
* Program-names, routine-names
UNREFS Items defined but not referenced (technically,
not a class but a generalized request for all such
items)
Default: NOCROSSREF
Placement: Anywhere
Scope: CROSSREF applies to all separately compiled program units, regardless
of nesting; that is, all programs within a nest appear in the same cross-
reference listing. You need not repeat CROSSREF for each program unit
in a compilation unit; the class list active at the end of one program unit
applies to the next program unit until explicitly altered by
NOCROSSREF.
Dependencies: CROSSREF works only if LIST is active and SUPPRESS is not.
References:
•
LIST and NOLIST
•
SUPPRESS and NOSUPPRESS
Class COBOL Identifiers Selected (page 2 of 2)