mirror of
https://github.com/python/cpython.git
synced 2025-08-22 17:55:18 +00:00
gh-99300: Use Py_NewRef() in Modules/ directory (#99468)
Replace Py_INCREF() and Py_XINCREF() with Py_NewRef() and Py_XNewRef() in test C files of the Modules/ directory.
This commit is contained in:
parent
9a7e9f9921
commit
c340cbb7f7
10 changed files with 92 additions and 173 deletions
|
@ -23,8 +23,7 @@ static PyObject *
|
|||
_typing__idfunc(PyObject *module, PyObject *x)
|
||||
/*[clinic end generated code: output=63c38be4a6ec5f2c input=49f17284b43de451]*/
|
||||
{
|
||||
Py_INCREF(x);
|
||||
return x;
|
||||
return Py_NewRef(x);
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue