COBOL Manual for TNS and TNS/R Programs

Program Compilation
HP COBOL Manual for TNS and TNS/R Programs522555-006
11-114
SECTION
SECTION
SECTION identifies a section of text to be copied from either a COPY library by a
COPY statement or from a source library by a SOURCE directive.
text-name
is a COBOL word (see COBOL Words).
TANDEM
specifies that subsequent source text is in Tandem reference format, which is
described in Reference Format for Source Program Lines.
ANSI
specifies that subsequent source text is in ANSI reference format, which is
described in Section 16, ANSI Reference Format.
If you do not specify TANDEM or ANSI in the SECTION directive, the compiler
assumes that the format of the library text is the same as the current source-text
format. Although you can override this by inserting a compiler directive as the first line
following the SECTION directive, the input format control directive (ANSI or TANDEM)
of the SECTION directive is usually more convenient for this purpose. In either case,
selecting Tandem or ANSI format as an option has an effect only for the duration of the
fetching of that portion of library text. Upon completion of the fetching operation, the
compiler reverts to the previous format. (See COPY Statement and SOURCE).
If two or more SECTION directives in a text library contain the same text-name, the
text following the first one in the library (the one on the edit line that has the lowest line
number) is the text fetched by a COPY statement or SOURCE directive.
If any SECTION directive in a text library contains a text-name that is not a legal
COBOL word, the first time the compiler attempts to fetch any member from the library,
the compiler reports an error, even if the offending text-name is not the one sought.
Default: None
Placement: Must be on a directive line of its own. If it appears in the text of the
compilation source file (the IN file), it is ignored.
Scope: Applies only to the section of text that it specifies
Dependencies: None
SECTION text-name
TANDEM
ANSI
,
VST307.vsd