From: Jacques Garrigue <garrigue@math.nagoya-u.ac.jp>
To: "Daniel Bünzli" <daniel.buenzli@erratique.ch>
Cc: OCaML List Mailing <caml-list@inria.fr>
Subject: Re: [Caml-list] non-optional labels in signatures
Date: Tue, 22 Apr 2014 08:50:37 +0900 [thread overview]
Message-ID: <17AF8444-F297-4584-ADE8-D17974BE6960@math.nagoya-u.ac.jp> (raw)
In-Reply-To: <8F9F12A8E9C94118A453E000BC387897@erratique.ch>
On 2014/04/22 06:30, Daniel Bünzli wrote:
>
> Hello,
>
> This is certainly a question for Jacques Garrigue. I'm asking out of pure curiosity if there's a particular reason why non-optional labels in signatures don't have the ~ ? Is to save a keystroke ?
This was actually a difficult choice.
In O’Labl (and in OCaml 2.99), there was no ~ in expressions either; a label was an identifier followed by a colon with no space.
However, in OCaml 3.00 we chose to be more conservative, and to preserve compatibility with type annotations (i.e. do not require to add spaces around the colon).
Since the conflict with type annotations was only for expressions, this left the question of what to do with signatures.
There the decision was mostly based on esthetics: a ~ after an arrow does not look good.
I don’t think that saving a keystroke was part of this decision.
Jacques Garrigue
next prev parent reply other threads:[~2014-04-21 23:50 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-21 21:30 Daniel Bünzli
2014-04-21 23:50 ` Jacques Garrigue [this message]
2014-04-22 0:11 ` Daniel Bünzli
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=17AF8444-F297-4584-ADE8-D17974BE6960@math.nagoya-u.ac.jp \
--to=garrigue@math.nagoya-u.ac.jp \
--cc=caml-list@inria.fr \
--cc=daniel.buenzli@erratique.ch \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox