@@ -4,7 +4,7 @@ use std::mem;
4
4
use rustc:: mir;
5
5
use rustc:: ty:: {
6
6
self ,
7
- layout:: { self , LayoutOf , Size , TyLayout } ,
7
+ layout:: { self , LayoutOf , Size , TyAndLayout } ,
8
8
List , TyCtxt ,
9
9
} ;
10
10
use rustc_hir:: def_id:: { DefId , CRATE_DEF_INDEX } ;
@@ -84,8 +84,8 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
84
84
self . eval_libc ( name) ?. to_i32 ( )
85
85
}
86
86
87
- /// Helper function to get the `TyLayout ` of a `libc` type
88
- fn libc_ty_layout ( & mut self , name : & str ) -> InterpResult < ' tcx , TyLayout < ' tcx > > {
87
+ /// Helper function to get the `TyAndLayout ` of a `libc` type
88
+ fn libc_ty_layout ( & mut self , name : & str ) -> InterpResult < ' tcx , TyAndLayout < ' tcx > > {
89
89
let this = self . eval_context_mut ( ) ;
90
90
let ty = this. resolve_path ( & [ "libc" , name] ) . monomorphic_ty ( * this. tcx ) ;
91
91
this. layout_of ( ty)
@@ -469,7 +469,7 @@ pub trait EvalContextExt<'mir, 'tcx: 'mir>: crate::MiriEvalContextExt<'mir, 'tcx
469
469
470
470
pub fn immty_from_int_checked < ' tcx > (
471
471
int : impl Into < i128 > ,
472
- layout : TyLayout < ' tcx > ,
472
+ layout : TyAndLayout < ' tcx > ,
473
473
) -> InterpResult < ' tcx , ImmTy < ' tcx , Tag > > {
474
474
let int = int. into ( ) ;
475
475
Ok ( ImmTy :: try_from_int ( int, layout) . ok_or_else ( || {
@@ -479,7 +479,7 @@ pub fn immty_from_int_checked<'tcx>(
479
479
480
480
pub fn immty_from_uint_checked < ' tcx > (
481
481
int : impl Into < u128 > ,
482
- layout : TyLayout < ' tcx > ,
482
+ layout : TyAndLayout < ' tcx > ,
483
483
) -> InterpResult < ' tcx , ImmTy < ' tcx , Tag > > {
484
484
let int = int. into ( ) ;
485
485
Ok ( ImmTy :: try_from_uint ( int, layout) . ok_or_else ( || {
0 commit comments