Emit a warning instead of an error if --generate-link-to-definition
is used with other output formats than HTML
This commit is contained in:
parent
53e87d211c
commit
d2177d90b0
@ -733,9 +733,11 @@ fn println_condition(condition: Condition) {
|
|||||||
let html_no_source = matches.opt_present("html-no-source");
|
let html_no_source = matches.opt_present("html-no-source");
|
||||||
|
|
||||||
if generate_link_to_definition && (show_coverage || output_format != OutputFormat::Html) {
|
if generate_link_to_definition && (show_coverage || output_format != OutputFormat::Html) {
|
||||||
dcx.fatal(
|
dcx.struct_warn(
|
||||||
"--generate-link-to-definition option can only be used with HTML output format",
|
"`--generate-link-to-definition` option can only be used with HTML output format",
|
||||||
);
|
)
|
||||||
|
.with_note("`--generate-link-to-definition` option will be ignored")
|
||||||
|
.emit();
|
||||||
}
|
}
|
||||||
|
|
||||||
let scrape_examples_options = ScrapeExamplesOptions::new(matches, dcx);
|
let scrape_examples_options = ScrapeExamplesOptions::new(matches, dcx);
|
||||||
|
Loading…
Reference in New Issue
Block a user