about summary refs log tree commit diff
path: root/tests/ui/parser/macro/macro-expand-to-match-arm.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ui/parser/macro/macro-expand-to-match-arm.rs')
-rw-r--r--tests/ui/parser/macro/macro-expand-to-match-arm.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/ui/parser/macro/macro-expand-to-match-arm.rs b/tests/ui/parser/macro/macro-expand-to-match-arm.rs
index 39d1d065ed9..972ca61cc84 100644
--- a/tests/ui/parser/macro/macro-expand-to-match-arm.rs
+++ b/tests/ui/parser/macro/macro-expand-to-match-arm.rs
@@ -1,6 +1,8 @@
 macro_rules! arm {
     ($pattern:pat => $block:block) => {
         $pattern => $block
+        //~^ ERROR macro expansion ignores token `=>` and any following
+        //~| NOTE the usage of `arm!` is likely invalid in pattern context
     };
 }
 
@@ -9,9 +11,7 @@ fn main() {
     match x {
         Some(1) => {},
         arm!(None => {}),
-        //~^ NOTE macros cannot expand to match arms
-        //~| ERROR unexpected `,` in pattern
-        // doesn't recover
+        //~^ NOTE caused by the macro expansion here
         Some(2) => {},
         _ => {},
     };