1
Fork 0

rework borrowck errors so that it's harder to not set tainted

This commit is contained in:
Michael Goulet 2022-02-07 22:37:32 -08:00
parent 8b7b0a0e49
commit 29c2bb51c0
7 changed files with 119 additions and 74 deletions

View file

@ -327,7 +327,7 @@ impl<'cx, 'tcx> crate::MirBorrowckCtxt<'cx, 'tcx> {
verb: &str,
optional_adverb_for_moved: &str,
moved_path: Option<String>,
) -> DiagnosticBuilder<'cx> {
) -> DiagnosticBuilder<'tcx> {
let moved_path = moved_path.map(|mp| format!(": `{}`", mp)).unwrap_or_default();
struct_span_err!(