We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 143dd0f commit a12c0e1Copy full SHA for a12c0e1
Python/specialize.c
@@ -644,12 +644,16 @@ specialize_dict_access_hint(
644
SPECIALIZATION_FAIL(base_op, SPEC_FAIL_ATTR_SPLIT_DICT);
645
return 0;
646
}
647
+#ifdef PY_GIL_DISABLED
648
PyObject *value;
649
Py_ssize_t index = _PyDict_LookupIndexAndValue(dict, name, &value);
650
if (value != NULL && PyLazyImport_CheckExact(value)) {
651
SPECIALIZATION_FAIL(base_op, SPEC_FAIL_ATTR_MODULE_LAZY_VALUE);
652
653
654
+#else
655
+ Py_ssize_t index = _PyDict_LookupIndex(dict, name);
656
+#endif
657
if (index != (uint16_t)index) {
658
SPECIALIZATION_FAIL(base_op,
659
index == DKIX_EMPTY ?
0 commit comments