std::panic - Rust
Description: API documentation for the Rust `panic` mod in crate `std`.
Keywords: rust, rustlang, rust-lang, panic

# 1.9.0[−][src]Module std::panic

Panic support in the standard library.

## Structs

AssertUnwindSafe | A simple wrapper around a type to assert that it is unwind safe.
Location | A struct containing information about the location of a panic.
PanicInfo | A struct providing information about a panic.

## Traits

RefUnwindSafe | A marker trait representing types where a shared reference is considered unwind safe.
UnwindSafe | A marker trait which represents "panic safe" types in Rust.

## Functions

panic_any | Experimental Panic the current thread with the given message as the panic payload.
catch_unwind | Invokes a closure, capturing the cause of an unwinding panic if one occurs.
resume_unwind | Triggers a panic without invoking the panic hook.
set_hook | Registers a custom panic hook, replacing any that was previously registered.
take_hook | Unregisters the current panic hook, returning it.