shen/release/test_programs/parse.prl in shen-ruby-0.12.1 vs shen/release/test_programs/parse.prl in shen-ruby-0.13.0

- old
+ new

@@ -1,14 +1,14 @@ -(defprolog pparse - S Grammar <-- (parsing [[s + 0] = [S + 0]] Grammar);) - -(defprolog parsing - [X = X] _ <--; - [[X + Y] = [X + Z]] Grammar <-- ! (parsing [Y = Z] Grammar); - [[[X + Y] + Z] = W] Grammar <-- ! (parsing [[X + [Y + Z]] = W] Grammar); - [W = [[X + Y] + Z]] Grammar <-- ! (parsing [W = [X + [Y + Z]]] Grammar); - [[X + Y] = Z] Grammar <-- (member [X = W] Grammar) (parsing [[W + Y] = Z] Grammar);) - -(defprolog member - X [X | _] <--; - X [_ | Y] <-- (member X Y);) - +(defprolog pparse + S Grammar <-- (parsing [[s + 0] = [S + 0]] Grammar);) + +(defprolog parsing + [X = X] _ <--; + [[X + Y] = [X + Z]] Grammar <-- ! (parsing [Y = Z] Grammar); + [[[X + Y] + Z] = W] Grammar <-- ! (parsing [[X + [Y + Z]] = W] Grammar); + [W = [[X + Y] + Z]] Grammar <-- ! (parsing [W = [X + [Y + Z]]] Grammar); + [[X + Y] = Z] Grammar <-- (member [X = W] Grammar) (parsing [[W + Y] = Z] Grammar);) + +(defprolog member + X [X | _] <--; + X [_ | Y] <-- (member X Y);) +