pub enum Type {
Struct(Struct),
Variant(Variant),
Enum(Enum),
Extern(Extern),
}Expand description
A type the flat API declares.
Four shapes, and the classification is what a destination language acts on: a product of fields, a sum, a named set of integers, or a handle whose contents do not cross.
Variants§
Struct(Struct)
Variant(Variant)
An enum whose alternatives carry payloads — a sum type.
Enum(Enum)
An enum whose every alternative is fieldless — a named set of integers.
Extern(Extern)
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl !Send for Type
impl !Sync for Type
impl Freeze for Type
impl RefUnwindSafe for Type
impl Unpin for Type
impl UnsafeUnpin for Type
impl UnwindSafe for Type
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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 more