diff options
author | Xiang Zhang <angwerzx@126.com> | 2017-05-13 05:36:14 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-05-13 05:36:14 (GMT) |
commit | a66f9c6bb134561a24374f10e8c35417d356ce14 (patch) | |
tree | 5a734db23e620a0d0a7703bb1f2b51702fbd951c /Include/object.h | |
parent | 8619c5417ceddb4165c68b9b8aacababd49b0607 (diff) | |
download | cpython-a66f9c6bb134561a24374f10e8c35417d356ce14.zip cpython-a66f9c6bb134561a24374f10e8c35417d356ce14.tar.gz cpython-a66f9c6bb134561a24374f10e8c35417d356ce14.tar.bz2 |
bpo-30341: Improve _PyTrash_thread_destroy_chain() a little bit (#1545)
* add a comment about why we need to increase trash_delete_nesting
* move increase and decrese outside of the loop
Diffstat (limited to 'Include/object.h')
-rw-r--r-- | Include/object.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Include/object.h b/Include/object.h index 63e37b8..f5ed70b 100644 --- a/Include/object.h +++ b/Include/object.h @@ -1029,7 +1029,7 @@ without deallocating anything (and so unbounded call-stack depth is avoided). When the call stack finishes unwinding again, code generated by the END macro notices this, and calls another routine to deallocate all the objects that may have been added to the list of deferred deallocations. In effect, a -chain of N deallocations is broken into N / PyTrash_UNWIND_LEVEL pieces, +chain of N deallocations is broken into (N-1)/(PyTrash_UNWIND_LEVEL-1) pieces, with the call stack never exceeding a depth of PyTrash_UNWIND_LEVEL. */ |