1! { dg-do compile }
2! Tests the fix for PR26779, where an error would occur because
3! init was detected to be public with a private type dummy argument.
4!
5! Contributed by Paul Thomas  <pault@gcc.gnu.org>
6!
7module test
8  public sub
9  type, private :: t
10    integer :: i
11  end type t
12contains
13  subroutine sub (arg)
14    integer arg
15    type(t) :: root
16    call init(root, arg)
17  contains
18    subroutine init(ir, i)
19      integer i
20      type(t) :: ir
21      ir%i = i
22    end subroutine init
23  end subroutine sub
24end module test
25