https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61632

--- Comment #18 from Dominique d'Humieres <dominiq at lps dot ens.fr> ---
> I did not say that iostat had to be used.  However, one can find 
> things like:
>
> 9.10.1     Error conditions and the ERR= specifier
>
> If an error condition occurs during execution of an input/output
> statement, the position of the file becomes indeterminate.
>
> 9.2.3.3   File position after data transfer
>
> If an error condition (9.10) occurred, the position of the file
> is indeterminate.
>
> If one explicitly uses IOSTAT= in an IO statement, it may be
> prudent to actually check its value.

AFAICT this does not change the problem (see the tests in comments 2, 3, and
15). Now if "the position of the file becomes indeterminate", I believe it
should be restored to a defined state after the error as been processed, either
after the jump to the error label for ERR= or after setting the value of
IOSTAT, see my comment

> Along this line, I have found that 'parse_format' is called only once even
> if 'ss' is called twice.

in comment 15.

Reply via email to