diff --git a/src/UniqueCPtr.hpp b/src/UniqueCPtr.hpp index 647f7e1..743a712 100644 --- a/src/UniqueCPtr.hpp +++ b/src/UniqueCPtr.hpp @@ -10,7 +10,9 @@ #include #include - +// UniqueCPtr is a wrapper around std::unique_ptr using std::free as its deallocator +// +// This allows to use it to manage memory allocated by C APIs (malloc, realloc, ...) template class UniqueCPtr : public std::unique_ptr { public: UniqueCPtr() : std::unique_ptr(nullptr, std::free) {}