 
   // MARK: Data handling
 
+  private var iptr: UnsafeMutablePointer<Void> = nil
+
   func setPointer<T>(p: UnsafeMutablePointer<T>)
   {
     pointer = UnsafeMutablePointer(p)

        OSSpinLockUnlock(&lock)
        s.svalue = 0
        s.iptr = nil
        s.currentState = ChannelSemaphoreState.Ready.rawValue
        return s
      }



  var pointer: UnsafeMutablePointer<Void> {
    get {
      if currentState == State.Pointer.rawValue ||
         currentState == State.DoubleSelect.rawValue
      { return iptr }
      else
      { return nil }
    }
    set {
      if currentState == State.Pointer.rawValue ||
         currentState == State.DoubleSelect.rawValue
      { iptr = newValue }
      else
      { iptr = nil }
    }
  }


  private var seln: Selection? = nil

  var selection: Selection! {
    get {
      if currentState == State.Select.rawValue ||
         currentState == State.DoubleSelect.rawValue
      { return seln }
      else
      { return nil }
    }
    set {
      if currentState == State.Select.rawValue ||
         currentState == State.DoubleSelect.rawValue
      { seln = newValue }
      else
      { seln = nil }
