debug_unreachable 0.1.1

unreachable!() in debug, std::intrinsics::unreachable() in release.
Documentation
1
2
3
4
5
6
7
8
9
#[macro_use]
extern crate debug_unreachable;

#[test]
#[should_panic]
fn explodes_in_debug() {
    unsafe { debug_unreachable!() }
}