blob: be983f8b022084406a5b8681554a7199b18add58 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
! { dg-do compile }
!
! PR 35831: [F95] Shape mismatch check missing for dummy procedure argument
!
! Contributed by Tobias Burnus <burnus@gcc.gnu.org>
program test
implicit none
interface
subroutine one(a)
integer a(:)
end subroutine
subroutine two(a)
integer a(2)
end subroutine
end interface
call foo(two) ! { dg-error "Shape mismatch in argument" }
call bar(two) ! { dg-error "Shape mismatch in argument" }
contains
subroutine foo(f1)
procedure(one) :: f1
end subroutine foo
subroutine bar(f2)
interface
subroutine f2(a)
integer a(:)
end subroutine
end interface
end subroutine bar
end program
|