Skip to main content

rustc_builtin_macros/
errors.rs

1use rustc_errors::codes::*;
2use rustc_errors::{
3    Diag, DiagCtxtHandle, Diagnostic, EmissionGuarantee, Level, MultiSpan, SingleLabelManySpans,
4    Subdiagnostic,
5};
6use rustc_macros::{Diagnostic, LintDiagnostic, Subdiagnostic};
7use rustc_span::{Ident, Span, Symbol};
8
9#[derive(const _: () =
    {
        impl<'__a> rustc_errors::LintDiagnostic<'__a, ()> for AvoidIntelSyntax
            {
            #[track_caller]
            fn decorate_lint<'__b>(self,
                diag: &'__b mut rustc_errors::Diag<'__a, ()>) {
                match self {
                    AvoidIntelSyntax => {
                        diag.primary_message(crate::fluent_generated::builtin_macros_avoid_intel_syntax);
                        ;
                        diag
                    }
                };
            }
        }
    };LintDiagnostic)]
10#[diag(builtin_macros_avoid_intel_syntax)]
11pub(crate) struct AvoidIntelSyntax;
12
13#[derive(const _: () =
    {
        impl<'__a> rustc_errors::LintDiagnostic<'__a, ()> for AvoidAttSyntax {
            #[track_caller]
            fn decorate_lint<'__b>(self,
                diag: &'__b mut rustc_errors::Diag<'__a, ()>) {
                match self {
                    AvoidAttSyntax => {
                        diag.primary_message(crate::fluent_generated::builtin_macros_avoid_att_syntax);
                        ;
                        diag
                    }
                };
            }
        }
    };LintDiagnostic)]
14#[diag(builtin_macros_avoid_att_syntax)]
15pub(crate) struct AvoidAttSyntax;
16
17#[derive(const _: () =
    {
        impl<'__a> rustc_errors::LintDiagnostic<'__a, ()> for
            IncompleteInclude {
            #[track_caller]
            fn decorate_lint<'__b>(self,
                diag: &'__b mut rustc_errors::Diag<'__a, ()>) {
                match self {
                    IncompleteInclude => {
                        diag.primary_message(crate::fluent_generated::builtin_macros_incomplete_include);
                        ;
                        diag
                    }
                };
            }
        }
    };LintDiagnostic)]
18#[diag(builtin_macros_incomplete_include)]
19pub(crate) struct IncompleteInclude;
20
21#[derive(const _: () =
    {
        impl<'__a> rustc_errors::LintDiagnostic<'__a, ()> for
            UnnameableTestItems {
            #[track_caller]
            fn decorate_lint<'__b>(self,
                diag: &'__b mut rustc_errors::Diag<'__a, ()>) {
                match self {
                    UnnameableTestItems => {
                        diag.primary_message(crate::fluent_generated::builtin_macros_unnameable_test_items);
                        ;
                        diag
                    }
                };
            }
        }
    };LintDiagnostic)]
22#[diag(builtin_macros_unnameable_test_items)]
23pub(crate) struct UnnameableTestItems;
24
25#[derive(const _: () =
    {
        impl<'__a> rustc_errors::LintDiagnostic<'__a, ()> for
            DuplicateMacroAttribute {
            #[track_caller]
            fn decorate_lint<'__b>(self,
                diag: &'__b mut rustc_errors::Diag<'__a, ()>) {
                match self {
                    DuplicateMacroAttribute => {
                        diag.primary_message(crate::fluent_generated::builtin_macros_duplicate_macro_attribute);
                        ;
                        diag
                    }
                };
            }
        }
    };LintDiagnostic)]
26#[diag(builtin_macros_duplicate_macro_attribute)]
27pub(crate) struct DuplicateMacroAttribute;
28
29#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            RequiresCfgPattern where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    RequiresCfgPattern { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_requires_cfg_pattern);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::_subdiag::label);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
30#[diag(builtin_macros_requires_cfg_pattern)]
31pub(crate) struct RequiresCfgPattern {
32    #[primary_span]
33    #[label]
34    pub(crate) span: Span,
35}
36
37#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for OneCfgPattern
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    OneCfgPattern { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_expected_one_cfg_pattern);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
38#[diag(builtin_macros_expected_one_cfg_pattern)]
39pub(crate) struct OneCfgPattern {
40    #[primary_span]
41    pub(crate) span: Span,
42}
43
44#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AllocErrorMustBeFn where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AllocErrorMustBeFn { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_alloc_error_must_be_fn);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
45#[diag(builtin_macros_alloc_error_must_be_fn)]
46pub(crate) struct AllocErrorMustBeFn {
47    #[primary_span]
48    pub(crate) span: Span,
49}
50
51#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AssertRequiresBoolean where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AssertRequiresBoolean { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_assert_requires_boolean);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::_subdiag::label);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
52#[diag(builtin_macros_assert_requires_boolean)]
53pub(crate) struct AssertRequiresBoolean {
54    #[primary_span]
55    #[label]
56    pub(crate) span: Span,
57}
58
59#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AssertRequiresExpression where G: rustc_errors::EmissionGuarantee
            {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AssertRequiresExpression {
                        span: __binding_0, token: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_assert_requires_expression);
                        let __code_0 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!(""))
                                            })].into_iter();
                        ;
                        diag.span(__binding_0);
                        diag.span_suggestions_with_style(__binding_1,
                            crate::fluent_generated::_subdiag::suggestion, __code_0,
                            rustc_errors::Applicability::MaybeIncorrect,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
60#[diag(builtin_macros_assert_requires_expression)]
61pub(crate) struct AssertRequiresExpression {
62    #[primary_span]
63    pub(crate) span: Span,
64    #[suggestion(code = "", applicability = "maybe-incorrect")]
65    pub(crate) token: Span,
66}
67
68#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AssertMissingComma where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AssertMissingComma { span: __binding_0, comma: __binding_1 }
                        => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_assert_missing_comma);
                        let __code_1 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!(", "))
                                            })].into_iter();
                        ;
                        diag.span(__binding_0);
                        diag.span_suggestions_with_style(__binding_1,
                            crate::fluent_generated::_subdiag::suggestion, __code_1,
                            rustc_errors::Applicability::MaybeIncorrect,
                            rustc_errors::SuggestionStyle::HideCodeInline);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
