about summary refs log tree commit diff
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2020-12-25 15:47:31 +0000
committerbors <bors@rust-lang.org>2020-12-25 15:47:31 +0000
commitb1e0d15d5888339ece2465866ebeba05cf2cd229 (patch)
tree3fbbc7f384153a0a693e9812b09829716f7b337f
parent02399f4b25d549b54973e0ff1a15fd5fcb37e2cc (diff)
parente1743ef5250d67260a2a1b0126708d969f80909f (diff)
downloadrust-b1e0d15d5888339ece2465866ebeba05cf2cd229.tar.gz
rust-b1e0d15d5888339ece2465866ebeba05cf2cd229.zip
Auto merge of #6505 - giraffate:fix_style_of_texts_in_map_err_ignore, r=phansch
Fix a style of texts in `map_err_ignore`

It's a small fix of texts.

changelog: none
-rw-r--r--clippy_lints/src/map_err_ignore.rs4
-rw-r--r--tests/ui/map_err.stderr2
2 files changed, 3 insertions, 3 deletions
diff --git a/clippy_lints/src/map_err_ignore.rs b/clippy_lints/src/map_err_ignore.rs
index f3c0515b9bc..76fe8e776ea 100644
--- a/clippy_lints/src/map_err_ignore.rs
+++ b/clippy_lints/src/map_err_ignore.rs
@@ -7,7 +7,7 @@ use rustc_session::{declare_lint_pass, declare_tool_lint};
 declare_clippy_lint! {
     /// **What it does:** Checks for instances of `map_err(|_| Some::Enum)`
     ///
-    /// **Why is this bad?** This map_err throws away the original error rather than allowing the enum to contain and report the cause of the error
+    /// **Why is this bad?** This `map_err` throws away the original error rather than allowing the enum to contain and report the cause of the error
     ///
     /// **Known problems:** None.
     ///
@@ -135,7 +135,7 @@ impl<'tcx> LateLintPass<'tcx> for MapErrIgnore {
                                     body_span,
                                     "`map_err(|_|...` wildcard pattern discards the original error",
                                     None,
-                                    "Consider storing the original error as a source in the new error, or silence this warning using an ignored identifier (`.map_err(|_foo| ...`)",
+                                    "consider storing the original error as a source in the new error, or silence this warning using an ignored identifier (`.map_err(|_foo| ...`)",
                                 );
                             }
                         }
diff --git a/tests/ui/map_err.stderr b/tests/ui/map_err.stderr
index 8ee2941790d..37e87e64de2 100644
--- a/tests/ui/map_err.stderr
+++ b/tests/ui/map_err.stderr
@@ -5,7 +5,7 @@ LL |     println!("{:?}", x.map_err(|_| Errors::Ignored));
    |                                ^^^
    |
    = note: `-D clippy::map-err-ignore` implied by `-D warnings`
-   = help: Consider storing the original error as a source in the new error, or silence this warning using an ignored identifier (`.map_err(|_foo| ...`)
+   = help: consider storing the original error as a source in the new error, or silence this warning using an ignored identifier (`.map_err(|_foo| ...`)
 
 error: aborting due to previous error