diff options
author | Ken Jin <kenjin4096@gmail.com> | 2022-06-07 10:32:42 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-06-07 10:32:42 (GMT) |
commit | 75260925ecae690434ed2c5502761f1f0bce11eb (patch) | |
tree | a43e537f8a228c568127228c0de0e1036c2b3737 /Python/ceval.c | |
parent | f012df706cf3a9e63625b8166fe3f419855e9a94 (diff) | |
download | cpython-75260925ecae690434ed2c5502761f1f0bce11eb.zip cpython-75260925ecae690434ed2c5502761f1f0bce11eb.tar.gz cpython-75260925ecae690434ed2c5502761f1f0bce11eb.tar.bz2 |
Fix MSVC compiler warnings in ceval.c (#93569)
Diffstat (limited to 'Python/ceval.c')
-rw-r--r-- | Python/ceval.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Python/ceval.c b/Python/ceval.c index d1480ac..0e81863 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -4581,7 +4581,7 @@ handle_eval_breaker: DEOPT_IF(self_cls->tp_version_tag != read_u32(cache->type_version), LOAD_METHOD); /* Treat index as a signed 16 bit value */ - int dictoffset = self_cls->tp_dictoffset; + Py_ssize_t dictoffset = self_cls->tp_dictoffset; assert(dictoffset > 0); PyDictObject **dictptr = (PyDictObject**)(((char *)self)+dictoffset); PyDictObject *dict = *dictptr; @@ -4625,7 +4625,7 @@ handle_eval_breaker: _PyLoadMethodCache *cache = (_PyLoadMethodCache *)next_instr; uint32_t type_version = read_u32(cache->type_version); DEOPT_IF(self_cls->tp_version_tag != type_version, LOAD_METHOD); - int dictoffset = self_cls->tp_dictoffset; + Py_ssize_t dictoffset = self_cls->tp_dictoffset; assert(dictoffset > 0); PyObject *dict = *(PyObject **)((char *)self + dictoffset); /* This object has a __dict__, just not yet created */ |