Merge branch 'refactor' of github.com:slsdetectorgroup/slsDetectorPackage into refactor

This commit is contained in:
2018-10-10 12:24:20 +02:00
3 changed files with 64 additions and 69 deletions

View File

@ -7,9 +7,18 @@
#include <type_traits>
#include <vector>
#include <sstream>
#include <memory>
namespace sls {
// C++11 make_unique implementation for exeption safety
// already available as std::make_unique in C++14
template <typename T, typename... Args>
std::unique_ptr<T> make_unique(Args &&... args) {
return std::unique_ptr<T>(new T(std::forward<Args>(args)...));
}
template <typename T>
bool allEqual(const std::vector<T>& container)
{