From dc16634f4abdb1e830d2749e64b419740702b302 Mon Sep 17 00:00:00 2001 From: Mica White Date: Thu, 26 Dec 2024 11:26:39 -0500 Subject: Commenting --- src/handle_unwind.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'src/handle_unwind.rs') diff --git a/src/handle_unwind.rs b/src/handle_unwind.rs index d515449..220d379 100644 --- a/src/handle_unwind.rs +++ b/src/handle_unwind.rs @@ -1,5 +1,6 @@ use std::panic::{catch_unwind, resume_unwind, AssertUnwindSafe}; +/// Runs `try_fn`. If it unwinds, it will run `catch` and then continue unwinding pub fn handle_unwind R, G: FnOnce()>(try_fn: F, catch: G) -> R { let try_fn = AssertUnwindSafe(try_fn); catch_unwind(try_fn).unwrap_or_else(|e| { -- cgit v1.2.3