annotate gcc/testsuite/gfortran.dg/string_pad_trunc.f90 @ 131:84e7813d76e9

gcc-8.2
author mir3636
date Thu, 25 Oct 2018 07:37:49 +0900
parents 04ced10e8804
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
111
kono
parents:
diff changeset
1 ! { dg-do run }
kono
parents:
diff changeset
2 ! PR20713. Pad and truncate string.
kono
parents:
diff changeset
3
kono
parents:
diff changeset
4 character(len = 6),parameter:: a = 'hello'
kono
parents:
diff changeset
5 character(len = 6),parameter:: b = 'hello *'
kono
parents:
diff changeset
6 character(len = 6),parameter:: c (1:1) = 'hello'
kono
parents:
diff changeset
7 character(len = 11) line
kono
parents:
diff changeset
8
kono
parents:
diff changeset
9 write (line, '(6A)') a, 'world'
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
10 if (line .ne. 'hello world') STOP 1
111
kono
parents:
diff changeset
11
kono
parents:
diff changeset
12 write (line, '(6A)') b, 'world'
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
13 if (line .ne. 'hello world') STOP 2
111
kono
parents:
diff changeset
14
kono
parents:
diff changeset
15 write (line, '(6A)') c, 'world'
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
16 if (line .ne. 'hello world') STOP 3
111
kono
parents:
diff changeset
17
kono
parents:
diff changeset
18 write (line, '(6A)') c(1), 'world'
131
84e7813d76e9 gcc-8.2
mir3636
parents: 111
diff changeset
19 if (line .ne. 'hello world') STOP 4
111
kono
parents:
diff changeset
20 end