Modernize use of std::make_unique
[folly.git] / folly / ConcurrentSkipList-inl.h
index eca30ceb3d01265f30b7984e4db5d10c64704559..090a732ed82a7a3d30bc4e3d0f99ad1676d68df8 100644 (file)
@@ -255,7 +255,7 @@ class NodeRecycler<NodeType, NodeAlloc, typename std::enable_if<
   void add(NodeType* node) {
     std::lock_guard<MicroSpinLock> g(lock_);
     if (nodes_.get() == nullptr) {
-      nodes_.reset(new std::vector<NodeType*>(1, node));
+      nodes_ = std::make_unique<std::vector<NodeType*>>(1, node);
     } else {
       nodes_->push_back(node);
     }