feat: Add support for if and compound statements.

This commit is contained in:
Jooris Hadeler
2026-01-15 21:38:07 +01:00
parent 10fd3b6abf
commit 6f19d38bf0
4 changed files with 50 additions and 1 deletions

View File

@@ -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),
}