Make itertools.starmap covariant (#11037)

This commit is contained in:
Alex Waygood
2023-11-29 11:10:26 +00:00
committed by GitHub
parent e7c57b5a6d
commit 09668963a1
2 changed files with 12 additions and 5 deletions

View File

@@ -101,10 +101,10 @@ class islice(Iterator[_T]):
def __iter__(self) -> Self: ...
def __next__(self) -> _T: ...
class starmap(Iterator[_T]):
def __init__(self, __function: Callable[..., _T], __iterable: Iterable[Iterable[Any]]) -> None: ...
class starmap(Iterator[_T_co]):
def __new__(cls, __function: Callable[..., _T], __iterable: Iterable[Iterable[Any]]) -> starmap[_T]: ...
def __iter__(self) -> Self: ...
def __next__(self) -> _T: ...
def __next__(self) -> _T_co: ...
class takewhile(Iterator[_T]):
def __init__(self, __predicate: _Predicate[_T], __iterable: Iterable[_T]) -> None: ...