From 1a38d360c7dafe726528cf451772ba24ebe2ab6b Mon Sep 17 00:00:00 2001 From: Matthias Kramm Date: Mon, 28 Sep 2015 08:25:41 -0700 Subject: [PATCH] clean up _functools.pyi --- builtins/2.7/_functools.pyi | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/builtins/2.7/_functools.pyi b/builtins/2.7/_functools.pyi index 7f4221e8c..9ac938eff 100644 --- a/builtins/2.7/_functools.pyi +++ b/builtins/2.7/_functools.pyi @@ -1,14 +1,14 @@ """Stub file for the '_functools' module.""" -# This is an autogenerated file. It serves as a starting point -# for a more precise manual annotation of this module. -# Feel free to edit the source below, but remove this header when you do. -from typing import Any, List, Tuple, Dict, Generic - -def reduce(*args, **kwargs) -> Any: - raise TypeError() +from typing import Any, Callable +_T = TypeVar("T") +def reduce(function: Callable[[_T, _T], _T], + sequence: Iterator[_T], initial=Optional[_T]) -> _T: ... class partial(object): - def __reduce__(self) -> tuple: ... - def __setstate__(self, a, b, c, d) -> None: ... + func = ... # type: Callable[..., Any] + args = ... # type: Tuple[Any] + keywords = ... # type: Dict[str, Any] + def __init__(self, func: Callable[..., Any], *args, **kwargs) -> None: ... + def __call__(self, *args, **kwargs) -> Any: ...