1 02/28/84 cobol
2
3 Syntax: cobol path -control_args
4
5
6 Function: invokes the COBOL compiler to translate a segment containing
7 the text of a COBOL source program into a Multics object segment.
8
9
10 Arguments:
11 path
12 is the pathname of a COBOL source segment to be translated by the
13 COBOL compiler. If path does not have a suffix of .cobol, one is
14 assumed; however, the suffix .cobol must be the last component of
15 the name of the source segment.
16
17
18 Control arguments:
19 -brief, -bf
20 causes error messages written to the user_output I/O switch to
21 contain only an error number and statement identification, once the
22 full message has been given on the first occurrence.
23 -card
24 removes meaningless trailing blanks from a standard fixed format
25 COBOL source program in card image format. Characters in the
26 identification field columns 73-80 are ignored.
27 -check, -ck
28 is used for syntactic and semantic checking of a COBOL program. No
29 code is generated.
30
31
32 -expand, -exp
33 translates a standard fixed format COBOL source program that
34 possibly contains COPY and REPLACE statements into an equivalent
35 source program that does not contain these statements.
36 -format, -fmt
37 translates a pseudofree form COBOL source program into a standard
38 fixed format COBOL source program see the expand_cobol_source
39 command for details.
40 -levelNM, -levNM
41 causes L-type diagnostics at severity M to be written to the
42 user_output I/O switch whenever a COBOL source line contains a
43 language construct outside the subset specified by N see "Notes
44 on L-type diagnostics" below.
45
46
47 -list, -ls
48 produces a source program listing with symbols, followed by an
49 assembly-like listing of the compiled object program.
50 -map
51 produces a source program listing with symbols, followed by a map of
52 the object code generated by this compilation. This control
53 argument produces sufficient information to allow you to debug
54 most problems online.
55 -no_table, -ntb
56 suppresses the generation of a full symbol table for use by symbolic
57 debuggers.
58 -profile, -pf
59 generates additional code to meter the execution of individual
60 statements.
61
62
63 -runtime_check, -rck
64 produces an object program in which parameters are validated
65 according to number and type, performs bounds checking on all
66 subscripted referenced, performs string range checking on all
67 variable-length string references, and verifies the validity of
68 every index name modification.
69 -severityN, -svN
70 does not write error messages whose severity is less than N where
71 N is 1 2 3 or 4 to the user_output I/O switch. All errors are
72 written into the listing. If this control argument is not given, a
73 severity level of 2 is assumed.
74 -table, -tb
75 generates a full symbol table for use by symbolic debuggers. If
76 -format, -expand, or -card is given with -table, the symbolic
77 debuggers are not able to display the source statements. Default
78
79
80 -temp_dir path, -td path
81 creates the compiler's internal work files in the specified
82 directory rather than in the process directory.
83 -debug, -db
84 leaves the work files generated by the compiler intact after a
85 compilation. This control argument is used for debugging the
86 compiler. The command cobol$clean_up can be used to discard these
87 files. This causes severity 4 errors, which do not unwind and
88 abort the compilation but rather invoke a new level of the command
89 processor at the point of the error.
90 -time, -tm
91 prints the time in seconds and the number of page faults taken by
92 each phase of the compiler; prints the total time at the end of the
93 compilation. This information is directed to the user_output I/O
94 switch.
95
96
97 Notes: The only result of invoking the cobol command without control
98 arguments is to generate an object segment containing a full symbol
99 table.
100
101
102 Notes on L-type diagnostics:
103 The value M can be one through three and specifies the severity of the
104 diagnostic. If M is omitted, severity 3 is assumed. The value N can
105 be one through five, corresponding to the four levels specified by
106 the Federal Information Processing Standards Publication, December 1,
107 1975 FIPS PUB 21-1and to the extended version of COBOL supported by
108 Multics. These values are
109 1 low level
110 2 low intermediate level
111 3 high intermediate level
112 4 high level
113 5 Multics COBOL extensions
114 If a program compiles without any L-type diagnostics, it means the
115 program is an acceptable subset of Multics COBOL at the level
116 requested. The default is level 5.