Rational Developer for System z
COBOL for Windows, Version 7.5, Programming Guide


Finding program entity definitions and references

Use the XREF(FULL) compiler option to find out where a data-name, procedure-name, or program-name is defined and referenced. The sorted cross-reference includes the line number where the entity was defined and the line numbers of all references to it.

To include only the explicitly referenced data items, use the XREF(SHORT) option.

Use both the XREF (either FULL or SHORT) and the SOURCE options to print a modified cross-reference to the right of the source listing. This embedded cross-reference shows the line number where the data-name or procedure-name was defined.

User-defined words in your program are sorted using the locale that is active. Hence, the collating sequence determines the order for the cross-reference listing, including multibyte words.

Group names in a MOVE CORRESPONDING statement are listed in the XREF listing. The cross-reference listing includes the group names and all the elementary names involved in the move.

Example: XREF output - data-name cross-references
Example: XREF output - program-name cross-references
Example: embedded cross-reference

related tasks
Getting listings

related references
XREF


Terms of use | Feedback

Copyright IBM Corporation 1996, 2008.
This information center is powered by Eclipse technology. (http://www.eclipse.org)