1
Fork 0

use pat<no_top_alt> for patterns in let bindings

This commit is contained in:
mark 2021-02-12 18:04:37 -06:00
parent 5233edcf1c
commit e64138c534
36 changed files with 602 additions and 357 deletions

View file

@ -847,7 +847,7 @@ impl EarlyLintPass for UnusedParens {
fn check_stmt(&mut self, cx: &EarlyContext<'_>, s: &ast::Stmt) {
if let StmtKind::Local(ref local) = s.kind {
self.check_unused_parens_pat(cx, &local.pat, false, false);
self.check_unused_parens_pat(cx, &local.pat, true, false);
}
<Self as UnusedDelimLint>::check_stmt(self, cx, s)