panik 0.2.0

Application-wide panic handling, whereby panics occurring in any thread are treated as a hard error and can be detected by other threads to trigger a graceful exit
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
mod setup;

#[test]
fn non_debug() {
    struct MyOpaque(i32);

    let result = setup::panik_builder().run_and_handle_panics_no_debug(|| MyOpaque(100));

    assert!(result.is_some());
    assert!(!panik::has_panicked());

    let opaque = result.unwrap();
    assert_eq!(opaque.0, 100);
}