about summary refs log tree commit diff
path: root/compiler/rustc_expand/src/errors.rs
diff options
context:
space:
mode:
authorTshepang Mbambo <tshepang@gmail.com>2023-03-04 07:54:29 +0200
committerTshepang Mbambo <tshepang@gmail.com>2023-03-04 07:54:29 +0200
commit7fe4f0701c34fd107101a6bdb2d62e0935d798a4 (patch)
tree04ede06da97e4e67d3c41d2e5237b724454aeea0 /compiler/rustc_expand/src/errors.rs
parent70adb4e5b4c8f8bde4ade0edcb0435ff7bf31281 (diff)
downloadrust-7fe4f0701c34fd107101a6bdb2d62e0935d798a4.tar.gz
rust-7fe4f0701c34fd107101a6bdb2d62e0935d798a4.zip
rustc_expand: make proc-macro derive error translatable
Diffstat (limited to 'compiler/rustc_expand/src/errors.rs')
-rw-r--r--compiler/rustc_expand/src/errors.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/compiler/rustc_expand/src/errors.rs b/compiler/rustc_expand/src/errors.rs
index 70ab222b484..e5102a952e7 100644
--- a/compiler/rustc_expand/src/errors.rs
+++ b/compiler/rustc_expand/src/errors.rs
@@ -390,3 +390,10 @@ pub(crate) struct ProcMacroPanicked {
 pub(crate) struct ProcMacroPanickedHelp {
     pub message: String,
 }
+
+#[derive(Diagnostic)]
+#[diag(expand_proc_macro_derive_tokens)]
+pub struct ProcMacroDeriveTokens {
+    #[primary_span]
+    pub span: Span,
+}