]> git.proxmox.com Git - rustc.git/blob - src/test/codegen/ffi-returns-twice.rs
New upstream version 1.51.0+dfsg1
[rustc.git] / src / test / codegen / ffi-returns-twice.rs
1 // compile-flags: -C no-prepopulate-passes
2 #![crate_type = "lib"]
3 #![feature(ffi_returns_twice)]
4
5 pub fn bar() { unsafe { foo() } }
6
7 extern "C" {
8 // CHECK-LABEL: declare void @foo()
9 // CHECK-SAME: [[ATTRS:#[0-9]+]]
10 // CHECK-DAG: attributes [[ATTRS]] = { {{.*}}returns_twice{{.*}} }
11 #[ffi_returns_twice] pub fn foo();
12 }