diff --git a/Doc/c-api/intro.rst b/Doc/c-api/intro.rst index 15006100c73..6bb2356f694 100644 --- a/Doc/c-api/intro.rst +++ b/Doc/c-api/intro.rst @@ -234,7 +234,7 @@ duration of the call. However, a common pitfall is to extract an object from a list and hold on to it for a while without incrementing its reference count. Some other operation might conceivably remove the object from the list, decrementing its reference count -and possible deallocating it. The real danger is that innocent-looking +and possibly deallocating it. The real danger is that innocent-looking operations may invoke arbitrary Python code which could do this; there is a code path which allows control to flow back to the user from a :c:func:`Py_DECREF`, so almost any operation is potentially dangerous. diff --git a/Doc/c-api/refcounting.rst b/Doc/c-api/refcounting.rst index 4f512ecdbe9..225a1feb250 100644 --- a/Doc/c-api/refcounting.rst +++ b/Doc/c-api/refcounting.rst @@ -58,8 +58,8 @@ objects. the macro carefully uses a temporary variable and sets the argument to *NULL* before decrementing its reference count. - It is a good idea to use this macro whenever decrementing the value of a - variable that might be traversed during garbage collection. + It is a good idea to use this macro whenever decrementing the reference + count of an object that might be traversed during garbage collection. The following functions are for runtime dynamic embedding of Python: