pub struct ResultData {
pub is_ok: bool,
pub payload: KindedSlot,
}Expand description
Result<T, E> carrier. is_ok discriminates Ok vs Err; payload carries
the inner value (T for Ok, E for Err). Both arms share the same
payload slot — the variant tag is the discriminator, not the slot’s
physical layout.
Fields§
§is_ok: bool§payload: KindedSlotImplementations§
Source§impl ResultData
impl ResultData
Sourcepub fn ok(payload: KindedSlot) -> Self
pub fn ok(payload: KindedSlot) -> Self
Construct an Ok-tagged result.
Sourcepub fn err(payload: KindedSlot) -> Self
pub fn err(payload: KindedSlot) -> Self
Construct an Err-tagged result.
Trait Implementations§
Source§impl Clone for ResultData
impl Clone for ResultData
Auto Trait Implementations§
impl Freeze for ResultData
impl RefUnwindSafe for ResultData
impl Send for ResultData
impl Sync for ResultData
impl Unpin for ResultData
impl UnsafeUnpin for ResultData
impl UnwindSafe for ResultData
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