Skip to content

Commit b0a4cae

Browse files
committed
Change group and use only func call
1 parent a183946 commit b0a4cae

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

clippy_lints/src/matches.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -239,7 +239,7 @@ declare_clippy_lint! {
239239
/// }
240240
/// ```
241241
pub PATS_WITH_WILD_MATCH_ARM,
242-
restriction,
242+
complexity,
243243
"a wildcard pattern used with others patterns in same match arm"
244244
}
245245

@@ -690,7 +690,7 @@ fn check_pats_wild_match(cx: &LateContext<'_, '_>, arms: &[Arm]) {
690690
for arm in arms {
691691
if let PatKind::Or(ref fields) = arm.pat.kind {
692692
// look for multiple fields where one at least matches Wild pattern
693-
if fields.len() > 1 && fields.into_iter().any(|pat| is_wild(pat)) {
693+
if fields.len() > 1 && fields.into_iter().any(is_wild) {
694694
span_lint_and_sugg(
695695
cx,
696696
PATS_WITH_WILD_MATCH_ARM,

0 commit comments

Comments
 (0)