@@ -92,8 +92,8 @@ impl<'a, 'gcc, 'tcx> IntrinsicCallMethods<'tcx> for Builder<'a, 'gcc, 'tcx> {
9292 let tcx = self . tcx ;
9393 let callee_ty = instance. ty ( tcx, ty:: ParamEnv :: reveal_all ( ) ) ;
9494
95- let ( def_id, substs ) = match * callee_ty. kind ( ) {
96- ty:: FnDef ( def_id, substs ) => ( def_id, substs ) ,
95+ let ( def_id, fn_args ) = match * callee_ty. kind ( ) {
96+ ty:: FnDef ( def_id, fn_args ) => ( def_id, fn_args ) ,
9797 _ => bug ! ( "expected fn item type, found {}" , callee_ty) ,
9898 } ;
9999
@@ -142,7 +142,7 @@ impl<'a, 'gcc, 'tcx> IntrinsicCallMethods<'tcx> for Builder<'a, 'gcc, 'tcx> {
142142 }
143143
144144 sym:: volatile_load | sym:: unaligned_volatile_load => {
145- let tp_ty = substs . type_at ( 0 ) ;
145+ let tp_ty = fn_args . type_at ( 0 ) ;
146146 let mut ptr = args[ 0 ] . immediate ( ) ;
147147 if let PassMode :: Cast ( ty, _) = & fn_abi. ret . mode {
148148 ptr = self . pointercast ( ptr, self . type_ptr_to ( ty. gcc_type ( self ) ) ) ;
@@ -264,7 +264,7 @@ impl<'a, 'gcc, 'tcx> IntrinsicCallMethods<'tcx> for Builder<'a, 'gcc, 'tcx> {
264264
265265 sym:: raw_eq => {
266266 use rustc_target:: abi:: Abi :: * ;
267- let tp_ty = substs . type_at ( 0 ) ;
267+ let tp_ty = fn_args . type_at ( 0 ) ;
268268 let layout = self . layout_of ( tp_ty) . layout ;
269269 let _use_integer_compare = match layout. abi ( ) {
270270 Scalar ( _) | ScalarPair ( _, _) => true ,
0 commit comments