@@ -29,13 +29,12 @@ use std::path::PathBuf;
2929use std:: process:: { self , Command , Stdio } ;
3030use std:: sync:: atomic:: { AtomicBool , Ordering } ;
3131use std:: sync:: { Arc , OnceLock } ;
32- use std:: time:: { Duration , Instant , SystemTime } ;
32+ use std:: time:: { Instant , SystemTime } ;
3333use std:: { env, str} ;
3434
3535use rustc_ast as ast;
3636use rustc_codegen_ssa:: traits:: CodegenBackend ;
3737use rustc_codegen_ssa:: { CodegenErrors , CodegenResults } ;
38- use rustc_const_eval:: CTRL_C_RECEIVED ;
3938use rustc_data_structures:: profiling:: {
4039 TimePassesFormat , get_resident_set_size, print_time_passes_entry,
4140} ;
@@ -1577,8 +1576,8 @@ pub fn install_ctrlc_handler() {
15771576 // time to check CTRL_C_RECEIVED and run its own shutdown logic, but after a short amount
15781577 // of time exit the process. This sleep+exit ensures that even if nobody is checking
15791578 // CTRL_C_RECEIVED, the compiler exits reasonably promptly.
1580- CTRL_C_RECEIVED . store( true , Ordering :: Relaxed ) ;
1581- std:: thread:: sleep( Duration :: from_millis( 100 ) ) ;
1579+ rustc_const_eval :: CTRL_C_RECEIVED . store( true , Ordering :: Relaxed ) ;
1580+ std:: thread:: sleep( std :: time :: Duration :: from_millis( 100 ) ) ;
15821581 std:: process:: exit( 1 ) ;
15831582 } )
15841583 . expect( "Unable to install ctrlc handler" ) ;
0 commit comments