Fix the signature of IOBase._checkClosed(). (#3305)

* In Python 2, the optional `msg` argument was missing.
* In Python 3, the method was missing altogether.

Reference:
https://github.com/python/cpython/blob/2.7/Lib/_pyio.py#L423
https://github.com/python/cpython/blob/3.6/Lib/_pyio.py#L443
This commit is contained in:
Rebecca Chen
2019-10-04 14:53:48 -07:00
committed by GitHub
parent 0a426d8a8e
commit 90aa27b54a
2 changed files with 2 additions and 1 deletions

View File

@@ -45,6 +45,7 @@ class IOBase:
def __del__(self) -> None: ...
@property
def closed(self) -> bool: ...
def _checkClosed(self, msg: Optional[str] = ...) -> None: ... # undocumented
class RawIOBase(IOBase):
def readall(self) -> bytes: ...