From: "Yaron Minsky" <yminsky@cs.cornell.edu>
To: "Joel Reymont" <joelr1@gmail.com>
Cc: "O'Caml Mailing List" <caml-list@yquem.inria.fr>
Subject: Re: [Caml-list] Preferred use of Invalid_argument and Failure
Date: Wed, 24 Oct 2007 09:15:36 -0400 [thread overview]
Message-ID: <891bd3390710240615j7916d8adua64ef1104f3444a8@mail.gmail.com> (raw)
In-Reply-To: <0D7AC9CC-1885-4C13-8D9F-31C2D6BEFEE2@gmail.com>
[-- Attachment #1: Type: text/plain, Size: 853 bytes --]
As in:
map_of_alist : ('a * 'b) list -> [ `Repeated_key of 'a | `Succ of ('a,'b)
Map.t ]
The return value is both explicit and a polymorphic variant.
y
On 10/24/07, Joel Reymont <joelr1@gmail.com> wrote:
>
> Yaron,
>
> On Oct 24, 2007, at 12:05 PM, Yaron Minsky wrote:
>
> > Where I work, we have come to dearly love the practice of returning
> > polymorphic variants with explicit variants for various "normal"
> > error cases.
>
> Can you elaborate? Are your explicit variants still polymorphic?
>
> --
> http://wagerlabs.com
>
>
>
>
> _______________________________________________
> Caml-list mailing list. Subscription management:
> http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
> Archives: http://caml.inria.fr
> Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
> Bug reports: http://caml.inria.fr/bin/caml-bugs
>
[-- Attachment #2: Type: text/html, Size: 1486 bytes --]
next prev parent reply other threads:[~2007-10-24 13:15 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-24 6:45 Michaël Le Barbier
2007-10-24 7:06 ` [Caml-list] " Alain Frisch
2007-10-24 8:06 ` Xavier Leroy
2007-10-24 11:05 ` Yaron Minsky
2007-10-24 11:30 ` Joel Reymont
2007-10-24 13:15 ` Yaron Minsky [this message]
2007-10-24 13:22 ` Daniel Bünzli
2007-10-24 14:45 ` Jon Harrop
2007-10-24 15:10 ` Richard Jones
2007-10-24 14:44 ` Jon Harrop
2007-10-25 7:07 ` Michaël Le Barbier
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=891bd3390710240615j7916d8adua64ef1104f3444a8@mail.gmail.com \
--to=yminsky@cs.cornell.edu \
--cc=caml-list@yquem.inria.fr \
--cc=joelr1@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;
as well as URLs for NNTP newsgroup(s).