From 4eea13b60f83b978339991f7a26b56da7db1ae1d Mon Sep 17 00:00:00 2001 From: Alex Waygood Date: Fri, 12 Nov 2021 11:05:21 +0000 Subject: [PATCH] Add ``__call__`` to ``staticmethod`` (#6275) --- stdlib/builtins.pyi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/stdlib/builtins.pyi b/stdlib/builtins.pyi index 4a7546767..f40094694 100644 --- a/stdlib/builtins.pyi +++ b/stdlib/builtins.pyi @@ -121,6 +121,8 @@ class staticmethod(object): # Special, only valid as a decorator. def __init__(self, __f: Callable[..., Any]) -> None: ... def __new__(cls: Type[_T], *args: Any, **kwargs: Any) -> _T: ... def __get__(self, __obj: _T, __type: Type[_T] | None = ...) -> Callable[..., Any]: ... + if sys.version_info >= (3, 10): + def __call__(self, *args: Any, **kwargs: Any) -> Any: ... class classmethod(object): # Special, only valid as a decorator. __func__: Callable[..., Any]