The System z® LPEX
editor accepts -INC and ++INCLUDE statements as synonyms for COBOL
COPY statements and PL/I %INCLUDE statements.
Some source code management systems, such as Panvalet® and Librarian®,
use -INC and ++INCLUDE statements in COBOL and PL/I source files to
indicate that additional lines of code are to be considered part of
the source file containing the statements. These additional lines
of code are contained in a separate file, whose name is specified
as part of the -INC or ++INCLUDE statement. The System z LPEX editor content assist function
supports these statements and can make statement completion suggestions
with them as with COPY and %INCLUDE statements. The following formats
of the -INC and ++INCLUDE statements are supported:
-INC copybookname
++INCLUDE copybookname
In these examples,
copybookname is
the name of the partitioned data set member to be considered part
of the source. For local files, it is the filename without its extension.
The -INC statement usually starts in column 1 of the source line,
but for COBOL may also start in column 7, 8, 9, or 10, and the ++INCLUDE
statement always starts in column 8 of the source line.
The following code samples show how these statements are used:
Identification Division.
Program-ID. StartApp.
Data Division.
Working-Storage Section.
01 Program-pass-fields.
05 Temp-name Pic x(30).
01 Program-other-fields.
05 Input-name Pic x(30).
05 Char-count Pic 99 Value ZEROS.
-INC COPY3.
++INCLUDE COPY4.
Procedure Division.