File: mangle.rs

package info (click to toggle)
rust-cbindgen 0.24.3-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,532 kB
  • sloc: ansic: 15; makefile: 11
file content (19 lines) | stat: -rw-r--r-- 221 bytes parent folder | download | duplicates (10)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#[repr(C)]
pub struct Foo<T> {
    a: T,
}

pub type Boo = Foo<u8>;

/// cbindgen:prefix-with-name=true
#[repr(C)]
pub enum Bar {
    Some,
    Thing,
}

#[no_mangle]
pub extern "C" fn root(
    x: Boo,
    y: Bar,
) { }