This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
g77: read/write file access
- To: gcc-bugs at gcc dot gnu dot org
- Subject: g77: read/write file access
- From: Thomas Henlich <henlich at mmers1 dot mw dot tu-dresden dot de>
- Date: Mon, 8 Jan 2001 16:58:27 +0100
I noticed the following bug in g77 (gcc-2.95,2, DOS/djgpp and Windows
NT/mingw32 ports):
The following program does not work as expected:
===
program test
integer un
un = 11
open (un, file='test.txt')
read (un, *)
write (un, '(A)') '2'
close (un)
end
===
If the file test.txt consists of the 2 lines:
===
one
two
===
it should look like this after running the program 'test':
===
one
2
===
instead it is:
===
one
t
===
--
Thomas Henlich