()
| 157 | #[test] |
| 158 | #[should_panic = "wrong store"] |
| 159 | fn array_new_fixed_cross_store_pre() { |
| 160 | let mut store1 = gc_store().unwrap(); |
| 161 | let mut store2 = gc_store().unwrap(); |
| 162 | |
| 163 | let array_ty = ArrayType::new( |
| 164 | store1.engine(), |
| 165 | FieldType::new(Mutability::Var, StorageType::ValType(ValType::ANYREF)), |
| 166 | ); |
| 167 | let pre = ArrayRefPre::new(&mut store2, array_ty); |
| 168 | |
| 169 | ArrayRef::new_fixed(&mut store1, &pre, &[Val::I32(0)]).unwrap(); |
| 170 | } |
| 171 | |
| 172 | #[test] |
| 173 | fn anyref_as_array() -> Result<()> { |