1
Fork 0

Filter out RPITITs when suggesting unconstrained assoc type on too many generics

This commit is contained in:
Michael Goulet 2025-01-30 18:39:08 +00:00
parent a6434ef9c0
commit 88d7ea36e9
3 changed files with 32 additions and 0 deletions

View file

@ -495,6 +495,7 @@ impl<'a, 'tcx> WrongNumberOfGenericArgs<'a, 'tcx> {
.iter()
.any(|constraint| constraint.ident.name == item.name)
})
.filter(|item| !item.is_impl_trait_in_trait())
.map(|item| self.tcx.item_ident(item.def_id).to_string())
.collect()
} else {