pub fn no_crash_panic() {
    let old_hook = panic::take_hook();
    panic::set_hook(Box::new(move |info| {
        old_hook(info);
        let thread = thread::current();
        let name = thread.name().unwrap_or("<unnamed>");
        println!("thread '{}' {}", name, info);
        exit(0);
    }));
}
/// Makes panics print to stdout and exit with code 0, avoiding causing a reboot.                                                       
Makes panics print to stdout and exit with code 0, avoiding causing a reboot.
Makes panics print to stdout and exit with code 0 avoiding causing a reboot .
pub fn no_crash_panic() {
    let old_hook = panic::take_hook();
    panic::set_hook(Box::new(move |info| {
        old_hook(info);
        let thread = thread::current();
        let name = thread.name().unwrap_or("<unnamed>");
        println!("thread '{}' {}", name, info);
        exit(0);
    }));
}
pub fn no_crash_panic ( ) { let old_hook = panic :: take_hook ( ) ; panic :: set_hook ( Box :: new ( move | info | { old_hook ( info ) ; let thread = thread :: current ( ) ; let name = thread . name ( ) . unwrap_or ( " " ) ; println ! ( " " name info ) ; exit ( 0 ) ; } ) ) ; }
Makes panics print to stdout and exit with code 0, avoiding causing a reboot.
Makes panics print to stdout and exit with code 0 avoiding causing a reboot .