Skip to content

Commit a679b50

Browse files
Update Objects/tupleobject.c
Co-authored-by: Victor Stinner <[email protected]>
1 parent 0d7eff1 commit a679b50

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Objects/tupleobject.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -159,8 +159,8 @@ _PyTuple_MaybeUntrack(PyObject *op)
159159
static bool
160160
tuple_need_tracking(PyTupleObject *t)
161161
{
162-
Py_ssize_t i = 0, n = Py_SIZE(t);
163-
for (; i < n; i++) {
162+
Py_ssize_t n = PyTuple_GET_SIZE(t);
163+
for (Py_ssize_t i = 0; i < n; i++) {
164164
PyObject *elt = PyTuple_GET_ITEM(t, i);
165165
/* Tuple with NULL elements aren't
166166
fully constructed, we should track them. */

0 commit comments

Comments
 (0)