@@ -346,7 +346,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
346346 kind = "vtable" ,
347347 )
348348 }
349- Some ( GlobalAlloc :: Type { .. } ) => {
349+ Some ( GlobalAlloc :: TypeId { .. } ) => {
350350 err_ub_custom ! (
351351 fluent:: const_eval_invalid_dealloc,
352352 alloc_id = alloc_id,
@@ -622,7 +622,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
622622 }
623623 Some ( GlobalAlloc :: Function { .. } ) => throw_ub ! ( DerefFunctionPointer ( id) ) ,
624624 Some ( GlobalAlloc :: VTable ( ..) ) => throw_ub ! ( DerefVTablePointer ( id) ) ,
625- Some ( GlobalAlloc :: Type { .. } ) => throw_ub ! ( DerefTypeIdPointer ( id) ) ,
625+ Some ( GlobalAlloc :: TypeId { .. } ) => throw_ub ! ( DerefTypeIdPointer ( id) ) ,
626626 None => throw_ub ! ( PointerUseAfterFree ( id, CheckInAllocMsg :: MemoryAccess ) ) ,
627627 Some ( GlobalAlloc :: Static ( def_id) ) => {
628628 assert ! ( self . tcx. is_static( def_id) ) ;
@@ -904,7 +904,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
904904 let ( size, align) = global_alloc. size_and_align ( * self . tcx , self . typing_env ) ;
905905 let mutbl = global_alloc. mutability ( * self . tcx , self . typing_env ) ;
906906 let kind = match global_alloc {
907- GlobalAlloc :: Type { .. }
907+ GlobalAlloc :: TypeId { .. }
908908 | GlobalAlloc :: Static { .. }
909909 | GlobalAlloc :: Memory { .. } => AllocKind :: LiveData ,
910910 GlobalAlloc :: Function { .. } => bug ! ( "We already checked function pointers above" ) ,
@@ -953,7 +953,7 @@ impl<'tcx, M: Machine<'tcx>> InterpCx<'tcx, M> {
953953 ptr : Pointer < Option < M :: Provenance > > ,
954954 ) -> InterpResult < ' tcx , ( Ty < ' tcx > , Size ) > {
955955 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 {
957957 throw_ub_format ! ( "type_id_eq: `TypeId` provenance is not a type id" )
958958 } ;
959959 interp_ok ( ( ty, offset) )
@@ -1220,7 +1220,7 @@ impl<'a, 'tcx, M: Machine<'tcx>> std::fmt::Debug for DumpAllocs<'a, 'tcx, M> {
12201220 Some ( GlobalAlloc :: VTable ( ty, dyn_ty) ) => {
12211221 write ! ( fmt, " (vtable: impl {dyn_ty} for {ty})" ) ?;
12221222 }
1223- Some ( GlobalAlloc :: Type { ty } ) => {
1223+ Some ( GlobalAlloc :: TypeId { ty } ) => {
12241224 write ! ( fmt, " (typeid for {ty})" ) ?;
12251225 }
12261226 Some ( GlobalAlloc :: Static ( did) ) => {
0 commit comments