gcc/libgfortran/io
Thomas Koenig 108bc19009 re PR libfortran/34370 (file positioning after nonadvancing i/o)
2007-12-13  Thomas Koenig  <tkoenig@gcc.gnu.org>

	PR libfortran/34370
	PR libfortran/34323
	PR libfortran/34405
	* io/io.h:  Add previous_nonadvancing_write to gfc_unit.
	Add prototype for finish_last_advance_record.
	* io/file_pos.c (st_backspace):  Generate error if backspace is
	attempted for direct access or unformatted stream.
	If there are bytes left from a previous ADVANCE="no", write
	them out before performing the backspace.
	(st_endfile):  Generate error if endfile is attempted for
	direct access.
	If there are bytes left from a previous ADVANCE="no", write
	them out before performing the endfile.
	(st_rewind):  Generate error if rewind is attempted for
	direct access.
	* unit.c (close_unit_1):  Move functionality to write
	previously written bytes to...
	(finish_last_advance_record):  ... here.
	* transfer.c (data_transfer_init):  If reading, reset
	previous_nonadvancing_write.
	(finalize_transfer):  Set the previous_noadvancing_write
	flag if we are writing and ADVANCE="no" was specified.
	Only call next_record() if advance="no" wasn't specified.

2007-12-13  Thomas Koenig  <tkoenig@gcc.gnu.org>

	PR libfortran/34370
	PR libfortran/34323
	PR libfortran/34405
	* gfortran.dg/advance_6.f90:  New test case.
	* gfortran.dg/direct_io_7.f90:  New test case.
	* gfortran.dg/streamio_13.f90:  New test case.

From-SVN: r130912
2007-12-13 19:35:09 +00:00
..
close.c re PR fortran/31675 (Fortran front-end and libgfortran should have a common header file) 2007-09-03 16:44:15 +00:00
file_pos.c re PR libfortran/34370 (file positioning after nonadvancing i/o) 2007-12-13 19:35:09 +00:00
format.c re PR fortran/31675 (Fortran front-end and libgfortran should have a common header file) 2007-09-03 16:44:15 +00:00
inquire.c re PR libfortran/33055 (Runtime error in INQUIRE unit existance with -fdefault-integer-8) 2007-10-15 13:59:02 +00:00
intrinsics.c minloc1.m4: Update copyright year and ajust headers order. 2007-08-31 14:01:34 +00:00
io.h re PR libfortran/34370 (file positioning after nonadvancing i/o) 2007-12-13 19:35:09 +00:00
list_read.c re PR libfortran/34427 (Revision 130708 breaks namelist input) 2007-12-13 12:01:00 +01:00
lock.c minloc1.m4: Update copyright year and ajust headers order. 2007-08-31 14:01:34 +00:00
open.c re PR fortran/31675 (Fortran front-end and libgfortran should have a common header file) 2007-09-03 16:44:15 +00:00
read.c re PR fortran/34411 (hang-up during read of non-expected input) 2007-12-11 03:49:52 +00:00
size_from_kind.c minloc1.m4: Update copyright year and ajust headers order. 2007-08-31 14:01:34 +00:00
transfer.c re PR libfortran/34370 (file positioning after nonadvancing i/o) 2007-12-13 19:35:09 +00:00
unit.c re PR libfortran/34370 (file positioning after nonadvancing i/o) 2007-12-13 19:35:09 +00:00
unix.c re PR fortran/33795 (Environment variable GFORTRAN_UNBUFFERED_<number> not working) 2007-10-19 04:10:58 +00:00
write_float.def re PR libfortran/33225 (Missing last digit in some formatted output (on 32bit targets), per kind write_float) 2007-09-05 00:51:18 +00:00
write.c re PR libfortran/33469 (Default formats for real input are not precise enough) 2007-10-02 23:27:51 +00:00