mirror of
https://github.com/davidhalter/typeshed.git
synced 2025-12-10 14:01:55 +08:00
Fix 'object.__reduce__' (#6662)
Reverts regressions introduced by #6292. Fixes #6661.
This commit is contained in:
@@ -106,11 +106,13 @@ class object:
|
||||
def __getattribute__(self, __name: str) -> Any: ...
|
||||
def __delattr__(self, __name: str) -> None: ...
|
||||
def __sizeof__(self) -> int: ...
|
||||
def __reduce__(self) -> str | Tuple[object, ...]: ...
|
||||
# return type of pickle methods is rather hard to express in the current type system
|
||||
# see #6661 and https://docs.python.org/3/library/pickle.html#object.__reduce__
|
||||
def __reduce__(self) -> str | Tuple[Any, ...]: ...
|
||||
if sys.version_info >= (3, 8):
|
||||
def __reduce_ex__(self, __protocol: SupportsIndex) -> str | Tuple[object, ...]: ...
|
||||
def __reduce_ex__(self, __protocol: SupportsIndex) -> str | Tuple[Any, ...]: ...
|
||||
else:
|
||||
def __reduce_ex__(self, __protocol: int) -> str | Tuple[object, ...]: ...
|
||||
def __reduce_ex__(self, __protocol: int) -> str | Tuple[Any, ...]: ...
|
||||
def __dir__(self) -> Iterable[str]: ...
|
||||
def __init_subclass__(cls) -> None: ...
|
||||
|
||||
|
||||
Reference in New Issue
Block a user