Sheltran - I/O statements


Form:

      ...,ERR=<exit specifier>,... 
      and/or 
      ...,END=<exit specifier>,...

Notes:

Actions:

The use of <procedure name> is equivalent to a PERFORM of the procedure between the I/O statement and the statement following it. The use of the other items will have the normal SHELTRAN meaning.

Example:

      WHILE .TRUE.
         READ(1,FMT='(A)',END=XWHILE,ERR=ERRPRC) LINE
         WRITE(2,FMT='(1X,A)',ERR=ERRPRC) LINE 
      CWHILE
         .
         .
         .
      PROC ERRPRC 
         REWIND 1
         REWIND 2
      CPROC

Programming GIPSY