summaryrefslogtreecommitdiff
path: root/gcc/testsuite/gfortran.dg/write_padding.f90
blob: e1c37917dc40710ba51e29f8dacedfbbd5bdf4e5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
! { dg-do run }
! PR25264 Verify that the internal unit, str, is not cleared
! before it is needed elsewhere.  This is an extension.
! Test derived from test case by JPR. Contributed by
! Jerry DeLisle <jvdelisle@verizon.net>.
program write_padding
   character(len=10) :: str
   real :: atime
   str = '123'
   write( str, '(a3,i1)' ) trim(str),4
   if (str.ne."1234") call abort()
end program write_padding