@@ -214,10 +214,10 @@ and initialize it by calling :c:func:`PyErr_NewException` in the module's
214214
215215 SpamError = PyErr_NewException("spam.error", NULL, NULL);
216216
217- Since :c:data: `!SpamError ` is a global variable, each call to the
218- :c:data: `Py_mod_exec ` function would overwrite it .
219- For now, let's avoid the issue:
220- we will block repeated initialization by raising an
217+ Since :c:data: `!SpamError ` is a global variable, it will be overwitten every time
218+ the module is reinitialized, when the :c:data: `Py_mod_exec ` function is called .
219+
220+ For now, let's avoid the issue: we will block repeated initialization by raising an
221221:py:exc: `ImportError `::
222222
223223 static PyObject *SpamError = NULL;
@@ -269,8 +269,8 @@ become a dangling pointer. Should it become a dangling pointer, C code which
269269raises the exception could cause a core dump or other unintended side effects.
270270
271271For now, the :c:func: `Py_DECREF ` call to remove this reference is missing.
272- Even when the Python interpreter shuts down, :c:data: `!SpamError ` will not be
273- garbage-collected. It will "leak".
272+ Even when the Python interpreter shuts down, the global :c:data: `!SpamError `
273+ variable will not be garbage-collected. It will "leak".
274274We did, however, ensure that this will happen at most once per process.
275275
276276We discuss the use of :c:macro: `PyMODINIT_FUNC ` as a function return type later in this
0 commit comments