(vm: &VirtualMachine)
| 86 | } |
| 87 | |
| 88 | pub fn get_vm_id(vm: &VirtualMachine) -> &str { |
| 89 | vm.wasm_id |
| 90 | .as_ref() |
| 91 | .expect("VirtualMachine inside of WASM crate should have wasm_id set") |
| 92 | } |
| 93 | pub(crate) fn stored_vm_from_wasm(wasm_vm: &WASMVirtualMachine) -> Rc<StoredVirtualMachine> { |
| 94 | STORED_VMS.with_borrow(|vms| { |
| 95 | vms.get(&wasm_vm.id) |