Home
last modified time | relevance | path

Searched refs:weaklist (Results 1 – 3 of 3) sorted by relevance

/external/python/cpython3/Lib/test/
Dtest_threading_local.py18 def target(local, weaklist): argument
21 weaklist.append(weakref.ref(weak))
33 weaklist = []
35 t = threading.Thread(target=target, args=(local, weaklist))
41 self.assertEqual(len(weaklist), n)
44 deadlist = [weak for weak in weaklist if weak() is None]
50 deadlist = [weak for weak in weaklist if weak() is None]
/external/python/cpython2/Lib/test/
Dtest_threading_local.py16 def target(local, weaklist): argument
19 weaklist.append(weakref.ref(weak))
30 weaklist = []
32 t = threading.Thread(target=target, args=(local, weaklist))
38 self.assertEqual(len(weaklist), n)
41 deadlist = [weak for weak in weaklist if weak() is None]
47 deadlist = [weak for weak in weaklist if weak() is None]
/external/python/cpython3/Python/
Dpylifecycle.c1343 PyObject *weaklist = PyList_New(0); in finalize_remove_modules() local
1344 if (weaklist == NULL) { in finalize_remove_modules()
1349 if (weaklist != NULL) { \ in finalize_remove_modules()
1353 if (!tup || PyList_Append(weaklist, tup) < 0) { \ in finalize_remove_modules()
1408 return weaklist; in finalize_remove_modules()
1445 PyObject *weaklist, int verbose) in finalize_modules_clear_weaklist() argument
1448 for (Py_ssize_t i = PyList_GET_SIZE(weaklist) - 1; i >= 0; i--) { in finalize_modules_clear_weaklist()
1449 PyObject *tup = PyList_GET_ITEM(weaklist, i); in finalize_modules_clear_weaklist()
1515 PyObject *weaklist = finalize_remove_modules(modules, verbose); in finalize_modules() local
1531 if (weaklist != NULL) { in finalize_modules()
[all …]