1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
submodule(parent) child1 implicit none interface module function my_fun() result (b) integer :: b end function my_fun end interface contains module procedure my_sub1 a = 1 end procedure my_sub1 end submodule child1