anchor.diff:  ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
   (in-package :sheeple)
   
  -(defstruct (reply-container (:type vector))
  -  reply rank)
  +(deftype ranked-reply ()
  +  'simple-vector)
   
  +(declaim (inline unbox-ranked-reply))
  +(defun unbox-ranked-reply (ranked-reply)
  +  (declare (ranked-reply ranked-reply) (optimize speed (safety 0)))
  +  (svref ranked-reply 0))
  +
  +(declaim (inline reply-specialized-length))
   (defun reply-specialized-length (reply)
     (count-required-parameters (reply-lambda-list reply)))
   
  -(defun contain-reply (reply)
  -  (make-reply-container
  -   :reply reply
  -   :rank (make-vector (reply-specialized-length reply))))
  +(defun box-reply (reply)                ; For lack of a better name
  +  (declare (reply reply) (optimize speed (safety 0)))
  +  (aprog1 (make-array (the fixnum (1+ (the fixnum (reply-specialized-length reply))))
  +                      :initial-element nil)
  +    (setf (svref it 0) reply)))
   
   (defun nunbox-replies (replies)
     "Unbox in-place each of the contained REPLIES."
  
positive.code:             (compute-primary-erfun (cdr replies)))))
  
  (defun find-applicable-replies (message args &optional (errorp t))
    "Returns the most specific reply using MESSAGE and ARGS."
    (if (null args)
        (message-replies message)
        (loop with discovered-replies list and contained-applicable-replies list
           for arg in args and index fixnum upfrom 0 do
             (loop
                for hierarchy-object in
  
negative.code:   (do ((tail replies (cdr tail)))
        ((null tail) replies)
      (declare (list tail))
      (setf (car tail) (unbox-ranked-reply (car tail)))))
  
  (defun score-ranked-reply (ranked-reply)
    ;; All hell breaks loose if you don't give this a simple-vector
    (declare (ranked-reply ranked-reply) (optimize speed (safety 0)))
    (loop for i fixnum downfrom (1- (length ranked-reply))
       for elt = (svref ranked-reply i) with total fixnum = 0
       when (zerop i) return total
       unless (null elt) do
         (setf total (the fixnum (+ total (the fixnum elt))))))
  
  (defun fully-specified-p (ranked-reply)
    ;; Same here, and all the elements better be (or fixnum null)
    (declare (ranked-reply ranked-reply) (optimize speed (safety 0)))
    (loop for i fixnum downfrom (1- (length ranked-reply))
       when (zerop i) return t
       unless (svref ranked-reply i) return nil))
  
  (defun sort-applicable-replies (reply-list)
    ;; Most lisps compile this as a tail call, so this function ends up being a
    ;; macro around SORT, and there's no harm in the (safety 0)
    (declare (optimize speed (safety 0)) (list reply-list))
    (sort reply-list #'< :key 'score-ranked-reply))
  
  (defun apply-message (message args)
    (let ((relevant-args-length (arg-info-number-required (message-arg-info message))))
  