You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
## `ProtoWasmSandbox` vs `WasmSandbox` vs `LoadedWasmSandbox`
30
30
31
-
The three primary APIs with which you'll be interacting are [`ProtoWasmSandbox`](./src/hyperlight_wasm/src/proto_wasm_sandbox.rs), [`WasmSandbox`](./src/hyperlight_wasm/src/wasm_sandbox.rs) and [`LoadedWasmSandbox`](./src/hyperlight_wasm//s
32
-
rc/loaded_wasm_sandbox.rs). These are three different Rust `struct`s that provide a type-safe way to ensure the current state of the system.
31
+
The three primary APIs with which you'll be interacting are [`ProtoWasmSandbox`](./src/hyperlight_wasm/src/sandbox/proto_wasm_sandbox.rs), [`WasmSandbox`](./src/hyperlight_wasm/src/sandbox/wasm_sandbox.rs) and [`LoadedWasmSandbox`](./src/hyperlight_wasm/src/sandbox/loaded_wasm_sandbox.rs). These are three different Rust `struct`s that provide a type-safe way to ensure the current state of the system.
33
32
34
33
One helpful way to think about these three different types is as a strongly-typed state machine that is enforced by the Rust compiler. This type-safety feature is important because it allows you, the application developer, to detect issues sooner, and without having to write as many tests (because the compiler is doing more checks for you).
35
34
@@ -74,7 +73,7 @@ Before you can transition a `ProtoWasmSandbox` to a `WasmSandbox` (and on to a `
74
73
75
74
In module mode, register host functions with `ProtoWasmSandbox::register_host_func_i`. In this method, the `i` suffix indicates the number of parameters your host function has. Currently a number in the range from `0` to `3` (inclusive) is supported.
76
75
77
-
Please see an illustration of how to do this in the [hostfunc/main.rs](./src/hyperlight_wasm/examples/hostfunc/main.rs) Rust example.
76
+
Please see an illustration of how to do this in the [hostfuncs/main.rs](./src/hyperlight_wasm/examples/hostfuncs/main.rs) Rust example.
78
77
79
78
#### Parameter and return types
80
79
@@ -143,8 +142,8 @@ In the above code snippet, we call a guest function named `my_function` that tak
143
142
144
143
There are more detailed full examples of calling module exports in
0 commit comments