1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
|
.pa 1
.he 'FC (I)'9/1/72'FC (I)'
.ti 0
NAME fc -- fortran compiler
.sp
.ti 0
SYNOPSIS fc__ [ -c__ ] sfile\d1\u.f__ ... ofile\d1\u ...
.sp
.ti 0
DESCRIPTION fc__
is the UNIX Fortran compiler.
It accepts three types of arguments:
Arguments whose names end with ".f" are assumed to be
Fortran source program units; they are compiled, and
the object program is left on the file sfile\d1\u.o (i.e.
the file whose name is that of the source with ".o" substituted
for ".f").
Other arguments (except for "-c") are assumed
to be either loader flags, or
object programs, typically produced by an earlier fc__ run,
or perhaps libraries of Fortran-compatible routines.
These programs, together with the results of any
compilations specified, are loaded (in the order
given) to produce an executable program with name
a.out_____.
The "-c" argument suppresses the loading phase, as does
any syntax error in any of the routines being compiled.
The following is a list
of differences between fc__
and ANSI standard Fortran (also see the BUGS section):
.sp
.in +3
.ti -3
1. Arbitrary combination of types is allowed
in expressions. Not all combinations are expected to
be supported at runtime.
All of the normal
conversions involving integer, real, double
precision and complex are allowed.
.sp
.ti -3
2. The 'standard' implicit statement is recognized.
.sp
.ti -3
3. The types
doublecomplex, logical*1,
integer*2 and real*8 (doubleprecision)
are supported.
.sp
.ti -3
4. &_ as the first character of a line
signals a continuation card.
.sp
.ti -3
5. c_ as the first character of a line signals a comment.
.sp
.ti -3
6. All keywords are recognized in lower case.
.sp
.ti -3
7. The notion of 'column 7' is not implemented.
.ti -3
8. G-format input is free form--
leading blanks are ignored, the first blank after the start
of the number terminates the field.
.ti -3
9. A comma in any numeric or logical input field terminates
the field.
.ti -4
10. There is no carriage control on output.
.sp
.in -3
In I/O statements, only unit numbers 0-19 are supported.
Unit number nn__ corresponds to file "fortnn__;"
(e.g. unit 9 is file "fort09").
For input, the file must exist;
for output, it will be created.
Unit 5 is permanently associated with
the standard input file; unit 6 with the
standard output file.
.sp
.ti 0
FILES file.f input file
.nf
a.out loaded output
f.tmp[123] temporary (deleted)
/usr/fort/fc[1234] compilation phases
/usr/lib/fr0.o runtime startoff
/usr/lib/filib.a interpreter library
/usr/lib/libf.a builtin functions, etc.
/usr/lib/liba.a system library
.fi
.sp
.ti 0
SEE ALSO ANSI standard
.sp
.ti 0
DIAGNOSTICS Compile-time diagnostics
are given by number.
If the source code is available, it is
printed with an underline at the current
character pointer.
Errors possible are:
.in +8
.ti -8
1 statement too long
.ti -8
2 syntax error in type statement
.ti -8
3 redeclaration
.ti -8
4 missing ( in array declarator
.ti -8
5 syntax error in dimension statement
.ti -8
6 inappropriate or gratuitous array declarator
.ti -8
7 syntax error in subscript bound
.ti -8
8 illegal character
.ti -8
9 common variable is a parameter or already in common
.ti -8
10 common syntax error
.ti -8
11 subroutine/blockdata/function not first statement
.ti -8
12 subroutine/function syntax error
.ti -8
13 block data syntax error
.ti -8
14 redeclaration in external
.ti -8
15 external syntax error
.ti -8
16 implicit syntax error
.ti -8
17 subscript on non-array
.ti -8
18 incorrect subscript count
.ti -8
19 subscript out of range
.ti -8
20 subscript syntax error
.ti -8
22 DATA syntax error
.ti -8
23 Illegal variable in DATA
.ti -8
23 equivalence inconsistency
.ti -8
24 equivalence syntax error
.ti -8
25 separate common blocks equivalenced
.ti -8
26 common block illegally extended by equivalence
.ti -8
27 common inconsistency created by equivalence
.ti -8
28 DATA table overflow
.ti -8
29 () imbalance in expression
.ti -8
30 expression syntax error
.ti -8
31 illegal variable in equivalence
.ti -8
32 Storage initialized twice by DATA
.ti -8
33 non array/function used with subscripts/arguments
.ti -8
35 goto syntax error
.ti -8
37 illegal return
.ti -8
38 continue, return, stop, call, end, or pause syntax error
.ti -8
39 assign syntax error
.ti -8
40 if syntax error
.ti -8
41 I/O syntax error
.ti -8
42 do or I/O iteration error
.ti -8
43 do end missing
.ti -8
50 illegal statement in block data
.ti -8
51 multiply defined labels
.ti -8
52 undefined label
.ti -8
53 dimension mismatch
.ti -8
54 expression syntax error
.ti -8
55 end of statement in hollerith constant
.ti -8
56 array too large
.ti -8
99 B table overflow
.ti -8
101 unrecognized statement
.ti -8
.ti -8
Runtime diagnostics:
.ti -8
.ti -8
1 invalid log argument
.ti -8
2 bad arg count to amod
.ti -8
3 bad arg count to atan2
.ti -8
4 excessive argument to cabs
.ti -8
5 exp too large in cexp
.ti -8
6 bad arg count to cmplx
.ti -8
7 bad arg count to dim
.ti -8
8 excessive argument to exp
.ti -8
9 bad arg count to idim
.ti -8
10 bad arg count to isign
.ti -8
11 bad arg count to mod
.ti -8
12 bad arg count to sign
.ti -8
13 illegal argument to sqrt
.ti -8
14 assigned/computed goto out of range
.ti -8
15 subscript out of range
.ti -8
16 real**real overflow
.ti -8
100 illegal I/O unit number
.ti -8
101 inconsistent use of I/O unit
.ti -8
102 cannot create output file
.ti -8
103 cannot open input file
.ti -8
104 EOF on input file
.ti -8
105 illegal character in format
.ti -8
106 format does not begin with (
.ti -8
107 no conversion in format but non-empty list
.ti -8
108 excessive parenthesis depth in format
.ti -8
109 illegal format specification
.ti -8
110 illegal character in input field
.ti -8
111 end of format in hollerith specification
.ti -8
999 unimplemented input conversion
.sp
.in -8
.ti 0
BUGS The following is a list of
those features not yet implemented:
.sp
.br
arithmetic statement functions
backspace, endfile, rewind runtime
binary I/O
no scale factors on input
|