#per-thread #panic-hook #thread-local #set-hook #update-hook

thread-local-panic-hook

Panic hooks that work per thread

1 unstable release

0.1.0 Aug 4, 2022

#14 in #per-thread

Download history 10/week @ 2024-11-13 5/week @ 2024-11-20 4/week @ 2024-11-27 17/week @ 2024-12-04 21/week @ 2024-12-11 6/week @ 2024-12-18 2/week @ 2025-01-01 10/week @ 2025-01-08 13/week @ 2025-01-15 9/week @ 2025-01-22 27/week @ 2025-01-29 40/week @ 2025-02-05 26/week @ 2025-02-12 13/week @ 2025-02-19 21/week @ 2025-02-26

103 downloads per month

GPL-3.0 license

4KB
71 lines

Thread Local Panic Hook

A simple crate that implements a std::panic::{set_hook, take_hook, update_hook} drop in replacements that work per thread.

When target family is wasm, this crate does nothing and just re-exports the std versions.


lib.rs:

This crate provides a wrapper around std::panic::{set_hook, take_hook, update_hook} that work per thread.

When building for a wasm, we just re-export the original methods found in the std library.

No runtime deps