Remove old autovect-branch by moving to "dead" directory.
[official-gcc.git] / old-autovect-branch / gcc / testsuite / gfortran.dg / tl_editing.f90
blobea86873a726b163ce8f9c3dab95a5eabe64b40be
1 ! { dg-do run }
2 ! Test of fix to bug triggered by NIST fm908.for.
3 ! Left tabbing, followed by X or T-tabbing to the right would
4 ! cause spaces to be overwritten on output data.
5 ! Contributed by Paul Thomas <pault@gcc.gnu.org>
6 ! PR25349 Revised by Jerry DeLisle <jvdelisle@gcc.gnu.org>
7 program tl_editting
8 character*10 :: line, many(5), s
9 character*10 :: aline = "abcdefxyij"
10 character*2 :: bline = "gh"
11 character*10 :: cline = "abcdefghij"
13 ! Character unit test
14 write (line, '(a10,tl6,2x,a2)') aline, bline
15 if (line.ne.cline) call abort ()
17 ! Character array unit test
18 many = "0123456789"
19 write(many(1:5:2), '(a10,tl6,2x,a2)') aline, bline, aline, bline, aline,&
20 &bline
21 if (many(1).ne.cline) call abort ()
22 if (many(3).ne.cline) call abort ()
23 if (many(5).ne.cline) call abort ()
25 ! File unit test
26 write (10, '(a10,tl6,2x,a2)') aline, bline
27 rewind(10)
28 read(10, '(a)') s
29 if (s.ne.cline) call abort
31 end program tl_editting