Can't we read namelists from stdin anymore ?
Janne Blomqvist
blomqvist.janne@gmail.com
Fri Oct 3 11:59:00 GMT 2014
On Fri, Oct 3, 2014 at 12:10 PM, Toon Moene <toon@moene.org> wrote:
> I have a program (that has run for years under various versions of gfortran)
> that now fails with 4.9.1.
>
> When it reads a namelist from stdin:
>
> READ (5, NAMPAR)
>
> the run time library says it fails at that very line with an end-of-file
> error.
>
> So in the script that calls the program, I changed
>
> ./program < namlis
>
> to
>
> ln -sf namlis fort.7
> ./program
>
> and the above line in
>
> READ (7, NAMPAR)
>
> and then it works flawlessly.
>
> (I have tried to change the 5 to *, but it led to the same EOF error).
>
> Seems completely legal to me to read a namelist from stdin (or TAPE 5, for
> that matter).
>
> What's your opinion ?
Yes, of course it *should* work (please file a PR, if nothing else).
The problem is that the (by now quite comprehensive!) testsuite only
tests using regular files, so bugs that only affect special files like
terminals, pipes, etc. tend to slip by undetected. Suggestions (or
even better, code!) on how to test special files within dejagnu
welcome. Or if that's not possible, perhaps creating an external
gfortran IO testsuite that can test functionality with special files
(how? when? who?).
--
Janne Blomqvist
More information about the Fortran
mailing list