]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-140550: allow slots that repeat information from PyModuleDef (GH-144340)
authorPetr Viktorin <encukou@gmail.com>
Mon, 9 Feb 2026 10:35:43 +0000 (11:35 +0100)
committerGitHub <noreply@github.com>
Mon, 9 Feb 2026 10:35:43 +0000 (11:35 +0100)
commitb22ff1e543a458fff7b11225bf743d1730bbcc71
tree2d51dc676ac591e070bea550374eccf8f1287082
parent432ddd99e2b06a75a4f47bd99c0fd0c911bdb19c
gh-140550: allow slots that repeat information from PyModuleDef (GH-144340)

When integrating slots-based module creation is with the inittab,
which currently requires PyModuleDef, it would be convenient to
reuse the the same slots array for the MethodDef.

Allow slots that match what's already present in the PyModuleDef.
Doc/c-api/module.rst
Lib/test/test_capi/test_module.py
Misc/NEWS.d/next/Core_and_Builtins/2026-01-30-10-38-07.gh-issue-140550.Us9vPD.rst [new file with mode: 0644]
Modules/_testcapi/module.c
Objects/moduleobject.c