Merge branch 'master' into master
This commit is contained in:
commit
b08b4848c3
447 changed files with 3097 additions and 2989 deletions
|
@ -156,6 +156,8 @@ crate struct Options {
|
|||
/// If this option is set to `true`, rustdoc will only run checks and not generate
|
||||
/// documentation.
|
||||
crate run_check: bool,
|
||||
/// Whether doctests should emit unused externs
|
||||
crate json_unused_externs: bool,
|
||||
}
|
||||
|
||||
impl fmt::Debug for Options {
|
||||
|
@ -355,7 +357,8 @@ impl Options {
|
|||
}
|
||||
|
||||
let color = config::parse_color(&matches);
|
||||
let (json_rendered, _artifacts) = config::parse_json(&matches);
|
||||
let config::JsonConfig { json_rendered, json_unused_externs, .. } =
|
||||
config::parse_json(&matches);
|
||||
let error_format = config::parse_error_format(&matches, color, json_rendered);
|
||||
|
||||
let codegen_options = build_codegen_options(matches, error_format);
|
||||
|
@ -484,7 +487,9 @@ impl Options {
|
|||
return Err(1);
|
||||
}
|
||||
if theme_file.extension() != Some(OsStr::new("css")) {
|
||||
diag.struct_err(&format!("invalid argument: \"{}\"", theme_s)).emit();
|
||||
diag.struct_err(&format!("invalid argument: \"{}\"", theme_s))
|
||||
.help("arguments to --theme must have a .css extension")
|
||||
.emit();
|
||||
return Err(1);
|
||||
}
|
||||
let (success, ret) = theme::test_theme_against(&theme_file, &paths, &diag);
|
||||
|
@ -510,7 +515,6 @@ impl Options {
|
|||
let edition = config::parse_crate_edition(&matches);
|
||||
|
||||
let mut id_map = html::markdown::IdMap::new();
|
||||
id_map.populate(&html::render::INITIAL_IDS);
|
||||
let external_html = match ExternalHtml::load(
|
||||
&matches.opt_strs("html-in-header"),
|
||||
&matches.opt_strs("html-before-content"),
|
||||
|
@ -692,6 +696,7 @@ impl Options {
|
|||
},
|
||||
crate_name,
|
||||
output_format,
|
||||
json_unused_externs,
|
||||
})
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue