File tree Expand file tree Collapse file tree 2 files changed +7
-0
lines changed
Expand file tree Collapse file tree 2 files changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -274,6 +274,10 @@ Type Objects
274274 Return the module object associated with the given type when the type was
275275 created using :c:func: `PyType_FromModuleAndSpec `.
276276
277+ The returned reference is :term: `borrowed <borrowed reference> ` from *type *,
278+ and will be valid as long as you hold a reference to *type *.
279+ Do not release it with :c:func: `Py_DECREF ` or similar.
280+
277281 If no module is associated with the given type, sets :py:class: `TypeError `
278282 and returns ``NULL ``.
279283
Original file line number Diff line number Diff line change @@ -2427,6 +2427,9 @@ PyType_GetFlags:PyTypeObject*:type:0:
24272427PyType_GetName:PyObject*::+1:
24282428PyType_GetName:PyTypeObject*:type:0:
24292429
2430+ PyType_GetModule:PyObject*::0:
2431+ PyType_GetModule:PyTypeObject*:type:0:
2432+
24302433PyType_GetModuleByToken:PyObject*::+1:
24312434PyType_GetModuleByToken:PyTypeObject*:type:0:
24322435PyType_GetModuleByToken:PyModuleDef*:def::
You can’t perform that action at this time.
0 commit comments