Commit 203ee514 authored by Jakub Klinkovský's avatar Jakub Klinkovský
Browse files

Removed custom implementation of std::make_unique which is available in STL since C++14

parent 826332e4
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -14,7 +14,6 @@
#include <string>
#include <vector>
#include <memory>
#include "make_unique.h"

#include <TNL/Assert.h>
#include <TNL/String.h>
+0 −1
Original line number Diff line number Diff line
@@ -12,7 +12,6 @@

#include <vector>
#include <memory>
#include "make_unique.h"

#include <TNL/param-types.h>
//#include <TNL/Debugging/StackBacktrace.h>

src/TNL/Config/make_unique.h

deleted100644 → 0
+0 −15
Original line number Diff line number Diff line
#pragma once

// std::make_unique does not exist until C++14
// https://stackoverflow.com/a/9657991
#if __cplusplus < 201402L
#include <memory>

namespace std {
   template<typename T, typename ...Args>
   std::unique_ptr<T> make_unique( Args&& ...args )
   {
      return std::unique_ptr<T>( new T( std::forward<Args>(args)... ) );
   }
}
#endif