From fbfa64ec69870d424d3f94bd87380efe565b64b5 Mon Sep 17 00:00:00 2001 From: colin Date: Sat, 29 Jul 2023 08:52:37 -0700 Subject: change language for rule def --- examples/calc.lisp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'examples') diff --git a/examples/calc.lisp b/examples/calc.lisp index 87993e8..7b2f9ef 100644 --- a/examples/calc.lisp +++ b/examples/calc.lisp @@ -11,15 +11,15 @@ (:seq (:eof)) (:seq (:eof)) (:seq (:eof))) - :=> car) + :then car) ( :-> (:or )) ( :-> (:item) - :?? listp - :=> (argot:parse calc )) - ( :-> (:item) :?? numberp) + :if listp + :then (argot:parse calc )) + ( :-> (:item) :if numberp) ( :-> (:seq (:@ lhs ) (:@ rhs (:+ (:seq (:or= + - / * ^ %) )))) - :=> (expand-binop lhs rhs)) + :then (expand-binop lhs rhs)) ( :-> (:seq (:or= sin cos tan -) ))) -- cgit v1.2.3