[Python-checkins] bpo-44135: Refine explanation of how passing tuples to issubclass() behaves (GH-26193) (GH-28094)
webhook-mailer at python.org
Tue Aug 31 12:00:25 EDT 2021
author: Łukasz Langa <lukasz at langa.pl>
committer: ambv <lukasz at langa.pl>
bpo-44135: Refine explanation of how passing tuples to issubclass() behaves (GH-26193) (GH-28094)
This is a quasi-backport to 3.9 since the wording in this branch is different.
Co-authored-by: Zachary Kneupper zachary.kneupper at gmail.com
diff --git a/Doc/library/functions.rst b/Doc/library/functions.rst
index c5c1c161293f6..39ce338d38871 100644
@@ -862,8 +862,8 @@ are always available. They are listed here in alphabetical order.
Return ``True`` if *class* is a subclass (direct, indirect or :term:`virtual
<abstract base class>`) of *classinfo*. A
class is considered a subclass of itself. *classinfo* may be a tuple of class
- objects, in which case every entry in *classinfo* will be checked. In any other
- case, a :exc:`TypeError` exception is raised.
+ objects, in which case return ``True`` if *class* is a subclass of any entry
+ in *classinfo*. In any other case, a :exc:`TypeError` exception is raised.
.. function:: iter(object[, sentinel])
More information about the Python-checkins