program main
use ieee_arithmetic
complex(4), pointer :: cx1(:,:), cx2(:)
character(:), allocatable :: string
10 format(dc, 12(" (", e22.15, " ; ", e22.15, " );"))
open (1, file='valueSeparator005.data', access='stream', form='formatted')
string = repeat(' ', 800)
allocate (cx1(2,5))
cx1 = cmplx(reshape((/(i, i=-10,-1)/), (/2,5/)), &
reshape((/(i**2, i=-10,-1)/), (/2,5/)), 4)
write (string, 10) cx1
!! now read in data from both external and internal files
allocate (cx2(10))
read (string, *, decimal='coMMA') cx2
end
> a.out
fatal Fortran runtime error(t.f:23): Bad real input data at column 51 of record 1
IOT/Abort trap(coredump)
All ifort, gfortran and XLF compile and execute the program successfully.
Consider the following code
Flang failed at the runtime with
All ifort, gfortran and XLF compile and execute the program successfully.