Open
Description
Summary
RFC: #3127
Documentation: https://doc.rust-lang.org/nightly/cargo/reference/unstable.html#profile-trim-paths-option
Issues:
Z-trim-paths
rustc tracking issue: rust-lang/rust#111540
This adds a new profile setting (among other things) to control how paths are sanitized in the resulting binary.
Unresolved Issues
- Should make
--remap-path-prefix
work withrustdoc
and doctest?- Yes as rustdoc supports both
- Integrate
--remap-path-prefix
in rustdoc invocations (cargo doc
) feat(trim-paths): rustdoc supports trim-paths for diagnostics #14389 - Integrate
--remap-path-prefix
and-Zremap-path-scope
in doctest (cargo test --doc
)
- Determine the remap rules: trim-paths: Remap rules for different dependency kinds #13171
- A cross-platform stable hash for
CARGO_HOME
layout? feature(SourceId): use stable hash from rustc-stable-hash #14917- On Windows the local path contains prefix component e.g.
C:/
, which essentially results in a different hash result from what on other platforms. This is unlikely to be resolved. - benchmark BLAKE3, BLAKE2s, and rustc-stable-hasher
- See result in feat!: use stable hash from rustc-stable-hash #14116 (comment)
- rustc-stable-hash is on par with the original siphash, while blake3 is 2-3x slower. The total spent in stable hashing for a
cargo build
invocation may be unimportant. It took 500μs-1500μs for buidling cargo itself.
- On Windows the local path contains prefix component e.g.
- A cross-platform stable hash for
- There should be some tests for Windows and macOS
- Be sure to consider the impact of back versus forward slashes, and whether or not that will work with either.
Future Extensions
No response
About tracking issues
Tracking issues are used to record the overall progress of implementation.
They are also used as hubs connecting to other relevant issues, e.g., bugs or open design questions.
A tracking issue is however not meant for large scale discussion, questions, or bug reports about a feature.
Instead, open a dedicated issue for the specific matter and add the relevant feature gate label.
Implementation history
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
In Progress