Commit Graph

3 Commits

Author SHA1 Message Date
Christoph Herzog
3b27b50880 build: Refactor wasi-types regenerate.sh to Rust
Replace the lib/wasi-types/regenerate.sh shell script with a Rust
implementation.

We already had some Rust fixup code in lib/wasi-types/wasi-types-generator-extra.

This mostly just converts the "wai-bindgen" CLI invokation into Rust
code that uses the wai-bindgen crates as a dependency.

Also moves the .wit files from "wit-clean" to ./schema/wasi and uses the
.wai extension.

The ./schema dir will also hold Wasix-specific definitions in the future.
2022-12-09 20:14:32 +01:00
Felix Schütt
4217cf8a82 Move wasi-types-generated into wasi-types 2022-09-22 19:08:16 +02:00
Ivan Enderlin
3129b550e5 feat(wasi-types) Extract types from wasi to a new wasi-types crate.
Because we are very likely to re-use those types in other crates (it
already happens in private repos already), we want to extract the WASI
types from the `wasi` crate.

This patch extracts the `wasi/src/syscalls/types.rs` module into its
own `wasi-types` crate. This new crate takes this opportunity to
classify the numerous types in submodules. All exported public types
are flatten.

What's missing is the documentation, let's address in another round of
PR.
2021-06-08 15:13:26 +02:00