Le 10/04/2012 15:57, David House a écrit :
On Tue, Apr 10, 2012 at 2:51 PM, Gabriel Kerneis<kern...@pps.jussieu.fr> wrote:
Is there any work-around?
Depending on your requirements, just wrapping up the recursive copy of
[t] in another constructor might do:
type t = [ `A of [ `B | `C of t ]]
I don't know why your original example is disallowed.
I think the semantic of [t|...] is just to syntactically replace t by
its definition, which is not possible if the definition is not done yet.
Cheers,
--
Romain Bardou
--
Caml-list mailing list. Subscription management and archives:
https://sympa-roc.inria.fr/wws/info/caml-list
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs