111
|
1 ! { dg-do run }
|
|
2 ! { dg-options "-std=gnu" }
|
|
3 ! PR fortran/46588
|
|
4 ! Original code contributed by Oleh Steblev <oleh dot steblev at gmail dot com>
|
|
5 !
|
|
6 ! Issue appears to be fixed by PR 67805/68108
|
|
7 function aufun(pm)
|
|
8 character(len = *) pm
|
|
9 character(len = *) aufun
|
|
10 character(len = len(aufun)) temp
|
|
11 temp = pm
|
|
12 aufun = 'Oh' // trim(temp)
|
|
13 end function aufun
|
|
14
|
|
15 program ds
|
|
16 implicit none
|
|
17 character(len = 4) :: ins = ' no!'
|
|
18 character(len = 20) st, aufun
|
|
19 st = aufun(ins)
|
|
20 if (trim(st) /= 'Oh no!') call abort
|
|
21 end
|