pub struct FunctionClause {
pub patterns: Vec<Pattern>,
pub guard: Option<Expr>,
pub body: Vec<Statement>,
pub span: Range<usize>,
}Expand description
A clause of a function.
Fields§
§patterns: Vec<Pattern>Patterns for the clause.
guard: Option<Expr>Optional guard for the clause.
body: Vec<Statement>Body of the clause.
span: Range<usize>Source span of the function clause.
Trait Implementations§
Source§impl Clone for FunctionClause
impl Clone for FunctionClause
Source§fn clone(&self) -> FunctionClause
fn clone(&self) -> FunctionClause
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 FunctionClause
impl Debug for FunctionClause
Source§impl<'de> Deserialize<'de> for FunctionClause
impl<'de> Deserialize<'de> for FunctionClause
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for FunctionClause
impl PartialEq for FunctionClause
Source§fn eq(&self, other: &FunctionClause) -> bool
fn eq(&self, other: &FunctionClause) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for FunctionClause
impl Serialize for FunctionClause
impl StructuralPartialEq for FunctionClause
Auto Trait Implementations§
impl Freeze for FunctionClause
impl RefUnwindSafe for FunctionClause
impl Send for FunctionClause
impl Sync for FunctionClause
impl Unpin for FunctionClause
impl UnsafeUnpin for FunctionClause
impl UnwindSafe for FunctionClause
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