re PR fortran/78741 (ICE in gfc_get_symbol_decl, at fortran/trans-decl.c:1534)
[official-gcc.git] / gcc / testsuite / gfortran.dg / fmt_g0_4.f08
blobfff6580ebf91cafb3f415b718a09f7e446b9ceed
1 ! { dg-do compile }
2 ! { dg-options "-std=f2008" }
3 ! PR36725 Compile time error for g0 edit descriptor
4 character(30) :: line
5 write(line, '(g0.3)') 0.1
6 if (line.ne."      1.000E-01") STOP 1
7 write(line, '(g0.9)') 1.0
8 if (line.ne."1.000000000E+00") STOP 2
9 write(line, '(g0.5)') 29.23
10 if (line.ne."    2.92300E+01") STOP 3
11 write(line, '(g0.8)') -28.4
12 if (line.ne."-2.83999996E+01") STOP 4
13 write(line, '(g0.8)') -0.0001
14 if (line.ne."-9.99999975E-05") STOP 5
15 end