From: Miss Islington (bot) <31488909+miss-islington@users.noreply.github.com> Date: Tue, 27 Jan 2026 07:21:38 +0000 (+0100) Subject: [3.14] gh-144257: document return values of PyModule_SetDocString (GH-144258) (GH... X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7af0d0607d50e53efabb836f551e5e8d7c4510e8;p=thirdparty%2FPython%2Fcpython.git [3.14] gh-144257: document return values of PyModule_SetDocString (GH-144258) (GH-144263) gh-144257: document return values of PyModule_SetDocString (GH-144258) (cherry picked from commit 3e9a5b022f01fa95b4485fcf2c0c87bfb9fff837) Co-authored-by: Nathan Goldbaum Co-authored-by: sobolevn --- diff --git a/Doc/c-api/module.rst b/Doc/c-api/module.rst index 11b488e4e520..eed47c8966c4 100644 --- a/Doc/c-api/module.rst +++ b/Doc/c-api/module.rst @@ -675,6 +675,9 @@ or code that creates modules dynamically. ``PyModuleDef`` (such as when using :ref:`multi-phase-initialization`, ``PyModule_Create``, or ``PyModule_FromDefAndSpec``). + Return ``0`` on success. + Return ``-1`` with an exception set on error. + .. versionadded:: 3.5 .. c:function:: int PyUnstable_Module_SetGIL(PyObject *module, void *gil)