Skip to content

Commit b01e7aa

Browse files
authored
Remove old compatibility alias _BufferWithLen (#14151)
1 parent ea39b36 commit b01e7aa

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

stdlib/_typeshed/__init__.pyi

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -298,9 +298,6 @@ class SupportsGetItemBuffer(SliceableBuffer, IndexableBuffer, Protocol):
298298

299299
class SizedBuffer(Sized, Buffer, Protocol): ...
300300

301-
# for compatibility with third-party stubs that may use this
302-
_BufferWithLen: TypeAlias = SizedBuffer # not stable # noqa: Y047
303-
304301
ExcInfo: TypeAlias = tuple[type[BaseException], BaseException, TracebackType]
305302
OptExcInfo: TypeAlias = ExcInfo | tuple[None, None, None]
306303

stubs/python-xlib/Xlib/protocol/display.pyi

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
from _typeshed import _BufferWithLen
1+
from _typeshed import SizedBuffer
22
from socket import socket
33
from typing import Literal, TypeVar, overload
44

@@ -16,7 +16,7 @@ class bytesview:
1616
@overload
1717
def __init__(self, data: bytes | bytesview, offset: int, size: int) -> None: ...
1818
@overload
19-
def __init__(self, data: _BufferWithLen, offset: int = 0, size: int | None = None) -> None: ...
19+
def __init__(self, data: SizedBuffer, offset: int = 0, size: int | None = None) -> None: ...
2020
@overload
2121
def __getitem__(self, key: slice) -> bytes: ...
2222
@overload

0 commit comments

Comments
 (0)