From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (from weis@localhost) by pauillac.inria.fr (8.7.6/8.7.3) id RAA01764 for caml-red; Tue, 31 Oct 2000 17:48:26 +0100 (MET) Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id NAA32128 for ; Tue, 31 Oct 2000 13:11:35 +0100 (MET) Received: from mail.pi.se (mail.pi.se [195.7.64.8]) by nez-perce.inria.fr (8.11.1/8.10.0) with ESMTP id e9VCBY501413; Tue, 31 Oct 2000 13:11:34 +0100 (MET) Received: from gateway ([195.7.85.166]) by mail.pi.se (8.8.8/8.8.8) with SMTP id NAA20941; Tue, 31 Oct 2000 13:11:33 +0100 (MET) From: "Mattias Waldau" To: "Damien Doligez" , Subject: RE: Where did the exception occur? Date: Tue, 31 Oct 2000 13:09:59 +0100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2911.0) Importance: Normal X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 In-reply-to: <200010311014.LAA0000024214@beaune.inria.fr> Sender: weis@pauillac.inria.fr Static analysis wouldn't have help me in my case, since I know that I can get Not_found in 10 different places. Of cource, I could catch each of these at their location, and raise a specific exception for each. This, however, would mess up the code. /mattias -----Original Message----- From: Pierre.Weis@inria.fr [mailto:Pierre.Weis@inria.fr]On Behalf Of Damien Doligez Sent: Tuesday, October 31, 2000 11:14 AM To: caml-list@inria.fr Subject: Re: Where did the exception occur? >From: "David McClain" >I found that the location of the exception is rarely the source of >a problem... Indeed, this discussion started because of an uncaught "Not_found". Most likely, this is raised by Hashtbl.find, List.assoc, or String.index (there are a few other). Knowing exactly which one is unlikely to help very much. I don't like the idea of adding run-time information just for the case when you cannot run the debugger, especially if it incurs a lot of overhead. IMO, it would be more interesting to make the debugger work for embedded code. In the short term, static analysis seems to be the way to go. -- Damien