-
Notifications
You must be signed in to change notification settings - Fork 237
Open
Labels
gen-rustRelated to bindings for Rust-compiled-to-WebAssemblyRelated to bindings for Rust-compiled-to-WebAssembly
Description
@rvolosatovs and @dicej had an idea in a meeting we had today where we should have an API in this crate for converting a Rust Future<Output = T>
to a WIT future<T>
by sort of "spawning" it, effectively you yield ownership of the future to wit-bindgen
crate and that'd give you back a future<T>
. That'd then manage polling the original future and then writing the result to the writer half of the channel the runtime provides. Similarly this could work for streams of values (maybe with a bit more finesse to handle chunking)
Metadata
Metadata
Assignees
Labels
gen-rustRelated to bindings for Rust-compiled-to-WebAssemblyRelated to bindings for Rust-compiled-to-WebAssembly