From: Nathan Goldbaum Date: Tue, 27 Jan 2026 07:15:16 +0000 (-0700) Subject: gh-144257: document return values of PyModule_SetDocString (GH-144258) X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3e9a5b022f01fa95b4485fcf2c0c87bfb9fff837;p=thirdparty%2FPython%2Fcpython.git gh-144257: document return values of PyModule_SetDocString (GH-144258) Co-authored-by: sobolevn --- diff --git a/Doc/c-api/module.rst b/Doc/c-api/module.rst index 431151b841eb..90f55add56bf 100644 --- a/Doc/c-api/module.rst +++ b/Doc/c-api/module.rst @@ -1021,6 +1021,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)