(fut, result)
Helper setting the result only if the future was not cancelled.
Helper setting the result only if the future was not cancelled.
Helper setting the result only if the future was not cancelled .
def _set_result_unless_cancelled(fut, result):
    """Helper setting the result only if the future was not cancelled."""
    if fut.cancelled():
        return
    fut.set_result(result)
def _set_result_unless_cancelled ( fut , result ) : if fut . cancelled ( ) : return fut . set_result ( result )