Skip to content

Commit

Permalink
Auto merge of #13740 - Muscraft:remove-rust-2024-compat, r=epage
Browse files Browse the repository at this point in the history
refactor: Remove `rust_2024_compatibility` lint group

The `rust_2024_compatibility` lint group was added as a way to be compatible with `Rust`. This group is meant to be used when switching to the 2024 edition (usually enabled by `cargo fix --edition`). Since we are not going to be interacting with `cargo fix` in the standard way to fix edition lints, this group is not needed at this time. Removing this will (slightly) reduce the complexity of working on things for the 2024 edition.
  • Loading branch information
bors committed Apr 11, 2024
2 parents 74fd5bc + d77faa6 commit d467208
Show file tree
Hide file tree
Showing 10 changed files with 1 addition and 270 deletions.
9 changes: 1 addition & 8 deletions src/cargo/util/lints.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,13 +66,6 @@ pub struct LintGroup {
pub edition_lint_opts: Option<(Edition, LintLevel)>,
}

const RUST_2024_COMPATIBILITY: LintGroup = LintGroup {
name: "rust_2024_compatibility",
default_level: LintLevel::Allow,
desc: "warn about compatibility with Rust 2024",
edition_lint_opts: Some((Edition::Edition2024, LintLevel::Deny)),
};

#[derive(Copy, Clone, Debug)]
pub struct Lint {
pub name: &'static str,
Expand Down Expand Up @@ -152,7 +145,7 @@ impl From<TomlLintLevel> for LintLevel {
const IMPLICIT_FEATURES: Lint = Lint {
name: "implicit_features",
desc: "warn about the use of unstable features",
groups: &[RUST_2024_COMPATIBILITY],
groups: &[],
default_level: LintLevel::Allow,
edition_lint_opts: Some((Edition::Edition2024, LintLevel::Deny)),
};
Expand Down
1 change: 0 additions & 1 deletion tests/testsuite/lints/mod.rs
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
mod implicit_features;
mod rust_2024_compatibility;
34 changes: 0 additions & 34 deletions tests/testsuite/lints/rust_2024_compatibility/edition_2021/mod.rs

This file was deleted.

This file was deleted.

This file was deleted.

34 changes: 0 additions & 34 deletions tests/testsuite/lints/rust_2024_compatibility/edition_2024/mod.rs

This file was deleted.

This file was deleted.

4 changes: 0 additions & 4 deletions tests/testsuite/lints/rust_2024_compatibility/mod.rs

This file was deleted.

38 changes: 0 additions & 38 deletions tests/testsuite/lints/rust_2024_compatibility/warn/mod.rs

This file was deleted.

38 changes: 0 additions & 38 deletions tests/testsuite/lints/rust_2024_compatibility/warn/stderr.term.svg

This file was deleted.

0 comments on commit d467208

Please sign in to comment.