@@ -28,16 +28,17 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
2828 instance : ty:: Instance < ' tcx > ,
2929 abi : Abi ,
3030 args : & [ OpTy < ' tcx , Tag > ] ,
31- ret : Option < ( & PlaceTy < ' tcx , Tag > , mir:: BasicBlock ) > ,
31+ dest : & PlaceTy < ' tcx , Tag > ,
32+ ret : Option < mir:: BasicBlock > ,
3233 unwind : StackPopUnwind ,
3334 ) -> InterpResult < ' tcx , Option < ( & ' mir mir:: Body < ' tcx > , ty:: Instance < ' tcx > ) > > {
3435 let this = self . eval_context_mut ( ) ;
35- trace ! ( "eval_fn_call: {:#?}, {:?}" , instance, ret . map ( |p| p . 0 ) ) ;
36+ trace ! ( "eval_fn_call: {:#?}, {:?}" , instance, dest ) ;
3637
3738 // There are some more lang items we want to hook that CTFE does not hook (yet).
3839 if this. tcx . lang_items ( ) . align_offset_fn ( ) == Some ( instance. def . def_id ( ) ) {
3940 let [ ptr, align] = check_arg_count ( args) ?;
40- if this. align_offset ( ptr, align, ret, unwind) ? {
41+ if this. align_offset ( ptr, align, dest , ret, unwind) ? {
4142 return Ok ( None ) ;
4243 }
4344 }
@@ -50,7 +51,7 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
5051 // to run extra MIR), and Ok(Some(body)) if we found MIR to run for the
5152 // foreign function
5253 // Any needed call to `goto_block` will be performed by `emulate_foreign_item`.
53- return this. emulate_foreign_item ( instance. def_id ( ) , abi, args, ret, unwind) ;
54+ return this. emulate_foreign_item ( instance. def_id ( ) , abi, args, dest , ret, unwind) ;
5455 }
5556
5657 // Otherwise, load the MIR.
@@ -63,11 +64,12 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
6364 & mut self ,
6465 ptr_op : & OpTy < ' tcx , Tag > ,
6566 align_op : & OpTy < ' tcx , Tag > ,
66- ret : Option < ( & PlaceTy < ' tcx , Tag > , mir:: BasicBlock ) > ,
67+ dest : & PlaceTy < ' tcx , Tag > ,
68+ ret : Option < mir:: BasicBlock > ,
6769 unwind : StackPopUnwind ,
6870 ) -> InterpResult < ' tcx , bool > {
6971 let this = self . eval_context_mut ( ) ;
70- let ( dest , ret) = ret. unwrap ( ) ;
72+ let ret = ret. unwrap ( ) ;
7173
7274 if this. machine . check_alignment != AlignmentCheck :: Symbolic {
7375 // Just use actual implementation.
0 commit comments