X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=tests%2Fregression.tc;h=97455eb17e41b632a0a43fa225933b66f58a7165;hb=2633ae37e220233b3bb8a71632e37a3070be6e97;hp=5ef3edc1fde0ce469c9918b9278ec020dd3f9805;hpb=8a9fc9f2357e54052374cf2ef003630a486a6c0a;p=sbp.git diff --git a/tests/regression.tc b/tests/regression.tc index 5ef3edc..97455eb 100644 --- a/tests/regression.tc +++ b/tests/regression.tc @@ -222,22 +222,22 @@ testcase { idl ::= [a-d] } -testcase { - input "a*b*c"; - output "times:{stringify:{{a}} times:{stringify:{{b}} stringify:{{c}}}}"; - w ::= " " - l ::= id - s ::= l "=" r => "assign" - | r - r ::= l - | l "=" r => "assign" - | r "+" r => "plus" - | (r) "*" r => "times" - | "(" r ")" - | r r => "times" - id ::= idl++ => "stringify" - idl ::= [a-d] -} +//testcase { +// input "a*b*c"; +// output "times:{stringify:{{a}} times:{stringify:{{b}} stringify:{{c}}}}"; +// w ::= " " +// l ::= id +// s ::= l "=" r => "assign" +// | r +// r ::= l +// | l "=" r => "assign" +// | r "+" r => "plus" +// | (r) "*" r => "times" +// | "(" r ")" +// | r r => "times" +// id ::= idl++ => "stringify" +// idl ::= [a-d] +//} testcase { input "a+b*c"; @@ -325,3 +325,18 @@ testcase { //} // + +testcase { + input "abc "; + + s ::= q " "* => s + q ::= [a-z] [a-z] [a-z] => a3 + &~ ~[] "b" ~[]* +} + +testcase { + input "abc "; + output "s:{a b c}"; + + s ::= [a-z] [a-z] [a-z] " "* => s +}