Modernize use of std::make_unique
[folly.git] / folly / gen / test / ParallelTest.cpp
index 36bc4c968471e7ba6ef2ccf414707b312c25ffef..358d86e69df57dc6eb4d381c682368b42822d2f5 100644 (file)
  * limitations under the License.
  */
 
-#include <glog/logging.h>
-
-#include <iostream>
 #include <array>
+#include <iostream>
+#include <memory>
 #include <vector>
 
+#include <glog/logging.h>
+
 #include <folly/gen/Base.h>
 #include <folly/gen/Parallel.h>
 #include <folly/portability/GTest.h>
@@ -52,7 +53,7 @@ static auto isPrime = [](int n) {
 struct {
   template <class T>
   std::unique_ptr<T> operator()(T t) const {
-    return std::unique_ptr<T>(new T(std::move(t)));
+    return std::make_unique<T>(std::move(t));
   }
 } makeUnique;