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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-old/] [gcc-4.2.2/] [gcc/] [testsuite/] [gfortran.dg/] [eof_1.f90] - 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
! Program to test for proper EOF errors when reading past the end of a file.
3
! We used to get this wrong when a formatted read followed a list formatted
4
! read.
5
program eof_1
6
  character(len=5) :: s
7
 
8
  open (unit=11, status="SCRATCH")
9
  write (11, '(a)') "Hello"
10
  rewind(11)
11
  read(11, *) s
12
  if (s .ne. "Hello") call abort
13
  read(11, '(a5)', end=10) s
14
  call abort
15
10 continue
16
  close (11)
17
end
18
 

powered by: WebSVN 2.1.0

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