rust/clippy_lints/src/matches
Catherine Flores 278e316d67
Fix needless_match FP on if-lets (#13646)
Closes #13574

Make sure that `needless_match` doesn't simplify:

```
if let Some(_) = a() {
// ..
} else let Some(_) = b() {
// ..
}
```

to:

```
a()
```

changelog: [`needless_match`]: Fix false-positive on if lets
2024-12-02 02:51:48 +00:00
..
collapsible_match.rs Simplify instances of Option::map_or(true, …) in Clippy sources 2024-11-16 00:12:41 +01:00
infallible_destructuring_match.rs Implement mut ref/mut ref mut 2024-03-27 09:53:23 -04:00
manual_filter.rs Merge commit '7901289135' into clippy-subtree-update 2024-09-24 11:58:04 +02:00
manual_map.rs Merge commit '7901289135' into clippy-subtree-update 2024-09-24 11:58:04 +02:00
manual_unwrap_or.rs Merge commit '7901289135' into clippy-subtree-update 2024-09-24 11:58:04 +02:00
manual_utils.rs Inline ExprPrecedence::order into Expr::precedence 2024-11-17 14:01:37 -08:00
match_as_ref.rs Rename BindingAnnotation to BindingMode 2024-04-17 09:34:39 -04:00
match_bool.rs Merge commit '371120bdbf' into clippyup 2023-05-05 17:45:49 +02:00
match_like_matches.rs Merge commit '786fbd6d68' into clippy-subtree-update 2024-11-14 19:35:26 +01:00
match_on_vec_items.rs Merge commit 'edb720b199' into clippyup 2023-11-16 19:13:24 +01:00
match_ref_pats.rs Merge commit 'cb806113e0' into clippy-subtree-update 2024-08-08 19:13:50 +02:00
match_same_arms.rs nightly feature tracking: get rid of the per-feature bool fields 2024-10-23 09:14:41 +01:00
match_single_binding.rs Rename hir::Node::Local into hir::Node::LetStmt 2024-03-22 20:48:36 +01:00
match_str_case_mismatch.rs Merge commit 'f712eb5cdc' into clippy-subtree-update 2024-11-07 22:37:01 +01:00
match_wild_enum.rs Merge commit 'cb806113e0' into clippy-subtree-update 2024-08-08 19:13:50 +02:00
match_wild_err_arm.rs Merge commit 'cb806113e0' into clippy-subtree-update 2024-08-08 19:13:50 +02:00
mod.rs Rename all clippy_config::msrvs -> clippy_utils::msrvs 2024-11-15 19:38:09 +01:00
needless_match.rs Fix needless_match FP on if-lets 2024-11-14 15:57:45 +01:00
overlapping_arms.rs Merge commit 'aa0d551351' into clippy-subtree-update 2024-10-03 16:32:51 +02:00
redundant_guards.rs Don't lint CStr literals, do lint float literals in redundant_guards (#13698) 2024-11-17 04:24:43 +00:00
redundant_pattern_match.rs Merge commit '786fbd6d68' into clippy-subtree-update 2024-11-14 19:35:26 +01:00
rest_pat_in_fully_bound_struct.rs Merge commit 'cb806113e0' into clippy-subtree-update 2024-08-08 19:13:50 +02:00
significant_drop_in_scrutinee.rs Handle clippy cases of rustc::potential_query_instability lint 2024-10-05 07:34:14 +03:00
single_match.rs Merge commit '786fbd6d68' into clippy-subtree-update 2024-11-14 19:35:26 +01:00
try_err.rs Merge commit '786fbd6d68' into clippy-subtree-update 2024-11-14 19:35:26 +01:00
wild_in_or_pats.rs Merge commit 'aa0d551351' into clippy-subtree-update 2024-10-03 16:32:51 +02:00