feat: Add support for if and compound statements.
This commit is contained in:
10
src/ast.rs
10
src/ast.rs
@@ -67,5 +67,15 @@ pub enum Statement {
|
||||
value: Option<Expression>,
|
||||
},
|
||||
|
||||
If {
|
||||
condition: Expression,
|
||||
then: Box<Statement>,
|
||||
elze: Option<Box<Statement>>,
|
||||
},
|
||||
|
||||
Compound {
|
||||
body: Vec<Statement>,
|
||||
},
|
||||
|
||||
Expr(Expression),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user