X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~mdw/git/sod/blobdiff_plain/aa14a4cddcb96b681d5c19a2ec8bad382f43b264..b3354e08ea601fe2420c15a9a16d1f6d5b98a897:/src/parser/parser-expr-impl.lisp diff --git a/src/parser/parser-expr-impl.lisp b/src/parser/parser-expr-impl.lisp index 89b0f58..41c154f 100644 --- a/src/parser/parser-expr-impl.lisp +++ b/src/parser/parser-expr-impl.lisp @@ -116,14 +116,14 @@ (defmethod push-operator (defmethod apply-operator ((operator simple-unary-operator) (state expression-parse-state)) - (with-slots (function) operator + (with-slots ((function %function)) operator (with-slots (valstack) state (assert (not (null valstack))) (push (funcall function (pop valstack)) valstack)))) (defmethod apply-operator ((operator simple-binary-operator) (state expression-parse-state)) - (with-slots (function) operator + (with-slots ((function %function)) operator (with-slots (valstack) state (assert (not (or (null valstack) (null (cdr valstack))))) @@ -151,7 +151,7 @@ (defmethod push-operator (let ((head (car opstack))) (cond ((not (typep head 'open-parenthesis)) (apply-operator head state)) - ((not (eq (slot-value head 'tag) tag)) + ((not (eql (slot-value head 'tag) tag)) (fail)) (t (return))) @@ -165,9 +165,11 @@ (defmethod apply-operator (cerror* "Parse error: missing `~A'" tag))) (defmethod operator-push-action (left (right open-parenthesis)) + (declare (ignore left)) :push) (defmethod operator-push-action ((left open-parenthesis) right) + (declare (ignore right)) :push) ;;;--------------------------------------------------------------------------