about summary refs log tree commit diff
path: root/src/librustdoc/html/render
diff options
context:
space:
mode:
authorMichael Goulet <michael@errs.io>2023-11-12 18:57:24 +0000
committerMichael Goulet <michael@errs.io>2024-01-08 20:30:10 +0000
commitdfb9f5df2c9f3c60f2541b3804cb6be1b5c66e63 (patch)
tree8079232438c59b7438ed903702045ffb483f43a8 /src/librustdoc/html/render
parent755b2da841b7dad218bd34708a592a2bef0f4b21 (diff)
Rustdoc and Clippy stop misusing Key for Ty -> (adt) DefId
Diffstat (limited to 'src/librustdoc/html/render')
-rw-r--r--src/librustdoc/html/render/print_item.rs3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/librustdoc/html/render/print_item.rs b/src/librustdoc/html/render/print_item.rs
index 5ca623f01f1..3b91fbdcb29 100644
--- a/src/librustdoc/html/render/print_item.rs
+++ b/src/librustdoc/html/render/print_item.rs
@@ -4,7 +4,6 @@ use rustc_hir as hir;
 use rustc_hir::def::CtorKind;
 use rustc_hir::def_id::DefId;
 use rustc_index::IndexVec;
-use rustc_middle::query::Key;
 use rustc_middle::ty::{self, TyCtxt};
 use rustc_span::hygiene::MacroKind;
 use rustc_span::symbol::{kw, sym, Symbol};
@@ -1259,7 +1258,7 @@ fn item_type_alias(w: &mut Buffer, cx: &mut Context<'_>, it: &clean::Item, t: &c
             clean::TypeAliasInnerType::Enum { variants, is_non_exhaustive } => {
                 let variants_iter = || variants.iter().filter(|i| !i.is_stripped());
                 let ty = cx.tcx().type_of(it.def_id().unwrap()).instantiate_identity();
-                let enum_def_id = ty.ty_adt_id().unwrap();
+                let enum_def_id = ty.ty_adt_def().unwrap().did();
 
                 wrap_item(w, |w| {
                     let variants_len = variants.len();