OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [gfortran.dg/] [tl_editing.f90] - Blame information for rev 694

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 694 jeremybenn
! { dg-do run }
2
! { dg-options "-std=legacy" }
3
!
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  
8
! PR25349 Revised by Jerry DeLisle 
9
program tl_editting
10
  character*10           ::  line, many(5), s
11
  character*10           ::  aline = "abcdefxyij"
12
  character*2            ::  bline = "gh"
13
  character*10           ::  cline = "abcdefghij"
14
 
15
! Character unit test
16
  write (line, '(a10,tl6,2x,a2)') aline, bline
17
  if (line.ne.cline) call abort ()
18
 
19
! Character array unit test
20
  many = "0123456789"
21
  write(many(1:5:2), '(a10,tl6,2x,a2)') aline, bline, aline, bline, aline,&
22
  &bline
23
  if (many(1).ne.cline) call abort ()
24
  if (many(3).ne.cline) call abort ()
25
  if (many(5).ne.cline) call abort ()
26
 
27
! File unit test
28
  write (10, '(a10,tl6,2x,a2)') aline, bline
29
  rewind(10)
30
  read(10, '(a)') s
31
  if (s.ne.cline) call abort
32
  close(10, status='delete')
33
 
34
end program tl_editting
35
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.