2020-04-16 01:50:32 -05:00
|
|
|
// run-fail
|
2014-11-04 21:31:20 -06:00
|
|
|
// error-pattern:stop
|
2020-05-07 10:39:02 -05:00
|
|
|
// ignore-emscripten no processes
|
2014-11-04 21:31:20 -06:00
|
|
|
|
|
|
|
// #18576
|
2015-10-07 17:11:25 -05:00
|
|
|
// Make sure that calling an extern function pointer in an unreachable
|
2014-11-04 21:31:20 -06:00
|
|
|
// context doesn't cause an LLVM assertion
|
|
|
|
|
|
|
|
#[allow(unreachable_code)]
|
|
|
|
fn main() {
|
|
|
|
panic!("stop");
|
|
|
|
let pointer = other;
|
|
|
|
pointer();
|
|
|
|
}
|
2020-04-16 01:50:32 -05:00
|
|
|
|
2016-05-26 21:39:36 -05:00
|
|
|
extern "C" fn other() {}
|