Skip to content

Commit 5707491

Browse files
committed
Auto merge of rust-lang#8418 - dtolnay-contrib:transmuteundefinedrepr, r=llogiq
Downgrade transmute_undefined_repr to nursery Reason: rust-lang#8417. I am skeptical of this lint but maybe there is a narrower subset of types on which it is useful, so keeping it for now but moving to nursery for further development. --- *Please write a short comment explaining your change (or "none" for internal only changes)* changelog: Remove [`transmute_undefined_repr`] from default set of enabled lints
2 parents 96c73c5 + 7964406 commit 5707491

File tree

4 files changed

+2
-3
lines changed

4 files changed

+2
-3
lines changed

clippy_lints/src/lib.register_all.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -277,7 +277,6 @@ store.register_group(true, "clippy::all", Some("clippy_all"), vec![
277277
LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT),
278278
LintId::of(transmute::TRANSMUTE_NUM_TO_BYTES),
279279
LintId::of(transmute::TRANSMUTE_PTR_TO_REF),
280-
LintId::of(transmute::TRANSMUTE_UNDEFINED_REPR),
281280
LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE),
282281
LintId::of(transmute::WRONG_TRANSMUTE),
283282
LintId::of(transmuting_null::TRANSMUTING_NULL),

clippy_lints/src/lib.register_correctness.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,6 @@ store.register_group(true, "clippy::correctness", Some("clippy_correctness"), ve
5858
LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT),
5959
LintId::of(swap::ALMOST_SWAPPED),
6060
LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY),
61-
LintId::of(transmute::TRANSMUTE_UNDEFINED_REPR),
6261
LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE),
6362
LintId::of(transmute::WRONG_TRANSMUTE),
6463
LintId::of(transmuting_null::TRANSMUTING_NULL),

clippy_lints/src/lib.register_nursery.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ store.register_group(true, "clippy::nursery", Some("clippy_nursery"), vec![
2626
LintId::of(strings::STRING_LIT_AS_BYTES),
2727
LintId::of(suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS),
2828
LintId::of(trailing_empty_array::TRAILING_EMPTY_ARRAY),
29+
LintId::of(transmute::TRANSMUTE_UNDEFINED_REPR),
2930
LintId::of(transmute::USELESS_TRANSMUTE),
3031
LintId::of(use_self::USE_SELF),
3132
])

clippy_lints/src/transmute/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ declare_clippy_lint! {
376376
/// ```
377377
#[clippy::version = "1.60.0"]
378378
pub TRANSMUTE_UNDEFINED_REPR,
379-
correctness,
379+
nursery,
380380
"transmute to or from a type with an undefined representation"
381381
}
382382

0 commit comments

Comments
 (0)