Descriptions of Directives (cont.) [ Micro Focus COBOL System Reference, Volume 2 ] MPE/iX 5.0 Documentation
Micro Focus COBOL System Reference, Volume 2
Descriptions of Directives (cont.)
LIBRARIAN
Allows -INC statements in your program.
Syntax:.
Parameters:.
None
Default:.
NOLIBRARIAN
Phase:.
Syntax check
Environment:.
All
$SET:.
Any
Remarks:.
The -INC statement specifies a file for inclusion in the source program.
The string -INC must be written as a contiguous sequence of characters
starting in column 1, followed by one or more spaces, and then, on the
same line, by the name of a file containing COBOL source. This file is
included in the program at the point where the -INC statement appears.
LINKCHECK
Specifies that each time a Linkage Section item is referenced a check is
to be made that it exists.
Syntax:.
Parameters:.
None
Default:.
NOLINKCHECK
Phase:.
Generate
Environment:.
16-bit
$SET:.
Initial
Remarks:.
The PARAMCOUNTCHECK directive must also be specified if you intend to use
the LINKCHECK directive.
If reference is made to a Linkage Section item that does not exist, a
run-time error 203 (CALL parameter not supplied) is generated.
See also:.
PARAMCOUNTCHECK
LINKCOUNT
Specifies the maximum number of Linkage Section items, external data
items, and external files (as defined for inter-program communication)
allowed.
Syntax:.
Parameters:.
integer The number allowed.
Default:.
LINKCOUNT"64"
Phase:.
Syntax check
Environment:.
All
$SET:.
Initial
Remarks:.
integer must not be less than the total number of Linkage Section items,
external data items, and external files after the end of the first
Linkage Section item, external data item or external file, whichever
appears first.
LINKLIB
Specifies the link library or libraries where the linker is to look for
the run-Time support routines.
Syntax:.
Parameters:.
library-names The names of one or more link libraries.
Default:.
LINKLIB"COBLIB+COBAPI"
Phase:.
Generate
Environment:.
16-bit
$SET:.
Initial
Remarks:.
Specifying a library-name of NUL is the same as NOLINKLIB. The choice of
library can be subsequently overridden by a directive to the linker.
Library names must be separated by a plus sign (+). If a library name
has no extension, .lib is assumed.
LIST
Specifies the destination of the source listing file.
Syntax:.
Parameters:.
destination A full file specification or a device-name.
Default:.
NOLIST
Phase:.
Both
Environment:.
All (syntax check), 16-bit (generate)
$SET:.
Any (LIST and NOLIST) None (for LIST "file-name " and LIST " ")
Dependencies:.
NOLIST sets NOFORM, NOREF, NOSETTINGS, NOSOURCEASM and NOXREF at end.
LIST sets FORM"60" immediately. Set to LIST by RSM immediately. Set to
NOLIST by RNIM at end.
Remarks:.
If you specify an existing file, it is overwritten. When NOLIST is
specified, no source listing is produced. If you specify LIST with no
destination, the source listing is sent to the screen. If you specify
either destination or "", you cannot use this directive in a $SET
statement.
The device-name can be any suitable device. On DOS, Windows and OS/2 and
Windows use CON: for the screen. On UNIX, the device selected must not
be under the control of a system spooler.
NOLIST and LIST with no parameter can be used in $SET statements within a
program to list selected parts of the program. The destination of the
listing cannot be changed in this way.
LIST"" causes the source listing to be put in the file source-name.lst,
where source-name is the root of the name of the program being compiled.
When used with the 16-bit Generator in add-on products from Micro Focus,
this creates the file source-name.grp.
If you want to list the source to a file for every compilation you do,
place the LIST " " directive in the cobol.dir file. This overrides the
default NOLIST.
Alternatively, if you already have a LIST directive in your cobol.dir,
making every listing go to the screen, you can override it by using LIST"
" on the command line.
LISTPATH
Specifies a path on which the list file is to be written. The name of
the list file is source-name.lst.
Syntax:.
Parameters:.
list-path path to which the list file is written
Default:.
NOLISTPATH
Phase:.
Syntax check
Environment:.
All
$SET:.
Initial
LISTWIDTH
LW
Sets the width of the listing.
Syntax:.
Parameters:.
integer Width in characters. It must be between 72 and 132.
Default:.
LISTWIDTH"80"
Phase:.
Syntax check
Environment:.
All
$SET:.
Any
Dependencies:.
If REF is set, and integer is less than 90, sets LISTWIDTH"90"
immediately. If integer is less than 90, sets NOREF at end.
Remarks:.
LISTWIDTH"132" causes additional information to be displayed for each
line listed. This includes the first eight characters of the current
COPY-file name (spaces for the main file) together with the number of the
line relative to the start of that file.
See also:.
REF
LITLINK
Makes the Compiler declare the literals in CALL literal statements as
public symbols, so they are resolved at link time rather than run time.
Syntax:.
Parameters:.
None
Default:.
NOLITLINK
Phase:.
Generate
Environment:.
16-bit
$SET:.
Initial
Dependencies:.
If OMF"GNT", LITLINK sets OMF"OBJ" at end. Set to LITLINK at end by
MODEL"SMALL", MODEL"COMPACT" or OBJLITE. If ASSUME is set, set to LITLINK
at end by REGPARM"OUT".
Remarks:.
This directive only affects .obj files.
With NOLITLINK, the Compiler declares as public symbols only those
literals that begin with the underscore character (_). If your program
calls a non-COBOL procedure whose name does not begin with an underscore,
you must either specify LITLINK or precede the name with two underscores
to ensure the procedure gets linked to your program.
LITVAL-SIZE
Specifies the number of bytes to pass if the SIZE clause is omitted when
passing numeric literals BY VALUE.
Syntax:.
Parameters:.
integer A number up to 4. The number of bytes to pass.
Default:.
LITVAL-SIZE"4"
Phase:.
Syntax check
Environment:.
All
$SET:.
Any
LNKALIGN
Indicates that any linkage records specified in a USING statement are 01
or 77-level items, aligned according to the ALIGN directive.
Syntax:.
Parameters:.
None
Default:.
NOLNKALIGN
Phase:.
Generate
Environment:.
32-bit
$SET:.
No
Remarks:.
Using LNKALIGN can reduce the time needed to access a linkage item at run
time. However, take care when using it. You must use the correct ALIGN
directive setting when compiling your program. No checks are made to
ensure that the items are aligned.
The results of using this directive are machine-dependent, and you should
not use it if you are in any doubt as to its effect. Unpredictable
results might occur if you pass linkage items that are not aligned.
See also:.
ALIGN
LOCALCOUNT
This directive is reserved for internal use by the system. Because it
might appear in the list of settings, it is included for completeness.
It is not intended for users' applications, and its setting should not be
changed.
Syntax:.
Parameters:.
integer Must be in the range 0 to 65536
Default:.
LOCALCOUNT"0"
Phase:.
Syntax check
Environment:.
All
$SET:.
Initial
LOCKTYPE
Specifies the type of record locking.
Syntax:.
Parameters:.
integer 0 or 1. The type of locking.
Default:.
LOCKTYPE"0"
Phase:.
Syntax check
Environment:.
All
$SET:.
Initial
Remarks:.
The possible values of integer are:
0 Programs can read locked records, but not access them in other
ways. This is the standard method with this system.
1 Programs cannot access locked records at all. This is as in
languages other than COBOL.
This directive is reserved for use with add-on products supplied by Micro
Focus. Do not change its setting unless you have an appropriate add-on
product.
This directive only has an effect if the CALLFH directive is used.
See also:.
CALLFH
LOGICOPT
Optimizes calls to the CBL_ logical routines so that they do not affect
RETURN-CODE.
Syntax:.
Parameters:.
None
Default:.
NOLOGICOPT
Phase:.
Generate
Environment:.
32-bit
$SET:.
No
Remarks:.
Specifying LOGICOPT optimizes COBOL logical calls, such as CBL_AND, so
that they do not affect RETURN-CODE.
MAKESYN
Makes one reserved word synonymous with another.
Syntax:.
On DOS, Windows and OS/2:
On UNIX:
Parameters:.
rsv-word-1 A reserved word.
rsv-word-2 The reserved word whose meaning is to be changed.
Default:.
No reserved word synonyms are created.
Phase:.
Syntax check
Environment:.
All
$SET:.
Initial
Remarks:.
The equals sign must be surrounded by spaces.
This directive does not appear in the list created with the SETTING
directive.
MAPNAME
Makes the Compiler alter program-names and entry-points to make them
compatible with OS/VS COBOL, DOS/VS COBOL, VS COBOL II and COBOL/370.
Syntax:.
Parameters:.
None
Default:.
NOMAPNAME
Phase:.
Syntax check
Environment:.
All
$SET:.
Initial
Remarks:.
Specifying MAPNAME affects program-names and entry-points defined in the
compilation and those referenced by the program as follows:
* ENTRY statements only in the outermost program
* CALL literal, but not CALL identifier, statements
* PROGRAM-ID entries in the outermost program, but not in nested
programs.
When a name is found to be incompatible, a warning message is given and a
modified name is used in the object program. The rules enforced and the
modifications made are:
* The first eight characters must be unique among program-names.
The name is truncated to the first eight characters.
* The first character must be alphabetic. If it is numeric it is
changed as follows:
0 becomes J
1 - 9 become A - I
* Hyphen (-) is not allowed. If one appears it is changed to zero
(0).
MASM
Makes the Compiler produce a listing file that can be submitted to
Microsoft MASM to produce an .obj file.
Syntax:.
Parameters:.
None
Default:.
NOMASM
Phase:.
Generate
Environment:.
16-bit
$SET:.
Initial
Dependencies:.
MASM sets NOFORM at end. Set to NOMASM by NOASM or OMF"GNT".
Remarks:.
This directive only affects .obj files.
You could use this directive to investigate the performance of small
sections of code, as it allows you to edit the generated output. You
should only use this directive on programs with one code segment, or the
code produced does not work correctly.
You must set the ASMLIST directive to specify the destination of the
MASM-compatible listing. You can still use SOURCEASM to enable you to
include source lines as comments. An .obj file is still generated,
although it might differ slightly from the .obj file produced by MASM.
MFCOMMENT
Prevents lines with an asterisk (*) in column 1, or a form-feed character
in columns 1 and 2 followed by an asterisk, appearing in the source
listing.
Syntax:.
Parameters:.
None
Default:.
MFCOMMENT
Phase:.
Syntax check
Environment:.
All
$SET:.
Any
Dependencies:.
Set to NOMFCOMMENT at end by SOURCEFORMAT"FREE"
Remarks:.
With MFCOMMENT, such lines are ignored by the Compiler and do not appear
in the source listing. With NOMFCOMMENT, they do appear.
MFLEVEL
MF
Facilitates forward compatibility with Micro Focus products by
selectively enabling Micro Focus-specific reserved words and changing the
behavior of certain features to be compatible with particular versions.
Syntax:.
Parameters:.
integer The level of Micro Focus COBOL to be compatible with.
Default:.
MF"9"
Phase:.
Syntax check
Environment:.
All
$SET:.
Initial
Dependencies:.
MF"7" sets DBCS"2" immediately. If integer >> 7, sets DBCS"3"
immediately
Remarks:.
The possible values of integer are:
1 Professional COBOL v1.0, v1.1, and v1.2
Level II COBOL v2.5 and v2.6
Level II COBOL/ET v1.1
2 VS COBOL Workbench v1.2
VS COBOL v.1.2
3 VS COBOL Workbench v1.3
VS COBOL Workbench v2.0
Professional COBOL v2.0
VS COBOL v1.5
4 COBOL/2 v1.1
Professional COBOL/2
COBOL/2 Workbench v2.2
Microsoft COBOL V3.0
5 COBOL/2 v1.2
COBOL/2 Workbench v2.3
6 COBOL/2 v2.4
COBOL/2 Workbench v2.4
Microsoft COBOL V4.0
7 COBOL/2 v2.5
COBOL/2 Workbench v2.5
Microsoft COBOL V4.5
8 COBOL v3.0
COBOL Workbench v3.0
Microsoft COBOL V5.0
9 COBOL v3.1
COBOL Workbench v3.1
Behavior of the BLANK LINE phrase in previous versions of this product
can be implemented using the OLDBLANKLINE directive. Behavior of the
NEXT SENTENCE phrase in previous versions of this product can be
implemented using the OLDNEXTSENTENCE directive.
If you specify MF without the parameter, all Micro Focus-specific
reserved words are treated as reserved words. It is equivalent to
specifying MF"9". If you specify NOMF, none of the Micro Focus reserved
words are treated as reserved words.
See also:.
OLDBLANKLINE, OLDNEXTSENTENCE
MFSCCS
Specifies whether to look for files in a Source Code Control System
(SCCS).
Syntax:.
Parameters:.
None
Default:.
NOMFSCCS
Phase:.
Syntax check
Environment:.
All
$SET:.
Initial
Remarks:.
You should only use this directive if you have an appropriate add-on
product.
If you are using the Micro Focus COBOL Workbench SCCS interface,
specifying MFSCCS causes the Compiler to search the SCCS if it cannot
find a file.
MPE/iX 5.0 Documentation