hir: Remove Expr::While

The previous commit desugared it to a loop.
This commit is contained in:
Tadeo Kondrak 2023-08-01 19:08:16 -06:00
parent 31bcba84f9
commit 92a97c292a
7 changed files with 0 additions and 73 deletions

View file

@ -191,11 +191,6 @@ pub enum Expr {
body: ExprId,
label: Option<LabelId>,
},
While {
condition: ExprId,
body: ExprId,
label: Option<LabelId>,
},
Call {
callee: ExprId,
args: Box<[ExprId]>,
@ -379,10 +374,6 @@ impl Expr {
}
}
Expr::Loop { body, .. } => f(*body),
Expr::While { condition, body, .. } => {
f(*condition);
f(*body);
}
Expr::Call { callee, args, .. } => {
f(*callee);
args.iter().copied().for_each(f);