Skip to content

Commit 991efa6

Browse files
committed
Auto merge of #5555 - flip1995:pedantic_match_on_vec_items, r=phansch
Move match_on_vec_items to pedantic Addresses #5551 (comment) Fixes #5553 changelog: Move [`match_on_vec_items`] to pedantic r? @phansch
2 parents e3b8c41 + 10e3f9b commit 991efa6

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
@@ -1138,6 +1138,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
11381138
LintId::of(&loops::EXPLICIT_INTO_ITER_LOOP),
11391139
LintId::of(&loops::EXPLICIT_ITER_LOOP),
11401140
LintId::of(&macro_use::MACRO_USE_IMPORTS),
1141+
LintId::of(&match_on_vec_items::MATCH_ON_VEC_ITEMS),
11411142
LintId::of(&matches::MATCH_BOOL),
11421143
LintId::of(&matches::SINGLE_MATCH_ELSE),
11431144
LintId::of(&methods::FILTER_MAP),
@@ -1283,7 +1284,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
12831284
LintId::of(&map_clone::MAP_CLONE),
12841285
LintId::of(&map_unit_fn::OPTION_MAP_UNIT_FN),
12851286
LintId::of(&map_unit_fn::RESULT_MAP_UNIT_FN),
1286-
LintId::of(&match_on_vec_items::MATCH_ON_VEC_ITEMS),
12871287
LintId::of(&matches::INFALLIBLE_DESTRUCTURING_MATCH),
12881288
LintId::of(&matches::MATCH_AS_REF),
12891289
LintId::of(&matches::MATCH_OVERLAPPING_ARM),
@@ -1647,7 +1647,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf:
16471647
LintId::of(&loops::NEVER_LOOP),
16481648
LintId::of(&loops::REVERSE_RANGE_LOOP),
16491649
LintId::of(&loops::WHILE_IMMUTABLE_CONDITION),
1650-
LintId::of(&match_on_vec_items::MATCH_ON_VEC_ITEMS),
16511650
LintId::of(&mem_discriminant::MEM_DISCRIMINANT_NON_ENUM),
16521651
LintId::of(&mem_replace::MEM_REPLACE_WITH_UNINIT),
16531652
LintId::of(&methods::CLONE_DOUBLE_REF),

clippy_lints/src/match_on_vec_items.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ declare_clippy_lint! {
3838
/// }
3939
/// ```
4040
pub MATCH_ON_VEC_ITEMS,
41-
correctness,
41+
pedantic,
4242
"matching on vector elements can panic"
4343
}
4444

src/lintlist/mod.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1146,7 +1146,7 @@ pub static ref ALL_LINTS: Vec<Lint> = vec![
11461146
},
11471147
Lint {
11481148
name: "match_on_vec_items",
1149-
group: "correctness",
1149+
group: "pedantic",
11501150
desc: "matching on vector elements can panic",
11511151
deprecation: None,
11521152
module: "match_on_vec_items",

0 commit comments

Comments
 (0)