Skip to content

Commit

Permalink
Auto merge of #11981 - Systemcluster:rustflags-comparable, r=epage
Browse files Browse the repository at this point in the history
Recompile on profile rustflags changes

Adding `rustflags` to the comparable profile properties.

Follow-up to #11121 without the additional changes.

Closes #11120
  • Loading branch information
bors committed Apr 18, 2023
2 parents 5861176 + e080273 commit 60bf28f
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/cargo/core/profiles.rs
Original file line number Diff line number Diff line change
Expand Up @@ -704,7 +704,7 @@ impl Profile {
/// Compares all fields except `name`, which doesn't affect compilation.
/// This is necessary for `Unit` deduplication for things like "test" and
/// "dev" which are essentially the same.
fn comparable(&self) -> impl Hash + Eq {
fn comparable(&self) -> impl Hash + Eq + '_ {
(
self.opt_level,
self.lto,
Expand All @@ -715,9 +715,8 @@ impl Profile {
self.debug_assertions,
self.overflow_checks,
self.rpath,
self.incremental,
self.panic,
self.strip,
(self.incremental, self.panic, self.strip),
&self.rustflags,
)
}
}
Expand Down

0 comments on commit 60bf28f

Please sign in to comment.