mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-02 06:41:48 +00:00
fix: various clippy lints
This commit is contained in:
parent
900d6030e7
commit
d7fdf141a4
5 changed files with 10 additions and 14 deletions
|
@ -366,8 +366,7 @@ impl ast::BlockExpr {
|
|||
match parent.kind() {
|
||||
FOR_EXPR | IF_EXPR => parent
|
||||
.children()
|
||||
.filter(|it| ast::Expr::can_cast(it.kind()))
|
||||
.next()
|
||||
.find(|it| ast::Expr::can_cast(it.kind()))
|
||||
.map_or(true, |it| it == *self.syntax()),
|
||||
LET_ELSE | FN | WHILE_EXPR | LOOP_EXPR | CONST_BLOCK_PAT => false,
|
||||
_ => true,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue