diff options
author | Yurii Karabas <1998uriyyo@gmail.com> | 2022-04-28 15:24:19 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-28 15:24:19 (GMT) |
commit | 0ef8d921f5c6945aa8f386e472c4110b81ac773d (patch) | |
tree | 4c06fd7aa389289ccf3404fec29402f891d3ab91 /Doc/library | |
parent | 4ed3900041c688a02dca1eb3323083d720dd0d93 (diff) | |
download | cpython-0ef8d921f5c6945aa8f386e472c4110b81ac773d.zip cpython-0ef8d921f5c6945aa8f386e472c4110b81ac773d.tar.gz cpython-0ef8d921f5c6945aa8f386e472c4110b81ac773d.tar.bz2 |
gh-91603: Speed up isinstance/issubclass on union types (GH-91631)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
Co-authored-by: Shantanu <12621235+hauntsaninja@users.noreply.github.com>
Diffstat (limited to 'Doc/library')
-rw-r--r-- | Doc/library/functions.rst | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Doc/library/functions.rst b/Doc/library/functions.rst index f3b8e40..3942814 100644 --- a/Doc/library/functions.rst +++ b/Doc/library/functions.rst @@ -905,7 +905,8 @@ are always available. They are listed here in alphabetical order. tuples) or a :ref:`types-union` of multiple types, return ``True`` if *object* is an instance of any of the types. If *classinfo* is not a type or tuple of types and such tuples, - a :exc:`TypeError` exception is raised. + a :exc:`TypeError` exception is raised. :exc:`TypeError` may not be + raised for an invalid type if an earlier check succeeds. .. versionchanged:: 3.10 *classinfo* can be a :ref:`types-union`. |