[Python-checkins] bpo-39973: Fix the docs for PyObject_GenericSetDict() (GH-19026)

Miss Islington (bot) webhook-mailer at python.org
Tue Mar 17 04:25:55 EDT 2020


https://github.com/python/cpython/commit/4e3a7f9205112e7da1032aa802edf84379b134fc
commit: 4e3a7f9205112e7da1032aa802edf84379b134fc
branch: 3.7
author: Miss Islington (bot) <31488909+miss-islington at users.noreply.github.com>
committer: GitHub <noreply at github.com>
date: 2020-03-17T01:25:50-07:00
summary:

bpo-39973: Fix the docs for PyObject_GenericSetDict() (GH-19026)


PyObject_GenericSetDict() takes three arguments, not two.
(cherry picked from commit a45b695b9fcfbbb0a087222abc5c8d691a7d2770)

Co-authored-by: Zackery Spytz <zspytz at gmail.com>

files:
M Doc/c-api/object.rst
M Doc/data/refcounts.dat

diff --git a/Doc/c-api/object.rst b/Doc/c-api/object.rst
index d81dc938e4f96..179efc4286f86 100644
--- a/Doc/c-api/object.rst
+++ b/Doc/c-api/object.rst
@@ -128,7 +128,7 @@ Object Protocol
    .. versionadded:: 3.3
 
 
-.. c:function:: int PyObject_GenericSetDict(PyObject *o, void *context)
+.. c:function:: int PyObject_GenericSetDict(PyObject *o, PyObject *value, void *context)
 
    A generic implementation for the setter of a ``__dict__`` descriptor. This
    implementation does not allow the dictionary to be deleted.
diff --git a/Doc/data/refcounts.dat b/Doc/data/refcounts.dat
index ec8094ef24863..39061e2c26f56 100644
--- a/Doc/data/refcounts.dat
+++ b/Doc/data/refcounts.dat
@@ -1655,7 +1655,8 @@ PyObject_GenericSetAttr:PyObject*:name:0:
 PyObject_GenericSetAttr:PyObject*:value:+1:
 
 PyObject_GenericSetDict:int:::
-PyObject_GenericSetDict:PyObject*:o:+1:
+PyObject_GenericSetDict:PyObject*:o:0:
+PyObject_GenericSetDict:PyObject*:value:+1:
 PyObject_GenericSetDict:void*:context::
 
 PyObject_GetAttr:PyObject*::+1:



More information about the Python-checkins mailing list