pub struct ArgBytesLike(/* private fields */);
Expand description
any bytes-like object. Like the y*
format code for PyArg_Parse
in CPython.
Implementations§
Trait Implementations§
Source§impl Debug for ArgBytesLike
impl Debug for ArgBytesLike
Source§impl From<ArgBytesLike> for PyBuffer
impl From<ArgBytesLike> for PyBuffer
Source§fn from(buffer: ArgBytesLike) -> Self
fn from(buffer: ArgBytesLike) -> Self
Converts to this type from the input type.
Source§impl Traverse for ArgBytesLike
impl Traverse for ArgBytesLike
Source§fn traverse(&self, tracer_fn: &mut TraverseFn<'_>)
fn traverse(&self, tracer_fn: &mut TraverseFn<'_>)
impl
traverse()
with caution! Following those guideline so traverse doesn’t cause memory error!: Read moreSource§impl<'a> TryFromBorrowedObject<'a> for ArgBytesLike
impl<'a> TryFromBorrowedObject<'a> for ArgBytesLike
Source§fn try_from_borrowed_object(
vm: &VirtualMachine,
obj: &'a PyObject,
) -> PyResult<Self>
fn try_from_borrowed_object( vm: &VirtualMachine, obj: &'a PyObject, ) -> PyResult<Self>
Attempt to convert a Python object to a value of this type.
Auto Trait Implementations§
impl Freeze for ArgBytesLike
impl !RefUnwindSafe for ArgBytesLike
impl !Send for ArgBytesLike
impl !Sync for ArgBytesLike
impl Unpin for ArgBytesLike
impl !UnwindSafe for ArgBytesLike
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
Source§impl<T> FromArgOptional for Twhere
T: TryFromObject,
impl<T> FromArgOptional for Twhere
T: TryFromObject,
Source§impl<T> FromArgs for Twhere
T: TryFromObject,
impl<T> FromArgs for Twhere
T: TryFromObject,
Source§fn arity() -> RangeInclusive<usize>
fn arity() -> RangeInclusive<usize>
The range of positional arguments permitted by the function signature. Read more
Source§fn from_args(
vm: &VirtualMachine,
args: &mut FuncArgs,
) -> Result<T, ArgumentError>
fn from_args( vm: &VirtualMachine, args: &mut FuncArgs, ) -> Result<T, ArgumentError>
Extracts this item from the next argument(s).
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 moreSource§impl<T, U> OverflowingInto<U> for Twhere
U: OverflowingFrom<T>,
impl<T, U> OverflowingInto<U> for Twhere
U: OverflowingFrom<T>,
fn overflowing_into(self) -> (U, bool)
Source§impl<T, U> RoundingInto<U> for Twhere
U: RoundingFrom<T>,
impl<T, U> RoundingInto<U> for Twhere
U: RoundingFrom<T>,
fn rounding_into(self, rm: RoundingMode) -> (U, Ordering)
Source§impl<T, U> SaturatingInto<U> for Twhere
U: SaturatingFrom<T>,
impl<T, U> SaturatingInto<U> for Twhere
U: SaturatingFrom<T>,
fn saturating_into(self) -> U
Source§impl<T> ToDebugString for Twhere
T: Debug,
impl<T> ToDebugString for Twhere
T: Debug,
Source§fn to_debug_string(&self) -> String
fn to_debug_string(&self) -> String
Source§impl<T> TryFromObject for Twhere
T: for<'a> TryFromBorrowedObject<'a>,
impl<T> TryFromObject for Twhere
T: for<'a> TryFromBorrowedObject<'a>,
Source§fn try_from_object(
vm: &VirtualMachine,
obj: PyObjectRef,
) -> Result<T, PyRef<PyBaseException>>
fn try_from_object( vm: &VirtualMachine, obj: PyObjectRef, ) -> Result<T, PyRef<PyBaseException>>
Attempt to convert a Python object to a value of this type.