MCPcopy Create free account
hub / github.com/dfinity/orbit / with_memory_manager

Function with_memory_manager

core/station/impl/src/core/memory.rs:47–49  ·  view source on GitHub ↗

A helper function that executes a closure with the memory manager.

(f: impl FnOnce(&MemoryManager<Memory>) -> R)

Source from the content-addressed store, hash-verified

45
46/// A helper function that executes a closure with the memory manager.
47pub fn with_memory_manager<R>(f: impl FnOnce(&MemoryManager<Memory>) -> R) -> R {
48 MEMORY_MANAGER.with(|cell| f(&cell.borrow()))
49}
50
51/// Reserve the first stable memory page for the configuration stable cell.
52pub fn system_state_memory() -> Memory {

Callers 1

save_memory_snapshotFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected