Skip to content

Commit 3035118

Browse files
authored
Rollup merge of #115730 - bjorn3:some_driver_refactors, r=compiler-errors
Some more small driver refactors To improve clarity and simplify some code.
2 parents aad7f60 + ac3c9a7 commit 3035118

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/bin/miri.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,6 @@ impl rustc_driver::Callbacks for MiriCompilerCalls {
5959

6060
fn after_analysis<'tcx>(
6161
&mut self,
62-
handler: &EarlyErrorHandler,
6362
_: &rustc_interface::interface::Compiler,
6463
queries: &'tcx rustc_interface::Queries<'tcx>,
6564
) -> Compilation {
@@ -68,7 +67,8 @@ impl rustc_driver::Callbacks for MiriCompilerCalls {
6867
tcx.sess.fatal("miri cannot be run on programs that fail compilation");
6968
}
7069

71-
init_late_loggers(handler, tcx);
70+
let handler = EarlyErrorHandler::new(tcx.sess.opts.error_format);
71+
init_late_loggers(&handler, tcx);
7272
if !tcx.crate_types().contains(&CrateType::Executable) {
7373
tcx.sess.fatal("miri only makes sense on bin crates");
7474
}

0 commit comments

Comments
 (0)