Skip to content

Commit b7d76e2

Browse files
authored
Use .cargo/config.toml for local compilation options (#15543)
This will be ignored when Clippy is part of the compiler workspace. Using `Cargo.toml` would complain about profiles defined outside the top-level when run from the compiler repository. Suggested by Jakub Beránek. changelog: none r? flip1995
2 parents 5ce5b89 + 2c28135 commit b7d76e2

File tree

2 files changed

+7
-7
lines changed

2 files changed

+7
-7
lines changed

.cargo/config.toml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,3 +23,10 @@ split-debuginfo = "unpacked"
2323
rustflags = ["--remap-path-prefix", "=clippy_dev"]
2424
[profile.dev.package.lintcheck]
2525
rustflags = ["--remap-path-prefix", "=lintcheck"]
26+
27+
# quine-mc_cluskey makes up a significant part of the runtime in dogfood
28+
# due to the number of conditions in the clippy_lints crate
29+
# and enabling optimizations for that specific dependency helps a bit
30+
# without increasing total build times.
31+
[profile.dev.package.quine-mc_cluskey]
32+
opt-level = 3

Cargo.toml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -65,13 +65,6 @@ harness = false
6565
name = "dogfood"
6666
harness = false
6767

68-
# quine-mc_cluskey makes up a significant part of the runtime in dogfood
69-
# due to the number of conditions in the clippy_lints crate
70-
# and enabling optimizations for that specific dependency helps a bit
71-
# without increasing total build times.
72-
[profile.dev.package.quine-mc_cluskey]
73-
opt-level = 3
74-
7568
[lints.rust.unexpected_cfgs]
7669
level = "warn"
7770
check-cfg = ['cfg(bootstrap)']

0 commit comments

Comments
 (0)