1
Fork 0

update auto trait lint

This commit is contained in:
lcnr 2022-02-24 08:36:29 +01:00
parent e780264e1e
commit 70018c19cb
3 changed files with 33 additions and 7 deletions

View file

@ -439,6 +439,7 @@ fn fast_reject_auto_impl<'tcx>(tcx: TyCtxt<'tcx>, trait_def_id: DefId, self_ty:
}
match t.kind() {
ty::Adt(def, substs) if def.is_phantom_data() => substs.super_visit_with(self),
ty::Adt(def, substs) => {
// @lcnr: This is the only place where cycles can happen. We avoid this
// by only visiting each `DefId` once.