[Python-checkins] cpython (2.7): note that Py_VISIT handles NULL (closes #27183)

benjamin.peterson python-checkins at python.org
Thu Jun 2 14:36:51 EDT 2016


https://hg.python.org/cpython/rev/42356e44af23
changeset: 101603:42356e44af23
branch: 2.7
parent: 101597:b0b463760b45
user: Benjamin Peterson <benjamin at python.org>
date: Thu Jun 02 11:35:59 2016 -0700
summary:
 note that Py_VISIT handles NULL (closes #27183)
files:
 Doc/c-api/gcsupport.rst | 7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)
diff --git a/Doc/c-api/gcsupport.rst b/Doc/c-api/gcsupport.rst
--- a/Doc/c-api/gcsupport.rst
+++ b/Doc/c-api/gcsupport.rst
@@ -137,9 +137,10 @@
 
 .. c:function:: void Py_VISIT(PyObject *o)
 
- Call the *visit* callback, with arguments *o* and *arg*. If *visit* returns
- a non-zero value, then return it. Using this macro, :c:member:`~PyTypeObject.tp_traverse`
- handlers look like::
+ If *o* is not *NULL*, call the *visit* callback, with arguments *o*
+ and *arg*. If *visit* returns a non-zero value, then return it.
+ Using this macro, :c:member:`~PyTypeObject.tp_traverse` handlers
+ look like::
 
 static int
 my_traverse(Noddy *self, visitproc visit, void *arg)
-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list

AltStyle によって変換されたページ (->オリジナル) /