2018-08-30 14:18:55 +02:00
|
|
|
//@ run-pass
|
2025-01-23 17:05:01 +08:00
|
|
|
//@ needs-threads
|
2018-01-25 21:04:01 -08:00
|
|
|
|
2018-01-15 01:18:48 +02:00
|
|
|
#[repr(C)]
|
|
|
|
|
pub struct Foo(i128);
|
|
|
|
|
|
|
|
|
|
#[no_mangle]
|
2020-05-28 15:57:09 +01:00
|
|
|
#[allow(improper_ctypes_definitions)]
|
2018-01-15 01:18:48 +02:00
|
|
|
pub extern "C" fn foo(x: Foo) -> Foo { x }
|
|
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
|
foo(Foo(1));
|
|
|
|
|
}
|