2014-08-30 03:37:11 -05:00
|
|
|
#![deny(unreachable_code)]
|
|
|
|
|
|
|
|
fn main() {
|
2023-04-15 16:43:20 -05:00
|
|
|
let x = || -> ! { panic!() };
|
2014-08-30 03:37:11 -05:00
|
|
|
x();
|
2015-06-12 13:15:57 -05:00
|
|
|
println!("Foo bar"); //~ ERROR: unreachable statement
|
2014-08-30 03:37:11 -05:00
|
|
|
}
|