Struct valkyrie_ast::PatternCaseNode
source · pub struct PatternCaseNode {
pub pattern: PatternNode,
pub guard: Option<ExpressionKind>,
pub span: Range<u32>,
}
Expand description
case Some(a) | Success { value :a } if a > 0:
Fields§
§pattern: PatternNode
case bind <- Some(a)
guard: Option<ExpressionKind>
case a | b | c
span: Range<u32>
The range of the node
Trait Implementations§
source§impl Clone for PatternCaseNode
impl Clone for PatternCaseNode
source§fn clone(&self) -> PatternCaseNode
fn clone(&self) -> PatternCaseNode
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for PatternCaseNode
impl Debug for PatternCaseNode
source§impl From<PatternCaseNode> for PatternCondition
impl From<PatternCaseNode> for PatternCondition
source§fn from(o: PatternCaseNode) -> Self
fn from(o: PatternCaseNode) -> Self
Converts to this type from the input type.
source§impl Hash for PatternCaseNode
impl Hash for PatternCaseNode
source§impl PartialEq for PatternCaseNode
impl PartialEq for PatternCaseNode
source§fn eq(&self, other: &PatternCaseNode) -> bool
fn eq(&self, other: &PatternCaseNode) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for PatternCaseNode
impl StructuralPartialEq for PatternCaseNode
Auto Trait Implementations§
impl RefUnwindSafe for PatternCaseNode
impl Send for PatternCaseNode
impl Sync for PatternCaseNode
impl Unpin for PatternCaseNode
impl UnwindSafe for PatternCaseNode
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