Rename ast::StmtKind::Local into ast::StmtKind::Let

This commit is contained in:
Guillaume Gomez 2024-03-14 11:25:05 +01:00
parent 6f3eb1ce3d
commit ca9f0630a9
17 changed files with 24 additions and 24 deletions

View file

@ -218,7 +218,7 @@ impl<'a> ExtCtxt<'a> {
}
pub fn stmt_local(&self, local: P<ast::Local>, span: Span) -> ast::Stmt {
ast::Stmt { id: ast::DUMMY_NODE_ID, kind: ast::StmtKind::Local(local), span }
ast::Stmt { id: ast::DUMMY_NODE_ID, kind: ast::StmtKind::Let(local), span }
}
pub fn stmt_item(&self, sp: Span, item: P<ast::Item>) -> ast::Stmt {

View file

@ -1389,7 +1389,7 @@ impl InvocationCollectorNode for ast::Stmt {
StmtKind::Item(item) => matches!(item.kind, ItemKind::MacCall(..)),
StmtKind::Semi(expr) => matches!(expr.kind, ExprKind::MacCall(..)),
StmtKind::Expr(..) => unreachable!(),
StmtKind::Local(..) | StmtKind::Empty => false,
StmtKind::Let(..) | StmtKind::Empty => false,
}
}
fn take_mac_call(self) -> (P<ast::MacCall>, Self::AttrsTy, AddSemicolon) {