Reword suggestion messages.

This commit is contained in:
Aaron Kofsky 2022-06-11 10:19:53 -04:00
parent cdf6606066
commit 7237e8635d
3 changed files with 6 additions and 6 deletions

View file

@ -150,12 +150,12 @@ fn build_and_emit_lint(
lint.build(msg)
.span_suggestion_verbose(
local.pat.span,
"consider binding to an unused variable",
"consider binding to an unused variable to avoid immediately dropping the value",
"_unused",
Applicability::MachineApplicable,
)
.multipart_suggestion(
"consider explicitly droping with `std::mem::drop`",
"consider immediately dropping the value",
vec![
(init_span.shrink_to_lo(), "drop(".to_string()),
(init_span.shrink_to_hi(), ")".to_string()),