about summary refs log tree commit diff
path: root/src/librustc_codegen_llvm/back/write.rs
diff options
context:
space:
mode:
authorNicholas Nethercote <nnethercote@mozilla.com>2020-04-02 16:44:47 +1100
committerNicholas Nethercote <nnethercote@mozilla.com>2020-04-19 19:53:54 +1000
commit58217bc996564965d3362ca3010a272b39e229f6 (patch)
tree93a178f13ac71e43f253d4b992636da87ecbe218 /src/librustc_codegen_llvm/back/write.rs
parentb9bcddc5276c97f8d66f637ae84658b37fbb4957 (diff)
downloadrust-58217bc996564965d3362ca3010a272b39e229f6.tar.gz
rust-58217bc996564965d3362ca3010a272b39e229f6.zip
Replace uses of `parse_opt_*` with `parse_*` where possible.
This lets us specify the default at the options declaration point,
instead of using `.unwrap(default)` or `None | Some(default)` at some
use point far away. It also makes the code more concise.
Diffstat (limited to 'src/librustc_codegen_llvm/back/write.rs')
-rw-r--r--src/librustc_codegen_llvm/back/write.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/librustc_codegen_llvm/back/write.rs b/src/librustc_codegen_llvm/back/write.rs
index 5708cb4e654..b57ad102d63 100644
--- a/src/librustc_codegen_llvm/back/write.rs
+++ b/src/librustc_codegen_llvm/back/write.rs
@@ -347,7 +347,7 @@ pub(crate) fn should_use_new_llvm_pass_manager(config: &ModuleConfig) -> bool {
     }
 
     // The new pass manager is disabled by default.
-    config.new_llvm_pass_manager.unwrap_or(false)
+    config.new_llvm_pass_manager
 }
 
 pub(crate) unsafe fn optimize_with_new_llvm_pass_manager(