#pragma once #include #include static int HeapAllocations = 0; static int HeapDeallocations = 0; inline void* operator new(std::size_t sz) { HeapAllocations++; return std::malloc(sz); } inline void operator delete(void* ptr) noexcept { HeapDeallocations++; std::free(ptr); }