@@ -4,13 +4,12 @@ use std::assert_matches::assert_matches;
44use std:: borrow:: Cow ;
55
66use either:: { Left , Right } ;
7+ use rustc_abi:: { self as abi, ExternAbi , FieldIdx , Integer } ;
78use rustc_middle:: ty:: layout:: { FnAbiOf , IntegerExt , LayoutOf , TyAndLayout } ;
89use rustc_middle:: ty:: { self , AdtDef , Instance , Ty } ;
910use rustc_middle:: { bug, mir, span_bug} ;
1011use rustc_span:: sym;
11- use rustc_target:: abi:: call:: { ArgAbi , FnAbi , PassMode } ;
12- use rustc_target:: abi:: { self , FieldIdx , Integer } ;
13- use rustc_target:: spec:: abi:: Abi ;
12+ use rustc_target:: callconv:: { ArgAbi , FnAbi , PassMode } ;
1413use tracing:: { info, instrument, trace} ;
1514
1615use super :: {
@@ -488,7 +487,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
488487 pub ( super ) fn init_fn_call (
489488 & mut self ,
490489 fn_val : FnVal < ' tcx , M :: ExtraFnVal > ,
491- ( caller_abi, caller_fn_abi) : ( Abi , & FnAbi < ' tcx , Ty < ' tcx > > ) ,
490+ ( caller_abi, caller_fn_abi) : ( ExternAbi , & FnAbi < ' tcx , Ty < ' tcx > > ) ,
492491 args : & [ FnArg < ' tcx , M :: Provenance > ] ,
493492 with_caller_location : bool ,
494493 destination : & MPlaceTy < ' tcx , M :: Provenance > ,
@@ -566,7 +565,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
566565
567566 // Special handling for the closure ABI: untuple the last argument.
568567 let args: Cow < ' _ , [ FnArg < ' tcx , M :: Provenance > ] > =
569- if caller_abi == Abi :: RustCall && !args. is_empty ( ) {
568+ if caller_abi == ExternAbi :: RustCall && !args. is_empty ( ) {
570569 // Untuple
571570 let ( untuple_arg, args) = args. split_last ( ) . unwrap ( ) ;
572571 trace ! ( "init_fn_call: Will pass last argument by untupling" ) ;
@@ -732,7 +731,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
732731 pub ( super ) fn init_fn_tail_call (
733732 & mut self ,
734733 fn_val : FnVal < ' tcx , M :: ExtraFnVal > ,
735- ( caller_abi, caller_fn_abi) : ( Abi , & FnAbi < ' tcx , Ty < ' tcx > > ) ,
734+ ( caller_abi, caller_fn_abi) : ( ExternAbi , & FnAbi < ' tcx , Ty < ' tcx > > ) ,
736735 args : & [ FnArg < ' tcx , M :: Provenance > ] ,
737736 with_caller_location : bool ,
738737 ) -> InterpResult < ' tcx > {
@@ -817,7 +816,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
817816
818817 self . init_fn_call (
819818 FnVal :: Instance ( instance) ,
820- ( Abi :: Rust , fn_abi) ,
819+ ( ExternAbi :: Rust , fn_abi) ,
821820 & [ FnArg :: Copy ( arg. into ( ) ) ] ,
822821 false ,
823822 & ret,
0 commit comments