mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-10-16 11:01:27 +08:00
Improved definition of divmod function in builtins (#5114)
Co-authored-by: Eric Traut <erictr@microsoft.com>
This commit is contained in:
1 parent
30fc2b8cd0
commit
29c3d67626
2 files changed
+13
-4
No files matched your search
@@ -31,6 +31,12 @@ class SupportsLessThan(Protocol):
|
||||
|
||||
SupportsLessThanT = TypeVar("SupportsLessThanT", bound=SupportsLessThan) # noqa: Y001
|
||||
|
||||
class SupportsDivMod(Protocol[_T_contra, _T_co]):
|
||||
def __divmod__(self, __other: _T_contra) -> _T_co: ...
|
||||
|
||||
class SupportsRDivMod(Protocol[_T_contra, _T_co]):
|
||||
def __rdivmod__(self, __other: _T_contra) -> _T_co: ...
|
||||
|
||||
# Mapping-like protocols
|
||||
|
||||
class SupportsItems(Protocol[_KT_co, _VT_co]):
|
||||
|
||||
Reference in new issue
Block a user