1
Fork 0

use hir::Let in hir::Guard

This commit is contained in:
SparrowLii 2022-05-09 20:35:58 +08:00
parent 4799baa70d
commit 5251a80c0a
13 changed files with 41 additions and 45 deletions

View file

@ -1915,14 +1915,9 @@ impl<'a> State<'a> {
self.print_expr(&e);
self.space();
}
hir::Guard::IfLet(pat, e) => {
hir::Guard::IfLet(hir::Let { pat, ty, init, .. }) => {
self.word_nbsp("if");
self.word_nbsp("let");
self.print_pat(&pat);
self.space();
self.word_space("=");
self.print_expr(&e);
self.space();
self.print_let(pat, *ty, init);
}
}
}