Fix full path being output with rustdoc -h
rustdoc would output the full path to the binary when calling it with the `-h` or `--help` flags. This is undesired behavior. It has been replaced with a hardcoded string `rustdoc` to fix the issue. Fixes #39310
This commit is contained in:
parent
6991938d3e
commit
bb34856e9d
1 changed files with 1 additions and 1 deletions
|
@ -193,7 +193,7 @@ pub fn main_args(args: &[String]) -> isize {
|
||||||
nightly_options::check_nightly_options(&matches, &opts());
|
nightly_options::check_nightly_options(&matches, &opts());
|
||||||
|
|
||||||
if matches.opt_present("h") || matches.opt_present("help") {
|
if matches.opt_present("h") || matches.opt_present("help") {
|
||||||
usage(&args[0]);
|
usage("rustdoc");
|
||||||
return 0;
|
return 0;
|
||||||
} else if matches.opt_present("version") {
|
} else if matches.opt_present("version") {
|
||||||
rustc_driver::version("rustdoc", &matches);
|
rustc_driver::version("rustdoc", &matches);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue