I know that circular dependence of modules in FORTRAN is forbidden. But I am wondering how strong that proscription is. Let's say I have:
module mod1
integer, public :: i,j,k
use mod2, only: m
end module mod1
and
module mod2
integer, public :: l,m,n
use mod1, only: j
end module mod2
It seems to me that this evades circularity in a logical sense, but that doesn't mean the standard allows it. Should it work?
If so, I am having trouble compiling because, of course, mod1 wants to see mod2 and vice versa. Is there a way around this?