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

Subversion Repositories openrisc

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

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

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do run }
2
! { dg-options "-fbackslash" }
3
!
4
! PR fortran/37025
5
!
6
! Check whether transferring to character(kind=4) and transferring back works
7
!
8
implicit none
9
character(len=4,kind=4) :: str
10
integer(4) :: buffer(4) = [int(z'039f'),int(z'03cd'),int(z'03c7'),  &
11
                           int(z'30b8') ], &
12
              buffer2(4)
13
 
14
open(6,encoding="UTF-8")
15
str = transfer(buffer, str)
16
!print *, str
17
!print *, 4_'\u039f\u03cd\u03c7\u30b8'
18
if (str /= 4_'\u039f\u03cd\u03c7\u30b8') call abort()
19
str = transfer([int(z'039f'),int(z'03cd'),int(z'03c7'),  &
20
                           int(z'30b8') ], str)
21
if (str /= 4_'\u039f\u03cd\u03c7\u30b8') call abort()
22
 
23
buffer2 = transfer(4_'\u039f\u03cd\u03c7\u30b8', buffer2, 4)
24
!print *, buffer
25
!print *, buffer2
26
buffer2 = transfer(str, buffer2, 4)
27
if (any(buffer2 /= buffer)) call abort()
28
end

powered by: WebSVN 2.1.0

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