Function catch_unwind

Source
pub unsafe fn catch_unwind<R, F: FnOnce() -> R>(
    f: F,
) -> Result<R, Box<dyn Any + Send>>
Expand description

Invoke a closure, capturing the cause of an unwinding panic if one occurs.