Skip to main content

Module panic

Module panic 

Source
Available on crate feature panic and non-target_family=wasm only.
Expand description

Panic utilities.

Structs§

CaughtPanic
A panic recovered by catch_unwind_with_details, bundling the panic message with the location and backtrace captured at the panic site.

Functions§

catch_unwind
Like std::panic::catch_unwind, but can unwind panics even if install_enhanced_handler has been called.
catch_unwind_str
Like crate::panic::catch_unwind, but downcasts the returned Box<dyn Any> error to a string which is almost always is.
catch_unwind_with_details
Like catch_unwind_str, but on panic also recovers the panic’s source location and a backtrace captured at the panic site, bundled together in a CaughtPanic.
install_enhanced_handler
Overwrites the default panic handler with an enhanced panic handler.