mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-09 05:24:52 +08:00
@@ -1,4 +1,4 @@
|
||||
from typing import Any, Callable, Generic, Mapping, Type, TypeVar, overload
|
||||
from typing import Any, Callable, Generic, Mapping, TypeVar, overload
|
||||
|
||||
_T = TypeVar("_T")
|
||||
|
||||
@@ -19,9 +19,9 @@ class singledispatchmethod(Generic[_T]):
|
||||
func: Callable[..., _T]
|
||||
def __init__(self, func: Callable[..., _T]) -> None: ...
|
||||
@overload
|
||||
def register(self, cls: Type[Any], method: None = ...) -> Callable[[Callable[..., _T]], Callable[..., _T]]: ...
|
||||
def register(self, cls: type[Any], method: None = ...) -> Callable[[Callable[..., _T]], Callable[..., _T]]: ...
|
||||
@overload
|
||||
def register(self, cls: Callable[..., _T], method: None = ...) -> Callable[..., _T]: ...
|
||||
@overload
|
||||
def register(self, cls: Type[Any], method: Callable[..., _T]) -> Callable[..., _T]: ...
|
||||
def register(self, cls: type[Any], method: Callable[..., _T]) -> Callable[..., _T]: ...
|
||||
def __call__(self, *args: Any, **kwargs: Any) -> _T: ...
|
||||
|
||||
Reference in New Issue
Block a user