From: "Frédéric Gava" <gava@univ-paris12.fr>
To: David Thomas <david_hd@yahoo.com>
Cc: caml-list@yquem.inria.fr
Subject: Re: [Caml-list] Anti-matching
Date: Sun, 24 Jun 2007 14:32:07 +0200 [thread overview]
Message-ID: <467E6447.4030606@univ-paris12.fr> (raw)
In-Reply-To: <20070624105238.82437.qmail@web30511.mail.mud.yahoo.com>
David Thomas a écrit :
> Isn't "!(x) -> a | _ -> b" the same as "x -> b | _ ->
> a"? I don't really see much of a benefit, at the cost
> (I assume) of complexity.
In this case, yes. But you can express interesting (more easier) thinks
as (examples of TOM)
!f(x,x) -> // matches either something different from f, or an f with x1
!= x2
f(x,!g(x)) -> {
// matches an f which has either x2!=g or x2=g(y) with y != x1
You can simulating this using classical pattern matching. So I thinks
that is possible using camlp4. But, looking for someone you have do this
work or plan to do this.
FG
prev parent reply other threads:[~2007-06-24 12:32 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-06-08 8:36 Intended behavior of GenerateMap Christian Stork
2007-06-13 11:36 ` [Caml-list] " Nicolas Pouillard
2007-06-14 12:35 ` Nicolas Pouillard
2007-06-23 18:59 ` Nicolas Pouillard
2007-06-23 21:04 ` Christian Stork
2007-06-24 8:13 ` Nicolas Pouillard
2007-06-24 10:21 ` Anti-matching Frédéric Gava
2007-06-24 10:52 ` [Caml-list] Anti-matching David Thomas
2007-06-24 12:32 ` Frédéric Gava [this message]
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=467E6447.4030606@univ-paris12.fr \
--to=gava@univ-paris12.fr \
--cc=caml-list@yquem.inria.fr \
--cc=david_hd@yahoo.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