1
Fork 0

Only store a LocalDefId in hir::TraitItem.

This commit is contained in:
Camille GILLOT 2021-01-30 20:46:50 +01:00
parent cebbba081e
commit a871a0f111
45 changed files with 139 additions and 125 deletions

View file

@ -816,7 +816,7 @@ fn foo(&self) -> Self::T { String::new() }
// an assoc type as a return type (#72076).
if let hir::Defaultness::Default { has_value: true } = item.defaultness
{
if self.type_of(self.hir().local_def_id(item.id.hir_id)) == found {
if self.type_of(item.id.def_id) == found {
db.span_label(
item.span,
"associated type defaults can't be assumed inside the \