Auto merge of #103761 - chenyukang:yukang/fix-103320-must-use, r=compiler-errors
Add explanatory message for [#must_use] in ops Fixes #103320
This commit is contained in:
commit
044a28a409
7 changed files with 142 additions and 9 deletions
|
@ -33,7 +33,7 @@ borrowck_var_here_defined = variable defined here
|
|||
|
||||
borrowck_var_here_captured = variable captured here
|
||||
|
||||
borrowck_closure_inferred_mut = inferred to be a `FnMut` closure
|
||||
borrowck_closure_inferred_mut = inferred to be a `FnMut` closure
|
||||
|
||||
borrowck_returned_closure_escaped =
|
||||
returns a closure that contains a reference to a captured variable, which then escapes the closure body
|
||||
|
|
|
@ -309,6 +309,7 @@ lint_unused_generator =
|
|||
.note = generators are lazy and do nothing unless resumed
|
||||
|
||||
lint_unused_def = unused {$pre}`{$def}`{$post} that must be used
|
||||
.suggestion = use `let _ = ...` to ignore the resulting value
|
||||
|
||||
lint_path_statement_drop = path statement drops value
|
||||
.suggestion = use `drop` to clarify the intent
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue