mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-25 08:13:41 +00:00
replace is_some() -> unwrap with if let
This commit is contained in:
parent
fbce03b195
commit
ddcb073c53
@ -463,12 +463,8 @@ fn run_compiler(
|
|||||||
linker.link(sess, codegen_backend)?
|
linker.link(sess, codegen_backend)?
|
||||||
}
|
}
|
||||||
|
|
||||||
if sess.opts.unstable_opts.print_fuel.is_some() {
|
if let Some(fuel) = sess.opts.unstable_opts.print_fuel.as_deref() {
|
||||||
eprintln!(
|
eprintln!("Fuel used by {}: {}", fuel, sess.print_fuel.load(Ordering::SeqCst));
|
||||||
"Fuel used by {}: {}",
|
|
||||||
sess.opts.unstable_opts.print_fuel.as_ref().unwrap(),
|
|
||||||
sess.print_fuel.load(Ordering::SeqCst)
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
|
Loading…
Reference in New Issue
Block a user