anchor.diff:          (slow-status-status %status)
           %status)))
   
  +(defun convert-to-slow-status (future stopping-conditions)
  +  (let (slow)
  +    (loop
  +      (let ((%status (future-%status future)))
  +        (when (slow-status-p %status)
  +          (return))
  +        (when (member %status stopping-conditions)
  +          (return %status))
  +        (unless slow
  +          (setf slow (make-slow-status)))
  +        (setf (slow-status-status slow) %status)
  +        (when (eql (cas (future-%status future) %status slow)
  +                   %status)
  +          (return))))))
  +
   (defun wait (future &rest stopping-conditions)
     (declare (dynamic-extent stopping-conditions))
  -  (loop
  -    (let ((%status (future-%status future)))
  -      (when (slow-status-p %status)
  -        (return))
  -      (when (member %status stopping-conditions)
  -        (return-from wait %status))
  -      (let ((new-status (make-slow-status %status)))
  -        (when (eql (compare-and-swap (future-%status future)
  -                                     %status new-status)
  -                   %status)
  -          (return)))))
  +  (let ((status (convert-to-slow-status future stopping-conditions)))
  +    (when status (return-from wait status)))
     (let* ((slow-status (future-%status future))
            (lock        (slow-status-lock slow-status))
            (cvar        (slow-status-cvar slow-status)))
  
positive.code: (defpackage "FUTURE"
    (:use "CL" "SB-EXT" "SB-THREAD")
    (:export "FUTURE" "TASK-FUTURE" "BULK-FUTURE"
             "DEPENDENTS"
             "STATUS" "WAIT" "CANCEL"
             "MARK-DEPENDENCIES" "MARK-DONE"))
  
  (in-package "FUTURE")
  (deftype status ()
    '(member :frozen :waiting :running :done :cancelled))
  
  (defstruct (slow-status
              (:constructor
                  make-slow-status (&optional (status :frozen))))
    (status :waiting         :type status)
    (lock   (make-mutex)     :type mutex
                             :read-only t)
    (cvar   (make-waitqueue) :type waitqueue
  
negative.code: (defstruct (future
              (:include work-stack:bulk-task)
              (:constructor nil))
    (function     nil :type (or list symbol function) :read-only t)
    (dependents   nil :type (or list (member :done :cancelled)))
    (dependencies nil :type simple-vector    :read-only t)
    (depcount       0 :type word)
    (%status  :orphan :type (or status slow-status)))
  
  (defun dependents (future)
    (let ((dependents (future-dependents future)))
      (and (listp dependents)
           dependents)))
  
  (defun status (future)
    (declare (type future future))
  