mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-27 21:43:37 +00:00
Simplify
This commit is contained in:
parent
836784f02b
commit
f04cff102f
2 changed files with 4 additions and 6 deletions
|
@ -448,10 +448,8 @@ fn match_arm(p: &mut Parser) {
|
||||||
// _ => ()
|
// _ => ()
|
||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
if blocklike.is_block() {
|
if !p.eat(T![,]) && !blocklike.is_block() && !p.at(T!['}']) {
|
||||||
p.eat(T![,]);
|
p.error("expected `,`");
|
||||||
} else if !p.at(T!['}']) {
|
|
||||||
p.expect(T![,]);
|
|
||||||
}
|
}
|
||||||
m.complete(p, MATCH_ARM);
|
m.complete(p, MATCH_ARM);
|
||||||
}
|
}
|
||||||
|
|
|
@ -194,11 +194,11 @@ SOURCE_FILE@0..293
|
||||||
error 52..52: expected `[`
|
error 52..52: expected `[`
|
||||||
error 52..52: expected pattern
|
error 52..52: expected pattern
|
||||||
error 53..53: expected FAT_ARROW
|
error 53..53: expected FAT_ARROW
|
||||||
error 78..78: expected COMMA
|
error 78..78: expected `,`
|
||||||
error 161..161: expected `[`
|
error 161..161: expected `[`
|
||||||
error 161..161: expected pattern
|
error 161..161: expected pattern
|
||||||
error 162..162: expected FAT_ARROW
|
error 162..162: expected FAT_ARROW
|
||||||
error 232..232: expected `[`
|
error 232..232: expected `[`
|
||||||
error 232..232: expected pattern
|
error 232..232: expected pattern
|
||||||
error 233..233: expected FAT_ARROW
|
error 233..233: expected FAT_ARROW
|
||||||
error 250..250: expected COMMA
|
error 250..250: expected `,`
|
||||||
|
|
Loading…
Reference in a new issue