diff options
author | Sebastian Rittau <srittau@rittau.biz> | 2018-10-28 16:03:29 (GMT) |
---|---|---|
committer | Ivan Levkivskyi <levkivskyi@gmail.com> | 2018-10-28 16:03:29 (GMT) |
commit | c8a8d6b347d5a6899feb7c810d28f22f3cb151b8 (patch) | |
tree | 19998b77ab7f5b04a531d981359b55a0a1ff36cd /Doc | |
parent | 163eca34c48f1b25e1504e37f4656773fd0fdc78 (diff) | |
download | cpython-c8a8d6b347d5a6899feb7c810d28f22f3cb151b8.zip cpython-c8a8d6b347d5a6899feb7c810d28f22f3cb151b8.tar.gz cpython-c8a8d6b347d5a6899feb7c810d28f22f3cb151b8.tar.bz2 |
bpo-35089: Don't mention typing.io and typing.re (GH-10173)
https://bugs.python.org/issue35089
Diffstat (limited to 'Doc')
-rw-r--r-- | Doc/library/typing.rst | 25 |
1 files changed, 9 insertions, 16 deletions
diff --git a/Doc/library/typing.rst b/Doc/library/typing.rst index 06c1b85..4469e88 100644 --- a/Doc/library/typing.rst +++ b/Doc/library/typing.rst @@ -779,32 +779,25 @@ The module defines the following classes, functions and decorators: .. versionadded:: 3.5.2 -.. class:: io +.. class:: IO + TextIO + BinaryIO - Wrapper namespace for I/O stream types. - - This defines the generic type ``IO[AnyStr]`` and subclasses ``TextIO`` - and ``BinaryIO``, deriving from ``IO[str]`` and ``IO[bytes]``, - respectively. These represent the types of I/O streams such as returned by + Generic type ``IO[AnyStr]`` and its subclasses ``TextIO(IO[str])`` + and ``BinaryIO(IO[bytes])`` + represent the types of I/O streams such as returned by :func:`open`. - These types are also accessible directly as ``typing.IO``, - ``typing.TextIO``, and ``typing.BinaryIO``. - -.. class:: re +.. class:: Pattern + Match - Wrapper namespace for regular expression matching types. - - This defines the type aliases ``Pattern`` and ``Match`` which + These type aliases correspond to the return types from :func:`re.compile` and :func:`re.match`. These types (and the corresponding functions) are generic in ``AnyStr`` and can be made specific by writing ``Pattern[str]``, ``Pattern[bytes]``, ``Match[str]``, or ``Match[bytes]``. - These types are also accessible directly as ``typing.Pattern`` - and ``typing.Match``. - .. class:: NamedTuple Typed version of namedtuple. |