blob: a7f7f2fb77f711bc7ad5ea1f77cfdbba6af7fe2e [file] [log] [blame]
//@ compile-flags: -C opt-level=0
//@ needs-unwind
#![crate_type = "lib"]
// We disable optimizations to prevent LLVM from inferring the attribute.
extern "C" {
fn bar();
}
// CHECK-NOT: Function Attrs:{{.*}}nounwind
pub unsafe extern "C" fn foo() {
bar();
}
// Note that this test will get removed when `C-unwind` is fully stabilized