Add many missing __match_args__ attributes (#7556)

Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
This commit is contained in:
Alex Waygood
2022-03-26 20:36:28 +01:00
committed by GitHub
parent 1192db784c
commit 61b22db692
6 changed files with 166 additions and 3 deletions

View File

@@ -79,6 +79,8 @@ def as_completed(fs: Iterable[Future[_T]], timeout: float | None = ...) -> Itera
# Ideally this would be a namedtuple, but mypy doesn't support generic tuple types. See #1976
class DoneAndNotDoneFutures(Sequence[set[Future[_T]]]):
if sys.version_info >= (3, 10):
__match_args__ = ("done", "not_done")
@property
def done(self) -> set[Future[_T]]: ...
@property