mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-16 00:37:10 +08:00
Make several type aliases private (#7661)
This commit is contained in:
@@ -20,7 +20,7 @@ _T6 = TypeVar("_T6")
|
||||
|
||||
_Step: TypeAlias = int | float | SupportsFloat | SupportsInt | SupportsIndex | SupportsComplex
|
||||
|
||||
Predicate: TypeAlias = Callable[[_T], object]
|
||||
_Predicate: TypeAlias = Callable[[_T], object]
|
||||
|
||||
# Technically count can take anything that implements a number protocol and has an add method
|
||||
# but we can't enforce the add method
|
||||
@@ -76,12 +76,12 @@ class compress(Iterator[_T], Generic[_T]):
|
||||
def __next__(self) -> _T: ...
|
||||
|
||||
class dropwhile(Iterator[_T], Generic[_T]):
|
||||
def __init__(self, __predicate: Predicate[_T], __iterable: Iterable[_T]) -> None: ...
|
||||
def __init__(self, __predicate: _Predicate[_T], __iterable: Iterable[_T]) -> None: ...
|
||||
def __iter__(self: Self) -> Self: ...
|
||||
def __next__(self) -> _T: ...
|
||||
|
||||
class filterfalse(Iterator[_T], Generic[_T]):
|
||||
def __init__(self, __predicate: Predicate[_T] | None, __iterable: Iterable[_T]) -> None: ...
|
||||
def __init__(self, __predicate: _Predicate[_T] | None, __iterable: Iterable[_T]) -> None: ...
|
||||
def __iter__(self: Self) -> Self: ...
|
||||
def __next__(self) -> _T: ...
|
||||
|
||||
@@ -107,7 +107,7 @@ class starmap(Iterator[_T], Generic[_T]):
|
||||
def __next__(self) -> _T: ...
|
||||
|
||||
class takewhile(Iterator[_T], Generic[_T]):
|
||||
def __init__(self, __predicate: Predicate[_T], __iterable: Iterable[_T]) -> None: ...
|
||||
def __init__(self, __predicate: _Predicate[_T], __iterable: Iterable[_T]) -> None: ...
|
||||
def __iter__(self: Self) -> Self: ...
|
||||
def __next__(self) -> _T: ...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user