Newer
Older
Import / projects / Gameloft / core / Utils / UniquePtr.h
@John John on 29 Dec 2020 337 bytes bulk import from macbookpro checkouts
#pragma once
#include <memory>

namespace stl
{
  template<class _Ty, class... _Types>
  inline typename std::enable_if<!std::is_array<_Ty>::value, std::unique_ptr<_Ty> >::type
    make_unique(_Types&&... _Args)
  { // make a unique_ptr
    return (std::unique_ptr<_Ty>(new _Ty(std::forward<_Types>(_Args)...)));
  }

} // namespace stl