mirror of https://github.com/python/cpython
e8752d7b80
This exposes `PyUnstable_Object_ClearWeakRefsNoCallbacks` as an unstable C-API function to provide a thread-safe mechanism for clearing weakrefs without executing callbacks. Some C-API extensions need to clear weakrefs without calling callbacks, such as after running finalizers like we do in subtype_dealloc. Previously they could use `_PyWeakref_ClearRef` on each weakref, but that's not thread-safe in the free-threaded build. Co-authored-by: Petr Viktorin <encukou@gmail.com> |
||
---|---|---|
.. | ||
__init__.py | ||
__main__.py | ||
check_config.py | ||
test_abstract.py | ||
test_bytearray.py | ||
test_bytes.py | ||
test_codecs.py | ||
test_complex.py | ||
test_dict.py | ||
test_eval_code_ex.py | ||
test_exceptions.py | ||
test_float.py | ||
test_getargs.py | ||
test_hash.py | ||
test_immortal.py | ||
test_list.py | ||
test_long.py | ||
test_mem.py | ||
test_misc.py | ||
test_object.py | ||
test_opt.py | ||
test_pyatomic.py | ||
test_run.py | ||
test_set.py | ||
test_structmembers.py | ||
test_sys.py | ||
test_time.py | ||
test_unicode.py | ||
test_watchers.py |