Fix kind for associated types in rustdoc JSON output for trait implementations
This commit is contained in:
parent
bd2e51a338
commit
c1c0d25939
@ -252,8 +252,11 @@ fn from_clean_item(item: clean::Item, tcx: TyCtxt<'_>) -> ItemEnum {
|
||||
bounds: b.into_iter().map(|x| x.into_tcx(tcx)).collect(),
|
||||
default: None,
|
||||
},
|
||||
// FIXME: do not map to Typedef but to a custom variant
|
||||
AssocTypeItem(t, _) => ItemEnum::Typedef(t.into_tcx(tcx)),
|
||||
AssocTypeItem(t, b) => ItemEnum::AssocType {
|
||||
generics: t.generics.into_tcx(tcx),
|
||||
bounds: b.into_iter().map(|x| x.into_tcx(tcx)).collect(),
|
||||
default: t.item_type.map(|ty| ty.into_tcx(tcx)),
|
||||
},
|
||||
// `convert_item` early returns `None` for striped items and keywords.
|
||||
StrippedItem(_) | KeywordItem(_) => unreachable!(),
|
||||
ExternCrateItem { ref src } => ItemEnum::ExternCrate {
|
||||
|
Loading…
x
Reference in New Issue
Block a user