Compaq COBOL for OpenVMS VAX and Compaq COBOL Compatibility and Migration
B.3 Command-Line Qualifiers (Options or Flags)
When you specify /STANDARD=OPENVMS_AXP, the Compaq COBOL for
OpenVMS VAX compiler generates informational messages to alert you to
language constructs that are not available in Compaq COBOL. (You must also
specify /WARNINGS=ALL or /WARNINGS=INFORMATIONAL to receive these
messages.) You can use this information to modify your program before using
Compaq COBOL.
Specify /STANDARD=NOOPENVMS_AXP, which is the default, to suppress these
informational messages.
B.4 Compaq COBOL and Compaq COBOL for OpenVMS VAX
Behavior Differences
This section describes behavior differences between Compaq COBOL for
OpenVMS VAX and Compaq COBOL.
B.4.1 Program Structure Messages
In some cases, the Compaq COBOL compiler (whether on the OpenVMS Alpha,
Windows NT, or the Tru64 UNIX system) generates more complete messages
about unreachable code or other logic errors than does the Compaq COBOL for
OpenVMS VAX compiler.
The following example illustrates a sample program and the messages issued by
the Compaq COBOL compiler:
Source file
IDENTIFICATION DIVISION.
PROGRAM-ID. T1.
ENVIRONMENT DIVISION.
PROCEDURE DIVISION.
P0.
GO TO P1.
P2.
DISPLAY "This is unreachable code".
P1.
STOP RUN.
On OpenVMS VAX systems
$ COBOL /ANSI/WARNINGS=ALL T1.COB
$
The program compiles. The Compaq COBOL for OpenVMS VAX compiler
produces no messages.
On OpenVMS Alpha systems
$ COBOL/ANSI/OPTIMIZE/WARNINGS=ALL T1.COB
P2.
.......^
%COBOL-I-UNREACH, code can never be executed at label P2
at line number 7 in file DISK$YOURDISK:[TESTDIR]T1.COB;1
On Tru64 UNIX systems
% cobol -ansi -O -warn all T1.COB
cobol: Info: T1.COB, line 7: code can never be executed at label P2
P2
-------^
B–10 Compaq COBOL for OpenVMS VAX and Compaq COBOL Compatibility and Migration
Содержание COBOL AAQ2G1FTK
Страница 22: ......
Страница 30: ......
Страница 94: ......
Страница 110: ......
Страница 146: ......
Страница 180: ......
Страница 194: ...Processing Files and Records 6 1 Defi...
Страница 300: ......
Страница 490: ......
Страница 516: ......
Страница 517: ......
Страница 530: ......
Страница 534: ......
Страница 590: ......
Страница 620: ......