Remove trait_of_item query.

This commit is contained in:
Camille GILLOT 2022-03-13 00:58:21 +01:00
parent d7ea161b7e
commit 957548183d
10 changed files with 25 additions and 36 deletions

View file

@ -2129,7 +2129,7 @@ impl<'a, 'tcx> InferCtxtPrivExt<'a, 'tcx> for InferCtxt<'a, 'tcx> {
}
] = path.segments
&& data.trait_ref.def_id == *trait_id
&& self.tcx.trait_of_item(item_id) == Some(*trait_id)
&& self.tcx.trait_of_item(*item_id) == Some(*trait_id)
&& !self.is_tainted_by_errors()
{
let (verb, noun) = match self.tcx.associated_item(item_id).kind {