69#[diag(builtin_macros_assert_missing_comma)]
70pub(crate) struct AssertMissingComma {
71    #[primary_span]
72    pub(crate) span: Span,
73    #[suggestion(code = ", ", applicability = "maybe-incorrect", style = "short")]
74    pub(crate) comma: Span,
75}
76
77#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            CfgAccessibleInvalid where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    CfgAccessibleInvalid::UnspecifiedPath(__binding_0) => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_cfg_accessible_unspecified_path);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                    CfgAccessibleInvalid::MultiplePaths(__binding_0) => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_cfg_accessible_multiple_paths);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                    CfgAccessibleInvalid::LiteralPath(__binding_0) => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_cfg_accessible_literal_path);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                    CfgAccessibleInvalid::HasArguments(__binding_0) => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_cfg_accessible_has_args);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
78pub(crate) enum CfgAccessibleInvalid {
79    #[diag(builtin_macros_cfg_accessible_unspecified_path)]
80    UnspecifiedPath(#[primary_span] Span),
81    #[diag(builtin_macros_cfg_accessible_multiple_paths)]
82    MultiplePaths(#[primary_span] Span),
83    #[diag(builtin_macros_cfg_accessible_literal_path)]
84    LiteralPath(#[primary_span] Span),
85    #[diag(builtin_macros_cfg_accessible_has_args)]
86    HasArguments(#[primary_span] Span),
87}
88
89#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            CfgAccessibleIndeterminate where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    CfgAccessibleIndeterminate { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_cfg_accessible_indeterminate);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
90#[diag(builtin_macros_cfg_accessible_indeterminate)]
91pub(crate) struct CfgAccessibleIndeterminate {
92    #[primary_span]
93    pub(crate) span: Span,
94}
95
96#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            ConcatMissingLiteral where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ConcatMissingLiteral { spans: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_concat_missing_literal);
                        diag.note(crate::fluent_generated::_subdiag::note);
                        ;
                        diag.span(__binding_0.clone());
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
97#[diag(builtin_macros_concat_missing_literal)]
98#[note]
99pub(crate) struct ConcatMissingLiteral {
100    #[primary_span]
101    pub(crate) spans: Vec<Span>,
102}
103
104#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for ConcatBytestr
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ConcatBytestr { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_concat_bytestr);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
105#[diag(builtin_macros_concat_bytestr)]
106pub(crate) struct ConcatBytestr {
107    #[primary_span]
108    pub(crate) span: Span,
109}
110
111#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for ConcatCStrLit
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ConcatCStrLit { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_concat_c_str_lit);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
112#[diag(builtin_macros_concat_c_str_lit)]
113pub(crate) struct ConcatCStrLit {
114    #[primary_span]
115    pub(crate) span: Span,
116}
117
118#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            ExportMacroRules where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ExportMacroRules { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_export_macro_rules);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
119#[diag(builtin_macros_export_macro_rules)]
120pub(crate) struct ExportMacroRules {
121    #[primary_span]
122    pub(crate) span: Span,
123}
124
125#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for ProcMacro
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ProcMacro { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_proc_macro);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
126#[diag(builtin_macros_proc_macro)]
127pub(crate) struct ProcMacro {
128    #[primary_span]
129    pub(crate) span: Span,
130}
131
132#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for TraceMacros
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    TraceMacros { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_trace_macros);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
133#[diag(builtin_macros_trace_macros)]
134pub(crate) struct TraceMacros {
135    #[primary_span]
136    pub(crate) span: Span,
137}
138
139#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for BenchSig where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    BenchSig { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_bench_sig);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
140#[diag(builtin_macros_bench_sig)]
141pub(crate) struct BenchSig {
142    #[primary_span]
143    pub(crate) span: Span,
144}
145
146#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AllocMustStatics where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AllocMustStatics { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_alloc_must_statics);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
147#[diag(builtin_macros_alloc_must_statics)]
148pub(crate) struct AllocMustStatics {
149    #[primary_span]
150    pub(crate) span: Span,
151}
152
153pub(crate) use autodiff::*;
154
155mod autodiff {
156    use super::*;
157    #[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AutoDiffMissingConfig where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AutoDiffMissingConfig { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_autodiff_missing_config);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
158    #[diag(builtin_macros_autodiff_missing_config)]
159    pub(crate) struct AutoDiffMissingConfig {
160        #[primary_span]
161        pub(crate) span: Span,
162    }
163    #[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AutoDiffUnknownActivity where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AutoDiffUnknownActivity {
                        span: __binding_0, act: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_autodiff_unknown_activity);
                        ;
                        diag.arg("act", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
164    #[diag(builtin_macros_autodiff_unknown_activity)]
165    pub(crate) struct AutoDiffUnknownActivity {
166        #[primary_span]
167        pub(crate) span: Span,
168        pub(crate) act: String,
169    }
170    #[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AutoDiffInvalidTypeForActivity where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AutoDiffInvalidTypeForActivity {
                        span: __binding_0, act: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_autodiff_ty_activity);
                        ;
                        diag.arg("act", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
171    #[diag(builtin_macros_autodiff_ty_activity)]
172    pub(crate) struct AutoDiffInvalidTypeForActivity {
173        #[primary_span]
174        pub(crate) span: Span,
175        pub(crate) act: String,
176    }
177    #[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AutoDiffInvalidNumberActivities where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AutoDiffInvalidNumberActivities {
                        span: __binding_0, expected: __binding_1, found: __binding_2
                        } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_autodiff_number_activities);
                        ;
                        diag.arg("expected", __binding_1);
                        diag.arg("found", __binding_2);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
178    #[diag(builtin_macros_autodiff_number_activities)]
179    pub(crate) struct AutoDiffInvalidNumberActivities {
180        #[primary_span]
181        pub(crate) span: Span,
182        pub(crate) expected: usize,
183        pub(crate) found: usize,
184    }
185    #[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AutoDiffInvalidApplicationModeAct where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AutoDiffInvalidApplicationModeAct {
                        span: __binding_0, mode: __binding_1, act: __binding_2 } =>
                        {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_autodiff_mode_activity);
                        ;
                        diag.arg("mode", __binding_1);
                        diag.arg("act", __binding_2);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
186    #[diag(builtin_macros_autodiff_mode_activity)]
187    pub(crate) struct AutoDiffInvalidApplicationModeAct {
188        #[primary_span]
189        pub(crate) span: Span,
190        pub(crate) mode: String,
191        pub(crate) act: String,
192    }
193
194    #[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AutoDiffInvalidRetAct where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AutoDiffInvalidRetAct {
                        span: __binding_0, mode: __binding_1, act: __binding_2 } =>
                        {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_autodiff_ret_activity);
                        ;
                        diag.arg("mode", __binding_1);
                        diag.arg("act", __binding_2);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
195    #[diag(builtin_macros_autodiff_ret_activity)]
196    pub(crate) struct AutoDiffInvalidRetAct {
197        #[primary_span]
198        pub(crate) span: Span,
199        pub(crate) mode: String,
200        pub(crate) act: String,
201    }
202
203    #[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AutoDiffInvalidWidth where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AutoDiffInvalidWidth { span: __binding_0, width: __binding_1
                        } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_autodiff_width);
                        ;
                        diag.arg("width", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
204    #[diag(builtin_macros_autodiff_width)]
205    pub(crate) struct AutoDiffInvalidWidth {
206        #[primary_span]
207        pub(crate) span: Span,
208        pub(crate) width: u128,
209    }
210
211    #[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AutoDiffInvalidApplication where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AutoDiffInvalidApplication { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_autodiff);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
212    #[diag(builtin_macros_autodiff)]
213    pub(crate) struct AutoDiffInvalidApplication {
214        #[primary_span]
215        pub(crate) span: Span,
216    }
217}
218
219#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            ConcatBytesInvalid where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ConcatBytesInvalid {
                        span: __binding_0,
                        lit_kind: __binding_1,
                        sugg: __binding_2,
                        cs_note: __binding_3 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_concat_bytes_invalid);
                        ;
                        diag.arg("lit_kind", __binding_1);
                        diag.span(__binding_0);
                        if let Some(__binding_2) = __binding_2 {
                            diag.subdiagnostic(__binding_2);
                        }
                        if let Some(__binding_3) = __binding_3 {
                            diag.note(crate::fluent_generated::builtin_macros_c_str_note);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
220#[diag(builtin_macros_concat_bytes_invalid)]
221pub(crate) struct ConcatBytesInvalid {
222    #[primary_span]
223    pub(crate) span: Span,
224    pub(crate) lit_kind: &'static str,
225    #[subdiagnostic]
226    pub(crate) sugg: Option<ConcatBytesInvalidSuggestion>,
227    #[note(builtin_macros_c_str_note)]
228    pub(crate) cs_note: Option<()>,
229}
230
231#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for ConcatBytesInvalidSuggestion {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    ConcatBytesInvalidSuggestion::CharLit {
                        span: __binding_0, snippet: __binding_1 } => {
                        let __code_2 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!("b{0}", __binding_1))
                                            })].into_iter();
                        diag.store_args();
                        diag.arg("snippet", __binding_1);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_byte_char);
                        diag.span_suggestions_with_style(__binding_0, __message,
                            __code_2, rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.restore_args();
                    }
                    ConcatBytesInvalidSuggestion::StrLit {
                        span: __binding_0, snippet: __binding_1 } => {
                        let __code_3 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!("b{0}", __binding_1))
                                            })].into_iter();
                        diag.store_args();
                        diag.arg("snippet", __binding_1);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_byte_str);
                        diag.span_suggestions_with_style(__binding_0, __message,
                            __code_3, rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.restore_args();
                    }
                    ConcatBytesInvalidSuggestion::CStrLit {
                        span: __binding_0, as_bstr: __binding_1 } => {
                        let __code_4 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!("{0}", __binding_1))
                                            })].into_iter();
                        diag.store_args();
                        diag.arg("as_bstr", __binding_1);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_c_str_note);
                        diag.span_note(__binding_0, __message);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_c_str);
                        diag.span_suggestions_with_style(__binding_0, __message,
                            __code_4, rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.restore_args();
                    }
                    ConcatBytesInvalidSuggestion::IntLit {
                        span: __binding_0, snippet: __binding_1 } => {
                        let __code_5 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!("[{0}]", __binding_1))
                                            })].into_iter();
                        diag.store_args();
                        diag.arg("snippet", __binding_1);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_number_array);
                        diag.span_suggestions_with_style(__binding_0, __message,
                            __code_5, rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
232pub(crate) enum ConcatBytesInvalidSuggestion {
233    #[suggestion(
234        builtin_macros_byte_char,
235        code = "b{snippet}",
236        applicability = "machine-applicable"
237    )]
238    CharLit {
239        #[primary_span]
240        span: Span,
241        snippet: String,
242    },
243    #[suggestion(
244        builtin_macros_byte_str,
245        code = "b{snippet}",
246        applicability = "machine-applicable"
247    )]
248    StrLit {
249        #[primary_span]
250        span: Span,
251        snippet: String,
252    },
253    #[note(builtin_macros_c_str_note)]
254    #[suggestion(builtin_macros_c_str, code = "{as_bstr}", applicability = "machine-applicable")]
255    CStrLit {
256        #[primary_span]
257        span: Span,
258        as_bstr: String,
259    },
260    #[suggestion(
261        builtin_macros_number_array,
262        code = "[{snippet}]",
263        applicability = "machine-applicable"
264    )]
265    IntLit {
266        #[primary_span]
267        span: Span,
268        snippet: String,
269    },
270}
271
272#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for ConcatBytesOob
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ConcatBytesOob { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_concat_bytes_oob);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
273#[diag(builtin_macros_concat_bytes_oob)]
274pub(crate) struct ConcatBytesOob {
275    #[primary_span]
276    pub(crate) span: Span,
277}
278
279#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            ConcatBytesNonU8 where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ConcatBytesNonU8 { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_concat_bytes_non_u8);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
280#[diag(builtin_macros_concat_bytes_non_u8)]
281pub(crate) struct ConcatBytesNonU8 {
282    #[primary_span]
283    pub(crate) span: Span,
284}
285
286#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            ConcatBytesMissingLiteral where G: rustc_errors::EmissionGuarantee
            {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ConcatBytesMissingLiteral { spans: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_concat_bytes_missing_literal);
                        diag.note(crate::fluent_generated::_subdiag::note);
                        ;
                        diag.span(__binding_0.clone());
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
287#[diag(builtin_macros_concat_bytes_missing_literal)]
288#[note]
289pub(crate) struct ConcatBytesMissingLiteral {
290    #[primary_span]
291    pub(crate) spans: Vec<Span>,
292}
293
294#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            ConcatBytesArray where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ConcatBytesArray { span: __binding_0, bytestr: __binding_1 }
                        => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_concat_bytes_array);
                        ;
                        diag.span(__binding_0);
                        if __binding_1 {
                            diag.note(crate::fluent_generated::_subdiag::note);
                        }
                        if __binding_1 {
                            diag.help(crate::fluent_generated::_subdiag::help);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
295#[diag(builtin_macros_concat_bytes_array)]
296pub(crate) struct ConcatBytesArray {
297    #[primary_span]
298    pub(crate) span: Span,
299    #[note]
300    #[help]
301    pub(crate) bytestr: bool,
302}
303
304#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            ConcatBytesBadRepeat where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ConcatBytesBadRepeat { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_concat_bytes_bad_repeat);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
305#[diag(builtin_macros_concat_bytes_bad_repeat)]
306pub(crate) struct ConcatBytesBadRepeat {
307    #[primary_span]
308    pub(crate) span: Span,
309}
310
311#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            BadDeriveTarget where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    BadDeriveTarget { span: __binding_0, item: __binding_1 } =>
                        {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_bad_derive_target);
                        diag.code(E0774);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::_subdiag::label);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::builtin_macros_label2);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
312#[diag(builtin_macros_bad_derive_target, code = E0774)]
313pub(crate) struct BadDeriveTarget {
314    #[primary_span]
315    #[label]
316    pub(crate) span: Span,
317    #[label(builtin_macros_label2)]
318    pub(crate) item: Span,
319}
320
321#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            TestsNotSupport where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    TestsNotSupport {} => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_tests_not_support);
                        ;
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
322#[diag(builtin_macros_tests_not_support)]
323pub(crate) struct TestsNotSupport {}
324
325#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for BadDeriveLit
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    BadDeriveLit { span: __binding_0, help: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_unexpected_lit);
                        diag.code(E0777);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::_subdiag::label);
                        diag.subdiagnostic(__binding_1);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
326#[diag(builtin_macros_unexpected_lit, code = E0777)]
327pub(crate) struct BadDeriveLit {
328    #[primary_span]
329    #[label]
330    pub(crate) span: Span,
331    #[subdiagnostic]
332    pub help: BadDeriveLitHelp,
333}
334
335#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for BadDeriveLitHelp {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    BadDeriveLitHelp::StrLit { sym: __binding_0 } => {
                        diag.store_args();
                        diag.arg("sym", __binding_0);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_str_lit);
                        diag.help(__message);
                        diag.restore_args();
                    }
                    BadDeriveLitHelp::Other => {
                        diag.store_args();
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_other);
                        diag.help(__message);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
336pub(crate) enum BadDeriveLitHelp {
337    #[help(builtin_macros_str_lit)]
338    StrLit { sym: Symbol },
339    #[help(builtin_macros_other)]
340    Other,
341}
342
343#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            DerivePathArgsList where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    DerivePathArgsList { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_derive_path_args_list);
                        let __code_6 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!(""))
                                            })].into_iter();
                        ;
                        diag.span_suggestions_with_style(__binding_0,
                            crate::fluent_generated::_subdiag::suggestion, __code_6,
                            rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
344#[diag(builtin_macros_derive_path_args_list)]
345pub(crate) struct DerivePathArgsList {
346    #[suggestion(code = "", applicability = "machine-applicable")]
347    #[primary_span]
348    pub(crate) span: Span,
349}
350
351#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            DerivePathArgsValue where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    DerivePathArgsValue { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_derive_path_args_value);
                        let __code_7 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!(""))
                                            })].into_iter();
                        ;
                        diag.span_suggestions_with_style(__binding_0,
                            crate::fluent_generated::_subdiag::suggestion, __code_7,
                            rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
352#[diag(builtin_macros_derive_path_args_value)]
353pub(crate) struct DerivePathArgsValue {
354    #[suggestion(code = "", applicability = "machine-applicable")]
355    #[primary_span]
356    pub(crate) span: Span,
357}
358
359#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            NoDefaultVariant where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    NoDefaultVariant {
                        span: __binding_0,
                        item_span: __binding_1,
                        suggs: __binding_2 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_no_default_variant);
                        diag.code(E0665);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::_subdiag::label);
                        for __binding_2 in __binding_2 {
                            diag.subdiagnostic(__binding_2);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
360#[diag(builtin_macros_no_default_variant, code = E0665)]
361pub(crate) struct NoDefaultVariant {
362    #[primary_span]
363    pub(crate) span: Span,
364    #[label]
365    pub(crate) item_span: Span,
366    #[subdiagnostic]
367    pub(crate) suggs: Vec<NoDefaultVariantSugg>,
368}
369
370#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for NoDefaultVariantSugg {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    NoDefaultVariantSugg { span: __binding_0 } => {
                        let __code_8 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!("#[default] "))
                                            })].into_iter();
                        diag.store_args();
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_suggestion);
                        diag.span_suggestions_with_style(__binding_0, __message,
                            __code_8, rustc_errors::Applicability::MaybeIncorrect,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
371#[suggestion(builtin_macros_suggestion, code = "#[default] ", applicability = "maybe-incorrect")]
372pub(crate) struct NoDefaultVariantSugg {
373    #[primary_span]
374    pub(crate) span: Span,
375}
376
377#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            MultipleDefaults where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    MultipleDefaults {
                        span: __binding_0,
                        first: __binding_1,
                        additional: __binding_2,
                        suggs: __binding_3 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_multiple_defaults);
                        diag.note(crate::fluent_generated::_subdiag::note);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::_subdiag::label);
                        for __binding_2 in __binding_2 {
                            diag.span_label(__binding_2,
                                crate::fluent_generated::builtin_macros_additional);
                        }
                        for __binding_3 in __binding_3 {
                            diag.subdiagnostic(__binding_3);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
378#[diag(builtin_macros_multiple_defaults)]
379#[note]
380pub(crate) struct MultipleDefaults {
381    #[primary_span]
382    pub(crate) span: Span,
383    #[label]
384    pub(crate) first: Span,
385    #[label(builtin_macros_additional)]
386    pub additional: Vec<Span>,
387    #[subdiagnostic]
388    pub suggs: Vec<MultipleDefaultsSugg>,
389}
390
391#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for MultipleDefaultsSugg {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    MultipleDefaultsSugg {
                        spans: __binding_0, ident: __binding_1 } => {
                        let mut suggestions = Vec::new();
                        let __code_9 =
                            ::alloc::__export::must_use({
                                    ::alloc::fmt::format(format_args!(""))
                                });
                        for __binding_0 in __binding_0 {
                            suggestions.push((__binding_0, __code_9.clone()));
                        }
                        diag.store_args();
                        diag.arg("ident", __binding_1);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_suggestion);
                        diag.multipart_suggestion_with_style(__message, suggestions,
                            rustc_errors::Applicability::MaybeIncorrect,
                            rustc_errors::SuggestionStyle::CompletelyHidden);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
392#[multipart_suggestion(
393    builtin_macros_suggestion,
394    applicability = "maybe-incorrect",
395    style = "tool-only"
396)]
397pub(crate) struct MultipleDefaultsSugg {
398    #[suggestion_part(code = "")]
399    pub(crate) spans: Vec<Span>,
400    pub(crate) ident: Ident,
401}
402
403#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for NonUnitDefault
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    NonUnitDefault { span: __binding_0, post: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_non_unit_default);
                        diag.help(crate::fluent_generated::_subdiag::help);
                        ;
                        diag.arg("post", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
404#[diag(builtin_macros_non_unit_default)]
405#[help]
406pub(crate) struct NonUnitDefault {
407    #[primary_span]
408    pub(crate) span: Span,
409    pub(crate) post: &'static str,
410}
411
412#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            NonExhaustiveDefault where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    NonExhaustiveDefault {
                        span: __binding_0, non_exhaustive: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_non_exhaustive_default);
                        diag.help(crate::fluent_generated::_subdiag::help);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::_subdiag::label);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
413#[diag(builtin_macros_non_exhaustive_default)]
414#[help]
415pub(crate) struct NonExhaustiveDefault {
416    #[primary_span]
417    pub(crate) span: Span,
418    #[label]
419    pub(crate) non_exhaustive: Span,
420}
421
422#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            MultipleDefaultAttrs where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    MultipleDefaultAttrs {
                        span: __binding_0,
                        first: __binding_1,
                        first_rest: __binding_2,
                        rest: __binding_3,
                        only_one: __binding_4,
                        sugg: __binding_5 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_multiple_default_attrs);
                        diag.note(crate::fluent_generated::_subdiag::note);
                        ;
                        diag.arg("only_one", __binding_4);
                        diag.span(__binding_0);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::_subdiag::label);
                        diag.span_label(__binding_2,
                            crate::fluent_generated::builtin_macros_label_again);
                        diag.span_help(__binding_3,
                            crate::fluent_generated::_subdiag::help);
                        diag.subdiagnostic(__binding_5);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
423#[diag(builtin_macros_multiple_default_attrs)]
424#[note]
425pub(crate) struct MultipleDefaultAttrs {
426    #[primary_span]
427    pub(crate) span: Span,
428    #[label]
429    pub(crate) first: Span,
430    #[label(builtin_macros_label_again)]
431    pub(crate) first_rest: Span,
432    #[help]
433    pub(crate) rest: MultiSpan,
434    pub(crate) only_one: bool,
435    #[subdiagnostic]
436    pub(crate) sugg: MultipleDefaultAttrsSugg,
437}
438
439#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for MultipleDefaultAttrsSugg {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    MultipleDefaultAttrsSugg { spans: __binding_0 } => {
                        let mut suggestions = Vec::new();
                        let __code_10 =
                            ::alloc::__export::must_use({
                                    ::alloc::fmt::format(format_args!(""))
                                });
                        for __binding_0 in __binding_0 {
                            suggestions.push((__binding_0, __code_10.clone()));
                        }
                        diag.store_args();
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_help);
                        diag.multipart_suggestion_with_style(__message, suggestions,
                            rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::CompletelyHidden);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
440#[multipart_suggestion(
441    builtin_macros_help,
442    applicability = "machine-applicable",
443    style = "tool-only"
444)]
445pub(crate) struct MultipleDefaultAttrsSugg {
446    #[suggestion_part(code = "")]
447    pub(crate) spans: Vec<Span>,
448}
449
450#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for DefaultHasArg
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    DefaultHasArg { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_default_arg);
                        let __code_11 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!("#[default]"))
                                            })].into_iter();
                        ;
                        diag.span(__binding_0);
                        diag.span_suggestions_with_style(__binding_0,
                            crate::fluent_generated::_subdiag::suggestion, __code_11,
                            rustc_errors::Applicability::MaybeIncorrect,
                            rustc_errors::SuggestionStyle::HideCodeAlways);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
451#[diag(builtin_macros_default_arg)]
452pub(crate) struct DefaultHasArg {
453    #[primary_span]
454    #[suggestion(code = "#[default]", style = "hidden", applicability = "maybe-incorrect")]
455    pub(crate) span: Span,
456}
457
458#[derive(const _: () =
    {
        impl<'_sess, 'a, G> rustc_errors::Diagnostic<'_sess, G> for
            DeriveFromWrongTarget<'a> where G: rustc_errors::EmissionGuarantee
            {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    DeriveFromWrongTarget { span: __binding_0, kind: __binding_1
                        } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_derive_from_wrong_target);
                        diag.note(crate::fluent_generated::builtin_macros_derive_from_usage_note);
                        ;
                        diag.arg("kind", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
459#[diag(builtin_macros_derive_from_wrong_target)]
460#[note(builtin_macros_derive_from_usage_note)]
461pub(crate) struct DeriveFromWrongTarget<'a> {
462    #[primary_span]
463    pub(crate) span: MultiSpan,
464    pub(crate) kind: &'a str,
465}
466
467#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            DeriveFromWrongFieldCount where G: rustc_errors::EmissionGuarantee
            {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    DeriveFromWrongFieldCount {
                        span: __binding_0, multiple_fields: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_derive_from_wrong_field_count);
                        diag.note(crate::fluent_generated::builtin_macros_derive_from_usage_note);
                        ;
                        diag.arg("multiple_fields", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
468#[diag(builtin_macros_derive_from_wrong_field_count)]
469#[note(builtin_macros_derive_from_usage_note)]
470pub(crate) struct DeriveFromWrongFieldCount {
471    #[primary_span]
472    pub(crate) span: MultiSpan,
473    pub(crate) multiple_fields: bool,
474}
475
476#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            DeriveMacroCall where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    DeriveMacroCall { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_derive_macro_call);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
477#[diag(builtin_macros_derive_macro_call)]
478pub(crate) struct DeriveMacroCall {
479    #[primary_span]
480    pub(crate) span: Span,
481}
482
483#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for DeriveUnion
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    DeriveUnion { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_cannot_derive_union);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
484#[diag(builtin_macros_cannot_derive_union)]
485pub(crate) struct DeriveUnion {
486    #[primary_span]
487    pub(crate) span: Span,
488}
489
490#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for EnvTakesArgs
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EnvTakesArgs { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_env_takes_args);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
491#[diag(builtin_macros_env_takes_args)]
492pub(crate) struct EnvTakesArgs {
493    #[primary_span]
494    pub(crate) span: Span,
495}
496
497pub(crate) struct EnvNotDefinedWithUserMessage {
498    pub(crate) span: Span,
499    pub(crate) msg_from_user: Symbol,
500}
501
502// Hand-written implementation to support custom user messages.
503impl<'a, G: EmissionGuarantee> Diagnostic<'a, G> for EnvNotDefinedWithUserMessage {
504    #[track_caller]
505    fn into_diag(self, dcx: DiagCtxtHandle<'a>, level: Level) -> Diag<'a, G> {
506        let mut diag = Diag::new(dcx, level, self.msg_from_user.to_string());
507        diag.span(self.span);
508        diag
509    }
510}
511
512#[derive(const _: () =
    {
        impl<'_sess, 'a, G> rustc_errors::Diagnostic<'_sess, G> for
            EnvNotDefined<'a> where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EnvNotDefined::CargoEnvVar {
                        span: __binding_0, var: __binding_1, var_expr: __binding_2 }
                        => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_env_not_defined);
                        diag.help(crate::fluent_generated::builtin_macros_cargo);
                        ;
                        diag.arg("var", __binding_1);
                        diag.arg("var_expr", __binding_2);
                        diag.span(__binding_0);
                        diag
                    }
                    EnvNotDefined::CargoEnvVarTypo {
                        span: __binding_0,
                        var: __binding_1,
                        suggested_var: __binding_2 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_env_not_defined);
                        diag.help(crate::fluent_generated::builtin_macros_cargo_typo);
                        ;
                        diag.arg("var", __binding_1);
                        diag.arg("suggested_var", __binding_2);
                        diag.span(__binding_0);
                        diag
                    }
                    EnvNotDefined::CustomEnvVar {
                        span: __binding_0, var: __binding_1, var_expr: __binding_2 }
                        => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_env_not_defined);
                        diag.help(crate::fluent_generated::builtin_macros_custom);
                        ;
                        diag.arg("var", __binding_1);
                        diag.arg("var_expr", __binding_2);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
513pub(crate) enum EnvNotDefined<'a> {
514    #[diag(builtin_macros_env_not_defined)]
515    #[help(builtin_macros_cargo)]
516    CargoEnvVar {
517        #[primary_span]
518        span: Span,
519        var: Symbol,
520        var_expr: &'a rustc_ast::Expr,
521    },
522    #[diag(builtin_macros_env_not_defined)]
523    #[help(builtin_macros_cargo_typo)]
524    CargoEnvVarTypo {
525        #[primary_span]
526        span: Span,
527        var: Symbol,
528        suggested_var: Symbol,
529    },
530    #[diag(builtin_macros_env_not_defined)]
531    #[help(builtin_macros_custom)]
532    CustomEnvVar {
533        #[primary_span]
534        span: Span,
535        var: Symbol,
536        var_expr: &'a rustc_ast::Expr,
537    },
538}
539
540#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for EnvNotUnicode
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EnvNotUnicode { span: __binding_0, var: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_env_not_unicode);
                        ;
                        diag.arg("var", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
541#[diag(builtin_macros_env_not_unicode)]
542pub(crate) struct EnvNotUnicode {
543    #[primary_span]
544    pub(crate) span: Span,
545    pub(crate) var: Symbol,
546}
547
548#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            FormatRequiresString where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    FormatRequiresString { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_requires_string);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
549#[diag(builtin_macros_format_requires_string)]
550pub(crate) struct FormatRequiresString {
551    #[primary_span]
552    pub(crate) span: Span,
553}
554
555#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            FormatDuplicateArg where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    FormatDuplicateArg {
                        span: __binding_0,
                        prev: __binding_1,
                        duplicate: __binding_2,
                        ident: __binding_3 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_duplicate_arg);
                        ;
                        diag.arg("ident", __binding_3);
                        diag.span(__binding_0);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::builtin_macros_label1);
                        diag.span_label(__binding_2,
                            crate::fluent_generated::builtin_macros_label2);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
556#[diag(builtin_macros_format_duplicate_arg)]
557pub(crate) struct FormatDuplicateArg {
558    #[primary_span]
559    pub(crate) span: Span,
560    #[label(builtin_macros_label1)]
561    pub(crate) prev: Span,
562    #[label(builtin_macros_label2)]
563    pub(crate) duplicate: Span,
564    pub(crate) ident: Ident,
565}
566
567#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            PositionalAfterNamed where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    PositionalAfterNamed { span: __binding_0, args: __binding_1
                        } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_positional_after_named);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::_subdiag::label);
                        for __binding_1 in __binding_1 {
                            diag.span_label(__binding_1,
                                crate::fluent_generated::builtin_macros_named_args);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
568#[diag(builtin_macros_format_positional_after_named)]
569pub(crate) struct PositionalAfterNamed {
570    #[primary_span]
571    #[label]
572    pub(crate) span: Span,
573    #[label(builtin_macros_named_args)]
574    pub(crate) args: Vec<Span>,
575}
576
577#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            InvalidFormatString where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    InvalidFormatString {
                        span: __binding_0,
                        desc: __binding_1,
                        label1: __binding_2,
                        note_: __binding_3,
                        label_: __binding_4,
                        sugg_: __binding_5 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_string_invalid);
                        ;
                        diag.arg("desc", __binding_1);
                        diag.arg("label1", __binding_2);
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::_subdiag::label);
                        if let Some(__binding_3) = __binding_3 {
                            diag.subdiagnostic(__binding_3);
                        }
                        if let Some(__binding_4) = __binding_4 {
                            diag.subdiagnostic(__binding_4);
                        }
                        if let Some(__binding_5) = __binding_5 {
                            diag.subdiagnostic(__binding_5);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
578#[diag(builtin_macros_format_string_invalid)]
579pub(crate) struct InvalidFormatString {
580    #[primary_span]
581    #[label]
582    pub(crate) span: Span,
583    pub(crate) desc: String,
584    pub(crate) label1: String,
585    #[subdiagnostic]
586    pub(crate) note_: Option<InvalidFormatStringNote>,
587    #[subdiagnostic]
588    pub(crate) label_: Option<InvalidFormatStringLabel>,
589    #[subdiagnostic]
590    pub(crate) sugg_: Option<InvalidFormatStringSuggestion>,
591}
592
593#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for InvalidFormatStringNote {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    InvalidFormatStringNote { note: __binding_0 } => {
                        diag.store_args();
                        diag.arg("note", __binding_0);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_note);
                        diag.note(__message);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
594#[note(builtin_macros_note)]
595pub(crate) struct InvalidFormatStringNote {
596    pub(crate) note: String,
597}
598
599#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for InvalidFormatStringLabel {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    InvalidFormatStringLabel {
                        span: __binding_0, label: __binding_1 } => {
                        diag.store_args();
                        diag.arg("label", __binding_1);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_second_label);
                        diag.span_label(__binding_0, __message);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
600#[label(builtin_macros_second_label)]
601pub(crate) struct InvalidFormatStringLabel {
602    #[primary_span]
603    pub(crate) span: Span,
604    pub(crate) label: String,
605}
606
607#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for InvalidFormatStringSuggestion {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    InvalidFormatStringSuggestion::UsePositional {
                        captured: __binding_0,
                        len: __binding_1,
                        span: __binding_2,
                        arg: __binding_3 } => {
                        let mut suggestions = Vec::new();
                        let __code_12 =
                            ::alloc::__export::must_use({
                                    ::alloc::fmt::format(format_args!("{0}", __binding_1))
                                });
                        let __code_13 =
                            ::alloc::__export::must_use({
                                    ::alloc::fmt::format(format_args!(", {0}", __binding_3))
                                });
                        suggestions.push((__binding_0, __code_12));
                        suggestions.push((__binding_2, __code_13));
                        diag.store_args();
                        diag.arg("len", __binding_1);
                        diag.arg("arg", __binding_3);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_format_use_positional);
                        diag.multipart_suggestion_with_style(__message, suggestions,
                            rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowAlways);
                        diag.restore_args();
                    }
                    InvalidFormatStringSuggestion::RemoveRawIdent {
                        span: __binding_0 } => {
                        let __code_14 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!(""))
                                            })].into_iter();
                        diag.store_args();
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_format_remove_raw_ident);
                        diag.span_suggestions_with_style(__binding_0, __message,
                            __code_14, rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.restore_args();
                    }
                    InvalidFormatStringSuggestion::ReorderFormatParameter {
                        span: __binding_0, replacement: __binding_1 } => {
                        let __code_15 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!("{0}", __binding_1))
                                            })].into_iter();
                        diag.store_args();
                        diag.arg("replacement", __binding_1);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_format_reorder_format_parameter);
                        diag.span_suggestions_with_style(__binding_0, __message,
                            __code_15, rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowAlways);
                        diag.restore_args();
                    }
                    InvalidFormatStringSuggestion::AddMissingColon {
                        span: __binding_0 } => {
                        let __code_16 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!(":?"))
                                            })].into_iter();
                        diag.store_args();
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_format_add_missing_colon);
                        diag.span_suggestions_with_style(__binding_0, __message,
                            __code_16, rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
608pub(crate) enum InvalidFormatStringSuggestion {
609    #[multipart_suggestion(
610        builtin_macros_format_use_positional,
611        style = "verbose",
612        applicability = "machine-applicable"
613    )]
614    UsePositional {
615        #[suggestion_part(code = "{len}")]
616        captured: Span,
617        len: String,
618        #[suggestion_part(code = ", {arg}")]
619        span: Span,
620        arg: String,
621    },
622    #[suggestion(
623        builtin_macros_format_remove_raw_ident,
624        code = "",
625        applicability = "machine-applicable"
626    )]
627    RemoveRawIdent {
628        #[primary_span]
629        span: Span,
630    },
631    #[suggestion(
632        builtin_macros_format_reorder_format_parameter,
633        code = "{replacement}",
634        style = "verbose",
635        applicability = "machine-applicable"
636    )]
637    ReorderFormatParameter {
638        #[primary_span]
639        span: Span,
640        replacement: String,
641    },
642    #[suggestion(
643        builtin_macros_format_add_missing_colon,
644        code = ":?",
645        applicability = "machine-applicable"
646    )]
647    AddMissingColon {
648        #[primary_span]
649        span: Span,
650    },
651}
652
653#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            FormatNoArgNamed where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    FormatNoArgNamed { span: __binding_0, name: __binding_1 } =>
                        {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_no_arg_named);
                        diag.note(crate::fluent_generated::_subdiag::note);
                        diag.note(crate::fluent_generated::builtin_macros_note2);
                        ;
                        diag.arg("name", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
654#[diag(builtin_macros_format_no_arg_named)]
655#[note]
656#[note(builtin_macros_note2)]
657pub(crate) struct FormatNoArgNamed {
658    #[primary_span]
659    pub(crate) span: Span,
660    pub(crate) name: Symbol,
661}
662
663#[derive(const _: () =
    {
        impl<'_sess, 'a, G> rustc_errors::Diagnostic<'_sess, G> for
            FormatUnknownTrait<'a> where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    FormatUnknownTrait {
                        span: __binding_0, ty: __binding_1, suggs: __binding_2 } =>
                        {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_unknown_trait);
                        diag.note(crate::fluent_generated::_subdiag::note);
                        ;
                        diag.arg("ty", __binding_1);
                        diag.span(__binding_0);
                        for __binding_2 in __binding_2 {
                            diag.subdiagnostic(__binding_2);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
664#[diag(builtin_macros_format_unknown_trait)]
665#[note]
666pub(crate) struct FormatUnknownTrait<'a> {
667    #[primary_span]
668    pub(crate) span: Span,
669    pub(crate) ty: &'a str,
670    #[subdiagnostic]
671    pub(crate) suggs: Vec<FormatUnknownTraitSugg>,
672}
673
674#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for FormatUnknownTraitSugg {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    FormatUnknownTraitSugg {
                        span: __binding_0, fmt: __binding_1, trait_name: __binding_2
                        } => {
                        let __code_17 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!("{0}", __binding_1))
                                            })].into_iter();
                        diag.store_args();
                        diag.arg("fmt", __binding_1);
                        diag.arg("trait_name", __binding_2);
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_suggestion);
                        diag.span_suggestions_with_style(__binding_0, __message,
                            __code_17, rustc_errors::Applicability::MaybeIncorrect,
                            rustc_errors::SuggestionStyle::CompletelyHidden);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
675#[suggestion(
676    builtin_macros_suggestion,
677    code = "{fmt}",
678    style = "tool-only",
679    applicability = "maybe-incorrect"
680)]
681pub(crate) struct FormatUnknownTraitSugg {
682    #[primary_span]
683    pub span: Span,
684    pub fmt: &'static str,
685    pub trait_name: &'static str,
686}
687
688#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            FormatUnusedArg where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    FormatUnusedArg { span: __binding_0, named: __binding_1 } =>
                        {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_unused_arg);
                        ;
                        diag.arg("named", __binding_1);
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::builtin_macros_format_unused_arg);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
689#[diag(builtin_macros_format_unused_arg)]
690pub(crate) struct FormatUnusedArg {
691    #[primary_span]
692    #[label(builtin_macros_format_unused_arg)]
693    pub(crate) span: Span,
694    pub(crate) named: bool,
695}
696
697// Allow the singular form to be a subdiagnostic of the multiple-unused
698// form of diagnostic.
699impl Subdiagnostic for FormatUnusedArg {
700    fn add_to_diag<G: EmissionGuarantee>(self, diag: &mut Diag<'_, G>) {
701        diag.arg("named", self.named);
702        let msg = diag.eagerly_translate(crate::fluent_generated::builtin_macros_format_unused_arg);
703        diag.remove_arg("named");
704        diag.span_label(self.span, msg);
705    }
706}
707
708#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            FormatUnusedArgs where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    FormatUnusedArgs {
                        unused: __binding_0,
                        fmt: __binding_1,
                        unused_labels: __binding_2 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_unused_args);
                        ;
                        diag.span(__binding_0.clone());
                        diag.span_label(__binding_1,
                            crate::fluent_generated::_subdiag::label);
                        for __binding_2 in __binding_2 {
                            diag.subdiagnostic(__binding_2);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
709#[diag(builtin_macros_format_unused_args)]
710pub(crate) struct FormatUnusedArgs {
711    #[primary_span]
712    pub(crate) unused: Vec<Span>,
713    #[label]
714    pub(crate) fmt: Span,
715    #[subdiagnostic]
716    pub(crate) unused_labels: Vec<FormatUnusedArg>,
717}
718
719#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            FormatPositionalMismatch where G: rustc_errors::EmissionGuarantee
            {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    FormatPositionalMismatch {
                        span: __binding_0,
                        n: __binding_1,
                        desc: __binding_2,
                        highlight: __binding_3 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_pos_mismatch);
                        ;
                        diag.arg("n", __binding_1);
                        diag.arg("desc", __binding_2);
                        diag.span(__binding_0);
                        diag.subdiagnostic(__binding_3);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
720#[diag(builtin_macros_format_pos_mismatch)]
721pub(crate) struct FormatPositionalMismatch {
722    #[primary_span]
723    pub(crate) span: MultiSpan,
724    pub(crate) n: usize,
725    pub(crate) desc: String,
726    #[subdiagnostic]
727    pub(crate) highlight: SingleLabelManySpans,
728}
729
730#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            FormatRedundantArgs where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    FormatRedundantArgs {
                        span: __binding_0,
                        n: __binding_1,
                        note: __binding_2,
                        sugg: __binding_3 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_format_redundant_args);
                        ;
                        diag.arg("n", __binding_1);
                        diag.span(__binding_0);
                        diag.span_note(__binding_2,
                            crate::fluent_generated::_subdiag::note);
                        if let Some(__binding_3) = __binding_3 {
                            diag.subdiagnostic(__binding_3);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
731#[diag(builtin_macros_format_redundant_args)]
732pub(crate) struct FormatRedundantArgs {
733    #[primary_span]
734    pub(crate) span: MultiSpan,
735    pub(crate) n: usize,
736
737    #[note]
738    pub(crate) note: MultiSpan,
739
740    #[subdiagnostic]
741    pub(crate) sugg: Option<FormatRedundantArgsSugg>,
742}
743
744#[derive(const _: () =
    {
        impl rustc_errors::Subdiagnostic for FormatRedundantArgsSugg {
            fn add_to_diag<__G>(self, diag: &mut rustc_errors::Diag<'_, __G>)
                where __G: rustc_errors::EmissionGuarantee {
                match self {
                    FormatRedundantArgsSugg { spans: __binding_0 } => {
                        let mut suggestions = Vec::new();
                        let __code_18 =
                            ::alloc::__export::must_use({
                                    ::alloc::fmt::format(format_args!(""))
                                });
                        for __binding_0 in __binding_0 {
                            suggestions.push((__binding_0, __code_18.clone()));
                        }
                        diag.store_args();
                        let __message =
                            diag.eagerly_translate(crate::fluent_generated::builtin_macros_suggestion);
                        diag.multipart_suggestion_with_style(__message, suggestions,
                            rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::ShowCode);
                        diag.restore_args();
                    }
                }
            }
        }
    };Subdiagnostic)]
745#[multipart_suggestion(builtin_macros_suggestion, applicability = "machine-applicable")]
746pub(crate) struct FormatRedundantArgsSugg {
747    #[suggestion_part(code = "")]
748    pub(crate) spans: Vec<Span>,
749}
750
751#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            TestCaseNonItem where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    TestCaseNonItem { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_test_case_non_item);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
752#[diag(builtin_macros_test_case_non_item)]
753pub(crate) struct TestCaseNonItem {
754    #[primary_span]
755    pub(crate) span: Span,
756}
757
758#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for TestBadFn
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    TestBadFn {
                        span: __binding_0, cause: __binding_1, kind: __binding_2 }
                        => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_test_bad_fn);
                        ;
                        diag.arg("kind", __binding_2);
                        diag.span(__binding_0);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::_subdiag::label);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
759#[diag(builtin_macros_test_bad_fn)]
760pub(crate) struct TestBadFn {
761    #[primary_span]
762    pub(crate) span: Span,
763    #[label]
764    pub(crate) cause: Span,
765    pub(crate) kind: &'static str,
766}
767
768#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmExplicitRegisterName where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmExplicitRegisterName { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_explicit_register_name);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
769#[diag(builtin_macros_asm_explicit_register_name)]
770pub(crate) struct AsmExplicitRegisterName {
771    #[primary_span]
772    pub(crate) span: Span,
773}
774
775#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmMutuallyExclusive where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmMutuallyExclusive {
                        spans: __binding_0, opt1: __binding_1, opt2: __binding_2 }
                        => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_mutually_exclusive);
                        ;
                        diag.arg("opt1", __binding_1);
                        diag.arg("opt2", __binding_2);
                        diag.span(__binding_0.clone());
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
776#[diag(builtin_macros_asm_mutually_exclusive)]
777pub(crate) struct AsmMutuallyExclusive {
778    #[primary_span]
779    pub(crate) spans: Vec<Span>,
780    pub(crate) opt1: &'static str,
781    pub(crate) opt2: &'static str,
782}
783
784#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for AsmPureCombine
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmPureCombine { spans: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_pure_combine);
                        ;
                        diag.span(__binding_0.clone());
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
785#[diag(builtin_macros_asm_pure_combine)]
786pub(crate) struct AsmPureCombine {
787    #[primary_span]
788    pub(crate) spans: Vec<Span>,
789}
790
791#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmPureNoOutput where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmPureNoOutput { spans: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_pure_no_output);
                        ;
                        diag.span(__binding_0.clone());
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
792#[diag(builtin_macros_asm_pure_no_output)]
793pub(crate) struct AsmPureNoOutput {
794    #[primary_span]
795    pub(crate) spans: Vec<Span>,
796}
797
798#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmModifierInvalid where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmModifierInvalid { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_modifier_invalid);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
799#[diag(builtin_macros_asm_modifier_invalid)]
800pub(crate) struct AsmModifierInvalid {
801    #[primary_span]
802    pub(crate) span: Span,
803}
804
805#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmAttributeNotSupported where G: rustc_errors::EmissionGuarantee
            {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmAttributeNotSupported { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_attribute_not_supported);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
806#[diag(builtin_macros_asm_attribute_not_supported)]
807pub(crate) struct AsmAttributeNotSupported {
808    #[primary_span]
809    pub(crate) span: Span,
810}
811
812#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmDuplicateArg where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmDuplicateArg {
                        span: __binding_0, prev: __binding_1, name: __binding_2 } =>
                        {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_duplicate_arg);
                        ;
                        diag.arg("name", __binding_2);
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::builtin_macros_arg);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::_subdiag::label);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
813#[diag(builtin_macros_asm_duplicate_arg)]
814pub(crate) struct AsmDuplicateArg {
815    #[primary_span]
816    #[label(builtin_macros_arg)]
817    pub(crate) span: Span,
818    #[label]
819    pub(crate) prev: Span,
820    pub(crate) name: Symbol,
821}
822
823#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmPositionalAfter where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmPositionalAfter {
                        span: __binding_0, named: __binding_1, explicit: __binding_2
                        } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_pos_after);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::builtin_macros_pos);
                        for __binding_1 in __binding_1 {
                            diag.span_label(__binding_1,
                                crate::fluent_generated::builtin_macros_named);
                        }
                        for __binding_2 in __binding_2 {
                            diag.span_label(__binding_2,
                                crate::fluent_generated::builtin_macros_explicit);
                        }
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
824#[diag(builtin_macros_asm_pos_after)]
825pub(crate) struct AsmPositionalAfter {
826    #[primary_span]
827    #[label(builtin_macros_pos)]
828    pub(crate) span: Span,
829    #[label(builtin_macros_named)]
830    pub(crate) named: Vec<Span>,
831    #[label(builtin_macros_explicit)]
832    pub(crate) explicit: Vec<Span>,
833}
834
835#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for AsmNoReturn
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmNoReturn { outputs_sp: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_noreturn);
                        ;
                        diag.span(__binding_0.clone());
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
836#[diag(builtin_macros_asm_noreturn)]
837pub(crate) struct AsmNoReturn {
838    #[primary_span]
839    pub(crate) outputs_sp: Vec<Span>,
840}
841
842#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmNoMatchedArgumentName where G: rustc_errors::EmissionGuarantee
            {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmNoMatchedArgumentName {
                        name: __binding_0, span: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_no_matched_argument_name);
                        ;
                        diag.arg("name", __binding_0);
                        diag.span(__binding_1);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
843#[diag(builtin_macros_asm_no_matched_argument_name)]
844pub(crate) struct AsmNoMatchedArgumentName {
845    pub(crate) name: String,
846    #[primary_span]
847    pub(crate) span: Span,
848}
849
850#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for AsmMayUnwind
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmMayUnwind { labels_sp: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_mayunwind);
                        ;
                        diag.span(__binding_0.clone());
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
851#[diag(builtin_macros_asm_mayunwind)]
852pub(crate) struct AsmMayUnwind {
853    #[primary_span]
854    pub(crate) labels_sp: Vec<Span>,
855}
856
857pub(crate) struct AsmClobberNoReg {
858    pub(crate) spans: Vec<Span>,
859    pub(crate) clobbers: Vec<Span>,
860}
861
862impl<'a, G: EmissionGuarantee> Diagnostic<'a, G> for AsmClobberNoReg {
863    fn into_diag(self, dcx: DiagCtxtHandle<'a>, level: Level) -> Diag<'a, G> {
864        // eager translation as `span_labels` takes `AsRef<str>`
865        let lbl1 = dcx.eagerly_translate_to_string(
866            crate::fluent_generated::builtin_macros_asm_clobber_abi,
867            [].into_iter(),
868        );
869        let lbl2 = dcx.eagerly_translate_to_string(
870            crate::fluent_generated::builtin_macros_asm_clobber_outputs,
871            [].into_iter(),
872        );
873        Diag::new(dcx, level, crate::fluent_generated::builtin_macros_asm_clobber_no_reg)
874            .with_span(self.spans.clone())
875            .with_span_labels(self.clobbers, &lbl1)
876            .with_span_labels(self.spans, &lbl2)
877    }
878}
879
880#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmOptAlreadyprovided where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmOptAlreadyprovided {
                        span: __binding_0,
                        symbol: __binding_1,
                        span_with_comma: __binding_2 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_opt_already_provided);
                        let __code_19 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!(""))
                                            })].into_iter();
                        ;
                        diag.arg("symbol", __binding_1);
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::_subdiag::label);
                        diag.span_suggestions_with_style(__binding_2,
                            crate::fluent_generated::_subdiag::suggestion, __code_19,
                            rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::CompletelyHidden);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
881#[diag(builtin_macros_asm_opt_already_provided)]
882pub(crate) struct AsmOptAlreadyprovided {
883    #[primary_span]
884    #[label]
885    pub(crate) span: Span,
886    pub(crate) symbol: Symbol,
887    #[suggestion(code = "", applicability = "machine-applicable", style = "tool-only")]
888    pub(crate) span_with_comma: Span,
889}
890
891#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmUnsupportedOption where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmUnsupportedOption {
                        span: __binding_0,
                        symbol: __binding_1,
                        span_with_comma: __binding_2,
                        macro_name: __binding_3 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_unsupported_option);
                        let __code_20 =
                            [::alloc::__export::must_use({
                                                ::alloc::fmt::format(format_args!(""))
                                            })].into_iter();
                        ;
                        diag.arg("symbol", __binding_1);
                        diag.arg("macro_name", __binding_3);
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::_subdiag::label);
                        diag.span_suggestions_with_style(__binding_2,
                            crate::fluent_generated::_subdiag::suggestion, __code_20,
                            rustc_errors::Applicability::MachineApplicable,
                            rustc_errors::SuggestionStyle::CompletelyHidden);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
892#[diag(builtin_macros_asm_unsupported_option)]
893pub(crate) struct AsmUnsupportedOption {
894    #[primary_span]
895    #[label]
896    pub(crate) span: Span,
897    pub(crate) symbol: Symbol,
898    #[suggestion(code = "", applicability = "machine-applicable", style = "tool-only")]
899    pub(crate) span_with_comma: Span,
900    pub(crate) macro_name: &'static str,
901}
902
903#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmUnsupportedClobberAbi where G: rustc_errors::EmissionGuarantee
            {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmUnsupportedClobberAbi {
                        spans: __binding_0, macro_name: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_asm_unsupported_clobber_abi);
                        ;
                        diag.arg("macro_name", __binding_1);
                        diag.span(__binding_0.clone());
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
904#[diag(builtin_macros_asm_unsupported_clobber_abi)]
905pub(crate) struct AsmUnsupportedClobberAbi {
906    #[primary_span]
907    pub(crate) spans: Vec<Span>,
908    pub(crate) macro_name: &'static str,
909}
910
911#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            TestRunnerInvalid where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    TestRunnerInvalid { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_test_runner_invalid);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
912#[diag(builtin_macros_test_runner_invalid)]
913pub(crate) struct TestRunnerInvalid {
914    #[primary_span]
915    pub(crate) span: Span,
916}
917
918#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            TestRunnerNargs where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    TestRunnerNargs { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_test_runner_nargs);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
919#[diag(builtin_macros_test_runner_nargs)]
920pub(crate) struct TestRunnerNargs {
921    #[primary_span]
922    pub(crate) span: Span,
923}
924
925#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            ExpectedCommaInList where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ExpectedCommaInList { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_expected_comma_in_list);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
926#[diag(builtin_macros_expected_comma_in_list)]
927pub(crate) struct ExpectedCommaInList {
928    #[primary_span]
929    pub span: Span,
930}
931
932#[derive(const _: () =
    {
        impl<'_sess, 'a, G> rustc_errors::Diagnostic<'_sess, G> for
            OnlyOneArgument<'a> where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    OnlyOneArgument { span: __binding_0, name: __binding_1 } =>
                        {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_only_one_argument);
                        ;
                        diag.arg("name", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
933#[diag(builtin_macros_only_one_argument)]
934pub(crate) struct OnlyOneArgument<'a> {
935    #[primary_span]
936    pub span: Span,
937    pub name: &'a str,
938}
939
940#[derive(const _: () =
    {
        impl<'_sess, 'a, G> rustc_errors::Diagnostic<'_sess, G> for
            TakesNoArguments<'a> where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    TakesNoArguments { span: __binding_0, name: __binding_1 } =>
                        {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_takes_no_arguments);
                        ;
                        diag.arg("name", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
941#[diag(builtin_macros_takes_no_arguments)]
942pub(crate) struct TakesNoArguments<'a> {
943    #[primary_span]
944    pub span: Span,
945    pub name: &'a str,
946}
947
948#[derive(const _: () =
    {
        impl<'_sess, 'a, G> rustc_errors::Diagnostic<'_sess, G> for
            AttributeOnlyUsableWithCrateType<'a> where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AttributeOnlyUsableWithCrateType {
                        span: __binding_0, path: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_proc_macro_attribute_only_usable_with_crate_type);
                        ;
                        diag.arg("path", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
949#[diag(builtin_macros_proc_macro_attribute_only_usable_with_crate_type)]
950pub(crate) struct AttributeOnlyUsableWithCrateType<'a> {
951    #[primary_span]
952    pub span: Span,
953    pub path: &'a str,
954}
955
956#[derive(const _: () =
    {
        impl<'_sess, 'a, G> rustc_errors::Diagnostic<'_sess, G> for
            ExpectedItem<'a> where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    ExpectedItem { span: __binding_0, token: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_source_utils_expected_item);
                        ;
                        diag.arg("token", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
957#[diag(builtin_macros_source_utils_expected_item)]
958pub(crate) struct ExpectedItem<'a> {
959    #[primary_span]
960    pub span: Span,
961    pub token: &'a str,
962}
963
964#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            NakedFunctionTestingAttribute where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    NakedFunctionTestingAttribute {
                        naked_span: __binding_0, testing_span: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_naked_functions_testing_attribute);
                        diag.code(E0736);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::builtin_macros_naked_attribute);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::_subdiag::label);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
965#[diag(builtin_macros_naked_functions_testing_attribute, code = E0736)]
966pub(crate) struct NakedFunctionTestingAttribute {
967    #[primary_span]
968    #[label(builtin_macros_naked_attribute)]
969    pub naked_span: Span,
970    #[label]
971    pub testing_span: Span,
972}
973
974#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            NonGenericPointee where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    NonGenericPointee { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_non_generic_pointee);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
975#[diag(builtin_macros_non_generic_pointee)]
976pub(crate) struct NonGenericPointee {
977    #[primary_span]
978    pub span: Span,
979}
980
981#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            AsmExpectedOther where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    AsmExpectedOther {
                        span: __binding_0, is_inline_asm: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_expected_other);
                        ;
                        diag.arg("is_inline_asm", __binding_1);
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::builtin_macros_expected_other);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
982#[diag(builtin_macros_expected_other)]
983pub(crate) struct AsmExpectedOther {
984    #[primary_span]
985    #[label(builtin_macros_expected_other)]
986    pub(crate) span: Span,
987    pub(crate) is_inline_asm: bool,
988}
989
990#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            CfgSelectNoMatches where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    CfgSelectNoMatches { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_cfg_select_no_matches);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
991#[diag(builtin_macros_cfg_select_no_matches)]
992pub(crate) struct CfgSelectNoMatches {
993    #[primary_span]
994    pub span: Span,
995}
996
997#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            CfgSelectUnreachable where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    CfgSelectUnreachable {
                        span: __binding_0, wildcard_span: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_cfg_select_unreachable);
                        ;
                        diag.span(__binding_0);
                        diag.span_label(__binding_0,
                            crate::fluent_generated::builtin_macros_label2);
                        diag.span_label(__binding_1,
                            crate::fluent_generated::_subdiag::label);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
998#[diag(builtin_macros_cfg_select_unreachable)]
999pub(crate) struct CfgSelectUnreachable {
1000    #[primary_span]
1001    #[label(builtin_macros_label2)]
1002    pub span: Span,
1003
1004    #[label]
1005    pub wildcard_span: Span,
1006}
1007
1008#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            EiiExternTargetExpectedMacro where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EiiExternTargetExpectedMacro { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_eii_declaration_expected_macro);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
1009#[diag(builtin_macros_eii_declaration_expected_macro)]
1010pub(crate) struct EiiExternTargetExpectedMacro {
1011    #[primary_span]
1012    pub span: Span,
1013}
1014
1015#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            EiiExternTargetExpectedList where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EiiExternTargetExpectedList { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_eii_declaration_expected_list);
                        ;
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
1016#[diag(builtin_macros_eii_declaration_expected_list)]
1017pub(crate) struct EiiExternTargetExpectedList {
1018    #[primary_span]
1019    pub span: Span,
1020}
1021
1022#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            EiiExternTargetExpectedUnsafe where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EiiExternTargetExpectedUnsafe { span: __binding_0 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_eii_declaration_expected_unsafe);
                        ;
                        diag.span(__binding_0);
                        diag.span_note(__binding_0,
                            crate::fluent_generated::_subdiag::note);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
1023#[diag(builtin_macros_eii_declaration_expected_unsafe)]
1024pub(crate) struct EiiExternTargetExpectedUnsafe {
1025    #[primary_span]
1026    #[note]
1027    pub span: Span,
1028}
1029
1030#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            EiiSharedMacroExpectedFunction where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EiiSharedMacroExpectedFunction {
                        span: __binding_0, name: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_eii_shared_macro_expected_function);
                        ;
                        diag.arg("name", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
1031#[diag(builtin_macros_eii_shared_macro_expected_function)]
1032pub(crate) struct EiiSharedMacroExpectedFunction {
1033    #[primary_span]
1034    pub span: Span,
1035    pub name: String,
1036}
1037
1038#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            EiiSharedMacroInStatementPosition where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EiiSharedMacroInStatementPosition {
                        span: __binding_0, name: __binding_1, item_span: __binding_2
                        } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_eii_shared_macro_in_statement_position);
                        ;
                        diag.arg("name", __binding_1);
                        diag.span(__binding_0);
                        diag.span_label(__binding_2,
                            crate::fluent_generated::_subdiag::label);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
1039#[diag(builtin_macros_eii_shared_macro_in_statement_position)]
1040pub(crate) struct EiiSharedMacroInStatementPosition {
1041    #[primary_span]
1042    pub span: Span,
1043    pub name: String,
1044    #[label]
1045    pub item_span: Span,
1046}
1047
1048#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for EiiOnlyOnce
            where G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EiiOnlyOnce {
                        span: __binding_0,
                        first_span: __binding_1,
                        name: __binding_2 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_eii_only_once);
                        ;
                        diag.arg("name", __binding_2);
                        diag.span(__binding_0);
                        diag.span_note(__binding_1,
                            crate::fluent_generated::_subdiag::note);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
1049#[diag(builtin_macros_eii_only_once)]
1050pub(crate) struct EiiOnlyOnce {
1051    #[primary_span]
1052    pub span: Span,
1053    #[note]
1054    pub first_span: Span,
1055    pub name: String,
1056}
1057
1058#[derive(const _: () =
    {
        impl<'_sess, G> rustc_errors::Diagnostic<'_sess, G> for
            EiiMacroExpectedMaxOneArgument where
            G: rustc_errors::EmissionGuarantee {
            #[track_caller]
            fn into_diag(self, dcx: rustc_errors::DiagCtxtHandle<'_sess>,
                level: rustc_errors::Level) -> rustc_errors::Diag<'_sess, G> {
                match self {
                    EiiMacroExpectedMaxOneArgument {
                        span: __binding_0, name: __binding_1 } => {
                        let mut diag =
                            rustc_errors::Diag::new(dcx, level,
                                crate::fluent_generated::builtin_macros_eii_shared_macro_expected_max_one_argument);
                        ;
                        diag.arg("name", __binding_1);
                        diag.span(__binding_0);
                        diag
                    }
                }
            }
        }
    };Diagnostic)]
1059#[diag(builtin_macros_eii_shared_macro_expected_max_one_argument)]
1060pub(crate) struct EiiMacroExpectedMaxOneArgument {
1061    #[primary_span]
1062    pub span: Span,
1063    pub name: String,
1064}