add suggest for PatternsInWithoutBody
This commit is contained in:
parent
463ce40428
commit
acbebd81d4
3 changed files with 21 additions and 8 deletions
|
@ -596,6 +596,9 @@ pub trait LintContext: Sized {
|
|||
db.help("to document an item produced by a macro, \
|
||||
the macro must produce the documentation as part of its expansion");
|
||||
}
|
||||
BuiltinLintDiagnostics::PatternsInFnsWithoutBody(span, ident) => {
|
||||
db.span_suggestion(span, "remove `mut` from the parameter", ident.to_string(), Applicability::MachineApplicable);
|
||||
}
|
||||
}
|
||||
// Rewrap `db`, and pass control to the user.
|
||||
decorate(LintDiagnosticBuilder::new(db));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue