pub struct Callee { /* private fields */ }Expand description
What a message says about the function whose arguments are being bound.
A binding that happens somewhere the name isn’t known leaves it off, the way
_PyArg_Parser.fname is NULL. A message describes the parameters the
function declares, so a method’s instance argument counts as neither an
expected parameter nor a given argument, the way descrobject.c reports
nargs - 1.
Implementations§
Source§impl Callee
impl Callee
Sourcepub fn for_type(class: &Py<PyType>) -> Self
pub fn for_type(class: &Py<PyType>) -> Self
The type a slot builds or initializes, named the way a message names it.
Sourcepub fn of<T: PyPayload>(vm: &VirtualMachine) -> Self
pub fn of<T: PyPayload>(vm: &VirtualMachine) -> Self
The same, for the type a slot was written for.
Sourcepub const fn with_instance_arg(self, instance_arg: bool) -> Self
pub const fn with_instance_arg(self, instance_arg: bool) -> Self
Marks a call whose leading argument fills the method’s instance parameter.
Trait Implementations§
impl Copy for Callee
Auto Trait Implementations§
impl Freeze for Callee
impl RefUnwindSafe for Callee
impl Send for Callee
impl Sync for Callee
impl Unpin for Callee
impl UnsafeUnpin for Callee
impl UnwindSafe for Callee
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ErasedDestructor for Twhere
T: 'static,
impl<T> Helper for T
Source§impl<T, U> ImaginaryInto<U> for Twhere
U: ImaginaryFrom<T>,
impl<T, U> ImaginaryInto<U> for Twhere
U: ImaginaryFrom<T>,
fn imaginary_into(self) -> U
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more