@@ -830,7 +830,7 @@ impl<'a, 'tcx: 'a, 'arena> Interpreter<'a, 'tcx, 'arena> {
830830
831831 Index ( ref operand) => {
832832 let elem_size = match base_ty. sty {
833- ty:: TyArray ( elem_ty, _) => self . type_size ( elem_ty ) ,
833+ ty:: TyArray ( elem_ty, _) |
834834 ty:: TySlice ( elem_ty) => self . type_size ( elem_ty) ,
835835 _ => panic ! ( "indexing expected an array or slice, got {:?}" , base_ty) ,
836836 } ;
@@ -1109,11 +1109,9 @@ impl<'a, 'tcx: 'a, 'arena> Interpreter<'a, 'tcx, 'arena> {
11091109 let vtable = selection. map ( |predicate| {
11101110 fulfill_cx. register_predicate_obligation ( & infcx, predicate) ;
11111111 } ) ;
1112- let vtable = infer:: drain_fulfillment_cx_or_panic (
1112+ infer:: drain_fulfillment_cx_or_panic (
11131113 DUMMY_SP , & infcx, & mut fulfill_cx, & vtable
1114- ) ;
1115-
1116- vtable
1114+ )
11171115 }
11181116
11191117 /// Trait method, which has to be resolved to an impl method.
@@ -1166,7 +1164,7 @@ impl<'a, 'tcx: 'a, 'arena> Interpreter<'a, 'tcx, 'arena> {
11661164 }
11671165}
11681166
1169- fn pointee_type < ' tcx > ( ptr_ty : ty:: Ty < ' tcx > ) -> Option < ty:: Ty < ' tcx > > {
1167+ fn pointee_type ( ptr_ty : ty:: Ty ) -> Option < ty:: Ty > {
11701168 match ptr_ty. sty {
11711169 ty:: TyRef ( _, ty:: TypeAndMut { ty, .. } ) |
11721170 ty:: TyRawPtr ( ty:: TypeAndMut { ty, .. } ) |
0 commit comments