Skip to content

Support for PumpMessageLoop, needed for webassembly#355

Open
fizx wants to merge 5 commits intorogchap:masterfrom
fizx:wasm
Open

Support for PumpMessageLoop, needed for webassembly#355
fizx wants to merge 5 commits intorogchap:masterfrom
fizx:wasm

Conversation

@fizx
Copy link
Copy Markdown
Collaborator

@fizx fizx commented Dec 16, 2022

Depends on (extends) #356's []byte support.

I haven't figured out a nice way to polyfill this into WebAssembly.compile yet, but this at least allows you to PumpMessageLoop at all. WebAssembly.compile uses both background and foreground tasks, and if you don't pump the message loop, the foreground tasks never execute, leading to a hanging process.

See the test case for how to do this. I'm following the idea of make it possible first, then make it nice later.

@fizx fizx changed the title Enables wasm support Support for PumpMesageLoop, needed for webassembly Dec 19, 2022
@fizx fizx changed the title Support for PumpMesageLoop, needed for webassembly Support for PumpMessageLoop, needed for webassembly Dec 19, 2022
@fizx fizx marked this pull request as ready for review December 19, 2022 23:06
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.

1 participant