This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [Patch, libfortran] PR 49296 List read of file without EOR
- From: Janne Blomqvist <blomqvist dot janne at gmail dot com>
- To: Fortran List <fortran at gcc dot gnu dot org>, GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 17 Jun 2011 22:02:50 +0300
- Subject: Re: [Patch, libfortran] PR 49296 List read of file without EOR
- References: <BANLkTi=aX=B9tDAQVtVc_bB43CxsY4aJdw@mail.gmail.com>
PING.
Also, here's a slightly simplfied testcase:
! { dg-do run }
! PR 49296 List formatted read of file without EOR marker (\n).
program read_list_eof_1
implicit none
character(len=100) :: s
call genfil ()
open (unit=20, file='read.dat', form='FORMATTED', action='READ', &
status='OLD')
read (20, fmt=*) s
close (20, status='delete')
if (trim(s) /= "a") then
call abort ()
end if
contains
subroutine genfil
open(10, file='read.dat', form='unformatted', action='write', &
status='replace', access='stream')
write(10) 'a'
close(10)
end subroutine genfil
end program read_list_eof_1
On Sat, Jun 11, 2011 at 13:05, Janne Blomqvist
<blomqvist.janne@gmail.com> wrote:
> Hi,
>
> attached patch fixes PR 49296. A new test for the testsuite is also included.
>
> Regtested on x86_64-unknown-linux-gnu, Ok for trunk?
>
> 2011-06-11 ÂJanne Blomqvist Â<jb@gcc.gnu.org>
>
> Â Â Â ÂPR libfortran/49296
> Â Â Â Â* io/list_read.c (read_character): Accept EOF as a separator when
> Â Â Â Âreading string.
>
>
> --
> Janne Blomqvist
>
--
Janne Blomqvist