From db4a06e9bdbfc808e60b06b357c35481a91fc8e6 Mon Sep 17 00:00:00 2001 From: Noah Lev Date: Thu, 11 Nov 2021 15:35:10 -0800 Subject: [PATCH] Use `path.def_id()` in `Type::inner_def_id()` --- src/librustdoc/clean/types.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/librustdoc/clean/types.rs b/src/librustdoc/clean/types.rs index d28f3ce87785..ed773cf4ad22 100644 --- a/src/librustdoc/clean/types.rs +++ b/src/librustdoc/clean/types.rs @@ -1522,7 +1522,7 @@ impl Type { fn inner_def_id(&self, cache: Option<&Cache>) -> Option { let t: PrimitiveType = match *self { - ResolvedPath { did, .. } => return Some(did), + ResolvedPath { ref path, did: _ } => return Some(path.def_id()), DynTrait(ref bounds, _) => return Some(bounds[0].trait_.def_id()), Primitive(p) => return cache.and_then(|c| c.primitive_locations.get(&p).cloned()), BorrowedRef { type_: box Generic(..), .. } => PrimitiveType::Reference,