mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-03 07:04:49 +00:00
show diagnostic for } token followed by else in let else statement
This commit is contained in:
parent
31c12ec282
commit
995aacfce8
5 changed files with 101 additions and 8 deletions
|
@ -43,7 +43,7 @@ pub(super) fn meta(p: &mut Parser<'_>) {
|
|||
match p.current() {
|
||||
T![=] => {
|
||||
p.bump(T![=]);
|
||||
if !expressions::expr(p) {
|
||||
if expressions::expr(p).is_none() {
|
||||
p.error("expected expression");
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue