Conversation
…w rejected by a compiler error. `Sync` and `Send` are now derived by the compiler for `ScopeFuture`, except that the `Send`-safety of `impl ScopeHandle` is is still asserted unsafety. I did not review `rayon_core` to judge whether that is correct.
Merge branch 'issue-697' of github.com:jClaireCodesStuff/rayon into issue-697
|
I do think you're right that this needs This PR constitutes a breaking change, though it's to fix soundness, which we've allowed without a semver bump before. Plus rayon-futures requires the nasty Does this sound OK? |
|
I published rayon-futures 0.1.1 with this change. |
Wrote a test case. It demonstrates that the master sends
!Sendresults, and fails to compile after my changes. The existing 12 tests pass.Removed
unsafe implofSyncandSendforScopeFuture. Replaced it with:Sendbounds for the return types of the user'sFutureScopeHandlewith unsafeimpl SendNow the only other type in the crate with
unsafe implisScopeFutureWrapped.I need help transforming the test into one that expects a compiler error.
I did not investigate whether sending
ScopeHandleis sound.