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

Function array_new_cross_store_pre

tests/all/arrays.rs:74–85  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

72#[test]
73#[should_panic = "wrong store"]
74fn array_new_cross_store_pre() {
75 let mut store1 = gc_store().unwrap();
76 let mut store2 = gc_store().unwrap();
77
78 let array_ty = ArrayType::new(
79 store1.engine(),
80 FieldType::new(Mutability::Var, StorageType::ValType(ValType::ANYREF)),
81 );
82 let pre = ArrayRefPre::new(&mut store2, array_ty);
83
84 ArrayRef::new(&mut store1, &pre, &Val::I32(0), 3).unwrap();
85}
86
87#[test]
88fn array_new_fixed_empty() -> Result<()> {

Callers

nothing calls this directly

Calls 5

gc_storeFunction · 0.85
newFunction · 0.50
ValTypeEnum · 0.50
unwrapMethod · 0.45
engineMethod · 0.45

Tested by

no test coverage detected