diff options
author | Shantanu <12621235+hauntsaninja@users.noreply.github.com> | 2022-03-03 05:32:57 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-03 05:32:57 (GMT) |
commit | 81d968b7c30d5b41f3f28b297b7ee5345d569509 (patch) | |
tree | 0e0f8e7b34fe59c76e1d0b72fbae966569fe6145 | |
parent | 3241cba4ec55ef0b9e73bf7a5a77ef29ae4b8756 (diff) | |
download | cpython-81d968b7c30d5b41f3f28b297b7ee5345d569509.zip cpython-81d968b7c30d5b41f3f28b297b7ee5345d569509.tar.gz cpython-81d968b7c30d5b41f3f28b297b7ee5345d569509.tar.bz2 |
bpo-46831: Update __build_class__ comment (#31522)
Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
-rw-r--r-- | Python/compile.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Python/compile.c b/Python/compile.c index 3609ff8..14595d9 100644 --- a/Python/compile.c +++ b/Python/compile.c @@ -2604,9 +2604,8 @@ compiler_class(struct compiler *c, stmt_ty s) /* ultimately generate code for: <name> = __build_class__(<func>, <name>, *<bases>, **<keywords>) where: - <func> is a function/closure created from the class body; - it has a single argument (__locals__) where the dict - (or MutableSequence) representing the locals is passed + <func> is a zero arg function/closure created from the class body. + It mutates its locals to build the class namespace. <name> is the class name <bases> is the positional arguments and *varargs argument <keywords> is the keyword arguments and **kwds argument |