[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Johan Baltié <johan.baltie@w...> |
| Subject: | Re: [Caml-list] Module/Functor modelisation |
Sorry for this one, my webmail is sometimes a bit anoying > Hi ! > > I have a simple functor: > > module type Used = > sig > type output > > val toto : int -> output -> output > val tutu : double -> output -> output > end > > module type User = > functor (U : Used) -> > sig > > val toto : int -> U.output -> U.output > val tutu : double -> U.output -> U.output > end > > And User is implemented by two types doing mostly the same things with > different init, and with recursive and/or mutual call in toto an tutu. > > I'd like to factorize the shared code, BUT the recursive call prevent > me of doing this. Here an implementation example of the part where the > problem lie: > > module User1: User = > functor (U : Used) -> > struct > let toto i output = > > end > > Ciao > > Jo > ------------------- > To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr > Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ > Beginner's list: http://groups.yahoo.com/group/ocaml_beginners Ciao Jo ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners