Skip to content

Require that captured variables are marked with vm:shared#4282

Merged
mraleph merged 3 commits intomainfrom
impose-requirement-of-annotation
Mar 5, 2025
Merged

Require that captured variables are marked with vm:shared#4282
mraleph merged 3 commits intomainfrom
impose-requirement-of-annotation

Conversation

@mraleph
Copy link
Member

@mraleph mraleph commented Mar 4, 2025

Amend shared native memory multithreading proposal to require that all captured variables are marked with vm:shared to make the closure shareable. This makes it clearer which values are crossing the boundary between isolates - which is significant for mutable values like TypedData. It is complete parallel to vm:shared annotations on static fields.

(This makes tear-offs not shareable - at least for now).

@mraleph mraleph merged commit d1e361e into main Mar 5, 2025
2 of 3 checks passed
@mraleph mraleph deleted the impose-requirement-of-annotation branch March 5, 2025 15:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants