rust-lang / rust

Empowering everyone to build reliable and efficient software.
https://www.rust-lang.org
Other
96.82k stars 12.5k forks source link

`rustc --print` doesn't list valid options #128930

Open ChrisDenton opened 1 month ago

ChrisDenton commented 1 month ago

I tried using rustc --print and found the error message is very terse:

> rustc --print
error: Argument to option 'print' missing

Using an invalid option does list the valid ones:

> rustc --print help
error: unknown print request: `help`
  |
  = help: valid print requests are: `all-target-specs-json`, `calling-conventions`, `cfg`, `check-cfg`, `code-models`, `crate-name`, `deployment-target`, `file-names`, `link-args`, `native-static-libs`, `relocation-models`, `split-debuginfo`, `stack-protector-strategies`, `sysroot`, `target-cpus`, `target-features`, `target-libdir`, `target-list`, `target-spec-json`, `tls-models`

rustc --version --verbose

rustc 1.82.0-nightly (8b3870784 2024-08-07)
binary: rustc
commit-hash: 8b3870784f69d8ed2ae4246d1b56f150e3131499
commit-date: 2024-08-07
host: x86_64-pc-windows-msvc
release: 1.82.0-nightly
LLVM version: 19.1.0
GKFX commented 1 month ago

@rustbot label +T-compiler +C-enhancement -needs-triage