template<class T> T* my_new(T*& obj, size_t size) { obj = static_cast<T*>(malloc(size * sizeof(T))); return obj; }