#pragma once #include template memType *malloc_s(unsigned int size); template class UniquePtr { public: explicit UniquePtr(); explicit UniquePtr(Target *target); UniquePtr(const UniquePtr &unique_ptr); UniquePtr(UniquePtr &&unique_ptr) noexcept; UniquePtr &operator=(const UniquePtr &unique_ptr); UniquePtr &operator=(UniquePtr &&unique_ptr) noexcept; ~UniquePtr(); Target operator*() const; Target *operator->() const; private: Target *_target = nullptr; }; template UniquePtr make_unique(Args... args); #include "memory.tpp"