aboutsummaryrefslogtreecommitdiff
path: root/crates/mbe/src/tests
diff options
context:
space:
mode:
authorJonas Schievink <[email protected]>2021-04-03 02:08:31 +0100
committerJonas Schievink <[email protected]>2021-04-03 02:08:31 +0100
commiteaffdae3006ed0386f21dc31c499ffea24c32c98 (patch)
tree962bde59e986c38ebc167e7b940af5ab3c9a0f45 /crates/mbe/src/tests
parenteb264fb81963d9ec08b2797818073e8ae2993a41 (diff)
Allow `,` to delimit macro 2.0 rules
Diffstat (limited to 'crates/mbe/src/tests')
-rw-r--r--crates/mbe/src/tests/expand.rs15
1 files changed, 15 insertions, 0 deletions
diff --git a/crates/mbe/src/tests/expand.rs b/crates/mbe/src/tests/expand.rs
index 8951f3813..e02d038b6 100644
--- a/crates/mbe/src/tests/expand.rs
+++ b/crates/mbe/src/tests/expand.rs
@@ -663,6 +663,21 @@ macro foo {
663} 663}
664 664
665#[test] 665#[test]
666fn test_macro_2_0_panic_2015() {
667 parse_macro2(
668 r#"
669macro panic_2015 {
670 () => (
671 ),
672 (bar) => (
673 ),
674}
675"#,
676 )
677 .assert_expand_items("panic_2015!(bar);", "");
678}
679
680#[test]
666fn test_path() { 681fn test_path() {
667 parse_macro( 682 parse_macro(
668 r#" 683 r#"