diff options
author | Kumar Aditya <59607654+kumaraditya303@users.noreply.github.com> | 2022-06-12 16:38:18 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-12 16:38:18 (GMT) |
commit | 93310879665368445f95df2f3d9be7fb82435248 (patch) | |
tree | e9ae1523092021d4979ef93ac77e9f83eb15e87d /Objects | |
parent | ae1ca74513e792b09c8057a87aa28715b5c9f50b (diff) | |
download | cpython-93310879665368445f95df2f3d9be7fb82435248.zip cpython-93310879665368445f95df2f3d9be7fb82435248.tar.gz cpython-93310879665368445f95df2f3d9be7fb82435248.tar.bz2 |
GH-90699: use statically allocated strings in typeobject.c (gh-93751)
Diffstat (limited to 'Objects')
-rw-r--r-- | Objects/typeobject.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Objects/typeobject.c b/Objects/typeobject.c index 18094bd..c6df50d 100644 --- a/Objects/typeobject.c +++ b/Objects/typeobject.c @@ -3637,13 +3637,13 @@ PyType_FromMetaclass(PyTypeObject *metaclass, PyObject *module, if (weaklistoffset) { type->tp_weaklistoffset = weaklistoffset; - if (PyDict_DelItemString((PyObject *)type->tp_dict, "__weaklistoffset__") < 0) { + if (PyDict_DelItem((PyObject *)type->tp_dict, &_Py_ID(__weaklistoffset__)) < 0) { goto finally; } } if (dictoffset) { type->tp_dictoffset = dictoffset; - if (PyDict_DelItemString((PyObject *)type->tp_dict, "__dictoffset__") < 0) { + if (PyDict_DelItem((PyObject *)type->tp_dict, &_Py_ID(__dictoffset__)) < 0) { goto finally; } } |