Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e8b7eb0

Browse files
committed
Link isinstance/issubclass to the ABC glossary entry (#12256)
1 parent 543edbd commit e8b7eb0

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

Doc/library/functions.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -624,7 +624,8 @@ are always available. They are listed here in alphabetical order.
624624
.. function:: isinstance(object, classinfo)
625625

626626
Return true if the *object* argument is an instance of the *classinfo*
627-
argument, or of a (direct or indirect) subclass thereof. If *object* is not
627+
argument, or of a (direct, indirect or :term:`virtual <abstract base
628+
class>`) subclass thereof. If *object* is not
628629
an object of the given type, the function always returns false. If
629630
*classinfo* is not a class (type object), it may be a tuple of type objects,
630631
or may recursively contain other such tuples (other sequence types are not
@@ -634,7 +635,8 @@ are always available. They are listed here in alphabetical order.
634635

635636
.. function:: issubclass(class, classinfo)
636637

637-
Return true if *class* is a subclass (direct or indirect) of *classinfo*. A
638+
Return true if *class* is a subclass (direct, indirect or :term:`virtual
639+
<abstract base class>`) of *classinfo*. A
638640
class is considered a subclass of itself. *classinfo* may be a tuple of class
639641
objects, in which case every entry in *classinfo* will be checked. In any other
640642
case, a :exc:`TypeError` exception is raised.

0 commit comments

Comments
 (0)