summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
authorNikita Sobolev <mail@sobolevn.me>2023-10-27 11:37:59 (GMT)
committerGitHub <noreply@github.com>2023-10-27 11:37:59 (GMT)
commit524a701d0742d2ae469771a065c62e41656a5dc7 (patch)
tree1d03c787993495164dce6a8b82632ccfa39c0b10 /Python
parentaa732459c5a69435f13a2730a057ce9d2087873b (diff)
downloadcpython-524a701d0742d2ae469771a065c62e41656a5dc7.zip
cpython-524a701d0742d2ae469771a065c62e41656a5dc7.tar.gz
cpython-524a701d0742d2ae469771a065c62e41656a5dc7.tar.bz2
gh-111386: Fix `uint32_t` cast in `generated_cases.c.h` (#111387)
Diffstat (limited to 'Python')
-rw-r--r--Python/bytecodes.c2
-rw-r--r--Python/generated_cases.c.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/Python/bytecodes.c b/Python/bytecodes.c
index 2d7b5ba..5b1d70b 100644
--- a/Python/bytecodes.c
+++ b/Python/bytecodes.c
@@ -2686,7 +2686,7 @@ dummy_func(
assert(next_instr[oparg].op.code == END_FOR ||
next_instr[oparg].op.code == INSTRUMENTED_END_FOR);
assert(1 + INLINE_CACHE_ENTRIES_FOR_ITER == next_instr - frame->instr_ptr);
- frame->return_offset = 1 + INLINE_CACHE_ENTRIES_FOR_ITER + oparg;
+ frame->return_offset = (uint16_t)(1 + INLINE_CACHE_ENTRIES_FOR_ITER + oparg);
DISPATCH_INLINED(gen_frame);
}
diff --git a/Python/generated_cases.c.h b/Python/generated_cases.c.h
index d5e0d84..fb4506e 100644
--- a/Python/generated_cases.c.h
+++ b/Python/generated_cases.c.h
@@ -3440,7 +3440,7 @@
assert(next_instr[oparg].op.code == END_FOR ||
next_instr[oparg].op.code == INSTRUMENTED_END_FOR);
assert(1 + INLINE_CACHE_ENTRIES_FOR_ITER == next_instr - frame->instr_ptr);
- frame->return_offset = 1 + INLINE_CACHE_ENTRIES_FOR_ITER + oparg;
+ frame->return_offset = (uint16_t)(1 + INLINE_CACHE_ENTRIES_FOR_ITER + oparg);
DISPATCH_INLINED(gen_frame);
}