From: blue storm <bluestorm.dylc@gmail.com>
To: yminsky@gmail.com
Cc: Yoann Padioleau <padator@wanadoo.fr>, caml-list@inria.fr
Subject: Re: [Caml-list] pattern matching and records vs tuples
Date: Wed, 15 Apr 2009 09:41:58 +0200 [thread overview]
Message-ID: <527cf6bc0904150041u7fa9e30dt3c5b5b8b0ab67ebf@mail.gmail.com> (raw)
In-Reply-To: <891bd3390904141744k4516f3d0y551f6c572ccadad5@mail.gmail.com>
On Wed, Apr 15, 2009 at 2:44 AM, Yaron Minsky <yminsky@gmail.com> wrote:
> Another thought I've had for making record matches lighter is to do the same
> kind of trick that's done with labeled arguments, i.e., have
>
> let { foo; bar } = x
>
> bind the variable foo to the x.foo, and bind bar to x.bar.
That part is achieved by the pa_records [1] syntax extension.
To my knowledge, it has not been port to post-3.10 camlp4 yet, but if
you're interested, I could probably do it.
[1] http://oandrieu.nerim.net/ocaml/#pa_records
next prev parent reply other threads:[~2009-04-15 7:41 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-04-14 14:12 Yoann Padioleau
2009-04-14 16:00 ` [Caml-list] " Christophe TROESTLER
2009-04-14 16:40 ` Goswin von Brederlow
2009-04-14 16:58 ` Yoann Padioleau
2009-04-14 20:01 ` Christophe Raffalli
2009-04-15 0:44 ` Yaron Minsky
2009-04-15 1:46 ` Pal-Kristian Engstad
2009-04-15 2:37 ` Yaron Minsky
2009-04-15 2:40 ` Ashish Agarwal
2009-04-16 16:05 ` Goswin von Brederlow
2009-04-16 16:59 ` David Allsopp
2009-04-17 0:26 ` Jacques Garrigue
2009-04-17 21:12 ` Goswin von Brederlow
2009-04-15 7:41 ` blue storm [this message]
2009-04-15 9:30 ` Martin Jambon
2009-04-15 11:01 ` Yaron Minsky
2009-04-15 12:04 ` Martin Jambon
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=527cf6bc0904150041u7fa9e30dt3c5b5b8b0ab67ebf@mail.gmail.com \
--to=bluestorm.dylc@gmail.com \
--cc=caml-list@inria.fr \
--cc=padator@wanadoo.fr \
--cc=yminsky@gmail.com \
/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