diff options
author | Lorry Tar Creator <lorry-tar-importer@lorry> | 2014-02-01 19:49:33 +0000 |
---|---|---|
committer | Lorry Tar Creator <lorry-tar-importer@lorry> | 2014-02-01 19:49:33 +0000 |
commit | 404ae0f284a3b2d41fcdb53826550e4dfec5c65c (patch) | |
tree | cc446af26234e4465b8cc168b720ec44816ff5ab /test/reparse.lm | |
download | colm-tarball-404ae0f284a3b2d41fcdb53826550e4dfec5c65c.tar.gz |
colm-0.12.0HEADcolm-0.12.0master
Diffstat (limited to 'test/reparse.lm')
-rw-r--r-- | test/reparse.lm | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/test/reparse.lm b/test/reparse.lm new file mode 100644 index 0000000..907ca6a --- /dev/null +++ b/test/reparse.lm @@ -0,0 +1,26 @@ +##### LM ##### +lex + ignore /space+/ + literal `* `( `) + token id /[a-zA-Z_]+/ +end + +def item + [id] +| [`( item* `)] + +def start + [item*] + +parse Input: item*[ stdin ] + +S: start = cons start[ Input ] + +parse Again: start[ %Input ] + +print( Again ) + +##### IN ##### +a b c ( chocolate fudge ) d e +##### EXP ##### +a b c ( chocolate fudge ) d e |