Skip to content

Commit a4be3bc

Browse files
authored
gh-133258: Fix crash in test_index (GH-133262)
1 parent d10bd81 commit a4be3bc

File tree

5 files changed

+30
-30
lines changed

5 files changed

+30
-30
lines changed

Include/internal/pycore_opcode_metadata.h

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Include/internal/pycore_uop_metadata.h

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Python/bytecodes.c

+2-3
Original file line numberDiff line numberDiff line change
@@ -916,11 +916,10 @@ dummy_func(
916916
assert(PyList_CheckExact(list));
917917

918918
PyObject *res_o = _PyList_SliceSubscript(list, sub);
919-
DEOPT_IF(res_o == NULL);
920-
STAT_INC(BINARY_OP, hit);
921-
res = PyStackRef_FromPyObjectSteal(res_o);
922919
STAT_INC(BINARY_OP, hit);
923920
DECREF_INPUTS();
921+
ERROR_IF(res_o == NULL);
922+
res = PyStackRef_FromPyObjectSteal(res_o);
924923
}
925924

926925
macro(BINARY_OP_SUBSCR_STR_INT) =

Python/executor_cases.c.h

+13-12
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Python/generated_cases.c.h

+13-13
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)