Fix reference and global dict in spezializing LOAD_GLOBAL

This commit is contained in:
Pablo Galindo Salgado 2025-09-23 16:31:18 +01:00 committed by Dino Viehland
parent 6a911327d0
commit 03a419ac2d

View file

@ -9193,7 +9193,9 @@
if (PyLazyImport_CheckExact(res_o)) {
_PyFrame_SetStackPointer(frame, stack_pointer);
PyObject *l_v = _PyImport_LoadLazyImportTstate(tstate, res_o);
Py_DECREF(res_o);
if(PyDict_SetItem(GLOBALS(), name, l_v) < 0) {
JUMP_TO_LABEL(error);
}
stack_pointer = _PyFrame_GetStackPointer(frame);
res_o = l_v;
_PyFrame_SetStackPointer(frame, stack_pointer);