[][src]Module safer_ffi::closure

Closures with a #[repr(C)] layout (inlined vtable), up to 9 function arguments.

Simplified for lighter documentation, but the actual struct definitions and impls range up to ...DynFn...9.

Re-exports

pub use self::arc::ArcDynFn0;
pub use self::arc::ArcDynFn1;
pub use self::boxed::BoxDynFnMut0;
pub use self::boxed::BoxDynFnMut1;
pub use borrowed::RefDynFnMut0;
pub use borrowed::RefDynFnMut1;

Modules

arcfeature="alloc"

Arc<dyn 'static + Send + Sync + Fn(...) -> _> but with a #[repr(C)] layout (inlined virtual method table).

borrowed

&'lt mut (dyn 'lt + Send + FnMut(...) -> _> but with a #[repr(C)] layout (env ptr + function ptr).

boxedfeature="alloc"

Box<dyn 'static + Send + FnMut(...) -> _> but with a #[repr(C)] layout (inlined virtual method table).