@@ -30,7 +30,7 @@ use std::ops::Range;
30
30
use std:: path:: PathBuf ;
31
31
use std:: str:: FromStr ;
32
32
use std:: sync:: atomic:: { AtomicI32 , Ordering } ;
33
- use std:: sync:: { Arc , Once } ;
33
+ use std:: sync:: Once ;
34
34
35
35
use miri:: {
36
36
BacktraceStyle , BorrowTrackerMethod , MiriConfig , MiriEntryFnType , ProvenanceMode , RetagFields ,
@@ -371,13 +371,10 @@ fn init_late_loggers(early_dcx: &EarlyDiagCtxt, tcx: TyCtxt<'_>) {
371
371
fn run_compiler_and_exit (
372
372
args : & [ String ] ,
373
373
callbacks : & mut ( dyn rustc_driver:: Callbacks + Send ) ,
374
- using_internal_features : Arc < std:: sync:: atomic:: AtomicBool > ,
375
374
) -> ! {
376
375
// Invoke compiler, and handle return code.
377
376
let exit_code = rustc_driver:: catch_with_exit_code ( move || {
378
- rustc_driver:: RunCompiler :: new ( args, callbacks)
379
- . set_using_internal_features ( using_internal_features)
380
- . run ( ) ;
377
+ rustc_driver:: run_compiler ( args, callbacks) ;
381
378
Ok ( ( ) )
382
379
} ) ;
383
380
std:: process:: exit ( exit_code)
@@ -468,8 +465,7 @@ fn main() {
468
465
// If the environment asks us to actually be rustc, then do that.
469
466
if let Some ( crate_kind) = env:: var_os ( "MIRI_BE_RUSTC" ) {
470
467
// Earliest rustc setup.
471
- let using_internal_features =
472
- rustc_driver:: install_ice_hook ( rustc_driver:: DEFAULT_BUG_REPORT_URL , |_| ( ) ) ;
468
+ rustc_driver:: install_ice_hook ( rustc_driver:: DEFAULT_BUG_REPORT_URL , |_| ( ) ) ;
473
469
rustc_driver:: init_rustc_env_logger ( & early_dcx) ;
474
470
475
471
let target_crate = if crate_kind == "target" {
@@ -493,16 +489,11 @@ fn main() {
493
489
}
494
490
495
491
// We cannot use `rustc_driver::main` as we want it to use `args` as the CLI arguments.
496
- run_compiler_and_exit (
497
- & args,
498
- & mut MiriBeRustCompilerCalls { target_crate } ,
499
- using_internal_features,
500
- )
492
+ run_compiler_and_exit ( & args, & mut MiriBeRustCompilerCalls { target_crate } )
501
493
}
502
494
503
495
// Add an ICE bug report hook.
504
- let using_internal_features =
505
- rustc_driver:: install_ice_hook ( "https://github.com/rust-lang/miri/issues/new" , |_| ( ) ) ;
496
+ rustc_driver:: install_ice_hook ( "https://github.com/rust-lang/miri/issues/new" , |_| ( ) ) ;
506
497
507
498
// Init loggers the Miri way.
508
499
init_early_loggers ( & early_dcx) ;
@@ -736,9 +727,5 @@ fn main() {
736
727
737
728
debug ! ( "rustc arguments: {:?}" , rustc_args) ;
738
729
debug ! ( "crate arguments: {:?}" , miri_config. args) ;
739
- run_compiler_and_exit (
740
- & rustc_args,
741
- & mut MiriCompilerCalls :: new ( miri_config, many_seeds) ,
742
- using_internal_features,
743
- )
730
+ run_compiler_and_exit ( & rustc_args, & mut MiriCompilerCalls :: new ( miri_config, many_seeds) )
744
731
}
0 commit comments