Executes f
and afterwards executes finally
, whether f
throws an exception or
not.
handle_uncaught ~exit f
catches an exception escaping f
and prints an error
message to stderr. Exits with return code 1 if exit
is true
. Otherwise returns
unit.
handle_uncaught_and_exit f
returns f ()
, unless that raises, in which case it
prints the exception and exits nonzero.
does_raise f
returns true
iff f ()
raises, which is often useful in unit
tests.
Printexc.get_backtrace