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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [widechar_IO_3.f90] - Blame information for rev 694

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do run { target fd_truncate } }
2
! Wide character I/O test 3, unformatted arrays
3
! Test case developed by Jerry DeLisle 
4
program test1
5
  integer, parameter :: k4 = 4
6
  character(len=10,kind=4) :: wide
7
  character(len=10,kind=4), dimension(5,7) :: widearray
8
  wide = k4_"abcdefg"
9
  widearray = k4_"1234abcd"
10
  open(10, form="unformatted", status="scratch")
11
  write(10) wide
12
  rewind(10)
13
  wide = "wrong"
14
  read(10) wide
15
  if (wide /= k4_"abcdefg") call abort
16
  rewind(10)
17
  write(10) widearray(2:4,3:7)
18
  widearray(2:4,3:7)=""
19
  rewind(10)
20
  read(10) widearray(2:4,3:7)
21
  close(10)
22
  if (any(widearray.ne.k4_"1234abcd")) call abort
23
end program test1

powered by: WebSVN 2.1.0

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