anchor.diff:              (sec-of object)
               (nsec-of object)
               (human-readable-duration object))))
  +
  +(defun human-readable-duration (duration &optional stream)
  +  (multiple-value-bind (nsecs secs minutes hours days weeks)
  +      (decode-duration duration :weeks t)
  +    (flet ((zero-is-nil (x) (if (zerop x) nil x)))
  +      (let ((output (with-output-to-string (human-readable)
  +                      (if (every #'zerop (list weeks days hours minutes secs nsecs))
  +                          (format human-readable "0 length")
  +                          (format human-readable "~@[~d week~:p~]~@[ ~d day~:p~]~@[ ~d hour~:p~]~@[ ~d minute~:p~]~@[ ~d second~:p~]~@[ ~d nsec~:p~]"
  +                                  (zero-is-nil weeks)
  +                                  (zero-is-nil days)
  +                                  (zero-is-nil hours)
  +                                  (zero-is-nil minutes)
  +                                  (zero-is-nil secs)
  +                                  (zero-is-nil nsecs))))))
  +        (setf output (string-left-trim '(#\Space) output))
  +        (cond ((eql stream t)
  +               (write-string output *standard-output*))
  +              ((eql stream nil)
  +               output)
  +              ((streamp stream)
  +               (write-string output stream))
  +              (t (error "Invalid value for stream ~S." stream)))))))
   
   (defun duration (&key (week 0) (day 0) (hour 0) (minute 0) (sec 0) (nsec 0))
     "Returns a new duration instance representing the sum of the `WEEK`, `DAY`, `HOUR`, `MINUTE`, `SEC`, and `NSEC` arguments. Durations are normalized, that is, (duration :hour 1) and (duration :minute 60) will result in duration instances with the same internal representation."
  
positive.code:                        :day normalized-days
                         :sec normalized-seconds
                         :nsec remaining-nsecs)))))
  
  (defun %duration-compare (a b)
    (declare (type duration a b))
  
negative.code:    (sec :accessor sec-of :initarg :sec :initform 0 :type integer)
     (nsec :accessor nsec-of :initarg :nsec :initform 0 :type (integer 0 999999999)))
    (:documentation "A duration instance represents a period of time with no additional context (e.g., starting or ending time or location)."))
  
  (defmethod print-object ((object duration) stream)
    (print-unreadable-object (object stream :type 'duration)
  