Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
GADT constructor syntax
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2010-12-04 (19:37)
From: gasche <gasche.dylc@g...>
Subject: Re: [Caml-list] GADT constructor syntax
I prefer option a) for the constructor form, and b) for the quantification
syntax. I'm strongly sure that the explicit quantification is a much better
choice, while I think the first choice (constructor form) is more of a
matter of taste.

I think the constructor form using "of" is better as the general function
syntax suggests currying is possible (| Foo : a -> b -> c), while it is not
possible for constructors (or you maybe it is, and then should support it).
"of foo * bar * baz" is not perfect (I prefer the revised syntax "of foo and
bar and baz"), but at least it's a consistent defect we're used to.