Auto merge of #138083 - nnethercote:rm-NtItem-NtStmt, r=petrochenkov
Remove `NtItem` and `NtStmt` Another piece of #124141. r? `@petrochenkov`
This commit is contained in:
commit
aaa2d47dae
49 changed files with 273 additions and 145 deletions
|
@ -1076,10 +1076,12 @@ impl<'a> Parser<'a> {
|
|||
let initial_semicolon = self.token.span;
|
||||
|
||||
while self.eat(exp!(Semi)) {
|
||||
let _ = self.parse_stmt_without_recovery(false, ForceCollect::No).unwrap_or_else(|e| {
|
||||
e.cancel();
|
||||
None
|
||||
});
|
||||
let _ = self
|
||||
.parse_stmt_without_recovery(false, ForceCollect::No, false)
|
||||
.unwrap_or_else(|e| {
|
||||
e.cancel();
|
||||
None
|
||||
});
|
||||
}
|
||||
|
||||
expect_err
|
||||
|
@ -1746,6 +1748,8 @@ pub enum ParseNtResult {
|
|||
Tt(TokenTree),
|
||||
Ident(Ident, IdentIsRaw),
|
||||
Lifetime(Ident, IdentIsRaw),
|
||||
Item(P<ast::Item>),
|
||||
Stmt(P<ast::Stmt>),
|
||||
Pat(P<ast::Pat>, NtPatKind),
|
||||
Ty(P<ast::Ty>),
|
||||
Meta(P<ast::AttrItem>),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue