mirror of
https://github.com/davidhalter/typeshed.git
synced 2026-08-02 14:10:23 +08:00
Amend annotation for asyncio.Protocol.__slots__ (#14980)
This commit is contained in:
@@ -67,7 +67,7 @@ _StructValue: TypeAlias = struct_pb2.Struct | struct_pb2.ListValue | str | float
|
||||
_StructValueArg: TypeAlias = _StructValue | Mapping[str, _StructValueArg] | Sequence[_StructValueArg]
|
||||
|
||||
class Struct:
|
||||
__slots__: tuple[()] = ()
|
||||
__slots__: tuple[str, ...] = ()
|
||||
def __getitem__(self, key: str) -> _StructValue: ...
|
||||
def __setitem__(self, key: str, value: _StructValueArg) -> None: ...
|
||||
def __delitem__(self, key: str) -> None: ...
|
||||
@@ -81,7 +81,7 @@ class Struct:
|
||||
def update(self, dictionary: SupportsItems[str, _StructValueArg]) -> None: ...
|
||||
|
||||
class ListValue:
|
||||
__slots__: tuple[()] = ()
|
||||
__slots__: tuple[str, ...] = ()
|
||||
def __len__(self) -> int: ...
|
||||
def append(self, value: _StructValue) -> None: ...
|
||||
def extend(self, elem_seq: Iterable[_StructValue]) -> None: ...
|
||||
|
||||
@@ -12,7 +12,7 @@ class DecodeError(Error): ...
|
||||
class EncodeError(Error): ...
|
||||
|
||||
class Message:
|
||||
__slots__: tuple[()] = ()
|
||||
__slots__: tuple[str, ...] = ()
|
||||
DESCRIPTOR: Descriptor | _upb_Descriptor
|
||||
def __deepcopy__(self, memo: Any = None) -> Self: ...
|
||||
def __eq__(self, other_msg): ...
|
||||
|
||||
Reference in New Issue
Block a user