Attribute Macro cpy_binder::cpy_fn_c
source · #[cpy_fn_c]
Expand description
Macro used to export exclusive C++ functions
Example
#[cpy_fn_c]
#[comment = "Format size of wheels for C ABI"]
fn format_size_of_wheels_c(sizes: *const u8, length: usize) {
let values = unsafe {
assert!(!sizes.is_null());
std::slice::from_raw_parts(sizes, length)
};
println!("Wheel sizes: {:?}", values);
}