def cancelled(self):
        """Return whether this future was successfully cancelled."""
        return self._state == self.S_EXCEPTION and isinstance(self._result, Cancelled)
def cancelled ( self ) : return self . _state == self . S_EXCEPTION and isinstance ( self . _result , Cancelled )
Return whether this future was successfully cancelled.