File: function_ptr.rs

package info (click to toggle)
rust-cbindgen 0.27.0-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,616 kB
  • sloc: ansic: 15; makefile: 11
file content (6 lines) | stat: -rw-r--r-- 280 bytes parent folder | download | duplicates (7)
1
2
3
4
5
6
pub type MyCallback = Option<unsafe extern "C" fn(a: usize, b: usize)>;

pub type MyOtherCallback = Option<unsafe extern "C" fn(a: usize, lot: usize, of: usize, args: usize, and_then_some: usize)>;

#[no_mangle]
pub extern "C" fn my_function(a: MyCallback, b: MyOtherCallback) {}