Skip to content

Commit

Permalink
Add py3.7 support to Future.add_done_callback (python#2970)
Browse files Browse the repository at this point in the history
  • Loading branch information
mvismonte authored and JelleZijlstra committed May 7, 2019
1 parent 53d4610 commit a193aac
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion stdlib/3/asyncio/futures.pyi
Original file line number Diff line number Diff line change
Expand Up @@ -41,16 +41,17 @@ class Future(Awaitable[_T], Iterable[_T]):
if sys.version_info >= (3, 7):
def get_loop(self) -> AbstractEventLoop: ...
def _callbacks(self: _S) -> List[Tuple[Callable[[_S], Any], Context]]: ...
def add_done_callback(self: _S, __fn: Callable[[_S], Any], *, context: Optional[Context] = ...) -> None: ...
else:
@property
def _callbacks(self: _S) -> List[Callable[[_S], Any]]: ...
def add_done_callback(self: _S, __fn: Callable[[_S], Any]) -> None: ...
def cancel(self) -> bool: ...
def _schedule_callbacks(self) -> None: ...
def cancelled(self) -> bool: ...
def done(self) -> bool: ...
def result(self) -> _T: ...
def exception(self) -> BaseException: ...
def add_done_callback(self: _S, fn: Callable[[_S], Any]) -> None: ...
def remove_done_callback(self: _S, fn: Callable[[_S], Any]) -> int: ...
def set_result(self, result: _T) -> None: ...
def set_exception(self, exception: Union[type, BaseException]) -> None: ...
Expand Down

0 comments on commit a193aac

Please sign in to comment.