mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-30 04:56:25 +03:00
3ddb0482a3
Fix ICE report flags display. #92310 made some changes to the ICE report that displays the rustc flags, but it introduced a bug where a flag like `-Z incremental-verify-ich=yes` was being treated as-if it was `-Cincremental`. This corrupted the output and made it confusing. The cause was using `starts_with` instead of properly splitting the option. For example, with the command like `rustc foo.rs -Cincremental=/tmp/a -Zincremental-verify-ich=yes --crate-type lib` would previously look like: ``` note: compiler flags: -C incremental -Z incremental --crate-type lib ``` It now looks like: ``` note: compiler flags: -C incremental=[REDACTED] -Z incremental-verify-ich=yes --crate-type lib ``` I added a `[REDACTED]` marker for `-Cincremental` so it is a little less confusing that a value has been removed. Fixes #101588