Open stephencelis opened 5 months ago
/cc @FranzBusch @ktoso
Thanks for the report! This is tracked internally as rdar://126047740
We're tracking this as rdar://126047740
@ktoso Sadly the above doesn't compile anymore in Xcode 16 (Mutex
can't be referenced in the task group for some reason?), but if you swap it out for a LockIsolated
you'll find a regression in withTaskExecutorPreference
that causes the test to crash (EXC_BAD_ACCESS
). Lowering the number of iterations from 1000 to 10 gets something that doesn't crash, for what it's worth.
Edit: Mutex
works with an explicit @Sendable
annotation in the group's addTask
closure.
Description
From this discussion: https://forums.swift.org/t/task-executor-preference-and-deterministic-scheduling/72448
Reproduction
Expected behavior
I expect the test to pass.
Environment
swift-driver version: 1.109.2 Apple Swift version 6.0 (swiftlang-6.0.0.3.300 clang-1600.0.20.10) Target: arm64-apple-macosx14.0
Additional information
No response