]> git.lizzy.rs Git - rust.git/blobdiff - src/tools/clippy/clippy_lints/src/double_parens.rs
Box `ExprKind::{Closure,MethodCall}`, and `QSelf` in expressions, types, and patterns.
[rust.git] / src / tools / clippy / clippy_lints / src / double_parens.rs
index 0f1d701865e7d711bbf8ae1bdb949c31d5214611..29425b2e5541791db6c485d904a38981abda173b 100644 (file)
@@ -61,10 +61,10 @@ fn check_expr(&mut self, cx: &EarlyContext<'_>, expr: &Expr) {
                     }
                 }
             },
-            ExprKind::MethodCall(_, _, ref params, _) => {
-                if let [ref param] = params[..] {
-                    if let ExprKind::Paren(_) = param.kind {
-                        span_lint(cx, DOUBLE_PARENS, param.span, msg);
+            ExprKind::MethodCall(ref call) => {
+                if let [ref arg] = call.args[..] {
+                    if let ExprKind::Paren(_) = arg.kind {
+                        span_lint(cx, DOUBLE_PARENS, arg.span, msg);
                     }
                 }
             },