Shuffle around the wiggle crates (#1414)
* Shuffle around the wiggle crates This commit reorganizes the wiggle crates slightly by performing the following transforms: * The `crates/wiggle` crate, previously named `wiggle`, was moved to `crates/wiggle/crates/macro` and is renamed to `wiggle-macro`. * The `crates/wiggle/crates/runtime` crate, previously named `wiggle-runtime`, was moved to `crates/wiggle` and is renamed to `wiggle`. * The new `wiggle` crate depends on `wiggle-macro` and reexports the macro. The goal here is that consumers only deal with the `wiggle` crate itself. No more crates depend on `wiggle-runtime` and all dependencies are entirely on just the `wiggle` crate. * Remove the `crates/wiggle/crates` directory Move everything into `crates/wiggle` directly, like `wasi-common` * Add wiggle-macro to test-all script * Fixup a test
This commit is contained in:
@@ -464,7 +464,7 @@ pub fn define_struct_for_wiggle(args: TokenStream) -> TokenStream {
|
||||
|
||||
quote! {
|
||||
/// Lightweight `wasmtime::Memory` wrapper so that we can
|
||||
/// implement `wiggle_runtime::GuestMemory` trait on it which is
|
||||
/// implement `wiggle::GuestMemory` trait on it which is
|
||||
/// now required to interface with `wasi-common`.
|
||||
struct WasiMemory(wasmtime::Memory);
|
||||
|
||||
@@ -474,7 +474,7 @@ pub fn define_struct_for_wiggle(args: TokenStream) -> TokenStream {
|
||||
}
|
||||
}
|
||||
|
||||
unsafe impl wiggle_runtime::GuestMemory for WasiMemory {
|
||||
unsafe impl wiggle::GuestMemory for WasiMemory {
|
||||
fn base(&self) -> (*mut u8, u32) {
|
||||
(self.0.data_ptr(), self.0.data_size() as _)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user