1 ! { dg-do run { target fd_truncate } }
2 ! Wide character I/O test 3, unformatted arrays
3 ! Test case developed by Jerry DeLisle <jvdelisle@gcc.gnu.org>
5 integer, parameter :: k4
= 4
6 character(len
=10,kind
=4) :: wide
7 character(len
=10,kind
=4), dimension(5,7) :: widearray
9 widearray
= k4_
"1234abcd"
10 open(10, form
="unformatted", status
="scratch")
15 if (wide
/= k4_
"abcdefg") STOP 1
17 write(10) widearray(2:4,3:7)
20 read(10) widearray(2:4,3:7)
22 if (any(widearray
.ne
.k4_
"1234abcd")) STOP 2