Navigation Menu

Skip to content

Commit

Permalink
Remove unnecessary lamda on emitter map.
Browse files Browse the repository at this point in the history
  • Loading branch information
heckad committed Oct 7, 2020
1 parent 28928c7 commit 141544a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions compiler/rustc_driver/src/lib.rs
Expand Up @@ -155,8 +155,7 @@ pub fn run_compiler(
),
}
}
let diagnostic_output =
emitter.map(|emitter| DiagnosticOutput::Raw(emitter)).unwrap_or(DiagnosticOutput::Default);
let diagnostic_output = emitter.map(DiagnosticOutput::Raw).unwrap_or(DiagnosticOutput::Default);
let matches = match handle_options(&args) {
Some(matches) => matches,
None => return Ok(()),
Expand Down

0 comments on commit 141544a

Please sign in to comment.