Files
cbindgen/tests/rust/namespaces_constant.rs
T
IGI-111 d32127e3d7 Fix #229
Place constants back inside namespace and add a test to make sure they
are namespaced correctly.
2018-10-24 11:50:03 -05:00

12 lines
180 B
Rust

const FOO: i32 = 10;
const BAR: &'static str = "hello world";
const ZOM: f32 = 3.14;
#[repr(C)]
struct Foo {
x: [i32; FOO],
}
#[no_mangle]
pub extern "C" fn root(x: Foo) { }