Enum rustc_mir_build::thir::pattern::deconstruct_pat::SliceKind
source · enum SliceKind {
FixedLen(usize),
VarLen(usize, usize),
}
Variants§
FixedLen(usize)
Patterns of length n
([x, y]
).
VarLen(usize, usize)
Patterns using the ..
notation ([x, .., y]
).
Captures any array constructor of length >= i + j
.
In the case where array_len
is Some(_)
,
this indicates that we only care about the first i
and the last j
values of the array,
and everything in between is a wildcard _
.
Implementations§
Trait Implementations§
source§impl PartialEq<SliceKind> for SliceKind
impl PartialEq<SliceKind> for SliceKind
impl Copy for SliceKind
impl Eq for SliceKind
impl StructuralEq for SliceKind
impl StructuralPartialEq for SliceKind
Auto Trait Implementations§
impl RefUnwindSafe for SliceKind
impl Send for SliceKind
impl Sync for SliceKind
impl Unpin for SliceKind
impl UnwindSafe for SliceKind
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
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 24 bytes
Size for each variant:
FixedLen
: 8 bytesVarLen
: 16 bytes