Version française
Home     About     Download     Resources     Contact us    
Browse thread
Re: Why OCaml sucks
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: David Teller <David.Teller@u...>
Subject: Re: [Caml-list] Re: Why OCaml rocks
For information, Batteries Included offers for each module an
ExceptionLess submodule, which redefines exception-throwing functions as
returning either an 'a option or, for more details, an ('a, 'b) result.

A Result module complements this with monadic operations for whoever is
interested.

Cheers,
 David


On Fri, 2008-05-09 at 07:37 -0400, Ralph Douglass wrote:
> Not_found and Failure _ can be a bit annoying to watch for, so I
> suggest using Core.  The default behavior for most functions is to
> return an option instead of raising an exception.  There are _exn
> versions of the functions if you want exceptions.

-- 
David Teller
 Security of Distributed Systems
  http://www.univ-orleans.fr/lifo/Members/David.Teller
 Angry researcher: French Universities need reforms, but the LRU act brings liquidations.