itemgetter parameters can be any type that the container accepts, not just int (#564)

This commit is contained in:
Gustavo J. A. M. Carneiro
2016-09-23 13:40:16 +01:00
committed by Matthias Kramm
parent bbf0ac2d1f
commit bda2b54dfc

View File

@@ -161,9 +161,9 @@ def attrgetter(attr: str) -> Callable[[Any], Any]: ...
def attrgetter(*attrs: str) -> Callable[[Any], Tuple[Any, ...]]: ...
@overload
def itemgetter(item: int) -> Callable[[Any], Any]: ...
def itemgetter(item: Any) -> Callable[[Any], Any]: ...
@overload
def itemgetter(*items: int) -> Callable[[Any], Tuple[Any, ...]]: ...
def itemgetter(*items: Any) -> Callable[[Any], Tuple[Any, ...]]: ...
def methodcaller(name: str, *args: Any, **kwargs: Any) -> Callable[..., Any]: ...