Enum neotron_common_bios::FfiResult
source · #[repr(C)]pub enum FfiResult<T, E> {
Ok(T),
Err(E),
}
Expand description
All API functions which can fail return this type.
We don’t use the Result
type from the standard library because that isn’t
FFI safe and may change layout between compiler versions.
Variants§
Ok(T)
The operation succeeded (like core::result::Result::Ok
).
Err(E)
The operation failed (like core::result::Result::Err
).
Implementations§
Trait Implementations§
source§impl<T, E> Ord for FfiResult<T, E>
impl<T, E> Ord for FfiResult<T, E>
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl<T, E> PartialEq for FfiResult<T, E>
impl<T, E> PartialEq for FfiResult<T, E>
source§impl<T, E> PartialOrd for FfiResult<T, E>where
T: PartialOrd,
E: PartialOrd,
impl<T, E> PartialOrd for FfiResult<T, E>where
T: PartialOrd,
E: PartialOrd,
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl<T, E> Eq for FfiResult<T, E>
impl<T, E> StructuralPartialEq for FfiResult<T, E>
Auto Trait Implementations§
impl<T, E> RefUnwindSafe for FfiResult<T, E>where
E: RefUnwindSafe,
T: RefUnwindSafe,
impl<T, E> Send for FfiResult<T, E>
impl<T, E> Sync for FfiResult<T, E>
impl<T, E> Unpin for FfiResult<T, E>
impl<T, E> UnwindSafe for FfiResult<T, E>where
E: UnwindSafe,
T: UnwindSafe,
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