pub struct Pattern {
pub span: NodeSpan,
pub kind: PatternKind,
}Expand description
A canonical pattern, and where it was written.
Same shape as [parser::Pattern] — a [NodeSpan] beside a kind — and for the
same reason: the children stay plain Patterns, so a reader matches &p.kind.
Fields§
§span: NodeSpan§kind: PatternKindImplementations§
Trait Implementations§
impl StructuralPartialEq for Pattern
Auto Trait Implementations§
impl Freeze for Pattern
impl RefUnwindSafe for Pattern
impl Send for Pattern
impl Sync for Pattern
impl Unpin for Pattern
impl UnsafeUnpin for Pattern
impl UnwindSafe for Pattern
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