OSDN Git Service

2006-06-20 Steven G. Kargl <kargls@comcast.net>
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gfortran.dg / fmt_tl.f
1 ! { dg-do run }
2 ! PR25631 Check that TL editing works for special case of no bytes written yet.
3 ! Contributed by Jerry DeLisle  <jvdelisle@gcc.gnu.org>
4       real x
5       character*15 line
6       x = 12.34
7       write(line,10) x
8  10   format(tr2,tl2,g11.4)
9       if (line.ne.'  12.34        ') call abort()
10       write(line,20) x
11  20   format(tr5,tl3,g11.4)
12       if (line.ne.'    12.34      ') call abort()
13       write(line,30) x
14  30   format(tr5,tl3,tl3,g11.4)
15       if (line.ne.'  12.34        ') call abort()
16       write(line,40) x
17  40   format(tr25,tl35,f11.4)
18       if (line.ne.'    12.3400    ') call abort()
19       write(line,50) x
20  50   format(tl5,tr3,f11.4)
21       if (line.ne.'       12.3400 ') call abort()
22       write(line,60) x
23  60   format(t5,tl3,f11.4)
24       if (line.ne.'     12.3400   ') call abort()
25       end