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
[Caml-list] variant with tuple arg in pattern match?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Christian RINDERKNECHT <rinderkn@h...>
Subject: Re: [Caml-list] variant with tuple arg in pattern match?
Dear Caml aficionados,

On Wed, Apr 04, 2001 at 09:49:18PM +0200, Daniel de Rauglaudre wrote:
> [...] by Camlp4, I propose to represent constructors with several
> parameters with currification syntax. You can write:
>      type t1 = [ Foo of int and int ]    to specify two parameters
>      type t2 = [ Bar of (int * int) ]    to specify one parameter, a tuple

I think this syntax (and the associated patterns) is much better
indeed than the current one, but, anyway, different syntactic
constructs are worth if there is a different operational semantics,
for instance if it is then allowed to apply partially a contructor,
like in a previous version of Caml Light. I understand that efficiency
is an important issue but it should remain as _syntactically_
transparent as possible...

Best regards,



Christian Rinderknecht                     Phone +33 (0)1 60 76 44 43
Institut National des Télécommunications   Fax   +33 (0)1 60 76 47 11
Département Logiciels Réseaux (LOR)        WWW
9, Rue Charles Fourier, F-91011 Évry Cedex
To unsubscribe, mail  Archives: