-
Notifications
You must be signed in to change notification settings - Fork 48
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update witx to 0.9 #59
Conversation
This pulls in the new `witx` 0.9 crate which notably includes WebAssembly/WASI#395. This is a large refactoring of how witx signatures are processed and a large update to the actual syntax of the witx ABIs themselves. This commit adjusts to all the new `witx` APIs and also tweaks idioms in a few locations as well. Code generation is now less custom to Rust and instead tries to match almost exactly what the `witx` crate tells us to generate. Additionally the representation of types is chosen to more closely align with interface types in the future where it's impossible to pass invalid values to the outside world. Notable changes here are: * `enum`-like values are now newtype wrappers around integers to prevent invalid values from flowing out. * Error traits are now implement directly for the `Errno` wrapper. * The module containing the raw functions now exclusively uses i32/i64 types and doesn't try to use convenience types in Rust.
512a7d9
to
5daf0f9
Compare
It should be worth pointing out, however, that WebAssembly/WASI#395 should block this and this should wait probably until that's published on crates.io. |
Ok should be good for review now! |
The |
This pulls in the new
witx
0.9 crate which notably includesWebAssembly/WASI#395. This is a large refactoring of how witx signatures
are processed and a large update to the actual syntax of the witx ABIs
themselves.
This commit adjusts to all the new
witx
APIs and also tweaks idioms ina few locations as well. Code generation is now less custom to Rust and
instead tries to match almost exactly what the
witx
crate tells us togenerate. Additionally the representation of types is chosen to more
closely align with interface types in the future where it's impossible
to pass invalid values to the outside world. Notable changes here are:
enum
-like values are now newtype wrappers around integers to preventinvalid values from flowing out.
Errno
wrapper.types and doesn't try to use convenience types in Rust.