Syntatically accept become expressions

This commit is contained in:
Maybe Waffle 2022-11-16 18:36:17 +00:00
parent 8d1fa473dd
commit d7713feb99
14 changed files with 71 additions and 2 deletions

View file

@ -537,6 +537,11 @@ impl<'a> State<'a> {
self.print_expr_maybe_paren(expr, parser::PREC_JUMP);
}
}
ast::ExprKind::Become(result) => {
self.word("become");
self.word(" ");
self.print_expr_maybe_paren(result, parser::PREC_JUMP);
}
ast::ExprKind::InlineAsm(a) => {
// FIXME: This should have its own syntax, distinct from a macro invocation.
self.word("asm!");