File tree 2 files changed +5
-4
lines changed
compiler/rustc_driver_impl/src
2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -1507,7 +1507,7 @@ pub fn init_logger(early_dcx: &EarlyDiagCtxt, cfg: rustc_log::LoggerConfig) {
1507
1507
}
1508
1508
1509
1509
/// Install our usual `ctrlc` handler, which sets [`rustc_const_eval::CTRL_C_RECEIVED`].
1510
- /// Makign this handler optional lets tools can install a different handler, if they wish.
1510
+ /// Making this handler optional lets tools can install a different handler, if they wish.
1511
1511
pub fn install_ctrlc_handler( ) {
1512
1512
ctrlc:: set_handler( move || {
1513
1513
// Indicate that we have been signaled to stop. If we were already signaled, exit
Original file line number Diff line number Diff line change @@ -344,6 +344,10 @@ fn main() {
344
344
let args = rustc_driver:: args:: raw_args ( & early_dcx)
345
345
. unwrap_or_else ( |_| std:: process:: exit ( rustc_driver:: EXIT_FAILURE ) ) ;
346
346
347
+ // Install the ctrlc handler that sets `rustc_const_eval::CTRL_C_RECEIVED`, even if
348
+ // MIRI_BE_RUSTC is set.
349
+ rustc_driver:: install_ctrlc_handler ( ) ;
350
+
347
351
// If the environment asks us to actually be rustc, then do that.
348
352
if let Some ( crate_kind) = env:: var_os ( "MIRI_BE_RUSTC" ) {
349
353
// Earliest rustc setup.
@@ -372,9 +376,6 @@ fn main() {
372
376
let using_internal_features =
373
377
rustc_driver:: install_ice_hook ( "https://github.com/rust-lang/miri/issues/new" , |_| ( ) ) ;
374
378
375
- // Install the ctrlc handler that sets `rustc_const_eval::CTRL_C_RECEIVED`.
376
- rustc_driver:: install_ctrlc_handler ( ) ;
377
-
378
379
// Init loggers the Miri way.
379
380
init_early_loggers ( & early_dcx) ;
380
381
You can’t perform that action at this time.
0 commit comments