MCPcopy Create free account
hub / github.com/emscripten-core/emscripten / offset_from_node

Function offset_from_node

system/lib/libcxxabi/src/fallback_malloc.cpp:98–102  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

96}
97
98heap_offset offset_from_node(const heap_node* ptr) {
99 return static_cast<heap_offset>(
100 static_cast<size_t>(reinterpret_cast<const char*>(ptr) - heap) /
101 sizeof(heap_node));
102}
103
104// Return a pointer to the first address, 'A', in `heap` that can actually be
105// used to represent a heap_node. 'A' must be aligned so that

Callers 3

init_heapFunction · 0.85
fallback_freeFunction · 0.85
print_free_listFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected