Exception Raiser not called
Posted: 15 Sep 2014 14:44
Hi Thomas and all,
my user defined run-time exception raiser does not get called by exception::raise_error and similar predicates (in VIP 7.5). The below code shows the problem. Is the behavior intended, resp. is there a way to set an exception raiser, which will be called on all kinds of exceptions?
Regards
Martin
my user defined run-time exception raiser does not get called by exception::raise_error and similar predicates (in VIP 7.5). The below code shows the problem. Is the behavior intended, resp. is there a way to set an exception raiser, which will be called on all kinds of exceptions?
Regards
Martin
Code: Select all
class facts
originalOnException : programControl::exceptionRaiser := erroneous.
class predicates
onException : programControl::exceptionRaiser.
clauses
onException(TraceId) :-
stdIo::write("my user defined run-time exception raiser was called\n"),
originalOnException(TraceId).
clauses
run() :-
originalOnException := programControl::setRuntimeExceptionRaiser(onException),
exception::raise_error().