pub fn catch_keyboard_interrupt<R, F: FnOnce() -> R + UnwindSafe>(
try_fn: F,
) -> Result<R, KeyboardInterrupt>
Expand description
Runs the passed function, catching any KeyboardInterrupts if they occur while running the function.
pub fn catch_keyboard_interrupt<R, F: FnOnce() -> R + UnwindSafe>(
try_fn: F,
) -> Result<R, KeyboardInterrupt>
Runs the passed function, catching any KeyboardInterrupts if they occur while running the function.