Migrate all diagnostics

This commit is contained in:
Nilstrieb 2022-10-22 11:07:54 +02:00
parent 2459569776
commit c65ebae221
No known key found for this signature in database
58 changed files with 1279 additions and 1318 deletions

View file

@ -3,28 +3,28 @@ use rustc_span::symbol::MacroRulesNormalizedIdent;
use rustc_span::Span;
#[derive(Diagnostic)]
#[diag(expand::expr_repeat_no_syntax_vars)]
#[diag(expand_expr_repeat_no_syntax_vars)]
pub(crate) struct NoSyntaxVarsExprRepeat {
#[primary_span]
pub span: Span,
}
#[derive(Diagnostic)]
#[diag(expand::must_repeat_once)]
#[diag(expand_must_repeat_once)]
pub(crate) struct MustRepeatOnce {
#[primary_span]
pub span: Span,
}
#[derive(Diagnostic)]
#[diag(expand::count_repetition_misplaced)]
#[diag(expand_count_repetition_misplaced)]
pub(crate) struct CountRepetitionMisplaced {
#[primary_span]
pub span: Span,
}
#[derive(Diagnostic)]
#[diag(expand::meta_var_expr_unrecognized_var)]
#[diag(expand_meta_var_expr_unrecognized_var)]
pub(crate) struct MetaVarExprUnrecognizedVar {
#[primary_span]
pub span: Span,
@ -32,7 +32,7 @@ pub(crate) struct MetaVarExprUnrecognizedVar {
}
#[derive(Diagnostic)]
#[diag(expand::var_still_repeating)]
#[diag(expand_var_still_repeating)]
pub(crate) struct VarStillRepeating {
#[primary_span]
pub span: Span,
@ -40,7 +40,7 @@ pub(crate) struct VarStillRepeating {
}
#[derive(Diagnostic)]
#[diag(expand::meta_var_dif_seq_matchers)]
#[diag(expand_meta_var_dif_seq_matchers)]
pub(crate) struct MetaVarsDifSeqMatchers {
#[primary_span]
pub span: Span,

View file

@ -598,12 +598,12 @@ pub fn compile_declarative_macro(
#[derive(Subdiagnostic)]
enum ExplainDocComment {
#[label(expand::explain_doc_comment_inner)]
#[label(expand_explain_doc_comment_inner)]
Inner {
#[primary_span]
span: Span,
},
#[label(expand::explain_doc_comment_outer)]
#[label(expand_explain_doc_comment_outer)]
Outer {
#[primary_span]
span: Span,