diff options
| author | Josh Triplett <josh@joshtriplett.org> | 2025-09-14 16:23:39 +0800 |
|---|---|---|
| committer | Josh Triplett <josh@joshtriplett.org> | 2025-10-01 16:19:39 -0700 |
| commit | 05c5b8779704e20620e18c822a18f28e4961e86e (patch) | |
| tree | edc9073b031ade438203b8cfc5ca8104b6d23c2a /tests/ui/parser/macro/bad-macro-definition.stderr | |
| parent | 6bff1abf9d3c171d2380aacb8b4c6f52580192b3 (diff) | |
| download | rust-05c5b8779704e20620e18c822a18f28e4961e86e.tar.gz rust-05c5b8779704e20620e18c822a18f28e4961e86e.zip | |
mbe: Add parsing tests for `unsafe` macro rules
Diffstat (limited to 'tests/ui/parser/macro/bad-macro-definition.stderr')
| -rw-r--r-- | tests/ui/parser/macro/bad-macro-definition.stderr | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/ui/parser/macro/bad-macro-definition.stderr b/tests/ui/parser/macro/bad-macro-definition.stderr index de6d9d6a38b..d15f33f708d 100644 --- a/tests/ui/parser/macro/bad-macro-definition.stderr +++ b/tests/ui/parser/macro/bad-macro-definition.stderr @@ -52,5 +52,11 @@ error: macros must contain at least one rule LL | macro_rules! f {} | ^^^^^^^^^^^^^^^^^ -error: aborting due to 9 previous errors +error: `unsafe` is only supported on `attr` rules + --> $DIR/bad-macro-definition.rs:24:18 + | +LL | macro_rules! g { unsafe {} => {} } + | ^^^^^^ + +error: aborting due to 10 previous errors |
