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 PAA14428 for caml-red; Mon, 30 Oct 2000 15:52:08 +0100 (MET) Received: from concorde.inria.fr (concorde.inria.fr [192.93.2.39]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id MAA14759 for ; Mon, 30 Oct 2000 12:34:34 +0100 (MET) Received: from pcrm.win.tue.nl (pcrm.win.tue.nl [131.155.69.41]) by concorde.inria.fr (8.11.1/8.10.0) with ESMTP id e9UBYXP13368; Mon, 30 Oct 2000 12:34:33 +0100 (MET) Received: from pcrm (stephan@localhost [127.0.0.1]) by pcrm.win.tue.nl (8.9.3/8.9.3/SuSE Linux 8.9.3-0.1) with SMTP id MAA32215; Mon, 30 Oct 2000 12:37:47 +0100 From: Stephan Houben Reply-To: stephanh@win.tue.nl Organization: Scientific Computing Group To: Pierre Weis , orodeh@cs.huji.ac.il (Ohad Rodeh) Subject: Re: Where did the exception occur? Date: Mon, 30 Oct 2000 12:33:35 +0100 X-Mailer: KMail [version 1.0.28] Content-Type: text/plain Cc: caml-list@inria.fr References: <200010301102.MAA16616@pauillac.inria.fr> In-Reply-To: <200010301102.MAA16616@pauillac.inria.fr> MIME-Version: 1.0 Message-Id: <00103012374700.31696@pcrm> Content-Transfer-Encoding: 8bit Sender: weis@pauillac.inria.fr On Mon, 30 Oct 2000, Pierre Weis wrote: > > List, > > I'd like to point out, that my application (LARGE OCaml project) is > > embedded in C code, so one cannot use the OCaml debugger to replay and > > find the exception. I'd be happy if a feature would be added to the > > language to point out which line in the code the exception came from (I > > understand this was added to SML ?). > Otherwise, the addition you mentioned is interesting, if only we could > implement it with no penalty on the speed of exception raising. Have > you an idea of such a compilation scheme ? I'm not the OP, but this can of course be implemented by having an additional (hidden) field in the exception which contains the source co-ordinate. I'm not sure how expensive this would be. But it would be useful to have, at least as a compiler option. I suppose raising of an exception is expected to be slow anyway, as opposed to installing an exception handler. Stephan -- ir. Stephan H.M.J. Houben tel. +31-40-2474358 / +31-40-2743497 e-mail: stephanh@win.tue.nl