stlab/concurrency/main_executor.hpp:164:40: error: no member named 'main_executor_type' in namespace 'stlab::detail'
constexpr auto main_executor = detail::main_executor_type{};
~~~~~~~~^
stlab/concurrency/main_executor.hpp:164:58: error: expected ';' after top level declarator
constexpr auto main_executor = detail::main_executor_type{};
And also, the wasm main executor can be improved:
Oh yes, a simpler solution using the new API (https://emscripten.org/docs/api_reference/proxying.h.html) would be to create a new em_proxying_queue then use emscripten_proxy_asyc to send work to the main thread with it. No need for the double indirection in your previous solution. The proxied work will be automatically executed whenever the main thread returns to the event loop, just like in your previous solution, but without any code running during cancellation points.
And also, the wasm main executor can be improved: