Function ffi_utils::test_utils::call_1
[−]
[src]
pub unsafe fn call_1<F, E: Debug, T>(f: F) -> Result<T, i32> where
F: FnOnce(*mut c_void, extern "C" fn(_: *mut c_void, _: FfiResult, _: T::C)),
T: ReprC<Error = E>,
Call an FFI function and block until its callback gets called, then return
the argument which were passed to that callback.
Use this if the callback accepts one argument in addition to user_data
and error_code
.