Re: All input data are in a line : tricky I/O Fortran error
- From: dpb <none@xxxxxxx>
- Date: Fri, 28 Sep 2007 09:06:24 -0500
dpb wrote:
sh wrote:On Sep 27, 7:04 pm, "Les" <l.neil...@xxxxxxxxxxxxxxxxxxx> wrote:...
I don't understand how an option like "Status='old'" would interfere
with a READ statement in a system point of view.
I mean, you open a file as "new". As soon as your write on it, the
status becomes "old" .. is that correct ?
Actually, there's a point I failed to mention I intended to...
If you OPEN a file w/ a given filename with either 'NEW' or 'UNKNOWN', on a subsequent run, the status will be determined as "old" whether you actually write any information into the new file or not. Consequently unless you could have an empty file successfully OPENed but no data in it on a subsequent run while in the process of testing, for example.
You would have to either use the DISPOSE specifier or otherwise fix this before the next run or an OPEN with the 'NEW' status will fail.
You could also inadvertently trash an existing data file while testing if you were to OPEN it without specifying 'READ' for the ACTION specifier and subsequently execute a WRITE to that unit so the file may no longer contain the data you think it does.
In debugging, you may want to not use a STATUS= specifiers on any of the i/o statements in the problem area so the default runtime errors will be displayed which may lead you more directly to the underlying problem that the internal error/information message seems to be confusing.
You might also uncover some hidden problems confusing issues if you compile w/ debugging options on including bounds checking just in case there's something peculiar going on there confounding the problems...
HTH...
--
.
- References:
- Prev by Date: Re: how to call C (non-intel C compiler) from ifort (intel fortran)?
- Next by Date: RE: Wade Ward
- Previous by thread: Re: All input data are in a line : tricky I/O Fortran error
- Next by thread: Re: All input data are in a line : tricky I/O Fortran error
- Index(es):