@@ -346,7 +346,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
346
346
kind = "vtable" ,
347
347
)
348
348
}
349
- Some ( GlobalAlloc :: Type { .. } ) => {
349
+ Some ( GlobalAlloc :: TypeId { .. } ) => {
350
350
err_ub_custom ! (
351
351
fluent:: const_eval_invalid_dealloc,
352
352
alloc_id = alloc_id,
@@ -622,7 +622,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
622
622
}
623
623
Some ( GlobalAlloc :: Function { .. } ) => throw_ub ! ( DerefFunctionPointer ( id) ) ,
624
624
Some ( GlobalAlloc :: VTable ( ..) ) => throw_ub ! ( DerefVTablePointer ( id) ) ,
625
- Some ( GlobalAlloc :: Type { .. } ) => throw_ub ! ( DerefTypeIdPointer ( id) ) ,
625
+ Some ( GlobalAlloc :: TypeId { .. } ) => throw_ub ! ( DerefTypeIdPointer ( id) ) ,
626
626
None => throw_ub ! ( PointerUseAfterFree ( id, CheckInAllocMsg :: MemoryAccess ) ) ,
627
627
Some ( GlobalAlloc :: Static ( def_id) ) => {
628
628
assert ! ( self . tcx. is_static( def_id) ) ;
@@ -904,7 +904,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
904
904
let ( size, align) = global_alloc. size_and_align ( * self . tcx , self . typing_env ) ;
905
905
let mutbl = global_alloc. mutability ( * self . tcx , self . typing_env ) ;
906
906
let kind = match global_alloc {
907
- GlobalAlloc :: Type { .. }
907
+ GlobalAlloc :: TypeId { .. }
908
908
| GlobalAlloc :: Static { .. }
909
909
| GlobalAlloc :: Memory { .. } => AllocKind :: LiveData ,
910
910
GlobalAlloc :: Function { .. } => bug ! ( "We already checked function pointers above" ) ,
@@ -953,7 +953,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
953
953
ptr : Pointer < Option < M :: Provenance > > ,
954
954
) -> InterpResult < ' tcx , ( Ty < ' tcx > , Size ) > {
955
955
let ( alloc_id, offset, _meta) = self . ptr_get_alloc_id ( ptr, 0 ) ?;
956
- let GlobalAlloc :: Type { ty } = self . tcx . global_alloc ( alloc_id) else {
956
+ let GlobalAlloc :: TypeId { ty } = self . tcx . global_alloc ( alloc_id) else {
957
957
throw_ub_format ! ( "type_id_eq: `TypeId` provenance is not a type id" )
958
958
} ;
959
959
interp_ok ( ( ty, offset) )
@@ -1220,7 +1220,7 @@ impl<'a, 'tcx, M: Machine<'tcx>> std::fmt::Debug for DumpAllocs<'a, 'tcx, M> {
1220
1220
Some ( GlobalAlloc :: VTable ( ty, dyn_ty) ) => {
1221
1221
write ! ( fmt, " (vtable: impl {dyn_ty} for {ty})" ) ?;
1222
1222
}
1223
- Some ( GlobalAlloc :: Type { ty } ) => {
1223
+ Some ( GlobalAlloc :: TypeId { ty } ) => {
1224
1224
write ! ( fmt, " (typeid for {ty})" ) ?;
1225
1225
}
1226
1226
Some ( GlobalAlloc :: Static ( did) ) => {
0 commit comments