2 ! PR libgfortran/105473
8 character(40):: testinput
9 n
= 999; m
= 777; r
=1.2345
12 ! Check that semi-colon is not allowed as separator with decimal=point.
14 testinput
= '1;17;3.14159'
15 read(testinput
,*,decimal
='point',iostat
=ios
) n
, m
, r
16 if (ios
/= 5010) stop 1
18 ! Check that semi-colon allowed as a separator with decimal=point.
20 testinput
= '1.23435 1243.24 13.24 ;'
21 read(testinput
, *, iostat
=ios
) x
24 ! Check that comma is not allowed as a separator with decimal=comma.
26 testinput
= '1,17,3,14159'
27 read(testinput
,*,decimal
='comma',iostat
=ios
) n
, m
, r
28 if (ios
/= 5010) stop 3
32 testinput
= '1;17;3,14159'
33 read(testinput
,*,decimal
='comma',iostat
=ios
) n
, m
, r
36 ! Check that comma is not allowed as a separator with decimal=comma.
37 ios
=99; z
= cmplx(0.0,0.0)
38 testinput
= '1,17, (3,14159, 1,7182)'
39 read(testinput
,*,decimal
='comma', iostat
=ios
) n
, m
, z
40 if (ios
/= 5010) stop 5
42 ! Check that semi-colon is not allowed as separator with decimal=point.
43 ios
=99; z
= cmplx(0.0,0.0)
44 testinput
= '1,17; (3.14159; 1.7182)'
45 read(testinput
,*,decimal
='point', iostat
=ios
) n
, m
, z
46 if (ios
/= 5010) stop 6
49 ios
=99;z
= cmplx(0.0,0.0)
50 testinput
= '1;17; (3,14159; 1,7182)'
51 read(testinput
,*,decimal
='comma', iostat
=ios
) n
, m
, z