GeezerVison is showing docs.rs — PySetterValue in rustpython_vm::function - Rust pub enum PySetterValue<T = PyObjectRef> {
Assign(T),
Delete,
}
Variants§Implementations§
Sourcepub fn or(self, optb: Self) -> SelfSourcepub fn map_or<_Other, _Function: FnOnce(T) -> _Other>(
self,
default: _Other,
f: _Function,
) -> _Other
Sourcepub fn map_or_else<_Other, _Default: FnOnce() -> _Other, _Function: FnOnce(T) -> _Other>(
self,
default: _Default,
f: _Function,
) -> _Other
Returns true if self is of variant Assign.
Returns Some if self is a reference of variant Assign, and None otherwise.
Returns Some if self is a mutable reference of variant Assign, and None otherwise.
Unwraps the value, yielding the content of Assign.
§Panics
Panics if the value is not Assign, with a panic message including the content of self.
Returns Some if self is of variant Assign, and None otherwise.
Returns true if self is of variant Delete.
Trait Implementations§
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more
Returns the “default value” for a type. Read more
Converts to this type from the input type.
Converts to this type from the input type.
Converts to this type from the input type.
The type of the elements being iterated over.
Which kind of iterator are we turning this into?
Auto Trait Implementations§Blanket Implementations§
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
🔬This is a nightly-only experimental API. (clone_to_uninit) Performs copy-assignment from self to dest. Read more
Converts to this type from the input type.
Returns the argument unchanged.
Calls U::from(self).
That is, this conversion is whatever the implementation of
From<T> for U chooses to do.
Returns the String produced by Ts Debug implementation.
§Examples
use malachite_base::strings::ToDebugString;
assert_eq!([1, 2, 3].to_debug_string(), "[1, 2, 3]");
assert_eq!(
[vec![2, 3], vec![], vec![4]].to_debug_string(),
"[[2, 3], [], [4]]"
);
assert_eq!(Some(5).to_debug_string(), "Some(5)");
The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
|