Skip to content

Commit 8cd038a

Browse files
committed
Amend missed case
1 parent 4e3e456 commit 8cd038a

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

Doc/reference/datamodel.rst

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2468,7 +2468,10 @@ The appropriate metaclass for a class definition is determined in two steps:
24682468

24692469
* if no bases and no explicit metaclass are given, then :func:`type` is used
24702470
as candidate;
2471-
* if bases are defined, the metaclass of the first base is used as candidate;
2471+
* if an explicit metaclass is given and it is an instance of :func:`type`,
2472+
then it is used as candidate;
2473+
* if bases are defined but no explicit metaclass, the metaclass of the first
2474+
base is used as candidate;
24722475
* if an explicit metaclass is given and it is *not* an instance of
24732476
:func:`type`, then it is used directly as the metaclass and step 2 is skipped.
24742477

0 commit comments

Comments
 (0)