File tree 2 files changed +8
-3
lines changed
src/cargo/core/compiler/context
2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -25,12 +25,12 @@ use crate::util::{self, CargoResult};
25
25
///
26
26
/// This also acts as the main layer of caching provided by Cargo.
27
27
/// For example, we want to cache `cargo build` and `cargo doc` separately, so that running one
28
- /// does not invalidate the artifacts for the other. We do this by including `profile ` in the hash,
29
- /// thus the artifacts go in different folders and do not override each other.
28
+ /// does not invalidate the artifacts for the other. We do this by including `CompileMode ` in the
29
+ /// hash, thus the artifacts go in different folders and do not override each other.
30
30
/// If we don't add something that we should have, for this reason, we get the
31
31
/// correct output but rebuild more than is needed.
32
32
///
33
- /// Some things that need to be tract to ensure the correct output should definitely *not*
33
+ /// Some things that need to be tracked to ensure the correct output should definitely *not*
34
34
/// go in the `Metadata`. For example, the modification time of a file, should be tracked to make a
35
35
/// rebuild when the file changes. However, it would be wasteful to include in the `Metadata`. The
36
36
/// old artifacts are never going to be needed again. We can save space by just overwriting them.
Original file line number Diff line number Diff line change @@ -1160,6 +1160,11 @@ fn changing_rustflags_is_cached() {
1160
1160
p. cargo ( "build" ) . run ( ) ;
1161
1161
p. cargo ( "build" )
1162
1162
. env ( "RUSTFLAGS" , "-C target-cpu=native" )
1163
+ . with_stderr (
1164
+ "\
1165
+ [COMPILING] foo v0.0.1 ([..])
1166
+ [FINISHED] dev [unoptimized + debuginfo] target(s) in [..]" ,
1167
+ )
1163
1168
. run ( ) ;
1164
1169
// This should not recompile!
1165
1170
p. cargo ( "build" )
You can’t perform that action at this time.
0 commit comments