Function ffi_support::call_with_output[][src]

pub fn call_with_output<R, F>(
    out_error: &mut ExternError,
    callback: F
) -> R::Value where
    F: UnwindSafe + FnOnce() -> R,
    R: IntoFfi

Call a callback that returns a T while:

Note that you still need to provide an ExternError to this function, to report panics.

See call_with_result if you’d like to return a Result<T, E> (Note: E must be convertible to ExternError).

This (or call_with_result) should be in the majority of the FFI functions, see the crate top-level docs for more info.