     source = nil
     determined = nil
     waiters = AtomicOptionalMutableRawPointer(nil)
-    stateid = AtomicInt8(0)
+    deferredState = AtomicInt(.waiting)
   }
 
   /// Initialize with a pre-determined `Outcome`


  public var state: DeferredState {
    return (waiters.load(.acquire) != .determined) ?
      (stateid.load(.relaxed) == 0 ? .waiting : .executing ) :
      (determined!.isValue ? .succeeded : .errored)
  }



  func beginExecution()
  {
    var current = deferredState.load(.relaxed)
    repeat {
      if current & .executing != 0
      { // execution state has already been marked as begun
        return
      }
    } while !deferredState.loadCAS(&current, current | .executing, .weak, .acqrel, .acquire)
  }

  /// Set the `Outcome` of this `Deferred` and dispatch all notifications for execution.
