blob: 212828679800be3cc8b67db52a82e95ff0301c54 [file] [edit]
#![deny(unreachable_code)]
#![allow(dead_code)]
use std::ptr;
pub unsafe fn g() {
return;
if *ptr::null() {}; //~ ERROR unreachable
//~| ERROR dereferencing a null pointer
}
pub fn main() {}
// https://github.com/rust-lang/rust/issues/7246