diff options
Diffstat (limited to 'tests/rust/namespace_constant.rs')
-rw-r--r-- | tests/rust/namespace_constant.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/tests/rust/namespace_constant.rs b/tests/rust/namespace_constant.rs new file mode 100644 index 0000000..01a8450 --- /dev/null +++ b/tests/rust/namespace_constant.rs @@ -0,0 +1,11 @@ +pub const FOO: i32 = 10; +pub const BAR: &'static str = "hello world"; +pub const ZOM: f32 = 3.14; + +#[repr(C)] +struct Foo { + x: [i32; FOO], +} + +#[no_mangle] +pub extern "C" fn root(x: Foo) { } |