1! PR fortran/47331
2! { dg-do compile }
3! { dg-options "-fopenmp" }
4
5subroutine foo
6  !$omp parallel
7    call bar ()
8  !$omp end parallel
9end subroutine foo
10
11subroutine bar
12  integer :: k
13  do k=1,5
14    call baz (k)
15  end do
16end subroutine bar
17
18subroutine baz (k)
19  integer :: k
20end subroutine
21
22program pr47331
23  call foo
24end program pr47331
25