From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: * X-Spam-Status: No, score=1.1 required=5.0 tests=AWL,SPF_SOFTFAIL autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by yquem.inria.fr (Postfix) with ESMTP id 56EB2BC0A for ; Sun, 10 Dec 2006 20:07:09 +0100 (CET) Received: from mail2.sea5.speakeasy.net (mail2.sea5.speakeasy.net [69.17.117.4]) by concorde.inria.fr (8.13.6/8.13.6) with ESMTP id kBAJ76gN031807 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=FAIL) for ; Sun, 10 Dec 2006 20:07:08 +0100 Received: (qmail 30063 invoked from network); 10 Dec 2006 19:07:05 -0000 Received: from shell3.sea5.speakeasy.net ([69.17.116.4]) (envelope-sender ) by mail2.sea5.speakeasy.net (qmail-ldap-1.03) with AES256-SHA encrypted SMTP for ; 10 Dec 2006 19:07:05 -0000 Date: Sun, 10 Dec 2006 11:07:05 -0800 (PST) From: brogoff To: caml-list@yquem.inria.fr Subject: Re: [Caml-list] Today's inflamatory opinion: exceptions are bad In-Reply-To: <200612100632.02292.jon@ffconsultancy.com> Message-ID: References: <875c7e070612091935q2388092dr51538ff444d0e3a6@mail.gmail.com> <200612100632.02292.jon@ffconsultancy.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Miltered: at concorde with ID 457C5ADA.001 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; ocamlexc:01 ocamlexc:01 wrote:01 caml-list:01 speakeasy:01 exceptions:01 exceptions:01 checking:02 subclasses:03 brian:05 dec:05 i'd:05 i'd:05 propagate:07 arguments:07 On Sun, 10 Dec 2006, Jon Harrop wrote: > This has been done. There was a tool called ocamlexc that did whole-program > analysis to find out which exceptions could propagate where. However, it > wasn't useful enough to be kept up to date. I think the fact is that it was never part of the main distribution, and quickly became out of date. That it wasn't or wouldn't have been useful is a conclusion that you've drawn which is arguable. If ocamlexc were part of the distr I'd have it run against all the programs I build. I'd like the extra checking, but, like Richard Jones, I don't want to have that in the source code. In all of my Java I use subclasses of RuntimeException to avoid having to list exceptions. I'm not convinced by the arguments so far, or even that exceptions are only for exceptional situations. Is End_of_file really exceptional? What's the proposed alternative to End_of_file, wrapping results in option? -- Brian