mirror of
https://github.com/python/cpython.git
synced 2026-06-05 01:10:53 +00:00
GH-149501: Fix compilation warning in _YIELD_VALUE uop (#149502)
This commit is contained in:
parent
6a0be131c3
commit
1a79fd0ad6
4 changed files with 18 additions and 12 deletions
|
|
@ -1867,8 +1867,9 @@ dummy_func(
|
|||
assert(INLINE_CACHE_ENTRIES_SEND == INLINE_CACHE_ENTRIES_FOR_ITER);
|
||||
#if TIER_ONE && defined(Py_DEBUG)
|
||||
if (!PyStackRef_IsNone(frame->f_executable)) {
|
||||
int i = frame->instr_ptr - _PyFrame_GetBytecode(frame);
|
||||
int opcode = _Py_GetBaseCodeUnit(_PyFrame_GetCode(frame), i).op.code;
|
||||
Py_ssize_t i = frame->instr_ptr - _PyFrame_GetBytecode(frame);
|
||||
assert(i >= 0 && i <= INT_MAX);
|
||||
int opcode = _Py_GetBaseCodeUnit(_PyFrame_GetCode(frame), (int)i).op.code;
|
||||
assert(opcode == SEND || opcode == FOR_ITER);
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
5
Python/executor_cases.c.h
generated
5
Python/executor_cases.c.h
generated
|
|
@ -9346,8 +9346,9 @@
|
|||
assert(INLINE_CACHE_ENTRIES_SEND == INLINE_CACHE_ENTRIES_FOR_ITER);
|
||||
#if TIER_ONE && defined(Py_DEBUG)
|
||||
if (!PyStackRef_IsNone(frame->f_executable)) {
|
||||
int i = frame->instr_ptr - _PyFrame_GetBytecode(frame);
|
||||
int opcode = _Py_GetBaseCodeUnit(_PyFrame_GetCode(frame), i).op.code;
|
||||
Py_ssize_t i = frame->instr_ptr - _PyFrame_GetBytecode(frame);
|
||||
assert(i >= 0 && i <= INT_MAX);
|
||||
int opcode = _Py_GetBaseCodeUnit(_PyFrame_GetCode(frame), (int)i).op.code;
|
||||
assert(opcode == SEND || opcode == FOR_ITER);
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
10
Python/generated_cases.c.h
generated
10
Python/generated_cases.c.h
generated
|
|
@ -7945,8 +7945,9 @@
|
|||
assert(INLINE_CACHE_ENTRIES_SEND == INLINE_CACHE_ENTRIES_FOR_ITER);
|
||||
#if TIER_ONE && defined(Py_DEBUG)
|
||||
if (!PyStackRef_IsNone(frame->f_executable)) {
|
||||
int i = frame->instr_ptr - _PyFrame_GetBytecode(frame);
|
||||
int opcode = _Py_GetBaseCodeUnit(_PyFrame_GetCode(frame), i).op.code;
|
||||
Py_ssize_t i = frame->instr_ptr - _PyFrame_GetBytecode(frame);
|
||||
assert(i >= 0 && i <= INT_MAX);
|
||||
int opcode = _Py_GetBaseCodeUnit(_PyFrame_GetCode(frame), (int)i).op.code;
|
||||
assert(opcode == SEND || opcode == FOR_ITER);
|
||||
}
|
||||
#endif
|
||||
|
|
@ -13053,8 +13054,9 @@
|
|||
assert(INLINE_CACHE_ENTRIES_SEND == INLINE_CACHE_ENTRIES_FOR_ITER);
|
||||
#if TIER_ONE && defined(Py_DEBUG)
|
||||
if (!PyStackRef_IsNone(frame->f_executable)) {
|
||||
int i = frame->instr_ptr - _PyFrame_GetBytecode(frame);
|
||||
int opcode = _Py_GetBaseCodeUnit(_PyFrame_GetCode(frame), i).op.code;
|
||||
Py_ssize_t i = frame->instr_ptr - _PyFrame_GetBytecode(frame);
|
||||
assert(i >= 0 && i <= INT_MAX);
|
||||
int opcode = _Py_GetBaseCodeUnit(_PyFrame_GetCode(frame), (int)i).op.code;
|
||||
assert(opcode == SEND || opcode == FOR_ITER);
|
||||
}
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue