1! { dg-do compile } 2! { dg-options "-fmodule-private" } 3module bar 4 implicit none 5 public :: i 6 integer :: i 7end module bar 8 9module foo 10 implicit none 11 integer :: j 12end module foo 13 14program main 15 use bar, only : i 16 use foo, only : j ! { dg-error "not found in module" } 17 i = 1 18 j = 1 19 print *, i, j 20end program main 21