Fix typo in error message for invalid casting

Corrected the spelling of "defererence" to "dereference" in the error message that informs users about invalid casting requirements.
This commit is contained in:
Philipp Hofer 2024-12-12 15:42:21 +01:00
parent 648a00936b
commit ec6e0983b8

View file

@ -59,7 +59,7 @@ pub(crate) fn invalid_cast(ctx: &DiagnosticsContext<'_>, d: &hir::InvalidCast) -
DiagnosticCode::RustcHardError("E0606"),
format_ty!(
ctx,
"casting `{}` as `{}` is invalid: needs defererence or removal of unneeded borrow",
"casting `{}` as `{}` is invalid: needs dereference or removal of unneeded borrow",
d.expr_ty,
d.cast_ty
),