MCPcopy Create free account
hub / github.com/CppCXY/EmmyLuaCodeStyle / test_heap2

Function test_heap2

3rd/mimalloc-2.0.9/test/test-api.c:297–306  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

295}
296
297bool test_heap2() {
298 mi_heap_t* heap = mi_heap_new();
299 int* p1 = mi_heap_malloc_tp(heap,int);
300 int* p2 = mi_heap_malloc_tp(heap,int);
301 mi_heap_delete(heap);
302 *p1 = 42;
303 mi_free(p1);
304 mi_free(p2);
305 return true;
306}
307
308bool test_stl_allocator1() {
309#ifdef __cplusplus

Callers 1

mainFunction · 0.85

Calls 3

mi_heap_newFunction · 0.85
mi_heap_deleteFunction · 0.85
mi_freeFunction · 0.85

Tested by

no test coverage detected