#[repr(C)]pub enum COption<T> {
None,
Some(T),
}
Expand description
FFI-safe Option.
This type is not really meant for general use, but rather as a last-resort conversion for type wrapping.
Typical workflow would include temporarily converting into/from COption.
Variants§
Implementations§
Trait Implementations§
impl<T: Copy> Copy for COption<T>
Auto Trait Implementations§
impl<T> RefUnwindSafe for COption<T>where T: RefUnwindSafe,
impl<T> Send for COption<T>where T: Send,
impl<T> Sync for COption<T>where T: Sync,
impl<T> Unpin for COption<T>where T: Unpin,
impl<T> UnwindSafe for COption<T>where 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