mirror of
https://github.com/python/cpython.git
synced 2025-10-10 00:43:41 +00:00
gh-99300: Use Py_NewRef() in Python/ directory (#99302)
Replace Py_INCREF() and Py_XINCREF() with Py_NewRef() and Py_XNewRef() in C files of the Python/ directory.
This commit is contained in:
parent
f883b7f8ee
commit
d8f239d86e
14 changed files with 41 additions and 80 deletions
|
@ -173,8 +173,7 @@ calculate_suggestions(PyObject *dir,
|
|||
suggestion_distance = current_distance;
|
||||
}
|
||||
}
|
||||
Py_XINCREF(suggestion);
|
||||
return suggestion;
|
||||
return Py_XNewRef(suggestion);
|
||||
}
|
||||
|
||||
static PyObject *
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue