]> git.lizzy.rs Git - rust.git/blobdiff - compiler/rustc_middle/src/ty/error.rs
Auto merge of #105323 - cjgillot:simplify-const-prop, r=davidtwco
[rust.git] / compiler / rustc_middle / src / ty / error.rs
index e1aa7fea441cdde9df8701cc3523f402173c10fb..50554cf9a82c85e7e53112ae0da4e6a3bb723f6e 100644 (file)
@@ -457,7 +457,7 @@ pub fn note_and_explain_type_err(
                             .def_id
                             .as_local()
                             .map(|id| hir.local_def_id_to_hir_id(id))
-                            .and_then(|id| self.hir().find(self.hir().parent_id(id)))
+                            .and_then(|id| self.hir().find_parent(id))
                             .as_ref()
                             .and_then(|node| node.generics())
                         {