Skip to content

Commit 3fc2419

Browse files
committed
Auto merge of #5200 - nipunn1313:unneeded_field_pattern, r=flip1995
Move unneeded_field_pattern to restriction group Fixes #1741 changelog: Move unneeded_field_pattern to pedantic group
2 parents 0d7ae7b + 78a2507 commit 3fc2419

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

clippy_lints/src/lib.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -1033,6 +1033,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
10331033
LintId::of(&methods::RESULT_UNWRAP_USED),
10341034
LintId::of(&methods::WRONG_PUB_SELF_CONVENTION),
10351035
LintId::of(&misc::FLOAT_CMP_CONST),
1036+
LintId::of(&misc_early::UNNEEDED_FIELD_PATTERN),
10361037
LintId::of(&missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS),
10371038
LintId::of(&missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS),
10381039
LintId::of(&modulo_arithmetic::MODULO_ARITHMETIC),
@@ -1270,7 +1271,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
12701271
LintId::of(&misc_early::MIXED_CASE_HEX_LITERALS),
12711272
LintId::of(&misc_early::REDUNDANT_CLOSURE_CALL),
12721273
LintId::of(&misc_early::REDUNDANT_PATTERN),
1273-
LintId::of(&misc_early::UNNEEDED_FIELD_PATTERN),
12741274
LintId::of(&misc_early::UNNEEDED_WILDCARD_PATTERN),
12751275
LintId::of(&misc_early::ZERO_PREFIXED_LITERAL),
12761276
LintId::of(&mut_key::MUTABLE_KEY_TYPE),
@@ -1433,7 +1433,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
14331433
LintId::of(&misc_early::DUPLICATE_UNDERSCORE_ARGUMENT),
14341434
LintId::of(&misc_early::MIXED_CASE_HEX_LITERALS),
14351435
LintId::of(&misc_early::REDUNDANT_PATTERN),
1436-
LintId::of(&misc_early::UNNEEDED_FIELD_PATTERN),
14371436
LintId::of(&mut_reference::UNNECESSARY_MUT_PASSED),
14381437
LintId::of(&neg_multiply::NEG_MULTIPLY),
14391438
LintId::of(&new_without_default::NEW_WITHOUT_DEFAULT),

clippy_lints/src/misc_early.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ declare_clippy_lint! {
2525
/// let { a: _, b: ref b, c: _ } = ..
2626
/// ```
2727
pub UNNEEDED_FIELD_PATTERN,
28-
style,
28+
restriction,
2929
"struct fields bound to a wildcard instead of using `..`"
3030
}
3131

src/lintlist/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -2228,7 +2228,7 @@ pub const ALL_LINTS: [Lint; 355] = [
22282228
},
22292229
Lint {
22302230
name: "unneeded_field_pattern",
2231-
group: "style",
2231+
group: "restriction",
22322232
desc: "struct fields bound to a wildcard instead of using `..`",
22332233
deprecation: None,
22342234
module: "misc_early",

0 commit comments

Comments
 (0)