]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Add PEP 573 additions to What's New (GH-21374)
authorPetr Viktorin <encukou@gmail.com>
Tue, 11 Aug 2020 16:15:57 +0000 (18:15 +0200)
committerGitHub <noreply@github.com>
Tue, 11 Aug 2020 16:15:57 +0000 (18:15 +0200)
Doc/whatsnew/3.9.rst

index db380bc1cdfa4e8eb71585bb6b3ab0a57c9f40f1..be7406e13c2cd44958c590c2b283101e865a8c26 100644 (file)
@@ -1024,6 +1024,13 @@ C API Changes
 New Features
 ------------
 
+* :pep:`573`: Add :c:func:`PyType_FromModuleAndSpec` to associate
+  a module with a class; :c:func:`PyType_GetModule` and
+  :c:func:`PyType_GetModuleState` to retrieve the module and its state; and
+  :c:data:`PyCMethod` and :c:data:`METH_METHOD` to allow a method to
+  access the class it was defined in.
+  (Contributed by Marcel Plch and Petr Viktorin in :issue:`38787`.)
+
 * Add :c:func:`PyFrame_GetCode` function: get a frame code.
   Add :c:func:`PyFrame_GetBack` function: get the frame next outer frame.
   (Contributed by Victor Stinner in :issue:`40421`.)