summaryrefslogtreecommitdiffstats
path: root/Python/optimizer_bytecodes.c
diff options
context:
space:
mode:
authorAN Long <aisk@users.noreply.github.com>2025-09-03 14:42:26 (GMT)
committerGitHub <noreply@github.com>2025-09-03 14:42:26 (GMT)
commit1ff2cbbac85e59ca675cc482b5bbe1aaf1fac5b2 (patch)
treefdb6aa10cf60042d238998c0294bc465c49baa19 /Python/optimizer_bytecodes.c
parent34ed03875a786879fe292fe472142ae0f3da0e80 (diff)
downloadcpython-1ff2cbbac85e59ca675cc482b5bbe1aaf1fac5b2.zip
cpython-1ff2cbbac85e59ca675cc482b5bbe1aaf1fac5b2.tar.gz
cpython-1ff2cbbac85e59ca675cc482b5bbe1aaf1fac5b2.tar.bz2
gh-137136: Suppress build warnings when build on Windows with --experimental-jit-interpreter (GH-137137)
Diffstat (limited to 'Python/optimizer_bytecodes.c')
-rw-r--r--Python/optimizer_bytecodes.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/Python/optimizer_bytecodes.c b/Python/optimizer_bytecodes.c
index 77759f6..781296d 100644
--- a/Python/optimizer_bytecodes.c
+++ b/Python/optimizer_bytecodes.c
@@ -316,7 +316,7 @@ dummy_func(void) {
assert(PyLong_CheckExact(sym_get_const(ctx, sub_st)));
long index = PyLong_AsLong(sym_get_const(ctx, sub_st));
assert(index >= 0);
- int tuple_length = sym_tuple_length(tuple_st);
+ Py_ssize_t tuple_length = sym_tuple_length(tuple_st);
if (tuple_length == -1) {
// Unknown length
res = sym_new_not_null(ctx);
@@ -1166,9 +1166,9 @@ dummy_func(void) {
op(_CALL_LEN, (callable, null, arg -- res)) {
res = sym_new_type(ctx, &PyLong_Type);
- int tuple_length = sym_tuple_length(arg);
+ Py_ssize_t tuple_length = sym_tuple_length(arg);
if (tuple_length >= 0) {
- PyObject *temp = PyLong_FromLong(tuple_length);
+ PyObject *temp = PyLong_FromSsize_t(tuple_length);
if (temp == NULL) {
goto error;
}
@@ -1182,13 +1182,13 @@ dummy_func(void) {
}
op(_GET_LEN, (obj -- obj, len)) {
- int tuple_length = sym_tuple_length(obj);
+ Py_ssize_t tuple_length = sym_tuple_length(obj);
if (tuple_length == -1) {
len = sym_new_type(ctx, &PyLong_Type);
}
else {
assert(tuple_length >= 0);
- PyObject *temp = PyLong_FromLong(tuple_length);
+ PyObject *temp = PyLong_FromSsize_t(tuple_length);
if (temp == NULL) {
goto error;
}