@@ -178,7 +178,7 @@ pub enum InstanceKind<'tcx> {
178
178
/// Generated by externally implementable items. This function adds indirection so we can choose
179
179
/// in the final crate whether to call an explicit implementation or, if none are given, call the
180
180
/// default.
181
- EiiShim { def_id : DefId , extern_item : DefId , chosen_impl : DefId } ,
181
+ EiiShim { def_id : DefId , extern_item : DefId , chosen_impl : DefId , weak_linkage : bool } ,
182
182
}
183
183
184
184
impl < ' tcx > Instance < ' tcx > {
@@ -416,7 +416,10 @@ pub fn fmt_instance(
416
416
InstanceKind :: FnPtrAddrShim ( _, ty) => write ! ( f, " - shim({ty})" ) ,
417
417
InstanceKind :: AsyncDropGlueCtorShim ( _, None ) => write ! ( f, " - shim(None)" ) ,
418
418
InstanceKind :: AsyncDropGlueCtorShim ( _, Some ( ty) ) => write ! ( f, " - shim(Some({ty}))" ) ,
419
- InstanceKind :: EiiShim { def_id : _, extern_item, chosen_impl } => {
419
+ InstanceKind :: EiiShim { def_id : _, extern_item, chosen_impl, weak_linkage : true } => {
420
+ write ! ( f, " - shim(eii: {extern_item:?} -> {chosen_impl:?} [weak]" )
421
+ }
422
+ InstanceKind :: EiiShim { def_id : _, extern_item, chosen_impl, weak_linkage : false } => {
420
423
write ! ( f, " - shim(eii: {extern_item:?} -> {chosen_impl:?})" )
421
424
}
422
425
}
0 commit comments