]> git.lizzy.rs Git - rust.git/blob - src/test/ui/reachable/expr_cast.rs
Merge commit '9e3cd88718cd1912a515d26dbd9c4019fd5a9577' into clippyup
[rust.git] / src / test / ui / reachable / expr_cast.rs
1 #![allow(unused_variables)]
2 #![allow(unused_assignments)]
3 #![allow(dead_code)]
4 #![deny(unreachable_code)]
5 #![feature(never_type, type_ascription)]
6
7 fn a() {
8     // the cast is unreachable:
9     let x = {return} as !; //~ ERROR unreachable
10 }
11
12 fn main() { }