MCPcopy Create free account
hub / github.com/Ruddle/Fomos / alloc

Method alloc

app_console/src/st.rs:1899–1901  ·  view source on GitHub ↗
(&self, layout: alloc::alloc::Layout)

Source from the content-addressed store, hash-verified

1897}
1898unsafe impl GlobalAlloc for AllocFromCtx {
1899 unsafe fn alloc(&self, layout: alloc::alloc::Layout) -> *mut u8 {
1900 (self.a)(layout.size(), layout.align())
1901 }
1902
1903 unsafe fn dealloc(&self, ptr: *mut u8, layout: alloc::alloc::Layout) {
1904 (self.d)(ptr, layout.size(), layout.align());

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected