#[non_exhaustive]pub enum Ctor {
Wild,
Other,
Variant(u32),
Product,
Bool(bool),
Int {
lo: i128,
hi: i128,
},
Char {
lo: char,
hi: char,
},
Lit(u64),
Slice {
len: u32,
},
SliceRest {
prefix: u32,
suffix: u32,
},
}Expand description
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.
Wild
_: any value of the type.
Other
A value no pattern can name: an opaque literal that no arm mentions,
or a BigInt outside the i128 range.
Printed as _.
Variant(u32)
Variant index of a sum type.
Product
The constructor of a product type.
Bool(bool)
A boolean.
Int
Any integer in lo..=hi.
Char
Any character in lo..=hi.
Lit(u64)
An opaque literal, by id.
Slice
A sequence of exactly len elements; the fields are the elements.
SliceRest
A sequence of at least prefix + suffix elements; the fields are the
first prefix and the last suffix elements.
Trait Implementations§
impl Copy for Ctor
impl Eq for Ctor
impl StructuralPartialEq for Ctor
Auto Trait Implementations§
impl Freeze for Ctor
impl RefUnwindSafe for Ctor
impl Send for Ctor
impl Sync for Ctor
impl Unpin for Ctor
impl UnsafeUnpin for Ctor
impl UnwindSafe for Ctor
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