Commit dd9eb0f7 by Jerry DeLisle

re PR libfortran/52539 (I/O: Wrong result for UTF-8/UCS-4 list-directed and…

re PR libfortran/52539 (I/O: Wrong result for UTF-8/UCS-4 list-directed and namelist read and nml write)

2014-04-26  Jerry DeLisle  <jvdelisle@gcc.gnu>

	PR libfortran/52539
	* gfortran.dg/namelist_utf8.f90: New test.

From-SVN: r209829
parent 42c1e008
2014-04-26 Jerry DeLisle <jvdelisle@gcc.gnu>
PR libfortran/52539
* gfortran.dg/namelist_utf8.f90: New test.
2014-04-26 Uros Bizjak <ubizjak@gmail.com>
* gcc.dg/tree-ssa/alias-30.c (dg-options): Dump only fre1 details.
......
! { dg-do run }
! PR52539 UTF-8 support for namelist read and write
character(len=10, kind=4) :: str, str2
character(len=25, kind=4) :: str3
namelist /nml/ str
str = 4_'a'//char (int (z'4F60'),4) &
//char (int (z'597D'), 4)//4_'b'
open(99, encoding='utf-8',form='formatted')
write(99, '(3a)') '&nml str = "', str, '" /'
write(99, '(a)') str
rewind(99)
str = 4_'XXXX'
str2 = 4_'YYYY'
read(99,nml=nml)
read(99, *) str2
if (str2 /= str) call abort
rewind(99)
read(99,'(A)') str3
if (str3 /= 4_'&nml str = "' // str // 4_'" /') call abort
read(99,'(A)') str3
if (str3 /= str) call abort
close(99, status='delete')
end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment