diff options
| author | Dylan DPC <99973273+Dylan-DPC@users.noreply.github.com> | 2024-02-21 08:55:56 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-02-21 08:55:56 +0000 |
| commit | 4840785cf8d6a1684403343e65ae664bbda23f18 (patch) | |
| tree | 291abe42d467690088a552453f4eacf9624ae07a /compiler/rustc_expand/src/errors.rs | |
| parent | d5206c6ecde0cb887518bc9142dcb6ac21cbbe94 (diff) | |
| parent | f68682fd484fc219192aa7ccf7bb1d809288df5e (diff) | |
| download | rust-4840785cf8d6a1684403343e65ae664bbda23f18.tar.gz rust-4840785cf8d6a1684403343e65ae664bbda23f18.zip | |
Rollup merge of #121288 - tshepang:make-expand-translatable, r=michaelwoerister
make rustc_expand translatable these are the last of the easy ones
Diffstat (limited to 'compiler/rustc_expand/src/errors.rs')
| -rw-r--r-- | compiler/rustc_expand/src/errors.rs | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/compiler/rustc_expand/src/errors.rs b/compiler/rustc_expand/src/errors.rs index 929f3479466..fe901603c73 100644 --- a/compiler/rustc_expand/src/errors.rs +++ b/compiler/rustc_expand/src/errors.rs @@ -393,6 +393,36 @@ pub(crate) struct ProcMacroPanickedHelp { } #[derive(Diagnostic)] +#[diag(expand_proc_macro_derive_panicked)] +pub(crate) struct ProcMacroDerivePanicked { + #[primary_span] + pub span: Span, + #[subdiagnostic] + pub message: Option<ProcMacroDerivePanickedHelp>, +} + +#[derive(Subdiagnostic)] +#[help(expand_help)] +pub(crate) struct ProcMacroDerivePanickedHelp { + pub message: String, +} + +#[derive(Diagnostic)] +#[diag(expand_custom_attribute_panicked)] +pub(crate) struct CustomAttributePanicked { + #[primary_span] + pub span: Span, + #[subdiagnostic] + pub message: Option<CustomAttributePanickedHelp>, +} + +#[derive(Subdiagnostic)] +#[help(expand_help)] +pub(crate) struct CustomAttributePanickedHelp { + pub message: String, +} + +#[derive(Diagnostic)] #[diag(expand_proc_macro_derive_tokens)] pub struct ProcMacroDeriveTokens { #[primary_span] |
