1! { dg-do compile }
2!
3! PR 35831: [F95] Shape mismatch check missing for dummy procedure argument
4!
5! Contributed by Janus Weil <janus@gcc.gnu.org>
6
7program test_attributes
8
9  call tester1 (a1)   ! { dg-error "ASYNCHRONOUS mismatch in argument" }
10  call tester2 (a2)   ! { dg-error "CONTIGUOUS mismatch in argument" }
11  call tester3 (a1)   ! { dg-error "VALUE mismatch in argument" }
12  call tester4 (a1)   ! { dg-error "VOLATILE mismatch in argument" }
13
14contains
15
16  subroutine a1(aa)
17    real :: aa
18  end subroutine
19
20  subroutine a2(bb)
21    real :: bb(:)
22  end subroutine
23
24  subroutine tester1 (f1)
25    interface
26      subroutine f1 (a)
27        real, asynchronous :: a
28      end subroutine
29    end interface
30  end subroutine
31
32  subroutine tester2 (f2)
33    interface
34      subroutine f2 (b)
35        real, contiguous :: b(:)
36      end subroutine
37    end interface
38  end subroutine
39
40  subroutine tester3 (f3)
41    interface
42      subroutine f3 (c)
43        real, value :: c
44      end subroutine
45    end interface
46  end subroutine
47
48  subroutine tester4 (f4)
49    interface
50      subroutine f4 (d)
51        real, volatile :: d
52      end subroutine
53    end interface
54  end subroutine
55
56end
57