Rollup merge of #151309 - main, r=alexcrichton
fix: thread creation failed on the wasm32-wasip1-threads target.
wasm32-wasip1-threads target cannot create thread since nightly-2026-01-16.
This commit (c1bcae0638) broken it.
It in https://github.com/rust-lang/rust/pull/151016
This pull-request fix that issue.
This commit is contained in:
commit
3222939950
1 changed files with 1 additions and 1 deletions
|
|
@ -49,7 +49,7 @@ impl Thread {
|
|||
// WASI does not support threading via pthreads. While wasi-libc provides
|
||||
// pthread stubs, pthread_create returns EAGAIN, which causes confusing
|
||||
// errors. We return UNSUPPORTED_PLATFORM directly instead.
|
||||
if cfg!(target_os = "wasi") {
|
||||
if cfg!(all(target_os = "wasi", not(target_feature = "atomics"))) {
|
||||
return Err(io::Error::UNSUPPORTED_PLATFORM);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue