]> git.lizzy.rs Git - rust.git/commitdiff
Formatting and naming
authorPhilipp Krones <hello@philkrones.com>
Sun, 19 Apr 2020 18:40:25 +0000 (20:40 +0200)
committerGitHub <noreply@github.com>
Sun, 19 Apr 2020 18:40:25 +0000 (20:40 +0200)
clippy_lints/src/loops.rs
clippy_lints/src/utils/internal_lints.rs

index cd65b337980e99b5d1ba8c8030a5dbdbbe9cdcbf..b03ff60385c62a86bb64429e95e9d8e772862bee 100644 (file)
@@ -2503,13 +2503,13 @@ fn check_needless_collect<'a, 'tcx>(expr: &'tcx Expr<'_>, cx: &LateContext<'a, '
                         NEEDLESS_COLLECT,
                         span,
                         NEEDLESS_COLLECT_MSG,
-                        |db| {
+                        |diag| {
                             let (arg, pred) = if contains_arg.starts_with('&') {
                                 ("x", &contains_arg[1..])
                             } else {
                                 ("&x", &*contains_arg)
                             };
-                            db.span_suggestion(
+                            diag.span_suggestion(
                                 span,
                                 "replace with",
                                 format!(
index ed90905ce32b8b8351b45d58fd5fa940bdcc9570..6eb6c2d98e9177f2acfa8d3945b9a89241dd86d8 100644 (file)
@@ -229,7 +229,7 @@ fn check_crate(&mut self, cx: &EarlyContext<'_>, krate: &AstCrate) {
                                         CLIPPY_LINTS_INTERNAL,
                                         item.span,
                                         "this constant should be before the previous constant due to lexical \
-                                        ordering",
+                                         ordering",
                                     );
                                 }
                             }