Mercurial > hg > CbC > CbC_gcc
view gcc/testsuite/gfortran.dg/utf8_2.f03 @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | 84e7813d76e9 |
children |
line wrap: on
line source
! { dg-do run } ! { dg-options "-fbackslash" } ! Contributed by Tobias Burnus program test2 integer,parameter :: ucs4 = selected_char_kind("iso_10646") character(1,ucs4),parameter :: nen=char(int(z'5e74'),ucs4), & !year gatsu=char(int(z'6708'),kind=ucs4), & !month nichi=char(int(z'65e5'),kind=ucs4) !day character(25,ucs4) :: string open(10, encoding="utf-8", status="scratch") write(10,1) 2008,nen,8,gatsu,10,nichi 1 format(i0,a,i0,a,i0,a) rewind(10) read(10,'(a)') string if (string /= ucs4_"2008\u5e748\u670810\u65e5") STOP 1 end program test2