anchor.diff:      (if (> day max-day)
           max-day
           day)))
  +
  +(eval-when (:compile-toplevel :load-toplevel)
   
   (defun expand-adjust-local-time-changes (local-time changes visitor)
     (dolist (change changes)
  
positive.code:            msec)
          1000)))
  
  (defun local-time- (time-a time-b)
    "Returns the difference between TIME-A and TIME-B in seconds"
    (setf time-a (adjust-local-time time-a (set :timezone (timezone-of time-b))))
    (multiple-value-bind (sec-a day-a)
        (adjust-to-timezone time-a (timezone-of time-b))
      (let ((nsec (- (nsec-of time-a) (nsec-of time-b)))
            (second (- sec-a (sec-of time-b)))
            (day (- day-a (day-of time-b))))
        (when (minusp nsec)
          (decf second)
          (incf nsec 1000000000))
        (when (minusp second)
          (decf day)
          (incf second 86400))
        (encode-duration :nsec nsec :sec second :day day))))
  
  (defun local-time+ (time seconds)
    "Returns a new LOCAL-TIME containing the sum of TIME and SECONDS"
    (adjust-local-time time (offset :sec seconds)))
  
  (defun local-time-compare (time-a time-b)
    "Returns the symbols <, >, or =, describing the relationship between TIME-A and TIME-b."
    (declare (type local-time time-a time-b))
  
negative.code:               year-difference
                (1- year-difference)))))))
  
  (defun local-time- (time-a time-b)
    "Returns the difference between TIME-A and TIME-B in seconds"
    (setf time-a (adjust-local-time time-a (set :timezone (timezone-of time-b))))
    (multiple-value-bind (sec-a day-a)
        (adjust-to-timezone time-a (timezone-of time-b))
      (let ((nsec (- (nsec-of time-a) (nsec-of time-b)))
            (second (- sec-a (sec-of time-b)))
            (day (- day-a (day-of time-b))))
        (when (minusp nsec)
          (decf second)
          (incf nsec 1000000000))
        (when (minusp second)
          (decf day)
          (incf second +seconds-per-day+))
        (encode-duration :nsec nsec :sec second :day day))))
  
  (defun local-time+ (time seconds)
    "Returns a new LOCAL-TIME containing the sum of TIME and SECONDS"
    (adjust-local-time time (offset :sec seconds)))
  
  (defun local-time-day-of-week (local-time)
    (mod (+ 3 (day-of local-time)) 7))
  
  