MCPcopy Create free account
hub / github.com/bytecodealliance/wasmtime / args

Method args

crates/wasi/src/ctx.rs:225–230  ·  view source on GitHub ↗

Appends a list of arguments to the argument array to pass to wasm.

(&mut self, args: &[impl AsRef<str>])

Source from the content-addressed store, hash-verified

223
224 /// Appends a list of arguments to the argument array to pass to wasm.
225 pub fn args(&mut self, args: &[impl AsRef<str>]) -> &mut Self {
226 self.cli
227 .arguments
228 .extend(args.iter().map(|a| a.as_ref().to_owned()));
229 self
230 }
231
232 /// Appends a single argument to get passed to wasm.
233 pub fn arg(&mut self, arg: impl AsRef<str>) -> &mut Self {

Callers 15

wasi_contextFunction · 0.45
build_wasi_exampleFunction · 0.45
set_legacy_p1_ctxMethod · 0.45
set_wasi_ctxMethod · 0.45
run_testsFunction · 0.45
discover_test_binariesFunction · 0.45
assert_outputFunction · 0.45
run_testFunction · 0.45
run_wasmtime_for_outputFunction · 0.45
specify_envFunction · 0.45
run_cwasm_from_stdinFunction · 0.45
memory_growth_failureFunction · 0.45

Calls 4

extendMethod · 0.45
mapMethod · 0.45
iterMethod · 0.45
as_refMethod · 0.45

Tested by 15

run_wasmtime_for_outputFunction · 0.36
specify_envFunction · 0.36
run_cwasm_from_stdinFunction · 0.36
memory_growth_failureFunction · 0.36
table_growth_failureFunction · 0.36
table_growth_failure2Function · 0.36
mpk_without_poolingFunction · 0.36
p2_cli_stdin_emptyFunction · 0.36
p2_cli_stdinFunction · 0.36
p2_cli_splice_stdinFunction · 0.36
p2_cli_exit_failureFunction · 0.36
p2_cli_exit_with_codeFunction · 0.36