comparison Python/pythonrun.c @ 45025:ea3fe302d392 legacy-trunk

Added clear cache methods to clear the internal type lookup cache for ref leak test runs.
author Christian Heimes <christian@cheimes.de>
date Sun, 27 Jan 2008 23:34:59 +0000
parents 599f22a349a2
children 262263737bce
comparison
equal deleted inserted replaced
45024:f062dda54894 45025:ea3fe302d392
374 PyOS_FiniInterrupts(); 374 PyOS_FiniInterrupts();
375 375
376 /* drop module references we saved */ 376 /* drop module references we saved */
377 Py_XDECREF(warnings_module); 377 Py_XDECREF(warnings_module);
378 warnings_module = NULL; 378 warnings_module = NULL;
379
380 /* Clear type lookup cache */
381 PyType_ClearCache();
379 382
380 /* Collect garbage. This may call finalizers; it's nice to call these 383 /* Collect garbage. This may call finalizers; it's nice to call these
381 * before all modules are destroyed. 384 * before all modules are destroyed.
382 * XXX If a __del__ or weakref callback is triggered here, and tries to 385 * XXX If a __del__ or weakref callback is triggered here, and tries to
383 * XXX import a module, bad things can happen, because Python no 386 * XXX import a module, bad things can happen, because Python no