@@ -201,7 +201,7 @@ impl<'tcx, Prov: Provenance> MPlaceTy<'tcx, Prov> {
201
201
layout : TyAndLayout < ' tcx > ,
202
202
cx : & impl HasDataLayout ,
203
203
) -> InterpResult < ' tcx , Self > {
204
- assert ! ( ! layout. is_unsized ( ) ) ;
204
+ assert ! ( layout. is_sized ( ) ) ;
205
205
self . offset_with_meta ( offset, MemPlaceMeta :: None , layout, cx)
206
206
}
207
207
@@ -340,7 +340,7 @@ where
340
340
& self ,
341
341
place : & MPlaceTy < ' tcx , M :: Provenance > ,
342
342
) -> InterpResult < ' tcx , Option < AllocRef < ' _ , ' tcx , M :: Provenance , M :: AllocExtra > > > {
343
- assert ! ( ! place. layout. is_unsized ( ) ) ;
343
+ assert ! ( place. layout. is_sized ( ) ) ;
344
344
assert ! ( !place. meta. has_meta( ) ) ;
345
345
let size = place. layout . size ;
346
346
self . get_ptr_alloc ( place. ptr , size, place. align )
@@ -351,7 +351,7 @@ where
351
351
& mut self ,
352
352
place : & MPlaceTy < ' tcx , M :: Provenance > ,
353
353
) -> InterpResult < ' tcx , Option < AllocRefMut < ' _ , ' tcx , M :: Provenance , M :: AllocExtra > > > {
354
- assert ! ( ! place. layout. is_unsized ( ) ) ;
354
+ assert ! ( place. layout. is_sized ( ) ) ;
355
355
assert ! ( !place. meta. has_meta( ) ) ;
356
356
let size = place. layout . size ;
357
357
self . get_ptr_alloc_mut ( place. ptr , size, place. align )
@@ -485,7 +485,7 @@ where
485
485
src : Immediate < M :: Provenance > ,
486
486
dest : & PlaceTy < ' tcx , M :: Provenance > ,
487
487
) -> InterpResult < ' tcx > {
488
- assert ! ( ! dest. layout. is_unsized ( ) , "Cannot write unsized data" ) ;
488
+ assert ! ( dest. layout. is_sized ( ) , "Cannot write unsized data" ) ;
489
489
trace ! ( "write_immediate: {:?} <- {:?}: {}" , * dest, src, dest. layout. ty) ;
490
490
491
491
// See if we can avoid an allocation. This is the counterpart to `read_immediate_raw`,
@@ -746,7 +746,7 @@ where
746
746
layout : TyAndLayout < ' tcx > ,
747
747
kind : MemoryKind < M :: MemoryKind > ,
748
748
) -> InterpResult < ' tcx , MPlaceTy < ' tcx , M :: Provenance > > {
749
- assert ! ( ! layout. is_unsized ( ) ) ;
749
+ assert ! ( layout. is_sized ( ) ) ;
750
750
let ptr = self . allocate_ptr ( layout. size , layout. align . abi , kind) ?;
751
751
Ok ( MPlaceTy :: from_aligned_ptr ( ptr. into ( ) , layout) )
752
752
}
0 commit comments