RE:Exception handling

Masaharu Goto (MXJ02154@nifty.ne.jp)
Mon, 5 Jul 1999 19:37:51 +0900


Dear George Heintzelman,

Cint has very limited capability about the exception handling. It is
recommended not to use exception handling in interpreted code at all.

In your message, it was not clear to me whether exception is thrown
from compiled code or interpreted code. You can not catch an exception
thrown by compiled code by an interpreted program or vise-versa. If
you try to mix them, it will never work. Once I examined this to work,
but there is a fundamental limitation in C++ language which makes this
impossible.

Thank you
Masaharu Goto

=============================================================
Rooters,

I observed in the documentation that ROOT/CINT supports exceptions when
the exception being thrown is an object type. Fine, I thought, that's
really the most useful form of exception anyway, and wrote some
Root-based code using them.

Running the code interactively, I made a mistake and caused an
exception to be thrown, which was not caught. When this happened, the
entire ROOT executable terminated.

This is, I think, not the desired behavior when Root/Cint is being
controlled from the command line -- exceptions should probably be
caught at the outer loop, any executing macros terminated and the user
returned to the command prompt with a message indicating that an
uncaught exception was thrown.

How hard would this be to implement?

George Heintzelman
gah@bnl.gov