1
Fork 0

Suggest removing unnecessary prefix let in patterns

This commit is contained in:
Michael Goulet 2022-09-03 05:39:46 +00:00
parent 8c6ce6b91b
commit 91674cc56c
6 changed files with 74 additions and 1 deletions

View file

@ -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.