1: /*
2: char id_fiodefs[] = "@(#)fiodefs.h 1.3";
3: *
4: * fortran file i/o type definitions
5: */
6:
7: #include <stdio.h>
8: #include "../libI77/f_errno.h"
9:
10: /* Logical Unit Table Size */
11: #define MXUNIT _NFILE
12:
13: #define GLITCH '\2' /* special quote for Stu, generated in f77pass1 */
14:
15: #define LISTDIRECTED -1
16: #define FORMATTED 1
17:
18: #define ERROR 1
19: #define OK 0
20: #define YES 1
21: #define NO 0
22:
23: #define STDERR 0
24: #define STDIN 5
25: #define STDOUT 6
26:
27: #define WRITE 1
28: #define READ 2
29: #define SEQ 3
30: #define DIR 4
31: #define FMT 5
32: #define UNF 6
33: #define EXT 7
34: #define INT 8
35:
36: typedef char ioflag;
37: typedef long ftnint;
38: typedef ftnint flag;
39: typedef long ftnlen;
40:
41: typedef struct /*external read, write*/
42: { flag cierr;
43: ftnint ciunit;
44: flag ciend;
45: char *cifmt;
46: ftnint cirec;
47: } cilist;
48:
49: typedef struct /*internal read, write*/
50: { flag icierr;
51: char *iciunit;
52: flag iciend;
53: char *icifmt;
54: ftnint icirlen;
55: ftnint icirnum;
56: ftnint icirec;
57: } icilist;
58:
59: typedef struct /*open*/
60: { flag oerr;
61: ftnint ounit;
62: char *ofnm;
63: ftnlen ofnmlen;
64: char *osta;
65: char *oacc;
66: char *ofm;
67: ftnint orl;
68: char *oblnk;
69: } olist;
70:
71: typedef struct /*close*/
72: { flag cerr;
73: ftnint cunit;
74: char *csta;
75: } cllist;
76:
77: typedef struct /*rewind, backspace, endfile*/
78: { flag aerr;
79: ftnint aunit;
80: } alist;
81:
82: typedef struct /*units*/
83: { FILE *ufd; /*0=unconnected*/
84: char *ufnm;
85: long uinode;
86: int url; /*0=sequential*/
87: flag useek; /*true=can backspace, use dir, ...*/
88: flag ufmt;
89: flag uprnt;
90: flag ublnk;
91: flag uend;
92: flag uwrt; /*last io was write*/
93: flag uscrtch;
94: } unit;
95:
96: typedef struct /* inquire */
97: { flag inerr;
98: ftnint inunit;
99: char *infile;
100: ftnlen infilen;
101: ftnint *inex; /*parameters in standard's order*/
102: ftnint *inopen;
103: ftnint *innum;
104: ftnint *innamed;
105: char *inname;
106: ftnlen innamlen;
107: char *inacc;
108: ftnlen inacclen;
109: char *inseq;
110: ftnlen inseqlen;
111: char *indir;
112: ftnlen indirlen;
113: char *inform;
114: ftnlen informlen;
115: char *infmt;
116: ftnint infmtlen;
117: char *inunf;
118: ftnlen inunflen;
119: ftnint *inrecl;
120: ftnint *innrec;
121: char *inblank;
122: ftnlen inblanklen;
123: } inlist;
124:
125: typedef union
126: { float pf;
127: double pd;
128: } ufloat;
129:
130: typedef union
131: { short is;
132: char ic;
133: long il;
134: } uint;
135:
136: struct ioiflg {
137: short if_oeof;
138: short if_ctrl;
139: short if_bzro;
140: };
141: #define opneof ioiflg_.if_oeof
142: #define ccntrl ioiflg_.if_ctrl
143: #define blzero ioiflg_.if_bzro
Defined struct's
Defined typedef's
flag
defined in line
38; used 40 times
- in line 42-44(2),
50-52(2),
60,
72,
78,
87-97(8)
- in /usr/src/lib/libI77/dfe.c line
27,
42
- in /usr/src/lib/libI77/dolio.c line
11,
22
- in /usr/src/lib/libI77/due.c line
31,
43
- in /usr/src/lib/libI77/endfile.c line
33-35(2),
54,
73-78(2)
- in /usr/src/lib/libI77/err.c line
20-23(4),
40
- in /usr/src/lib/libI77/fio.h line
23
- in /usr/src/lib/libI77/sfe.c line
26,
38
- in /usr/src/lib/libI77/sue.c line
43,
54
- in /usr/src/lib/libU77/signal_.c line
30-31(2),
42,
49
ftnint
defined in line
37; used 270 times
- in line 38-46(3),
54-61(4),
67,
73,
79,
98-104(5),
116-120(3)
- in /usr/src/lib/libI77/backspace.c line
26
- in /usr/src/lib/libI77/close.c line
51,
63-64(2)
- in /usr/src/lib/libI77/dfe.c line
42
- in /usr/src/lib/libI77/dofio.c line
16-20(2)
- in /usr/src/lib/libI77/dolio.c line
22,
34
- in /usr/src/lib/libI77/douio.c line
12,
31,
39
- in /usr/src/lib/libI77/due.c line
43
- in /usr/src/lib/libI77/err.c line
35,
55
- in /usr/src/lib/libI77/fio.h line
31
- in /usr/src/lib/libI77/iio.c line
9-13(2)
- in /usr/src/lib/libI77/lread.c line
80
- in /usr/src/lib/libI77/lwrite.c line
41-44(2),
92,
101
- in /usr/src/lib/libI77/open.c line
140
- in /usr/src/lib/libI77/rdfmt.c line
134
- in /usr/src/lib/libI77/rewind.c line
22
- in /usr/src/lib/libI77/sfe.c line
38
- in /usr/src/lib/libI77/sue.c line
54
- in /usr/src/lib/libI77/wrtfmt.c line
137
- in /usr/src/lib/libU77/access_.c line
22,
30-35(3),
51-52(2)
- in /usr/src/lib/libU77/alarm_.c line
20-26(4)
- in /usr/src/lib/libU77/chdir_.c line
20,
27-31(3)
- in /usr/src/lib/libU77/chmod_.c line
17,
26-37(5)
- in /usr/src/lib/libU77/fgetc_.c line
18-19(2),
25-40(6)
- in /usr/src/lib/libU77/fork_.c line
19-27(4)
- in /usr/src/lib/libU77/fputc_.c line
18-19(2),
25-30(3),
36-38(2)
- in /usr/src/lib/libU77/fseek_.c line
22-33(9)
- in /usr/src/lib/libU77/fstat_.c line
19-27(4),
41-43(2)
- in /usr/src/lib/libU77/ftell_.c line
22
- in /usr/src/lib/libU77/getarg_.c line
16
- in /usr/src/lib/libU77/getc_.c line
18,
26-38(5)
- in /usr/src/lib/libU77/getcwd_.c line
22,
33-35(2)
- in /usr/src/lib/libU77/getenv_.c line
20,
34,
42
- in /usr/src/lib/libU77/getgid_.c line
15-17(2)
- in /usr/src/lib/libU77/getpid_.c line
15-17(2)
- in /usr/src/lib/libU77/getuid_.c line
15-17(2)
- in /usr/src/lib/libU77/hostnm_.c line
18,
30-33(2)
- in /usr/src/lib/libU77/iargc_.c line
16-18(2)
- in /usr/src/lib/libU77/idate_.c line
18(3),
25-27(3)
- in /usr/src/lib/libU77/ierrno_.c line
16-18(2)
- in /usr/src/lib/libU77/isatty_.c line
17-27(5)
- in /usr/src/lib/libU77/itime_.c line
18(3),
25-27(3)
- in /usr/src/lib/libU77/kill_.c line
16-23(6)
- in /usr/src/lib/libU77/link_.c line
20,
28-35(4)
- in /usr/src/lib/libU77/loc_.c line
14-17(3)
- in /usr/src/lib/libU77/lstat_.c line
21-22(2),
28,
43-45(2)
- in /usr/src/lib/libU77/putc_.c line
18,
26-28(2),
34-36(2)
- in /usr/src/lib/libU77/qsort_.c line
27-28(2)
- in /usr/src/lib/libU77/signal_.c line
30-31(2),
40,
52-53(2)
- in /usr/src/lib/libU77/sleep_.c line
15
- in /usr/src/lib/libU77/stat_.c line
20-21(2),
27,
42-44(2)
- in /usr/src/lib/libU77/symlnk_.c line
21,
29-36(4)
- in /usr/src/lib/libU77/system_.c line
20-32(4),
71
- in /usr/src/lib/libU77/tapeio.c line
48,
64-68(3),
75,
84,
91,
98,
111-113(2),
119-129(4),
141-143(2),
152,
158-165(3),
180,
192-194(2),
200-205(4),
211-219(3),
230,
237-239(2),
246-253(6),
259,
288,
295-297(2),
306-310(4),
321,
327-331(2),
338,
349,
358,
367,
373,
384,
391-393(2),
400,
406-421(9)
- in /usr/src/lib/libU77/ttynam_.c line
20
- in /usr/src/lib/libU77/unlink_.c line
20,
28-32(3)
- in /usr/src/lib/libU77/wait_.c line
20-28(5)
ftnlen
defined in line
39; used 59 times
- in line 63,
100,
106-122(7)
- in /usr/src/lib/libI77/dofio.c line
20
- in /usr/src/lib/libI77/dolio.c line
34
- in /usr/src/lib/libI77/douio.c line
12,
31,
39
- in /usr/src/lib/libI77/lread.c line
80
- in /usr/src/lib/libI77/lwrite.c line
41,
107,
126-131(2),
145-150(2)
- in /usr/src/lib/libI77/rdfmt.c line
13,
94,
147,
217
- in /usr/src/lib/libI77/util.c line
69,
76
- in /usr/src/lib/libI77/wrtfmt.c line
14,
85,
145,
156,
225,
249
- in /usr/src/lib/libU77/access_.c line
24
- in /usr/src/lib/libU77/chdir_.c line
22
- in /usr/src/lib/libU77/chmod_.c line
19
- in /usr/src/lib/libU77/ctime_.c line
20
- in /usr/src/lib/libU77/fdate_.c line
19
- in /usr/src/lib/libU77/fgetc_.c line
19
- in /usr/src/lib/libU77/fputc_.c line
19
- in /usr/src/lib/libU77/gerror_.c line
23
- in /usr/src/lib/libU77/getarg_.c line
18
- in /usr/src/lib/libU77/getc_.c line
19
- in /usr/src/lib/libU77/getcwd_.c line
25
- in /usr/src/lib/libU77/getenv_.c line
23
- in /usr/src/lib/libU77/getlog_.c line
21
- in /usr/src/lib/libU77/hostnm_.c line
21
- in /usr/src/lib/libU77/link_.c line
22
- in /usr/src/lib/libU77/lstat_.c line
22
- in /usr/src/lib/libU77/perror_.c line
21
- in /usr/src/lib/libU77/putc_.c line
19
- in /usr/src/lib/libU77/stat_.c line
21
- in /usr/src/lib/libU77/symlnk_.c line
23
- in /usr/src/lib/libU77/system_.c line
22
- in /usr/src/lib/libU77/tapeio.c line
69,
145,
196
- in /usr/src/lib/libU77/ttynam_.c line
20
- in /usr/src/lib/libU77/unlink_.c line
23
Defined macros
DIR
defined in line
30; used 3 times
ERROR
defined in line
18; used 1 times
EXT
defined in line
33;
never used
FMT
defined in line
31; used 6 times
INT
defined in line
34;
never used
MXUNIT
defined in line
11; used 14 times
NO
defined in line
21; used 62 times
- in /usr/src/lib/libI77/backspace.c line
19,
30
- in /usr/src/lib/libI77/close.c line
17,
59
- in /usr/src/lib/libI77/dfe.c line
29-32(2),
52
- in /usr/src/lib/libI77/dolio.c line
14,
28
- in /usr/src/lib/libI77/due.c line
24-26(2),
34-35(2)
- in /usr/src/lib/libI77/endfile.c line
18
- in /usr/src/lib/libI77/fmt.c line
273
- in /usr/src/lib/libI77/inquire.c line
16,
25
- in /usr/src/lib/libI77/lread.c line
49,
88,
391
- in /usr/src/lib/libI77/lwrite.c line
16-22(3)
- in /usr/src/lib/libI77/open.c line
28,
62,
69,
79,
88,
104,
113,
122-123(2),
132,
159-160(2)
- in /usr/src/lib/libI77/rewind.c line
16,
26
- in /usr/src/lib/libI77/riio.c line
82
- in /usr/src/lib/libI77/rwiio.c line
15-16(2),
39,
65-74(3)
- in /usr/src/lib/libI77/sfe.c line
32,
49
- in /usr/src/lib/libI77/sue.c line
33,
39,
46-48(2)
- in /usr/src/lib/libI77/util.c line
20-21(2),
52,
66
- in /usr/src/lib/libI77/wdfe.c line
17-19(2)
- in /usr/src/lib/libI77/wiio.c line
34,
46,
80
- in /usr/src/lib/libI77/wsfe.c line
17-20(2),
49
OK
defined in line
19; used 121 times
- in /usr/src/lib/libI77/backspace.c line
32-35(2),
44,
50-58(3)
- in /usr/src/lib/libI77/close.c line
46
- in /usr/src/lib/libI77/dfe.c line
18,
24,
53
- in /usr/src/lib/libI77/dofio.c line
34,
41,
68-70(2),
81-83(2)
- in /usr/src/lib/libI77/dolio.c line
31
- in /usr/src/lib/libI77/douio.c line
28,
51
- in /usr/src/lib/libI77/due.c line
18,
28,
53-58(2),
68
- in /usr/src/lib/libI77/endfile.c line
44,
51,
76
- in /usr/src/lib/libI77/fmt.c line
33
- in /usr/src/lib/libI77/inquire.c line
26,
102
- in /usr/src/lib/libI77/lread.c line
57,
75-77(2),
94,
115,
150,
168,
186,
195,
201,
241,
262-264(2),
275,
281-283(2),
299,
307,
314-321(3),
352,
362,
375-380(2)
- in /usr/src/lib/libI77/lwrite.c line
24,
32,
38,
89,
98,
113,
164,
177,
184,
190
- in /usr/src/lib/libI77/open.c line
51,
137
- in /usr/src/lib/libI77/rdfe.c line
27,
55-60(2)
- in /usr/src/lib/libI77/rdfmt.c line
68,
75-80(2),
131,
144,
214,
235,
250,
267
- in /usr/src/lib/libI77/rewind.c line
30
- in /usr/src/lib/libI77/riio.c line
25-28(2),
59,
88
- in /usr/src/lib/libI77/rsfe.c line
26,
39
- in /usr/src/lib/libI77/rwiio.c line
28,
75
- in /usr/src/lib/libI77/sfe.c line
50
- in /usr/src/lib/libI77/sue.c line
21,
40,
62,
72,
78
- in /usr/src/lib/libI77/wdfe.c line
28,
35,
48
- in /usr/src/lib/libI77/wiio.c line
19,
65
- in /usr/src/lib/libI77/wrtfmt.c line
56-61(2),
67,
94,
101,
112,
124-126(2),
134,
142,
153,
170,
185,
214,
222,
242,
267,
281
- in /usr/src/lib/libI77/wsfe.c line
31,
39,
52-56(2)
READ
defined in line
28; used 8 times
SEQ
defined in line
29; used 6 times
STDERR
defined in line
23; used 17 times
- in /usr/src/lib/libF77/main.c line
79
- in /usr/src/lib/libF77/trapov_.c line
169,
275,
296,
333,
348,
433,
460,
534,
553,
570,
627
- in /usr/src/lib/libI77/close.c line
22
- in /usr/src/lib/libI77/err.c line
168
- in /usr/src/lib/libI77/open.c line
103,
131
- in /usr/src/lib/libU77/perror_.c line
38
STDIN
defined in line
24; used 2 times
UNF
defined in line
32; used 2 times
WRITE
defined in line
27; used 8 times
YES
defined in line
20; used 55 times
- in /usr/src/lib/libI77/backspace.c line
20
- in /usr/src/lib/libI77/close.c line
18,
51
- in /usr/src/lib/libI77/dfe.c line
35,
45
- in /usr/src/lib/libI77/dolio.c line
25
- in /usr/src/lib/libI77/due.c line
15,
37,
46
- in /usr/src/lib/libI77/endfile.c line
29
- in /usr/src/lib/libI77/fmt.c line
280
- in /usr/src/lib/libI77/inquire.c line
19
- in /usr/src/lib/libI77/lread.c line
46-48(2),
65,
164,
373,
390
- in /usr/src/lib/libI77/open.c line
29,
74,
112-118(3),
161
- in /usr/src/lib/libI77/rdfe.c line
17,
42
- in /usr/src/lib/libI77/rdfmt.c line
67,
74-79(2)
- in /usr/src/lib/libI77/rewind.c line
17
- in /usr/src/lib/libI77/riio.c line
33,
45,
76-80(2)
- in /usr/src/lib/libI77/rsfe.c line
16,
35,
53
- in /usr/src/lib/libI77/rwiio.c line
19-20(2),
32,
66
- in /usr/src/lib/libI77/sfe.c line
41,
47
- in /usr/src/lib/libI77/sue.c line
17,
23,
45,
57
- in /usr/src/lib/libI77/util.c line
19-20(2),
61
- in /usr/src/lib/libI77/wrtfmt.c line
55-60(2),
66
- in /usr/src/lib/libI77/wsfe.c line
23,
45
Usage of this include