compiler: fix some clippy needless_pass_by_ref_mut
warning: this argument is a mutable reference, but not used mutably --> compiler\rustc_session\src\config.rs:2111:20 | 2111 | unstable_opts: &mut UnstableOptions, | ^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&UnstableOptions` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_pass_by_ref_mut
This commit is contained in:
parent
bf47641726
commit
b6cfe71f38
@ -2108,7 +2108,7 @@ fn should_override_cgus_and_disable_thinlto(
|
||||
fn collect_print_requests(
|
||||
early_dcx: &EarlyDiagCtxt,
|
||||
cg: &mut CodegenOptions,
|
||||
unstable_opts: &mut UnstableOptions,
|
||||
unstable_opts: &UnstableOptions,
|
||||
matches: &getopts::Matches,
|
||||
) -> Vec<PrintRequest> {
|
||||
let mut prints = Vec::<PrintRequest>::new();
|
||||
@ -2732,6 +2732,8 @@ pub fn build_session_options(early_dcx: &mut EarlyDiagCtxt, matches: &getopts::M
|
||||
}
|
||||
|
||||
if let Ok(graphviz_font) = std::env::var("RUSTC_GRAPHVIZ_FONT") {
|
||||
// FIXME: this is only mutation of UnstableOptions here, move into
|
||||
// UnstableOptions::build?
|
||||
unstable_opts.graphviz_font = graphviz_font;
|
||||
}
|
||||
|
||||
@ -2781,7 +2783,7 @@ pub fn build_session_options(early_dcx: &mut EarlyDiagCtxt, matches: &getopts::M
|
||||
));
|
||||
}
|
||||
|
||||
let prints = collect_print_requests(early_dcx, &mut cg, &mut unstable_opts, matches);
|
||||
let prints = collect_print_requests(early_dcx, &mut cg, &unstable_opts, matches);
|
||||
|
||||
let cg = cg;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user