From: Judicaël Courant <Judicael.Courant@lri.fr>
To: Patrick M Doane <patrick@watson.org>
Cc: checker@d6.com, caml-list@inria.fr
Subject: Re: [Caml-list] two unrelated questions
Date: Thu, 26 Apr 2001 08:04:15 +0200 [thread overview]
Message-ID: <20010426080415.63b4affc.Judicael.Courant@lri.fr> (raw)
In-Reply-To: <Pine.BSF.3.96.1010425202832.44330B-100000@fledge.watson.org>
Hi,
On Wed, 25 Apr 2001 20:38:43 -0400 (EDT) Patrick M Doane wrote:
>
> One way to think about exceptions is to treat them simply as control
flow
> expressions. For example, the 'break' statement is used in C/C++ to
> early-out of iteration constructs. This translates naturally to
> exceptions:
>
> exception Break
> try
> List.iter (fun .. -> ... raise Break) l
> with Break -> ()
>
Actually there is already such a predefined exception in the core library
of O'Caml. The doc says:
-------------------------------------------------------------------
exception Exit
This exception is not raised by any library function. It is provided
for use in your programs.
-------------------------------------------------------------------
Judicaël.
--
Judicael.Courant@lri.fr, http://www.lri.fr/~jcourant/
(+33) (0)1 69 15 64 85
"Montre moi des morceaux de ton monde, et je te montrerai le mien"
Tim, matricule #929, condamné à mort.
http://rozenn.picard.free.fr/tim.html
-------------------
To unsubscribe, mail caml-list-request@inria.fr. Archives: http://caml.inria.fr
next prev parent reply other threads:[~2001-04-26 6:04 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-04-25 21:08 Chris Hecker
2001-04-26 0:38 ` Patrick M Doane
2001-04-26 6:04 ` Judicaël Courant [this message]
2001-04-26 12:06 ` John Max Skaller
2001-04-27 9:12 ` Anton Moscal
2001-04-29 22:24 ` Brian Rogoff
2001-04-30 18:57 ` Fergus Henderson
2001-05-01 1:31 ` Jacques Garrigue
2001-05-01 12:45 ` [Caml-list] " Ken Friis Larsen
2001-04-27 15:09 ` [Caml-list] " Brian Rogoff
2001-04-27 17:49 ` John Max Skaller
2001-04-26 8:22 ` Andreas Rossberg
2001-04-26 1:13 ` Jacques Garrigue
2001-04-26 13:47 ` Xavier Leroy
2001-04-26 22:34 ` Chris Hecker
2001-04-26 16:57 ` Mark Seaborn
2001-04-26 22:20 ` John Max Skaller
2001-05-01 21:08 ` Brian Rogoff
2001-05-01 23:30 ` John Max Skaller
2001-05-02 0:03 ` John Max Skaller
2001-05-01 17:25 Dave Berry
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=20010426080415.63b4affc.Judicael.Courant@lri.fr \
--to=judicael.courant@lri.fr \
--cc=caml-list@inria.fr \
--cc=checker@d6.com \
--cc=patrick@watson.org \
/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