Skip to content

Commit bb079f4

Browse files
committed
List options specifically for cargo
1 parent dec1901 commit bb079f4

File tree

1 file changed

+11
-2
lines changed

1 file changed

+11
-2
lines changed

text/3127-trim-paths.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ This flag accepts a comma-separated list of values and may be specified multiple
9494

9595
- `macro` - apply remappings to the expansion of `std::file!()` macro. This is where paths in embedded panic messages come from
9696
- `diagnostics` - apply remappings to printed compiler diagnostics
97-
- `unsplit-debuginfo` - apply to remappings to debug information only when they are written to compiled executables or libraries, but not when they are in split files
97+
- `unsplit-debuginfo` - apply remappings to debug information only when they are written to compiled executables or libraries, but not when they are in split debuginfo files
9898
- `split-debuginfo` - apply remappings to debug information only when they are written to split debug information files, but not in compiled executables or libraries
9999
- `split-debuginfo-file` - apply remappings to the paths pointing to split debug information files. Does nothing when these files are not generated.
100100
- `object` - an alias for `macro,unsplit-debuginfo,split-debuginfo-file`. This ensures all paths in compiled executables or libraries are remapped, but not elsewhere.
@@ -104,7 +104,16 @@ Debug information are written to split files when the separate codegen option `-
104104

105105
## Cargo
106106

107-
`trim-paths` is a profile setting which enables and controls the sanitisation of file paths in compilation outputs. It corresponds to the `--remap-path-scope` flag of rustc and accepts all valid scope, or combination of scopes that `--remap-path-scope` accepts, in addition to the `none` or `false` option which disables path sanitisation completely.
107+
`trim-paths` is a profile setting which enables and controls the sanitisation of file paths in compilation outputs. It corresponds to the `--remap-path-scope` flag of rustc and accepts all valid scope, or combination of scopes that `--remap-path-scope` accepts, in addition to the `none` or `false` option which disables path sanitisation completely. Possible values are:
108+
109+
- `none` and `false` - disable path sanitisation
110+
- `macro` - sanitise paths in the expansion of `std::file!()` macro. This is where paths in embedded panic messages come from
111+
- `diagnostics` - sanitise paths in printed compiler diagnostics
112+
- `unsplit-debuginfo` - sanitise paths in debug information in compiled executables or libraries. Does nothing if debug information are in split files
113+
- `split-debuginfo` - sanitise paths in debug information in split debuginfo files. Does nothing if debug information are in compiled executables or libraries
114+
- `split-debuginfo-file` - sanitise paths pointing to split debug information files. Does nothing if these files are not generated.
115+
- `object` - an alias for `macro,unsplit-debuginfo,split-debuginfo-file`. This ensures all paths in compiled executables or libraries are sanitised, but not elsewhere.
116+
- `all` and `true` - an alias for all of the above
108117

109118
It is defaulted to `none` for debug profiles, and `object` for release profiles. You can manually override it by specifying this option in `Cargo.toml`:
110119
```toml

0 commit comments

Comments
 (0)