1
Fork 0

Separate collection of crate-local inherent impls from error reporting

This commit is contained in:
Michael Goulet 2024-09-23 18:07:42 -04:00
parent 11e760b7f4
commit cfb8419900
22 changed files with 127 additions and 125 deletions

View file

@ -1183,7 +1183,7 @@ fn collect_alloc<'tcx>(tcx: TyCtxt<'tcx>, alloc_id: AllocId, output: &mut MonoIt
}
fn assoc_fn_of_type<'tcx>(tcx: TyCtxt<'tcx>, def_id: DefId, fn_ident: Ident) -> Option<DefId> {
for impl_def_id in tcx.inherent_impls(def_id).ok()? {
for impl_def_id in tcx.inherent_impls(def_id) {
if let Some(new) = tcx.associated_items(impl_def_id).find_by_name_and_kind(
tcx,
fn_ident,