Version française
Home     About     Download     Resources     Contact us    

This site is updated infrequently. For up-to-date information, please visit the new OCaml website at

Browse thread
[Caml-list] assertions or exceptions?
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: 2004-07-17 (14:24)
From: David MENTRE <dmentre@l...>
Subject: Re: [Caml-list] assertions or exceptions?
John Prevost <> writes:

> An example of one place in the OCaml standard libraries where I get
> irked is with various container data-structures where searching for an
> item raises "Not_found" when the item is not in the structure.  From
> my point of view, not finding something is very much expected
> behavior.

Please notice that in that very specific case you have the "mem"
function (e.g. Hashtbl.mem) that gives you the opportunity to check for
the element if you expect it missing.

 David Mentré <>

To unsubscribe, mail Archives:
Bug reports: FAQ:
Beginner's list: