summary refs log tree commit diff
path: root/compiler/rustc_parse/src/errors.rs
diff options
context:
space:
mode:
authorcarbotaniuman <41451839+carbotaniuman@users.noreply.github.com>2024-07-09 19:06:49 -0500
committercarbotaniuman <41451839+carbotaniuman@users.noreply.github.com>2024-07-30 18:28:43 -0500
commit49db8a5a999f0908b5bf74b88a2d72a4f4dddf48 (patch)
treea080b5f39b3e923e2a2057102cf88362757f316c /compiler/rustc_parse/src/errors.rs
parentd8bc8761a5bb8456c0b7940434b3b3b4f0ed035c (diff)
downloadrust-49db8a5a999f0908b5bf74b88a2d72a4f4dddf48.tar.gz
rust-49db8a5a999f0908b5bf74b88a2d72a4f4dddf48.zip
Add toggle for `parse_meta_item` unsafe parsing
This makes it possible for the `unsafe(...)` syntax to only be
valid at the top level, and the `NestedMetaItem`s will automatically
reject `unsafe(...)`.
Diffstat (limited to 'compiler/rustc_parse/src/errors.rs')
-rw-r--r--compiler/rustc_parse/src/errors.rs1
1 files changed, 1 insertions, 0 deletions
diff --git a/compiler/rustc_parse/src/errors.rs b/compiler/rustc_parse/src/errors.rs
index 10762803708..e5b0dc804a5 100644
--- a/compiler/rustc_parse/src/errors.rs
+++ b/compiler/rustc_parse/src/errors.rs
@@ -3188,6 +3188,7 @@ pub(crate) struct DotDotRangeAttribute {
 #[note]
 pub struct InvalidAttrUnsafe {
     #[primary_span]
+    #[label]
     pub span: Span,
     pub name: Path,
 }