Add experimental struct with views memory and ctxs
This struct is heavily taking from Lucet's Vmctx struct.
This commit is contained in:
10
src/ctx.rs
10
src/ctx.rs
@@ -198,6 +198,16 @@ pub struct WasiCtx {
|
||||
pub env: Vec<CString>,
|
||||
}
|
||||
|
||||
impl Default for WasiCtx {
|
||||
fn default() -> Self {
|
||||
Self {
|
||||
fds: HashMap::new(),
|
||||
args: Vec::new(),
|
||||
env: Vec::new(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl WasiCtx {
|
||||
/// Make a new `WasiCtx` with some default settings.
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user