mirror of
https://github.com/python/cpython.git
synced 2025-08-03 08:34:29 +00:00
GH-115775: Use __static_attributes__
to initialize shared keys (GH-118468)
This commit is contained in:
parent
fe85a8291d
commit
89328f7b12
3 changed files with 18 additions and 3 deletions
|
@ -8334,7 +8334,7 @@ type_ready_managed_dict(PyTypeObject *type)
|
|||
}
|
||||
PyHeapTypeObject* et = (PyHeapTypeObject*)type;
|
||||
if (et->ht_cached_keys == NULL) {
|
||||
et->ht_cached_keys = _PyDict_NewKeysForClass();
|
||||
et->ht_cached_keys = _PyDict_NewKeysForClass(et);
|
||||
if (et->ht_cached_keys == NULL) {
|
||||
PyErr_NoMemory();
|
||||
return -1;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue