1
Fork 0

Fix typo in hir lowering lint diag

This commit is contained in:
Yotam Ofek 2025-03-14 20:19:38 +00:00
parent ecade534c6
commit 5da1ba41b3
8 changed files with 15 additions and 13 deletions

View file

@ -411,7 +411,9 @@ impl<'tcx> dyn HirTyLowerer<'tcx> + '_ {
Applicability::MachineApplicable,
);
if !is_dyn_compatible {
diag.note(format!("`{trait_name}` it is dyn-incompatible, so it can't be `dyn`"));
diag.note(format!(
"`{trait_name}` is dyn-incompatible, otherwise a trait object could be used"
));
} else {
// No ampersand in suggestion if it's borrowed already
let (dyn_str, paren_dyn_str) =