diff --git a/CHANGELOG.md b/CHANGELOG.md index 78e5a631..b0127865 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,6 +15,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). * [#51](https://github.com/stlehmann/PyQt5-stubs/pull/51) adds `pyqtBoundSignal.signal` hinted as `str` ### Changed +* [#104](https://github.com/stlehmann/PyQt5-stubs/pull/104) `sip.voidptr` handles integer values and sequences and takes `self` * [#103](https://github.com/stlehmann/PyQt5-stubs/pull/103) `pyqtBoundSignal.disconnect()`'s `slot` parameter is optional * [#100](https://github.com/stlehmann/PyQt5-stubs/pull/100) fill generic parameter as `sip.array[int]` for QtDataVisualization textures * [#92](https://github.com/stlehmann/PyQt5-stubs/pull/92) remove self from `qDefaultSurfaceFormat()` and `qIdForNode()` diff --git a/PyQt5-stubs/sip.pyi b/PyQt5-stubs/sip.pyi index 1d19bcad..90a4b9ed 100644 --- a/PyQt5-stubs/sip.pyi +++ b/PyQt5-stubs/sip.pyi @@ -63,7 +63,7 @@ class array(Sequence[_T], Generic[_T]): # The voidptr type. class voidptr: - def __init__(addr: Union[int, Buffer], size: int = -1, writeable: bool = True) -> None: ... + def __init__(self, addr: Union[int, None, bytes, bytearray, 'voidptr'], size: int = -1, writeable: bool = True) -> None: ... def __int__(self) -> int: ... @@ -79,7 +79,7 @@ class voidptr: def __setitem__(self, i: Union[int, slice], v: Buffer) -> None: ... - def asarray(self, size: int = -1) -> array: ... + def asarray(self, size: int = -1) -> array[int]: ... # Python doesn't expose the capsule type. #def ascapsule(self) -> capsule: ...