Skip to content

Commit 81d968b

Browse files
bpo-46831: Update __build_class__ comment (#31522)
Co-authored-by: Jelle Zijlstra <[email protected]>
1 parent 3241cba commit 81d968b

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

Python/compile.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2604,9 +2604,8 @@ compiler_class(struct compiler *c, stmt_ty s)
26042604
/* ultimately generate code for:
26052605
<name> = __build_class__(<func>, <name>, *<bases>, **<keywords>)
26062606
where:
2607-
<func> is a function/closure created from the class body;
2608-
it has a single argument (__locals__) where the dict
2609-
(or MutableSequence) representing the locals is passed
2607+
<func> is a zero arg function/closure created from the class body.
2608+
It mutates its locals to build the class namespace.
26102609
<name> is the class name
26112610
<bases> is the positional arguments and *varargs argument
26122611
<keywords> is the keyword arguments and **kwds argument

0 commit comments

Comments
 (0)