refactor: use Path::push to construct remap-path-prefix by weihanglo · Pull Request #14908 · rust-lang/cargo (original) (raw)
What does this PR try to resolve?
It creates paths with correct separators for different systems.
How should we test and review this PR?
Try out -Ztrim-paths
on Windows. Run cargo build --verbose
and see if slashes in --remap-path-prefix
use the system's path separators.
cargo-features = ["trim-paths"]
[package] name = "foo"
[profile.release]trim-paths = true