pub enum Lean4DoStmt {
Bind(String, Option<Lean4Type>, Box<Lean4Expr>),
LetBind(String, Option<Lean4Type>, Box<Lean4Expr>),
Expr(Box<Lean4Expr>),
Return(Box<Lean4Expr>),
Pure(Box<Lean4Expr>),
If(Box<Lean4Expr>, Vec<Lean4DoStmt>, Vec<Lean4DoStmt>),
}Expand description
Statements in a do block.
Variants§
Bind(String, Option<Lean4Type>, Box<Lean4Expr>)
let x ← action
LetBind(String, Option<Lean4Type>, Box<Lean4Expr>)
let x := value
Expr(Box<Lean4Expr>)
Plain expression statement: action
Return(Box<Lean4Expr>)
return e
Pure(Box<Lean4Expr>)
pure e
If(Box<Lean4Expr>, Vec<Lean4DoStmt>, Vec<Lean4DoStmt>)
if c then ...
Trait Implementations§
Source§impl Clone for Lean4DoStmt
impl Clone for Lean4DoStmt
Source§fn clone(&self) -> Lean4DoStmt
fn clone(&self) -> Lean4DoStmt
Returns a duplicate 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 Lean4DoStmt
impl Debug for Lean4DoStmt
Source§impl Display for Lean4DoStmt
impl Display for Lean4DoStmt
Source§impl PartialEq for Lean4DoStmt
impl PartialEq for Lean4DoStmt
impl StructuralPartialEq for Lean4DoStmt
Auto Trait Implementations§
impl Freeze for Lean4DoStmt
impl RefUnwindSafe for Lean4DoStmt
impl Send for Lean4DoStmt
impl Sync for Lean4DoStmt
impl Unpin for Lean4DoStmt
impl UnsafeUnpin for Lean4DoStmt
impl UnwindSafe for Lean4DoStmt
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