Skip to main content

guard_drop

Function guard_drop 

Source
pub fn guard_drop(thunk_name: &str, f: impl FnOnce())
Expand description

Runs a destructor closure under catch_unwind for drop_handle thunks.

On panic, logs the message and returns normally, leaking whatever the destructor failed to release. A leaked value is recoverable; unwinding across the FFI boundary or aborting the process is not.