typeshed icon indicating copy to clipboard operation
typeshed copied to clipboard

ctypes errcheck type is wrong

Open socketpair opened this issue 3 years ago • 0 comments

now: _ECT = Callable[[Optional[Type[_CData]], _FuncPointer, Tuple[_CData, ...]], _CData]

should be: _ECT = Callable[[Optional[_CData], _FuncPointer, Tuple[_CData, ...]], _CData]

Because, at least, the return type of this function must be the same as the first argument. And it should be an instance like c_int.

socketpair avatar Jun 05 '21 20:06 socketpair