anchor.diff:               (type (mod #.most-positive-fixnum) carry))
       (setf (aref block i) (logand sub #xff)))
     (values))
  -
  -;;; Only really works on big-endian processors...
  -#+nil
  -(defun increment-counter-block (block)
  -  (let ((words (truncate (length block) sb-vm:n-word-bytes))
  -        (carry 1))
  -    (loop for i from (1- words) downto 0
  -          until (zerop carry) do
  -          (let ((word (sb-kernel:%vector-raw-bits block i)))
  -            (multiple-value-setq (word carry)
  -              (sb-bignum:%add-with-carry word 0 carry))
  -            (setf (sb-kernel:%vector-raw-bits block i) word)))
  -    (values)))
   
   ;;; This way is kind of ugly, but I don't know a better way.
   (macrolet ((define-mode-function (&rest mode-definition-funs &environment env)
  
positive.code: (defclass ctr-mode (encryption-mode inititialization-vector-mixin)
    ((keystream-blocks :accessor keystream-blocks :initform 0)))
  
  #+nil
  (defclass padded-cipher-mode (encryption-mode)
    ((buffer :reader buffer)
     (buffer-index :accessor buffer-index :initform 0)
     (sub-mode :reader sub-mode :initarg :sub-mode)))
  
  (defmethod print-object ((object encryption-mode) stream)
    (print-unreadable-object (object stream :identity t)
      (format stream "~A" (class-name (class-of object)))))
  
negative.code:   (multiple-value-bind (efun dfun) (mode-crypt-functions cipher mode)
      (setf (slot-value mode 'encrypt-function) efun
            (slot-value mode 'decrypt-function) dfun)))
  
  (defvar *supported-modes* (list :ecb :cbc :ofb :cfb :cfb8 :ctr))
  
  