rust/tests/ui/reachable/expr_oror.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

13 lines
220 B
Rust
Raw Normal View History

// build-pass (FIXME(62277): could be check-pass?)
#![allow(unused_variables)]
#![allow(dead_code)]
#![deny(unreachable_code)]
fn foo() {
let x = false || (return);
println!("I am not dead.");
}
fn main() { }