Clean up parser.parse_token_tree()
.
This commit is contained in:
parent
ac919fcd9d
commit
5f280a5c60
1 changed files with 13 additions and 22 deletions
|
@ -2833,13 +2833,6 @@ impl<'a> Parser<'a> {
|
|||
close_span: close_span,
|
||||
})))
|
||||
},
|
||||
_ => {
|
||||
// invariants: the current token is not a left-delimiter,
|
||||
// not an EOF, and not the desired right-delimiter (if
|
||||
// it were, parse_seq_to_before_end would have prevented
|
||||
// reaching this point).
|
||||
maybe_whole!(deref self, NtTT);
|
||||
match self.token {
|
||||
token::CloseDelim(_) => {
|
||||
// An unexpected closing delimiter (i.e., there is no
|
||||
// matching opening delimiter).
|
||||
|
@ -2857,8 +2850,6 @@ impl<'a> Parser<'a> {
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// parse a stream of tokens into a list of TokenTree's,
|
||||
// up to EOF.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue