Remove box_syntax from AST and use in tools

This commit is contained in:
clubby789 2023-02-27 13:17:29 +00:00
parent dd7df04e16
commit 0932452fa4
28 changed files with 40 additions and 95 deletions

View file

@ -2300,3 +2300,16 @@ impl HelpUseLatestEdition {
}
}
}
#[derive(Diagnostic)]
#[diag(parse_box_syntax_removed)]
pub struct BoxSyntaxRemoved<'a> {
#[primary_span]
#[suggestion(
code = "Box::new({code})",
applicability = "machine-applicable",
style = "verbose"
)]
pub span: Span,
pub code: &'a str,
}