]> git.lizzy.rs Git - rust.git/commitdiff
Avoid period in lint message according to convention
authorTakayuki Nakata <f.seasons017@gmail.com>
Mon, 24 Aug 2020 01:11:53 +0000 (10:11 +0900)
committerTakayuki Nakata <f.seasons017@gmail.com>
Mon, 24 Aug 2020 01:11:53 +0000 (10:11 +0900)
clippy_lints/src/redundant_closure_call.rs
tests/ui/redundant_closure_call_early.stderr
tests/ui/redundant_closure_call_fixable.stderr

index d8fad217e5a43be33f3101c2d39e73681e4b4545..49cb2ffc4e372a3f765e89e1f9fe4bf0f7740a23 100644 (file)
@@ -77,7 +77,7 @@ fn check_expr(&mut self, cx: &EarlyContext<'_>, expr: &ast::Expr) {
                         cx,
                         REDUNDANT_CLOSURE_CALL,
                         expr.span,
-                        "try not to call a closure in the expression where it is declared.",
+                        "try not to call a closure in the expression where it is declared",
                         |diag| {
                             if decl.inputs.is_empty() {
                                 let mut app = Applicability::MachineApplicable;
index 79f276634619e277c24cef3069afe85953948210..2735e41738f0d0ef4555759f74260fa5e82bca38 100644 (file)
@@ -1,4 +1,4 @@
-error: try not to call a closure in the expression where it is declared.
+error: try not to call a closure in the expression where it is declared
   --> $DIR/redundant_closure_call_early.rs:9:17
    |
 LL |     let mut k = (|m| m + 1)(i);
@@ -6,7 +6,7 @@ LL |     let mut k = (|m| m + 1)(i);
    |
    = note: `-D clippy::redundant-closure-call` implied by `-D warnings`
 
-error: try not to call a closure in the expression where it is declared.
+error: try not to call a closure in the expression where it is declared
   --> $DIR/redundant_closure_call_early.rs:12:9
    |
 LL |     k = (|a, b| a * b)(1, 5);
index 644161d9f5d885eb24da0c187bfcd5e63ffa1352..afd704ef12a934f913454334a42bd68c5a95a954 100644 (file)
@@ -1,4 +1,4 @@
-error: try not to call a closure in the expression where it is declared.
+error: try not to call a closure in the expression where it is declared
   --> $DIR/redundant_closure_call_fixable.rs:7:13
    |
 LL |     let a = (|| 42)();