Suggest removing unnecessary prefix let in patterns
This commit is contained in:
parent
8c6ce6b91b
commit
91674cc56c
6 changed files with 74 additions and 1 deletions
|
@ -705,6 +705,14 @@ pub(crate) struct LeftArrowOperator {
|
|||
pub span: Span,
|
||||
}
|
||||
|
||||
#[derive(SessionDiagnostic)]
|
||||
#[diag(parser::remove_let)]
|
||||
pub(crate) struct RemoveLet {
|
||||
#[primary_span]
|
||||
#[suggestion(applicability = "machine-applicable", code = "")]
|
||||
pub span: Span,
|
||||
}
|
||||
|
||||
// SnapshotParser is used to create a snapshot of the parser
|
||||
// without causing duplicate errors being emitted when the `Parser`
|
||||
// is dropped.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue