caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* [Caml-list] parametric modules file layout
@ 2012-07-18  7:16 Ivan
  2012-07-18  8:19 ` Romain Bardou
  2012-07-18 14:16 ` Dan Bensen
  0 siblings, 2 replies; 3+ messages in thread
From: Ivan @ 2012-07-18  7:16 UTC (permalink / raw)
  To: caml-list


Hello!

I'm creating a functor named Forest that is parametrized by two modules: A - defines operations on assoc pair, and H - defines operations on hierarchical types. So I have three signatures : ASSOC, HIER, FOREST and one module Make. Each signature is rather large and needs to be defined both in mli and ml. 

I know, that with types the problem of code repetition can be solved by refactoring them in a separate module (a ml file with implicit mli). Is it a valid solution for signatures? Can I put a signature in the sig.ml file and then refer to it with  ``Sig.ASSOC?'' Or maybe there're other solutions or common practices to solve such problems?


Thanks, in advance.

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-07-18 14:16 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-07-18  7:16 [Caml-list] parametric modules file layout Ivan
2012-07-18  8:19 ` Romain Bardou
2012-07-18 14:16 ` Dan Bensen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).