@@ -7,7 +7,7 @@ use std::str::FromStr;
7
7
use std:: time:: Duration ;
8
8
use std:: { cmp, env, iter} ;
9
9
10
- use rustc_ast:: expand:: allocator:: { ALLOC_ERROR_HANDLER , AllocatorKind , global_fn_name} ;
10
+ use rustc_ast:: expand:: allocator:: { AllocatorKind , global_fn_name} ;
11
11
use rustc_ast:: { self as ast, * } ;
12
12
use rustc_data_structures:: fx:: FxHashSet ;
13
13
use rustc_data_structures:: owned_slice:: OwnedSlice ;
@@ -25,8 +25,8 @@ use rustc_middle::ty::data_structures::IndexSet;
25
25
use rustc_middle:: ty:: { TyCtxt , TyCtxtFeed } ;
26
26
use rustc_proc_macro:: bridge:: client:: ProcMacro ;
27
27
use rustc_session:: config:: {
28
- self , CrateType , ExtendedTargetModifierInfo , ExternLocation , OptionsTargetModifiers ,
29
- TargetModifier ,
28
+ self , CrateType , ExtendedTargetModifierInfo , ExternLocation , OomStrategy ,
29
+ OptionsTargetModifiers , TargetModifier ,
30
30
} ;
31
31
use rustc_session:: cstore:: { CrateDepKind , CrateSource , ExternCrate , ExternCrateSource } ;
32
32
use rustc_session:: lint:: { self , BuiltinLintDiag } ;
@@ -322,10 +322,6 @@ impl CStore {
322
322
self . allocator_kind
323
323
}
324
324
325
- pub ( crate ) fn alloc_error_handler_kind ( & self ) -> Option < AllocatorKind > {
326
- self . alloc_error_handler_kind
327
- }
328
-
329
325
pub ( crate ) fn has_global_allocator ( & self ) -> bool {
330
326
self . has_global_allocator
331
327
}
@@ -1068,7 +1064,7 @@ impl<'a, 'tcx> CrateLoader<'a, 'tcx> {
1068
1064
spans => !spans. is_empty ( ) ,
1069
1065
} ;
1070
1066
self . cstore . has_alloc_error_handler =
1071
- match & * fn_spans ( krate, Symbol :: intern ( ALLOC_ERROR_HANDLER ) ) {
1067
+ match & * fn_spans ( krate, Symbol :: intern ( OomStrategy :: SYMBOL ) ) {
1072
1068
[ span1, span2, ..] => {
1073
1069
self . dcx ( ) . emit_err ( errors:: NoMultipleAllocErrorHandler {
1074
1070
span2 : * span2,
0 commit comments