#[non_exhaustive]#[repr(C)]pub enum Type {
Primitive(PrimitiveType),
Sequence(SequenceType),
User(UserType),
Pointer(PointerType),
}Expand description
The definition of a shape in accordance to rust reference:
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Primitive(PrimitiveType)
Built-in primitive.
Sequence(SequenceType)
Sequence (tuple, array, slice).
User(UserType)
User-defined type (struct, enum, union).
Pointer(PointerType)
Pointer type (reference, raw, function pointer).
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Type
impl RefUnwindSafe for Type
impl Send for Type
impl Sync for Type
impl Unpin 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