 
   public func beginExecution()
   {
-    var current = CAtomicsLoad(deferredState, .relaxed)
+    var state = CAtomicsLoad(deferredState, .relaxed)
     repeat {
-      guard current.tag == .waiting else { return }
+      guard state.tag == .waiting else { return }
       // execution state has not yet been marked as begun
 
       // read-modify-write `deferredState` with memory_order_release.
       // this means that this write is in the release sequence of all previous writes.
       // a subsequent read-from `deferredState` will therefore synchronize-with all previous writes.
       // this matters for the `resolve(_:)` function, which operates on the queue of `Waiter` instances.
-    } while !CAtomicsCompareAndExchange(deferredState, &current, .executing, .weak, .release, .relaxed)
-
-    if let taskp = deferredTask(from: current)
+    } while !CAtomicsCompareAndExchange(deferredState, &state, .executing, .weak, .release, .relaxed)
+
+    if let taskp = deferredTask(from: state)
     { // we need to execute the task
       self.queue.async {
         [self] in

  @discardableResult
  fileprivate func resolve(_ result: Result<Success, Failure>) -> Bool
  {
    var current = CAtomicsLoad(deferredState, .relaxed)
    guard current.tag != .resolved else { return false }

    let resolved = UnsafeMutablePointer<Result<Success, Failure>>.allocate(capacity: 1)
    resolved.initialize(to: result)

    let final = Int(resolved, tag: .resolved)
    current = CAtomicsLoad(deferredState, .relaxed)
    repeat {
      if current.tag == .resolved
      {
        resolved.deinitialize(count: 1)
        resolved.deallocate()

  private func deferredTask(from state: Int) -> UnsafeMutablePointer<DeferredTask<Success, Failure>>?
  {
    guard state.tag == .waiting else { return nil }
    return state.ptr?.assumingMemoryBound(to: DeferredTask<Success, Failure>.self)
  }

  /// Get a pointer to a `Result` for a resolved `Deferred`.
