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
Re: [Caml-list] Future of labels
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2001-04-11 (15:32)
From: Jacques Garrigue <garrigue@k...>
Subject: Re: [Caml-list] Future of labels, and ideas for library labelling
From: (François-René Rideau)

> You left without discussion the approach suggested by Arturo Borquez,
> which is quite distinct from that by Chris Hecker:
> "An unlabeled argument should be labeled with the first available label
> in the declared type of the function being called."

I might have worded my classification in this (less understandable
way): all proposals have to choose between two types of unification,
strictly matching labels or ignoring them.

You must ignore them to be compatible with classic mode.
You must match them strictly to be compatible with label mode (provide
commutation with any decent semantics).

So this is just impossible to be compatible with both simultaneously.
To some degree you may allow idioms of classic mode in label mode
(like dropping some labels), but not the other way round, and not 100%

This is the basic reason I didn't try to answer in detail all

The rule you describe here might also be seen as an alternative to
label mode (yet incompatible with classic mode). However it is not
compatible with label mode, semantics are a bit more complex, and
this idea of choosing label by label whether to write or not sounds a
bit too laxist to me (not a good reason, but the other two are).


Jacques Garrigue
To unsubscribe, mail  Archives: