Skip to content

Commit

Permalink
Use short_ty_string
Browse files Browse the repository at this point in the history
  • Loading branch information
estebank committed Nov 2, 2024
1 parent c6017ba commit 86b5965
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1872,7 +1872,9 @@ impl<'a, 'tcx> TypeErrCtxt<'a, 'tcx> {
StringPart::normal(" implemented for `"),
]);
if types_content.0 == types_content.1 {
msg.push(StringPart::normal(obligation_trait_ref.self_ty().to_string()));
let ty =
self.tcx.short_ty_string(obligation_trait_ref.self_ty(), &mut None);
msg.push(StringPart::normal(ty));
} else {
msg.extend(types.0.0);
}
Expand Down

0 comments on commit 86b5965

Please sign in to comment.