mirror of
https://github.com/python/cpython.git
synced 2025-07-10 04:45:36 +00:00
Issue #1545463: Global variables caught in reference cycles are now garbage-collected at shutdown.
This commit is contained in:
parent
1df37c657d
commit
5f454a07a0
6 changed files with 56 additions and 5 deletions
|
@ -544,10 +544,6 @@ Py_Finalize(void)
|
|||
while (PyGC_Collect() > 0)
|
||||
/* nothing */;
|
||||
#endif
|
||||
/* We run this while most interpreter state is still alive, so that
|
||||
debug information can be printed out */
|
||||
_PyGC_Fini();
|
||||
|
||||
/* Destroy all modules */
|
||||
PyImport_Cleanup();
|
||||
|
||||
|
@ -628,6 +624,7 @@ Py_Finalize(void)
|
|||
PyFloat_Fini();
|
||||
PyDict_Fini();
|
||||
PySlice_Fini();
|
||||
_PyGC_Fini();
|
||||
|
||||
/* Cleanup Unicode implementation */
|
||||
_PyUnicode_Fini();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue