Rollup merge of #135478 - Kobzol:gcc-clippy, r=onur-ozkan

Run clippy for rustc_codegen_gcc on CI

Requested on [Zulip](https://rust-lang.zulipchat.com/#narrow/channel/242791-t-infra/topic/Run.20clippy.20for.20rustc_codegen_gcc.20in.20the.20Rust.20CI).

Opening as a draft, since it's not clear which rules should be applied to it.

r? `@ghost`
This commit is contained in:
Matthias Krüger 2025-01-18 13:58:02 +01:00 committed by GitHub
commit 86947bb18a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 19 additions and 6 deletions

View File

@ -334,6 +334,7 @@ lint_any!(
CargoMiri, "src/tools/miri/cargo-miri", "cargo-miri";
Clippy, "src/tools/clippy", "clippy";
CollectLicenseMetadata, "src/tools/collect-license-metadata", "collect-license-metadata";
CodegenGcc, "compiler/rustc_codegen_gcc", "rustc-codegen-gcc";
Compiletest, "src/tools/compiletest", "compiletest";
CoverageDump, "src/tools/coverage-dump", "coverage-dump";
Jsondocck, "src/tools/jsondocck", "jsondocck";
@ -400,6 +401,12 @@ impl Step for CI {
],
forbid: vec![],
};
builder.ensure(Std {
target: self.target,
config: self.config.merge(&library_clippy_cfg),
crates: vec![],
});
let compiler_clippy_cfg = LintConfig {
allow: vec!["clippy::all".into()],
warn: vec![],
@ -419,16 +426,21 @@ impl Step for CI {
],
forbid: vec![],
};
builder.ensure(Std {
target: self.target,
config: self.config.merge(&library_clippy_cfg),
crates: vec![],
});
builder.ensure(Rustc {
target: self.target,
config: self.config.merge(&compiler_clippy_cfg),
crates: vec![],
});
let rustc_codegen_gcc = LintConfig {
allow: vec![],
warn: vec![],
deny: vec!["warnings".into()],
forbid: vec![],
};
builder.ensure(CodegenGcc {
target: self.target,
config: self.config.merge(&rustc_codegen_gcc),
});
}
}

View File

@ -900,6 +900,7 @@ impl<'a> Builder<'a> {
clippy::BuildManifest,
clippy::CargoMiri,
clippy::Clippy,
clippy::CodegenGcc,
clippy::CollectLicenseMetadata,
clippy::Compiletest,
clippy::CoverageDump,