(* TEST
flags = " -w -a "
* setup-ocamlc.byte-build-env
** ocamlc.byte
*** check-ocamlc.byte-output
*)

module Gen_spec = struct type 't extra = unit end

module type S = sig
  module Spec : sig type 't extra = unit end

  type t
  val make : unit -> t Spec.extra
end (* S *)

module Make () : S with module Spec := Gen_spec = struct
  type t = int
  let make () = ()
end (* Make *)

let () =
  let module M = Make () in
  M.make ()
  (* (M.make () : unit) *)

 TEST
flags = " -w -a "
* setup-ocamlc.byte-build-env
** ocamlc.byte
*** check-ocamlc.byte-output

 S 
 Make 
 (M.make () : unit) 

module Gen_spec = struct type 't extra = unit end

module type S = sig
  module Spec : sig type 't extra = unit end

  type t
  val make : unit -> t Spec.extra

module Make () : S with module Spec := Gen_spec = struct
  type t = int
  let make () = ()

let () =
  let module M = Make () in
  M.make ()
