mirror of
https://github.com/python/cpython.git
synced 2026-08-03 12:10:52 +08:00
Clang-20 detects a data race between the unlock and the non-atomic read of the lock state. Use a relaxed load for the assertion to avoid the race. (cherry picked from commit f11ec6e643f54f4ee698f7dfc878812a315f2af4) Co-authored-by: Sam Gross <colesbury@gmail.com>
Tests in this directory are compiled into the _testinternalcapi extension. The main file for the extension is Modules/_testinternalcapimodule.c, which calls `_PyTestInternalCapi_Init_*` from these functions. See Modules/_testcapi/README.txt for guideline when writing C test code.