* cfgloopmanip.c (duplicate_loop_to_header_edge): Cleanup profile
[official-gcc.git] / gcc / testsuite / gfortran.dg / list_read_14.f90
blob15bcfad500dd8ec1d6cfbcfdc8ad2575e757f177
1 ! { dg-do run }
2 ! PR70684 incorrect reading of values from file on Windows
3 program test
4 implicit none
5 integer,parameter :: isize=12
6 integer,parameter :: funit=12
7 integer :: i
8 character(1), parameter :: cr=char(13)
9 double precision, dimension(isize) :: a, res
10 res= (/ 1.0000000000000000, 2.0000000000000000, 3.0000000000000000, &
11 4.0000000000000000, 5.0000000000000000, 6.0000000000000000, &
12 7.0000000000000000, 8.0000000000000000, 9.0000000000000000, &
13 10.000000000000000, 11.000000000000000, 12.000000000000000 /)
14 do i=1,isize
15 a(i)=dble(i)
16 enddo
17 open(funit,status="scratch")
18 write(funit,'(1x,6(f25.20,'',''),a)') (a(i),i=1,6), cr
19 write(funit,'(1x,6(f25.20,'',''),a)') (a(i),i=7,12), cr
20 rewind(funit)
21 a=0d0
22 read(funit,*) (a(i),i=1,isize)
23 close(funit)
24 if (any(a /= res)) call abort
25 end