]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-38352: Add to typing.__all__ (GH-25821) (#25884)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Tue, 4 May 2021 09:51:33 +0000 (02:51 -0700)
committerGitHub <noreply@github.com>
Tue, 4 May 2021 09:51:33 +0000 (11:51 +0200)
This adds IO, TextIO, BinaryIO, Match, and Pattern.

Co-authored-by: Ɓukasz Langa <lukasz@langa.pl>
Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
(cherry picked from commit b11557973476963f7c0fd0041eac175bc0d4c514)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Lib/typing.py
Misc/NEWS.d/next/Library/2021-05-02-13-54-25.bpo-38352.N9MlhV.rst [new file with mode: 0644]

index ff964343c5336ac699b154c5ec790132f58eb392..301a47745d837e1d136e1a18a9c2ade884bf5242 100644 (file)
@@ -99,6 +99,13 @@ __all__ = [
     '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 (file)
index 0000000..bf8fe75
--- /dev/null
@@ -0,0 +1,2 @@
+Add ``IO``, ``BinaryIO``, ``TextIO``, ``Match``, and ``Pattern`` to
+``typing.__all__``. Patch by Jelle Zijlstra.