Debian Codegraph @

.cargo/vendor/cbindgen/tests/rust/reserved.rs

raw
1 #[repr(C)]
2 struct A {
3 namespace: i32,
4 float: f32,
5 }
6
7 /// cbindgen:field-names=[namespace, float]
8 #[repr(C)]
9 struct B(i32, f32);
10
11 #[repr(C, u8)]
12 enum C {
13 D { namespace: i32, float: f32 },
14 }
15
16 #[repr(C, u8)]
17 enum E {
18 Double(f64),
19 Float(f32),
20 }
21
22 #[repr(C, u8)]
23 enum F {
24 double(f64),
25 float(f32),
26 }
27
28 #[no_mangle]
29 pub extern "C" fn root(
30 a: A,
31 b: B,
32 c: C,
33 e: E,
34 f: F,
35 namespace: i32,
36 float: f32,
37 ) { }