name async generators something more human friendly in type error diagnostics
This commit is contained in:
@@ -1366,8 +1366,8 @@ impl<'a, 'tcx> InferCtxtPrivExt<'tcx> for InferCtxt<'a, 'tcx> {
|
||||
Some(t) => Some(t),
|
||||
None => {
|
||||
let ty = parent_trait_ref.skip_binder().self_ty();
|
||||
let span =
|
||||
TyCategory::from_ty(ty).map(|(_, def_id)| self.tcx.def_span(def_id));
|
||||
let span = TyCategory::from_ty(self.tcx, ty)
|
||||
.map(|(_, def_id)| self.tcx.def_span(def_id));
|
||||
Some((ty.to_string(), span))
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user