@@ -247,7 +247,7 @@ impl Visitor<'tcx> for Validator<'_, 'mir, 'tcx> {
247
247
if let box [ proj_base @ .., elem] = & place. projection {
248
248
if * elem == ProjectionElem :: Deref {
249
249
let base_ty = Place :: ty_from ( & place. base , proj_base, self . body , self . tcx ) . ty ;
250
- if let ty:: Ref ( ..) = base_ty. sty {
250
+ if let ty:: Ref ( ..) = base_ty. kind {
251
251
reborrow_place = Some ( proj_base) ;
252
252
}
253
253
}
@@ -302,7 +302,7 @@ impl Visitor<'tcx> for Validator<'_, 'mir, 'tcx> {
302
302
}
303
303
304
304
Rvalue :: BinaryOp ( op, ref lhs, _) => {
305
- if let ty:: RawPtr ( _) | ty:: FnPtr ( ..) = lhs. ty ( self . body , self . tcx ) . sty {
305
+ if let ty:: RawPtr ( _) | ty:: FnPtr ( ..) = lhs. ty ( self . body , self . tcx ) . kind {
306
306
assert ! ( op == BinOp :: Eq || op == BinOp :: Ne ||
307
307
op == BinOp :: Le || op == BinOp :: Lt ||
308
308
op == BinOp :: Ge || op == BinOp :: Gt ||
@@ -431,7 +431,7 @@ impl Visitor<'tcx> for Validator<'_, 'mir, 'tcx> {
431
431
}
432
432
433
433
let base_ty = Place :: ty_from ( place_base, proj_base, self . body , self . tcx ) . ty ;
434
- if let ty:: RawPtr ( _) = base_ty. sty {
434
+ if let ty:: RawPtr ( _) = base_ty. kind {
435
435
self . check_op ( ops:: RawPtrDeref ) ;
436
436
}
437
437
}
@@ -508,7 +508,7 @@ impl Visitor<'tcx> for Validator<'_, 'mir, 'tcx> {
508
508
TerminatorKind :: Call { func, .. } => {
509
509
let fn_ty = func. ty ( self . body , self . tcx ) ;
510
510
511
- let def_id = match fn_ty. sty {
511
+ let def_id = match fn_ty. kind {
512
512
ty:: FnDef ( def_id, _) => def_id,
513
513
514
514
ty:: FnPtr ( _) => {
0 commit comments