
module M

  interface

     module subroutine A1()
     end subroutine A1

     module subroutine A2()
     end subroutine A2

     module subroutine B1()
     end subroutine B1

     module subroutine B2()
     end subroutine B2

  end interface

contains

  subroutine test()
    call A1()
    call A2()
    call B1()
    call B2()
    read *
  end subroutine

  subroutine P()
    print *, 'visit from parent'
  end subroutine P
  
end module M
