Skip to main content

FnOnceWithSig

Trait FnOnceWithSig 

Source
pub unsafe trait FnOnceWithSig<Sig: FnSig>: Sized + SealedWithSig<Sig> { }
Expand description

Trait implemented by closures that can be invoked once with signature Sig.

§Safety

  • VTABLE_ONCE.call_once must be a valid trampoline for Self that, given a pointer to a properly aligned and initialized Self with exclusive ownership, moves Self out of the pointer and invokes it once.
  • VTABLE_ONCE.drop must be a valid drop function for Self that, given a pointer to a properly aligned and initialized Self with exclusive access, drops Self in place (or is a no-op if !core::mem::needs_drop::<Self>()).

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

Source§

impl<A1, A2, A3, A4, A5, A6, A7, A8, Ret, F> FnOnceWithSig<fn(A1, A2, A3, A4, A5, A6, A7, A8) -> Ret> for F
where F: FnOnce(A1, A2, A3, A4, A5, A6, A7, A8) -> Ret,

Source§

impl<A1, A2, A3, A4, A5, A6, A7, Ret, F> FnOnceWithSig<fn(A1, A2, A3, A4, A5, A6, A7) -> Ret> for F
where F: FnOnce(A1, A2, A3, A4, A5, A6, A7) -> Ret,

Source§

impl<A1, A2, A3, A4, A5, A6, Ret, F> FnOnceWithSig<fn(A1, A2, A3, A4, A5, A6) -> Ret> for F
where F: FnOnce(A1, A2, A3, A4, A5, A6) -> Ret,

Source§

impl<A1, A2, A3, A4, A5, Ret, F> FnOnceWithSig<fn(A1, A2, A3, A4, A5) -> Ret> for F
where F: FnOnce(A1, A2, A3, A4, A5) -> Ret,

Source§

impl<A1, A2, A3, A4, Ret, F> FnOnceWithSig<fn(A1, A2, A3, A4) -> Ret> for F
where F: FnOnce(A1, A2, A3, A4) -> Ret,

Source§

impl<A1, A2, A3, Ret, F> FnOnceWithSig<fn(A1, A2, A3) -> Ret> for F
where F: FnOnce(A1, A2, A3) -> Ret,

Source§

impl<A1, A2, Ret, F> FnOnceWithSig<fn(A1, A2) -> Ret> for F
where F: FnOnce(A1, A2) -> Ret,

Source§

impl<A1, Ret, F> FnOnceWithSig<fn(A1) -> Ret> for F
where F: FnOnce(A1) -> Ret,

Source§

impl<Ret, F> FnOnceWithSig<fn() -> Ret> for F
where F: FnOnce() -> Ret,