1. Rhys !
  2. zorkish

Source

zorkish / util.cpp

/*
 * util.cpp
 *
 *  Created on: 25/08/2012
 *      Author: rhys
 */

#include <memory>

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