WebAssembly / shared-everything-threads

A draft proposal for spawning threads in WebAssembly
Other
34 stars 1 forks source link

Is there a way to make i31 shared? #57

Open tlively opened 5 months ago

tlively commented 5 months ago

As @rossberg pointed out in https://github.com/WebAssembly/shared-everything-threads/pull/55#issuecomment-2088280990, it would be nice if we could allow i31ref in shared contexts. The trouble is that it would then have to be a subtype of both eqref and (shared eqref) (at least AFAICT), and we have never allowed a type to have multiple supertypes before, making this a risky new frontier. We should experiment with this and see whether we run into problems in practice.