(j3.2006) Question about defined I/O
Wed Jan 27 03:57:58 EST 2016
>If a defined input subroutine returns a nonzero iostat, is further
>processing of the input list terminated, and do further input list items
>If a defined output subroutine returns a nonzero iostat, is further
>processing of the output list terminated?
>188.8.131.52.3p17-19 are silent concerning these questions.
The standard however, is not.
>is further processing of the [input/output] list terminated
Not standardised. It might seem unlikely, but some list items could in
theory be evaluated in parallel (some of this could happen automatically
with some kinds of code generators). We could mandate that list items
before a defined-i/o invocation are fully processed, and ones after a
failing one are not processed at all, but it is unclear that this would do
more than encourage scary and unreliable programming styles.
>do further input list items become undefined
No. ***ALL*** input list items become undefined.
"If an error condition occurs ... if the statement is a READ statement
..., all input items or namelist group objects in the statement ... become
This is of course in 9.11.2 Error conditions and the ERR= specifier, which
makes no distinction between normal i/o and defined i/o.
........................Malcolm Cohen, Nihon NAG, Tokyo.
More information about the J3