Skip to content

Commit

Permalink
Update wasmtime and wit-bindgen (bytecodealliance#68)
Browse files Browse the repository at this point in the history
* Update wasmtime and wit-bindgen

This commit updates the `wasmtime` dependency and the
`wit-bindgen-guest-rust` dependencies to namely update the `wit-parser`
and component underlying implementations. This pulls in
bytecodealliance/wasm-tools#867 which is the implementation of `use` for
WIT. This does not currently break apart the one large `wasi.wit` file,
instead just gets tests working.

* Split apart `wasi.wit` into multiple `*.wit` files

This commit refactors the monolithic `wasi.wit` file into multiple
files. I've taken some liberties in naming here so suggestions are
definitely welcome! I've resolved some TODO annotations as well about
`use`-ing types between interfaces. There are two issues remaining,
however:

* The `wasi-command` world still hardcodes `u32` because `world` items
  don't support `use` just yet. That isn't a hard limitation of WIT,
  however, it's just a temporary limitation of the implementation.

* The `wasi-clocks` interface defines the `wasi-future` type. This is
  due to a cyclic dependency where `wasi-future` is defined within
  `wasi-poll` which depends on `wasi-clocks` for types. I've left this
  to a future refactoring to probably have a `types` interface of some
  form somewhere.

* Update patch for wasm-tools

* Switch to wasmtime upstream

* Update CI for build

* Remove patch overrides

* Update names of uploaded files
  • Loading branch information
alexcrichton committed Jan 25, 2023
1 parent 9b10c0b commit 710cc4c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ mod macros;

mod bindings {
wit_bindgen_guest_rust::generate!({
path: "wit/wasi.wit",
world: "wasi-command",
no_std,
raw_strings,
unchecked,
Expand Down

0 comments on commit 710cc4c

Please sign in to comment.