]> git.lizzy.rs Git - rust.git/commitdiff
match_wild_err_arm: Fix typo in note text
authorTim Siegel <siegeltr@gmail.com>
Wed, 31 Aug 2022 13:09:11 +0000 (09:09 -0400)
committerTim Siegel <siegeltr@gmail.com>
Wed, 31 Aug 2022 13:09:11 +0000 (09:09 -0400)
clippy_lints/src/matches/match_wild_err_arm.rs
tests/ui/match_wild_err_arm.edition2018.stderr
tests/ui/match_wild_err_arm.edition2021.stderr

index bc16f17b6196e420184860ce3dd731f9eeeebdbe..a3aa2e4b389afe74f1e40f96da6fb5ea4eab66c9 100644 (file)
@@ -40,7 +40,7 @@ pub(crate) fn check<'tcx>(cx: &LateContext<'tcx>, ex: &Expr<'tcx>, arms: &[Arm<'
                                 arm.pat.span,
                                 &format!("`Err({})` matches all errors", ident_bind_name),
                                 None,
-                                "match each error separately or use the error output, or use `.except(msg)` if the error case is unreachable",
+                                "match each error separately or use the error output, or use `.expect(msg)` if the error case is unreachable",
                             );
                         }
                     }
index 2a4012039ba97a62b993f0234906695186293e7f..2d66daea8046e15c67bb4a3d2d4b7ea00c19eb21 100644 (file)
@@ -5,7 +5,7 @@ LL |         Err(_) => panic!("err"),
    |         ^^^^^^
    |
    = note: `-D clippy::match-wild-err-arm` implied by `-D warnings`
-   = note: match each error separately or use the error output, or use `.except(msg)` if the error case is unreachable
+   = note: match each error separately or use the error output, or use `.expect(msg)` if the error case is unreachable
 
 error: `Err(_)` matches all errors
   --> $DIR/match_wild_err_arm.rs:20:9
@@ -13,7 +13,7 @@ error: `Err(_)` matches all errors
 LL |         Err(_) => panic!(),
    |         ^^^^^^
    |
-   = note: match each error separately or use the error output, or use `.except(msg)` if the error case is unreachable
+   = note: match each error separately or use the error output, or use `.expect(msg)` if the error case is unreachable
 
 error: `Err(_)` matches all errors
   --> $DIR/match_wild_err_arm.rs:26:9
@@ -21,7 +21,7 @@ error: `Err(_)` matches all errors
 LL |         Err(_) => {
    |         ^^^^^^
    |
-   = note: match each error separately or use the error output, or use `.except(msg)` if the error case is unreachable
+   = note: match each error separately or use the error output, or use `.expect(msg)` if the error case is unreachable
 
 error: `Err(_e)` matches all errors
   --> $DIR/match_wild_err_arm.rs:34:9
@@ -29,7 +29,7 @@ error: `Err(_e)` matches all errors
 LL |         Err(_e) => panic!(),
    |         ^^^^^^^
    |
-   = note: match each error separately or use the error output, or use `.except(msg)` if the error case is unreachable
+   = note: match each error separately or use the error output, or use `.expect(msg)` if the error case is unreachable
 
 error: aborting due to 4 previous errors
 
index 2a4012039ba97a62b993f0234906695186293e7f..2d66daea8046e15c67bb4a3d2d4b7ea00c19eb21 100644 (file)
@@ -5,7 +5,7 @@ LL |         Err(_) => panic!("err"),
    |         ^^^^^^
    |
    = note: `-D clippy::match-wild-err-arm` implied by `-D warnings`
-   = note: match each error separately or use the error output, or use `.except(msg)` if the error case is unreachable
+   = note: match each error separately or use the error output, or use `.expect(msg)` if the error case is unreachable
 
 error: `Err(_)` matches all errors
   --> $DIR/match_wild_err_arm.rs:20:9
@@ -13,7 +13,7 @@ error: `Err(_)` matches all errors
 LL |         Err(_) => panic!(),
    |         ^^^^^^
    |
-   = note: match each error separately or use the error output, or use `.except(msg)` if the error case is unreachable
+   = note: match each error separately or use the error output, or use `.expect(msg)` if the error case is unreachable
 
 error: `Err(_)` matches all errors
   --> $DIR/match_wild_err_arm.rs:26:9
@@ -21,7 +21,7 @@ error: `Err(_)` matches all errors
 LL |         Err(_) => {
    |         ^^^^^^
    |
-   = note: match each error separately or use the error output, or use `.except(msg)` if the error case is unreachable
+   = note: match each error separately or use the error output, or use `.expect(msg)` if the error case is unreachable
 
 error: `Err(_e)` matches all errors
   --> $DIR/match_wild_err_arm.rs:34:9
@@ -29,7 +29,7 @@ error: `Err(_e)` matches all errors
 LL |         Err(_e) => panic!(),
    |         ^^^^^^^
    |
-   = note: match each error separately or use the error output, or use `.except(msg)` if the error case is unreachable
+   = note: match each error separately or use the error output, or use `.expect(msg)` if the error case is unreachable
 
 error: aborting due to 4 previous errors