pub enum LetDeclaration {
Function(Box<Function>),
Destructuring {
pattern: Box<Spanned<Pattern>>,
body: Box<Spanned<Expr>>,
},
}Expand description
A declaration within a let-in block.
Variants§
Function(Box<Function>)
A function definition within a let block.
let
add x y = x + y
in
...Destructuring
A destructuring within a let block.
let
( x, y ) = point
in
...Trait Implementations§
Source§impl Clone for LetDeclaration
impl Clone for LetDeclaration
Source§fn clone(&self) -> LetDeclaration
fn clone(&self) -> LetDeclaration
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 LetDeclaration
impl Debug for LetDeclaration
Source§impl PartialEq for LetDeclaration
impl PartialEq for LetDeclaration
Source§fn eq(&self, other: &LetDeclaration) -> bool
fn eq(&self, other: &LetDeclaration) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Eq for LetDeclaration
impl StructuralPartialEq for LetDeclaration
Auto Trait Implementations§
impl Freeze for LetDeclaration
impl RefUnwindSafe for LetDeclaration
impl Send for LetDeclaration
impl Sync for LetDeclaration
impl Unpin for LetDeclaration
impl UnsafeUnpin for LetDeclaration
impl UnwindSafe for LetDeclaration
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