Trim whitespace in RemoveLet primary span
Separate `RemoveLet` span into primary span for `let` and removal suggestion span for `let `, so that primary span does not include whitespace. Fixes: #133031 Signed-off-by: Tyrone Wu <wudevelops@gmail.com>
This commit is contained in:
parent
c82e0dff84
commit
dd557c988f
5 changed files with 31 additions and 15 deletions
|
@ -650,8 +650,9 @@ pub(crate) struct LeftArrowOperator {
|
|||
#[diag(parse_remove_let)]
|
||||
pub(crate) struct RemoveLet {
|
||||
#[primary_span]
|
||||
#[suggestion(applicability = "machine-applicable", code = "", style = "verbose")]
|
||||
pub span: Span,
|
||||
#[suggestion(applicability = "machine-applicable", code = "", style = "verbose")]
|
||||
pub suggestion: Span,
|
||||
}
|
||||
|
||||
#[derive(Diagnostic)]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue