let b:int=5

module D = struct
  let c:int=4
  module B = struct
    let a:int=3
  end
end

module A(B : sig val c : int module B : sig val a : int end end) = struct
  let b:int = B.B.a
  module B = struct
    let a:int = B.c
    let c:unit = ()
  end
  let a:unit = B.c
end

module F = A(D)

module E = struct
  let a:int=b
  let c:unit=F.a
end
