anchor.diff:  ;;; File: language.lisp
   ;;; Description: Code that implements the LISA programming language.
   ;;;
  -;;; $Id: language.lisp,v 1.7 2000/10/20 02:32:43 youngde Exp $
  +;;; $Id: language.lisp,v 1.8 2000/10/20 18:07:50 youngde Exp $
   
   (in-package "LISA")
   
  
positive.code: 
  (defun redefine-defrule (name body)
    (with-rule-components ((doc-string decls lhs rhs) body)
      (let ((rule (make-defrule name :doc-string doc-string)))
        (mapc #'(lambda (p)
                  (add-pattern rule p))
              lhs)
  
negative.code:            (overall-structure-ok (body)
               (< (position 'when body :test #'eq :key #'car)
                  (position 'then body :test #'eq :key #'car))))
      (multiple-value-bind (lhs remains)
          (find-before '=> body :test #'eq)
        (if (not (null remains))
            (values (parse-lhs lhs)
                    (parse-rhs (find-after '=> remains :test #'eq)))
          (error "parse-rulebody: rule structure unsound.")))))
  
  (defun make-rule-pattern (template &optional (assign-to nil))
    (labels ((parse-pattern (p)
  