Hi Nick,
The CINT interpreter whether it is called directly from the prompt or via ProcessLine(Fast) has its own exception handler (to avoid that the interpreter crashes upon an exception). To disable it (and to re-enable it) use :
gROOT->ProcessLine(".exception");
and your code will properly work.
Cheers,
Philippe.
-----Original Message-----
From: owner-roottalk_at_pcroot.cern.ch [mailto:owner-roottalk_at_pcroot.cern.ch]
On Behalf Of Nick West
Sent: Wednesday, February 01, 2006 4:40 AM
To: roottalk_at_pcroot.cern.ch
Subject: [ROOT] FW: Exception catching across a call to ProcessLineFast
Dear RootTalk,
Is there a limitation on ProcessLineFast that prevents code from catching an exception thrown from code called via ProcessLineFast?
i.e.
try { gROOT->ProcessLineFast("MyFunction()"); } catch(object-thrown-by-MyFunction) { ...}
and if not, can anyone see what's wrong with the attached macro where the catch works fine for a direct call but fails when the call goes via ProcessLineFast.
Note I am using ACliC; I am not expecting exception handling to be handled within CINT.
I am running Scientific Linux SL Release 3.0.4 (SL)
gcc version 3.2.3 2
With ROOT 4.04/02 build 12 September 2005
With ROOT 5.08/00 build 13 December 2005
Error: C++ exception caught :0:
and ROOT recovers but I have lost the exception information.
Thanks,
Nick West Received on Wed Feb 01 2006 - 19:57:51 MET
This archive was generated by hypermail 2.2.0 : Mon Jan 01 2007 - 16:31:57 MET