I am trying to use preview2 of WASI and working on implementing wasi-io::write(this: output-stream, buf: list<u8>) -> result<u64, stream-error>. stream-error is currently defined as (record) (see here, and as such wit-bindgen generates struct StreamError {}. However, it seems that the struct does not implement Lower, which means I cannot use it in wasmtime::LinkerInstance::func_wrap(). Am I doing something wrong or has that just not been implemented yet?
the trait `wasmtime::component::Lower` is not implemented for `wasi_io::StreamError`
Oooh I just now realized that Lower is not _actually_ an empty trait. I guess I can just manually implement it for now (esp. for an empty struct)
Last updated: Jan 10 2026 at 02:36 UTC