]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-18576.rs
point at private fields in struct literal
[rust.git] / src / test / ui / issues / issue-18576.rs
1 // run-fail
2 // error-pattern:stop
3 // ignore-emscripten no processes
4
5 // #18576
6 // Make sure that calling an extern function pointer in an unreachable
7 // context doesn't cause an LLVM assertion
8
9 #[allow(unreachable_code)]
10 fn main() {
11     panic!("stop");
12     let pointer = other;
13     pointer();
14 }
15
16 extern "C" fn other() {}