mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-10-27 23:03:16 +08:00
Fix type for reduce
This commit is contained in:
1 parent
8d8e7caa77
commit
b0c0f94210
1 file changed
+3
-2
@@ -9,8 +9,9 @@ from collections import namedtuple
|
||||
_AnyCallable = Callable[..., Any]
|
||||
|
||||
_T = TypeVar("_T")
|
||||
def reduce(function: Callable[[_T], _T],
|
||||
sequence: Iterator[_T], initial: Optional[_T] = ...) -> _T: ...
|
||||
_S = TypeVar("_S")
|
||||
def reduce(function: Callable[[_T, _S], _T],
|
||||
sequence: Iterator[_S], initial: Optional[_T] = ...) -> _T: ...
|
||||
|
||||
|
||||
class CacheInfo(NamedTuple('CacheInfo', [
|
||||
|
||||
Reference in new issue
Block a user