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

Function table_set

crates/fuzzing/tests/oom/table.rs:79–92  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

77
78#[test]
79fn table_set() -> Result<()> {
80 let mut config = Config::new();
81 config.enable_compiler(false);
82 config.concurrency_support(false);
83 let engine = Engine::new(&config)?;
84
85 OomTest::new().allow_alloc_after_oom(true).test(|| {
86 let mut store = Store::try_new(&engine, ())?;
87 let ty = TableType::new(RefType::FUNCREF, 1, None);
88 let table = Table::new(&mut store, ty, Ref::Func(None))?;
89 table.set(&mut store, 0, Ref::Func(None))?;
90 Ok(())
91 })
92}
93
94#[test]
95fn table_copy() -> Result<()> {

Callers

nothing calls this directly

Calls 9

OkFunction · 0.85
enable_compilerMethod · 0.80
allow_alloc_after_oomMethod · 0.80
newFunction · 0.50
try_newFunction · 0.50
FuncClass · 0.50
concurrency_supportMethod · 0.45
testMethod · 0.45
setMethod · 0.45

Tested by

no test coverage detected