Sign in
◑
Theme
gdch-oss
/
third_party
/
b503df007cec594352c4befab54bb5c29cd94cb2
/
.
/
tests
/
rust
/
box.rs
blob: 11bc2a9e4d8f2acbbfbe54c98d6dd091cf8e86f3 [
file
]
#[
repr
(
C
)]
pub
struct
MyStruct
{
number
:
Box
<
i32
>,
}
pub
struct
NotReprC
<
T
>
{
inner
:
T
,
}
pub
type
Foo
=
NotReprC
<
Box
<
i32
>>;
#[
no_mangle
]
pub
extern
"C"
fn
root
(
a
:
&
Foo
,
with_box
:
&
MyStruct
)
{}
#[
no_mangle
]
pub
extern
"C"
fn
drop_box
(
x
:
Box
<
i32
>)
{}