[Python-checkins] bpo-38352: Add to typing.__all__ (GH-25821) (#25884)
ambv
webhook-mailer at python.org
Tue May 4 05:51:46 EDT 2021
https://github.com/python/cpython/commit/e1bcc88a502aa0239b6bcc4da3fe024307fd27f4
commit: e1bcc88a502aa0239b6bcc4da3fe024307fd27f4
branch: 3.10
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: ambv <lukasz at langa.pl>
date: 2021-05-04T11:51:33+02:00
summary:
bpo-38352: Add to typing.__all__ (GH-25821) (#25884)
This adds IO, TextIO, BinaryIO, Match, and Pattern.
Co-authored-by: Łukasz Langa <lukasz at langa.pl>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner at users.noreply.github.com>
(cherry picked from commit b11557973476963f7c0fd0041eac175bc0d4c514)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra at gmail.com>
files:
A Misc/NEWS.d/next/Library/2021-05-02-13-54-25.bpo-38352.N9MlhV.rst
M Lib/typing.py
diff --git a/Lib/typing.py b/Lib/typing.py
index ff964343c5336..301a47745d837 100644
--- a/Lib/typing.py
+++ b/Lib/typing.py
@@ -99,6 +99,13 @@
'NamedTuple', # Not really a type.
'TypedDict', # Not really a type.
'Generator',
+
+ # Other concrete types.
+ 'BinaryIO',
+ 'IO',
+ 'Match',
+ 'Pattern',
+ 'TextIO',
# One-off things.
'AnyStr',
diff --git a/Misc/NEWS.d/next/Library/2021-05-02-13-54-25.bpo-38352.N9MlhV.rst b/Misc/NEWS.d/next/Library/2021-05-02-13-54-25.bpo-38352.N9MlhV.rst
new file mode 100644
index 0000000000000..bf8fe758f3570
--- /dev/null
+++ b/Misc/NEWS.d/next/Library/2021-05-02-13-54-25.bpo-38352.N9MlhV.rst
@@ -0,0 +1,2 @@
+Add ``IO``, ``BinaryIO``, ``TextIO``, ``Match``, and ``Pattern`` to
+``typing.__all__``. Patch by Jelle Zijlstra.
More information about the Python-checkins
mailing list