1 /* Input/Output Statements */
9 { ioclause(IOSUNIT
, $
2); endioctl(); }
15 | read infmt SCOMMA inlist
17 | read ioctl SCOMMA inlist
25 |
print SCOMMA outlist
29 iofmove
: fmkwd end_spec in_ioctl
33 { iostmt
= IOREWIND
; }
35 { iostmt
= IOREWIND
; }
37 { iostmt
= IOENDFILE
; }
40 iofctl
: ctlkwd end_spec in_ioctl
44 { iostmt
= IOINQUIRE
; }
53 ioclause(IOSUNIT
, NULL);
59 ioclause(IOSUNIT
, NULL);
60 ioclause(IOSFMT
, NULL);
65 ioctl
: SLPAR fexpr SRPAR
66 { ioclause(IOSUNIT
, $
2); endioctl(); }
71 ctllist
: ioclause SCOMMA ioclause
72 | ctllist SCOMMA ioclause
76 { ioclause(IOSPOSITIONAL
, $
1); }
78 { ioclause(IOSPOSITIONAL
, NULL); }
82 { ioclause($
1, NULL); }
89 read
: SREAD end_spec in_ioctl
93 write: SWRITE end_spec in_ioctl
97 print: SPRINT end_spec fexpr in_ioctl
100 ioclause(IOSUNIT
, NULL);
101 ioclause(IOSFMT
, $
3);
104 | SPRINT end_spec SSTAR in_ioctl
107 ioclause(IOSUNIT
, NULL);
108 ioclause(IOSFMT
, NULL);
114 { $$
= mkchain($
1,0); }
115 | inlist SCOMMA inelt
116 { $$
= hookup($
1, mkchain($
3,0)); }
120 | SLPAR inlist SCOMMA dospec SRPAR
121 { $$
= mkiodo($
4,$
2); }
125 { $$
= mkchain($
1, 0); }
127 { $$
= mkchain($
1, 0); }
131 out2
: uexpr SCOMMA uexpr
132 { $$
= mkchain($
1, mkchain($
3, 0) ); }
134 { $$
= mkchain($
1, mkchain($
3, 0) ); }
136 { $$
= mkchain($
1, mkchain($
3, 0) ); }
138 { $$
= mkchain($
1, mkchain($
3, 0) ); }
140 { $$
= hookup($
1, mkchain($
3, 0) ); }
142 { $$
= hookup($
1, mkchain($
3, 0) ); }
146 | SLPAR uexpr SCOMMA dospec SRPAR
147 { $$
= mkiodo($
4, mkchain($
2, 0) ); }
148 | SLPAR other SCOMMA dospec SRPAR
149 { $$
= mkiodo($
4, mkchain($
2, 0) ); }
150 | SLPAR out2 SCOMMA dospec SRPAR
151 { $$
= mkiodo($
4, $
2); }