2 ! { dg-options "-std=legacy" }
4 ! Test of fix to bug triggered by NIST fm908.for.
5 ! Left tabbing, followed by X or T-tabbing to the right would
6 ! cause spaces to be overwritten on output data.
7 ! Contributed by Paul Thomas <pault@gcc.gnu.org>
8 ! PR25349 Revised by Jerry DeLisle <jvdelisle@gcc.gnu.org>
10 character*10 :: line
, many(5), s
11 character*10 :: aline
= "abcdefxyij"
12 character*2 :: bline
= "gh"
13 character*10 :: cline
= "abcdefghij"
16 write (line
, '(a10,tl6,2x,a2)') aline
, bline
17 if (line
.ne
.cline
) STOP 1
19 ! Character array unit test
21 write(many(1:5:2), '(a10,tl6,2x,a2)') aline
, bline
, aline
, bline
, aline
,&
23 if (many(1).ne
.cline
) STOP 2
24 if (many(3).ne
.cline
) STOP 3
25 if (many(5).ne
.cline
) STOP 4
28 write (10, '(a10,tl6,2x,a2)') aline
, bline
31 if (s
.ne
.cline
) STOP 1
32 close(10, status
='delete')
34 end program tl_editting