mirror of
https://github.com/rust-lang/rust-clippy
synced 2024-11-24 05:33:27 +00:00
Stop visiting once it's found Let
This commit is contained in:
parent
d989f432a4
commit
108c04acf0
1 changed files with 2 additions and 2 deletions
|
@ -96,8 +96,8 @@ impl Visitor<'_> for IsAnyLetVisitor {
|
|||
fn visit_expr(&mut self, expr: &Expr<'_>) {
|
||||
if matches!(expr.kind, ExprKind::Let(..)) {
|
||||
self.0 = true;
|
||||
} else {
|
||||
walk_expr(self, expr);
|
||||
}
|
||||
|
||||
walk_expr(self, expr);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue