diff options
author | Christian Heimes <christian@cheimes.de> | 2008-01-27 23:34:59 (GMT) |
---|---|---|
committer | Christian Heimes <christian@cheimes.de> | 2008-01-27 23:34:59 (GMT) |
commit | 908caac52e8e62baa1ee54e4e650e1cd3ac37907 (patch) | |
tree | 291efd46f16d74de6e49bba69f785883c6cdfcc1 /Python/pythonrun.c | |
parent | 3ea7b41b5805c60a05e697211d0bfc14a62a19fb (diff) | |
download | cpython-908caac52e8e62baa1ee54e4e650e1cd3ac37907.zip cpython-908caac52e8e62baa1ee54e4e650e1cd3ac37907.tar.gz cpython-908caac52e8e62baa1ee54e4e650e1cd3ac37907.tar.bz2 |
Added clear cache methods to clear the internal type lookup cache for ref leak test runs.
Diffstat (limited to 'Python/pythonrun.c')
-rw-r--r-- | Python/pythonrun.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Python/pythonrun.c b/Python/pythonrun.c index 4939f54..f5465c5 100644 --- a/Python/pythonrun.c +++ b/Python/pythonrun.c @@ -377,6 +377,9 @@ Py_Finalize(void) Py_XDECREF(warnings_module); warnings_module = NULL; + /* Clear type lookup cache */ + PyType_ClearCache(); + /* Collect garbage. This may call finalizers; it's nice to call these * before all modules are destroyed. * XXX If a __del__ or weakref callback is triggered here, and tries to |