mirror of
https://github.com/python/cpython.git
synced 2026-01-06 15:32:22 +00:00
bpo-45459: C API uses type names rather than structure names (GH-31528)
Thanks to the new pytypedefs.h, it becomes to use type names like PyObject rather like structure names like "struct _object".
This commit is contained in:
parent
ec091bd47e
commit
042f31da55
23 changed files with 69 additions and 75 deletions
|
|
@ -1500,7 +1500,7 @@ _PyDict_GetItemWithError(PyObject *dp, PyObject *kv)
|
|||
}
|
||||
|
||||
PyObject *
|
||||
_PyDict_GetItemIdWithError(PyObject *dp, struct _Py_Identifier *key)
|
||||
_PyDict_GetItemIdWithError(PyObject *dp, _Py_Identifier *key)
|
||||
{
|
||||
PyObject *kv;
|
||||
kv = _PyUnicode_FromId(key); /* borrowed */
|
||||
|
|
@ -3411,7 +3411,7 @@ _PyDict_Contains_KnownHash(PyObject *op, PyObject *key, Py_hash_t hash)
|
|||
}
|
||||
|
||||
int
|
||||
_PyDict_ContainsId(PyObject *op, struct _Py_Identifier *key)
|
||||
_PyDict_ContainsId(PyObject *op, _Py_Identifier *key)
|
||||
{
|
||||
PyObject *kv = _PyUnicode_FromId(key); /* borrowed */
|
||||
if (kv == NULL) {
|
||||
|
|
@ -3589,7 +3589,7 @@ PyDict_GetItemString(PyObject *v, const char *key)
|
|||
}
|
||||
|
||||
int
|
||||
_PyDict_SetItemId(PyObject *v, struct _Py_Identifier *key, PyObject *item)
|
||||
_PyDict_SetItemId(PyObject *v, _Py_Identifier *key, PyObject *item)
|
||||
{
|
||||
PyObject *kv;
|
||||
kv = _PyUnicode_FromId(key); /* borrowed */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue