diff options
Diffstat (limited to 'test/colm.d/redef3.lm')
-rw-r--r-- | test/colm.d/redef3.lm | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/test/colm.d/redef3.lm b/test/colm.d/redef3.lm new file mode 100644 index 00000000..e8013018 --- /dev/null +++ b/test/colm.d/redef3.lm @@ -0,0 +1,30 @@ +lex + token ident /[a-z]+/ + ignore /[ \t\n]+/ +end + +def main + [ident] + +redef main + [ident ident] +| [...] + +parse Main: main[stdin] + +if Main + print [Main] +else + print "parse error +##### IN ##### +a +##### EXP ##### +a +##### IN ##### +a b +##### EXP ##### +a b +##### IN ##### +a b c +##### EXP ##### +parse error |