]> git.lizzy.rs Git - rust.git/commit
Put `intrinsics::unreachable` on a possible path to stabilization
authorTobias Bucher <tobiasbucher5991@gmail.com>
Tue, 8 Aug 2017 22:47:38 +0000 (00:47 +0200)
committerTobias Bucher <tobiasbucher5991@gmail.com>
Tue, 8 Aug 2017 22:47:38 +0000 (00:47 +0200)
commit315de9c58f15612ffacac6f264e50f8f57181080
treec5030dbf392555b30b2a13991e5c7348bf36252a
parent215e0b10eac17e43f0132971f4e2dd018fc33d43
Put `intrinsics::unreachable` on a possible path to stabilization

Mark it with the `unreachable` feature and put it into the `mem` module.
This is a pretty straight-forward API that can already be simulated in
stable Rust by using `transmute` to create an uninhabited enum that can
be matched.
src/libcore/intrinsics.rs
src/libcore/mem.rs