]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-111569: Fix critical sections test on WebAssembly (GH-111897)
authorSam Gross <colesbury@gmail.com>
Thu, 9 Nov 2023 23:37:11 +0000 (18:37 -0500)
committerGitHub <noreply@github.com>
Thu, 9 Nov 2023 23:37:11 +0000 (15:37 -0800)
commit289af8612283508b67d7969d7182070381b4349b
tree55d8082aad0a83f47ec27e0f3d7aab629ca53dec
parentb9f814ce6fdc2fd636bb01e60c60f3ed708a245f
gh-111569: Fix critical sections test on WebAssembly (GH-111897)

This adds a macro `Py_CAN_START_THREADS` that corresponds to the Python
function `test.support.threading_helper.can_start_thread()`. WASI and
some Emscripten builds do not have a working pthread implementation.

This macro is used to guard the critical sections C API tests that
require a working threads implementation.
Include/pyport.h
Modules/_testinternalcapi/test_critical_sections.c