2.00;crefpas (cross reference Pascal program), version 2.00, 81/11/01
CREFPAS (CROSS_REFERENCE_PASCAL) -- Cross reference a Pascal program.
usage: CREFPAS pathname [-L pathname_2]
FORMAT
CREFPAS pathname [-L pathname_2]
CREFPAS produces a cross reference list of the identifiers (other than Pascal
reserved words) used in a Pascal source program. The listing is in four
parts. The first part lists the program, with line numbers added. The
second part lists BEGIN, REPEAT, and CASE statements, with their associated
ending statement lines identified. The third part lists BEGIN, REPEAT, and
CASE statements and their associated ending statements, but
with the ending statements listed first. The fourth part lists all identifiers
(other than Pascal reserved words) and the line numbers on which they appear.
Appearances in declaration sections are flagged with a 'D'.
Insert files are not included in the cross reference listing.
ARGUMENT
pathname
(required) Specify Pascal source file to be cross referenced. If the
pathname you supply has the suffix ".PAS", then CREFPAS
searches for that file. Otherwise, CREFPAS automatically
appends the ".PAS" suffix prior to searching for the file.
OPTION
-L pathname_2 Specify alternate listing file. The suffix ".LST" is appended
to 'pathname_2' if it is not already present. If this option
is not specified, the cross reference listing is written to
a file named 'pathname'.LST. (If 'pathname' ends in ".PAS",
then ".LST" replaces ".PAS".)
EXAMPLE
Suppose a program stored in a file named "my_prog" had a BEGIN statement on
line 20, a REPEAT statement on line 25, a CASE statement on line 30, and their
associated ending statements on lines 50, 40, and 35, respectively.
The command
$ crefpas my_prog -L list_it
would produce the following analysis in the file "list_it.lst":
Part 1
(The normal program listing, with line numbers added.)
Part 2
20>B>50, 25>R>40 30>C>35
Part 3
35<C<30 40<R<25 50<B<20
Part 4
(The list of all identifiers with their line numbers.)