Add apply() and coerce() to 2.7 builtins.

This commit is contained in:
Guido van Rossum
2016-05-12 15:50:41 -07:00
parent 833a81d85e
commit 5c881a6b86

View File

@@ -881,3 +881,8 @@ class file(BinaryIO):
def write(self, data: str) -> None: ...
def writelines(self, data: Iterable[str]) -> None: ...
def truncate(self, pos: int = ...) -> int: ...
# Very old builtins
def apply(func: Callable[..., _T], args: Sequence[Any] = None, kwds: Mapping[str, Any] = None) -> _T: ...
_N = TypeVar('_N', bool, int, float, complex)
def coerce(x: _N, y: _N) -> Tuple[_N, _N]: ...