This is the mail archive of the fortran@gcc.gnu.org mailing list for the GNU Fortran project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch,libgfortran] PR28335 flush() / write() statement on closed units


On Mon, Jul 31, 2006 at 01:06:54AM +0200, Steven Bosscher wrote:
> On Monday 31 July 2006 00:54, Michael Paton wrote:
> > I've just run across the effects of this in the 20060729 snapshot, where
> > previously working code got runtime errors. It seems that Jerry's patch
> > makes it an error to attempt to CLOSE a unit which has not been OPENED, or
> > "associated". My reading of the f77 standard and a late draft of the 2003
> > standard show this to be explicitly permitted.
> 
> Do you have a pointer to a paragraph in the standard?
> 

F95 standard, Section 9.3.5, page 143, lines 6 an 7.

  Execution of a CLOSE statement specify a unit that does not
  exit or has no file connected to it is permitted and affects
  no file.

F2003 has the exact same text.  Seems we have a regression.

-- 
Steve


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]