@@ -82,7 +82,7 @@ fn get_output_path(args: &[String], use_override_crates: &HashSet<String>) -> Pa
82
82
output_path : None ,
83
83
use_override_crates : use_override_crates. clone ( ) ,
84
84
} ;
85
- rustc_driver:: RunCompiler :: new ( & args, & mut callbacks) . run ( ) . unwrap ( ) ;
85
+ rustc_driver:: run_compiler ( & args, & mut callbacks) ;
86
86
callbacks. output_path . unwrap ( )
87
87
}
88
88
@@ -216,14 +216,14 @@ fn go() -> ExitCode {
216
216
eprintln ! ( "normal build - {:?}" , args) ;
217
217
// This is a normal, non-test build. Just run the build, generating a `.mir` file
218
218
// alongside the normal output.
219
- rustc_driver:: RunCompiler :: new (
219
+ rustc_driver:: run_compiler (
220
220
& args,
221
221
& mut MirJsonCallbacks {
222
222
analysis_data : None ,
223
223
use_override_crates : use_override_crates. clone ( ) ,
224
224
export_style,
225
225
} ,
226
- ) . run ( ) . unwrap ( ) ;
226
+ ) ;
227
227
return ExitCode :: SUCCESS ;
228
228
} ,
229
229
Some ( x) => x,
@@ -257,7 +257,7 @@ fn go() -> ExitCode {
257
257
use_override_crates : use_override_crates. clone ( ) ,
258
258
export_style,
259
259
} ;
260
- rustc_driver:: RunCompiler :: new ( & args, & mut callbacks) . run ( ) . unwrap ( ) ;
260
+ rustc_driver:: run_compiler ( & args, & mut callbacks) ;
261
261
let data = callbacks. analysis_data
262
262
. expect ( "failed to find main MIR path" ) ;
263
263
0 commit comments