mirror of https://github.com/python/cpython
When tracing references, reset the type and size of tuples allocated
from the fast free list -- the type (at least) is reset by _Py_Dealloc().
This commit is contained in:
parent
21ef088265
commit
68055ce6fe
|
@ -73,6 +73,10 @@ PyTuple_New(size)
|
|||
free_tuples[size] = (PyTupleObject *) op->ob_item[0];
|
||||
#ifdef COUNT_ALLOCS
|
||||
fast_tuple_allocs++;
|
||||
#endif
|
||||
#ifdef Py_TRACE_REFS
|
||||
op->ob_type = &PyTuple_Type;
|
||||
op->ob_size = size;
|
||||
#endif
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue