Properly handle reexport of foreign items.
Handles `pub use` of `extern { fn, static, type }`. Also plug in some more
`match` arms where handling `extern type` is reasonable.
Fixed #46098.
This commit is contained in:
parent
e06138338f
commit
f0fcdbc021
3 changed files with 79 additions and 0 deletions
|
|
@ -2970,6 +2970,7 @@ fn register_def(cx: &DocContext, def: Def) -> DefId {
|
|||
Def::Struct(i) => (i, TypeKind::Struct),
|
||||
Def::Union(i) => (i, TypeKind::Union),
|
||||
Def::Mod(i) => (i, TypeKind::Module),
|
||||
Def::TyForeign(i) => (i, TypeKind::Foreign),
|
||||
Def::Static(i, _) => (i, TypeKind::Static),
|
||||
Def::Variant(i) => (cx.tcx.parent_def_id(i).unwrap(), TypeKind::Enum),
|
||||
Def::SelfTy(Some(def_id), _) => (def_id, TypeKind::Trait),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue