1
Fork 0

Use non-exhaustive matches for TyKind

Also no longer export noop async_drop_in_place_raw
This commit is contained in:
Daria Sukhonina 2024-04-17 20:49:53 +03:00
parent 24a24ec6ba
commit 80c0b7e90f
13 changed files with 150 additions and 182 deletions

View file

@ -772,7 +772,7 @@ fn mono_item_visibility<'tcx>(
let def_id = match instance.def {
InstanceDef::Item(def_id)
| InstanceDef::DropGlue(def_id, Some(_))
| InstanceDef::AsyncDropGlueCtorShim(def_id, _) => def_id,
| InstanceDef::AsyncDropGlueCtorShim(def_id, Some(_)) => def_id,
// We match the visibility of statics here
InstanceDef::ThreadLocalShim(def_id) => {
@ -789,6 +789,7 @@ fn mono_item_visibility<'tcx>(
| InstanceDef::ConstructCoroutineInClosureShim { .. }
| InstanceDef::CoroutineKindShim { .. }
| InstanceDef::DropGlue(..)
| InstanceDef::AsyncDropGlueCtorShim(..)
| InstanceDef::CloneShim(..)
| InstanceDef::FnPtrAddrShim(..) => return Visibility::Hidden,
};