OpenCores
URL https://opencores.org/ocsvn/openrisc_me/openrisc_me/trunk

Subversion Repositories openrisc_me

[/] [openrisc/] [trunk/] [gnu-src/] [gcc-4.2.2/] [gcc/] [testsuite/] [gfortran.dg/] [overwrite_1.f] - Blame information for rev 149

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 149 jeremybenn
! { dg-do run } 
2
! PR 19872 - closed and re-opened file not overwriten
3
      implicit none
4
      integer i(4)
5
      data i / 4 * 0 /
6
      open(1,form='FORMATTED',status='UNKNOWN')
7
      write(1,'("1 2 3 4 5 6 7 8 9")')
8
      close(1)
9
      open(1,form='FORMATTED')
10
      write(1,'("9 8 7 6")')
11
      close(1)
12
      open(1,form='FORMATTED')
13
      read(1,*)i
14
      if(i(1).ne.9.and.i(2).ne.8.and.i(3).ne.7.and.i(4).ne.9)call abort
15
      read(1,*,end=200)i
16
! should only be able to read one line from the file
17
      call abort
18
 200  continue
19
      close(1,STATUS='DELETE')
20
      end

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.