mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 12:54:58 +00:00
simplify
This commit is contained in:
parent
febbc9acdd
commit
749907d330
5 changed files with 14 additions and 9 deletions
|
@ -236,7 +236,7 @@ fn lhs(p: &mut Parser, r: Restrictions) -> Option<CompletedMarker> {
|
|||
DOTDOT => {
|
||||
m = p.start();
|
||||
p.bump();
|
||||
if EXPR_FIRST.contains(p.current()) {
|
||||
if p.at_ts(EXPR_FIRST) {
|
||||
expr_bp(p, r, 2);
|
||||
}
|
||||
return Some(m.complete(p, RANGE_EXPR));
|
||||
|
@ -376,7 +376,7 @@ fn arg_list(p: &mut Parser) {
|
|||
let m = p.start();
|
||||
p.bump();
|
||||
while !p.at(R_PAREN) && !p.at(EOF) {
|
||||
if !EXPR_FIRST.contains(p.current()) {
|
||||
if !p.at_ts(EXPR_FIRST) {
|
||||
p.error("expected expression");
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue