diff options
Diffstat (limited to 'chomp-macro/tests/regex_fix.rs')
-rw-r--r-- | chomp-macro/tests/regex_fix.rs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/chomp-macro/tests/regex_fix.rs b/chomp-macro/tests/regex_fix.rs new file mode 100644 index 0000000..9842484 --- /dev/null +++ b/chomp-macro/tests/regex_fix.rs @@ -0,0 +1,11 @@ +chomp_macro::nibble! { + let opt(x) = _ | x; + let ws = [star](opt(" " . star)); + + match [rec]("a" . opt("." . ws . rec)); +} + +#[test] +fn regex_fix_cat() { + Ast::parse_str(r#"a. a"#).unwrap(); +} |