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 acd469681f
commit 04ac6f8405

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
),