Function wasmtime_wasi_threads::add_to_linker

source ยท
pub fn add_to_linker<T: Clone + Send + 'static>(
    linker: &mut Linker<T>,
    store: &Store<T>,
    module: &Module,
    get_cx: impl Fn(&mut T) -> &WasiThreadsCtx<T> + Send + Sync + Copy + 'static,
) -> Result<()>
Expand description

Manually add the WASI thread_spawn function to the linker.

It is unclear what namespace the wasi-threads proposal should live under: it is not clear if it should be included in any of the preview* releases so for the time being its module namespace is simply "wasi" (TODO).