OSDN Git Service

ChangeLogs fixed, again.
[pf3gnuchains/gcc-fork.git] / gcc / testsuite / gfortran.dg / whole_file_4.f90
1 ! { dg-do compile }
2 ! { dg-options "-fwhole-file -std=legacy" }
3 ! Tests the fix for PR24886 in which the mismatch between the
4 ! character lengths of the actual and formal arguments of
5 ! 'foo' was not detected.
6 !
7 ! Contributed by Uttam Pawar <uttamp@us.ibm.com>
8 !
9         subroutine foo(y)
10            character(len=20) :: y
11            y = 'hello world'
12         end
13
14         program test
15            character(len=10) :: x
16            call foo(x) ! { dg-warning "actual argument shorter" }
17            write(*,*) 'X=',x
18            pause
19         end