(&self, index: MemoryIndex)
| 467 | /// Get a locally defined or imported memory. |
| 468 | #[cfg(all(has_host_compiler_backend, feature = "debug-builtins"))] |
| 469 | pub(crate) fn get_memory(&self, index: MemoryIndex) -> VMMemoryDefinition { |
| 470 | if let Some(defined_index) = self.env_module().defined_memory_index(index) { |
| 471 | self.memory(defined_index) |
| 472 | } else { |
| 473 | let import = self.imported_memory(index); |
| 474 | unsafe { VMMemoryDefinition::load(import.from.as_ptr()) } |
| 475 | } |
| 476 | } |
| 477 | |
| 478 | /// Return the indexed `VMMemoryDefinition`, loaded from vmctx memory |
| 479 | /// already. |
no test coverage detected