public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug fortran/21471] New: 'POSITION = "APPEND"' doesn't seem to work
@ 2005-05-09 14:50 P dot Schaffnit at access dot rwth-aachen dot de
2005-05-09 17:21 ` [Bug libfortran/21471] " pinskia at gcc dot gnu dot org
` (4 more replies)
0 siblings, 5 replies; 6+ messages in thread
From: P dot Schaffnit at access dot rwth-aachen dot de @ 2005-05-09 14:50 UTC (permalink / raw)
To: gcc-bugs
Hi!
I am under the impression that the gfortran compiler doesn't (at least in some
cases) handle well the "APPEND" file access, and rather overwrites the contents
of the file...
Can you help me with that?
Thanks!
Philippe
PS: gfortran -vUsing built-in specs.
Target: i686-pc-linux-gnu
Configured with:
/USER/philippe/Irix/Compilation/gcc/Sources/Release_4_0_0/gcc/configure
--prefix=/usr1/MICRESS/Philippe/Tools/Gcc
--with-mpfr=/usr1/MICRESS/Philippe/Tools/Mpfr
--with-gmp=/usr1/MICRESS/Philippe/Tools/Gmp
Thread model: posix
gcc version 4.1.0 20050503 (experimental)
PPS: the command I use to run this test:
gfortran --static -o Hello_World Hello_World.f90 ; rm -f File ; touch File ;
./Hello_World ; cat File
PPPS: a small example I put together: "File" should contains 13 times
Hello_World, but in fact only has the last one
!======================================================================!
! **********************************************************************
! * *
! * T e s t *
! * *
! **********************************************************************
!======================================================================!
!
!======================================================================!
! Declaration
!======================================================================!
!
PROGRAM Test
!
INTEGER :: Counter
!
CHARACTER ( LEN = 250 ), PARAMETER :: String = "Hello world!"
!
!======================================================================!
! Begin
!======================================================================!
!
!
WRITE ( 6, "(/A)" ) "Beginning of screen output"
DO Counter = 1, 13
OPEN ( UNIT = 13, FILE = "File", FORM = "FORMATTED", &
& POSITION = "APPEND", STATUS = "OLD" )
WRITE ( UNIT = 13, FMT = "(A,I5)" ) TRIM(String), Counter
CLOSE ( UNIT = 13 )
WRITE ( 6, "(A,I3)" ) TRIM(String), Counter
END DO
WRITE ( 6, "(A/)" ) "End of screen output"
!
!
!======================================================================!
! End
!======================================================================!
END PROGRAM Test
--
Summary: 'POSITION = "APPEND"' doesn't seem to work
Product: gcc
Version: 4.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: fortran
AssignedTo: unassigned at gcc dot gnu dot org
ReportedBy: P dot Schaffnit at access dot rwth-aachen dot de
CC: gcc-bugs at gcc dot gnu dot org
GCC target triplet: i686-pc-linux-gnu
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21471
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libfortran/21471] 'POSITION = "APPEND"' doesn't seem to work
2005-05-09 14:50 [Bug fortran/21471] New: 'POSITION = "APPEND"' doesn't seem to work P dot Schaffnit at access dot rwth-aachen dot de
@ 2005-05-09 17:21 ` pinskia at gcc dot gnu dot org
2005-05-10 10:26 ` fxcoudert at gcc dot gnu dot org
` (3 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2005-05-09 17:21 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From pinskia at gcc dot gnu dot org 2005-05-09 17:21 -------
It is a bug in the library as it is being passed correctly to it:
_gfortran_ioparm.position = "APPEND";
_gfortran_ioparm.position_len = 6;
--
What |Removed |Added
----------------------------------------------------------------------------
Component|fortran |libfortran
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21471
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libfortran/21471] 'POSITION = "APPEND"' doesn't seem to work
2005-05-09 14:50 [Bug fortran/21471] New: 'POSITION = "APPEND"' doesn't seem to work P dot Schaffnit at access dot rwth-aachen dot de
2005-05-09 17:21 ` [Bug libfortran/21471] " pinskia at gcc dot gnu dot org
@ 2005-05-10 10:26 ` fxcoudert at gcc dot gnu dot org
2005-05-11 5:56 ` cvs-commit at gcc dot gnu dot org
` (2 subsequent siblings)
4 siblings, 0 replies; 6+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2005-05-10 10:26 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From fxcoudert at gcc dot gnu dot org 2005-05-10 10:26 -------
Confirmed. Library does not use this APPEND parameter.
Patch here: http://gcc.gnu.org/ml/fortran/2005-05/msg00095.html
--
What |Removed |Added
----------------------------------------------------------------------------
URL| |http://gcc.gnu.org/ml/fortra
| |n/2005-05/msg00095.html
Status|UNCONFIRMED |NEW
Ever Confirmed| |1
GCC target triplet|i686-pc-linux-gnu |
Keywords| |patch
Last reconfirmed|0000-00-00 00:00:00 |2005-05-10 10:26:20
date| |
Target Milestone|--- |4.0.1
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21471
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libfortran/21471] 'POSITION = "APPEND"' doesn't seem to work
2005-05-09 14:50 [Bug fortran/21471] New: 'POSITION = "APPEND"' doesn't seem to work P dot Schaffnit at access dot rwth-aachen dot de
2005-05-09 17:21 ` [Bug libfortran/21471] " pinskia at gcc dot gnu dot org
2005-05-10 10:26 ` fxcoudert at gcc dot gnu dot org
@ 2005-05-11 5:56 ` cvs-commit at gcc dot gnu dot org
2005-05-11 5:57 ` cvs-commit at gcc dot gnu dot org
2005-05-11 7:24 ` fxcoudert at gcc dot gnu dot org
4 siblings, 0 replies; 6+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2005-05-11 5:56 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-05-11 05:56 -------
Subject: Bug 21471
CVSROOT: /cvs/gcc
Module name: gcc
Changes by: fxcoudert@gcc.gnu.org 2005-05-11 05:56:20
Modified files:
gcc/testsuite : ChangeLog
libgfortran : ChangeLog
libgfortran/io : open.c
Added files:
gcc/testsuite/gfortran.dg: append-1.f90
Log message:
PR libfortran/21471
* open.c (new_unit): Take care of the case where POSITION_APPEND
is specified (sseek to the end, and set u>-endfile).
* gfortran.dg/append-1.f90: New test.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&r1=1.5462&r2=1.5463
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gfortran.dg/append-1.f90.diff?cvsroot=gcc&r1=NONE&r2=1.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/ChangeLog.diff?cvsroot=gcc&r1=1.212&r2=1.213
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/io/open.c.diff?cvsroot=gcc&r1=1.12&r2=1.13
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21471
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libfortran/21471] 'POSITION = "APPEND"' doesn't seem to work
2005-05-09 14:50 [Bug fortran/21471] New: 'POSITION = "APPEND"' doesn't seem to work P dot Schaffnit at access dot rwth-aachen dot de
` (2 preceding siblings ...)
2005-05-11 5:56 ` cvs-commit at gcc dot gnu dot org
@ 2005-05-11 5:57 ` cvs-commit at gcc dot gnu dot org
2005-05-11 7:24 ` fxcoudert at gcc dot gnu dot org
4 siblings, 0 replies; 6+ messages in thread
From: cvs-commit at gcc dot gnu dot org @ 2005-05-11 5:57 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-05-11 05:57 -------
Subject: Bug 21471
CVSROOT: /cvs/gcc
Module name: gcc
Branch: gcc-4_0-branch
Changes by: fxcoudert@gcc.gnu.org 2005-05-11 05:57:07
Modified files:
gcc/testsuite : ChangeLog
libgfortran : ChangeLog
libgfortran/io : open.c
Added files:
gcc/testsuite/gfortran.dg: append-1.f90
Log message:
PR libfortran/21471
* open.c (new_unit): Take care of the case where POSITION_APPEND
is specified (sseek to the end, and set u>-endfile).
* gfortran.dg/append-1.f90: New test.
Patches:
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.5084.2.170&r2=1.5084.2.171
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/testsuite/gfortran.dg/append-1.f90.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=NONE&r2=1.1.2.1
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/ChangeLog.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.163.2.26&r2=1.163.2.27
http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libgfortran/io/open.c.diff?cvsroot=gcc&only_with_tag=gcc-4_0-branch&r1=1.10.10.2&r2=1.10.10.3
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21471
^ permalink raw reply [flat|nested] 6+ messages in thread
* [Bug libfortran/21471] 'POSITION = "APPEND"' doesn't seem to work
2005-05-09 14:50 [Bug fortran/21471] New: 'POSITION = "APPEND"' doesn't seem to work P dot Schaffnit at access dot rwth-aachen dot de
` (3 preceding siblings ...)
2005-05-11 5:57 ` cvs-commit at gcc dot gnu dot org
@ 2005-05-11 7:24 ` fxcoudert at gcc dot gnu dot org
4 siblings, 0 replies; 6+ messages in thread
From: fxcoudert at gcc dot gnu dot org @ 2005-05-11 7:24 UTC (permalink / raw)
To: gcc-bugs
------- Additional Comments From fxcoudert at gcc dot gnu dot org 2005-05-11 07:24 -------
This one is fixed.
--
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
Resolution| |FIXED
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=21471
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2005-05-11 7:24 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-05-09 14:50 [Bug fortran/21471] New: 'POSITION = "APPEND"' doesn't seem to work P dot Schaffnit at access dot rwth-aachen dot de
2005-05-09 17:21 ` [Bug libfortran/21471] " pinskia at gcc dot gnu dot org
2005-05-10 10:26 ` fxcoudert at gcc dot gnu dot org
2005-05-11 5:56 ` cvs-commit at gcc dot gnu dot org
2005-05-11 5:57 ` cvs-commit at gcc dot gnu dot org
2005-05-11 7:24 ` fxcoudert at gcc dot gnu dot org
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).