Availability:C-language interface function
FALSEand the exception is accessible through
An example of a handler that can trigger an exception in PL_cut_query() is:
test_setup_call_cleanup(X) :- setup_call_cleanup( true, between(1, 5, X), throw(error)).
TRUE on the first result and the
will only run when PL_cut_query()
is run. On the other hand, if the goal in
has completed (failure, exception, determinitic success), the cleanup
handler will have done its work before control gets back to Prolog and
will have generated the exception.