Skip to content

Commit

Permalink
Merge #199
Browse files Browse the repository at this point in the history
199: Don't emit `codegen-units=1` when `stable_coverage` is set r=taiki-e a=ldm0

Do the same thing in <https://github.com/taiki-e/cargo-llvm-cov/pull/130/files#diff-42cb6807ad74b3e201c5a7ca98b911c5fa08380e942be6e4ac5807f8377f87fcR204> since rust-lang/rust#85461 is already closed.

Co-authored-by: Liu Dingming <[email protected]>
  • Loading branch information
bors[bot] and ldm0 authored Jul 24, 2022
2 parents a267540 + 6d97ce3 commit f43e059
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -268,12 +268,12 @@ fn set_env(cx: &Context, env: &mut impl EnvTarget) {
} else {
// TODO: drop support for `-Z instrument-coverage` in the future major release.
rustdocflags.push_str(" -Z instrument-coverage");
if cfg!(windows) {
rustdocflags.push_str(" -C codegen-units=1");
}
}
let _ =
write!(rustdocflags, " -Z unstable-options --persist-doctests {}", cx.ws.doctests_dir);
if cfg!(windows) {
rustdocflags.push_str(" -C codegen-units=1");
}
if !cx.cov.no_cfg_coverage {
rustdocflags.push_str(" --cfg coverage");
}
Expand Down

0 comments on commit f43e059

Please sign in to comment.