diff --git a/src/libslic3r/MutablePriorityQueue.hpp b/src/libslic3r/MutablePriorityQueue.hpp index cc1cae68c..418d8deff 100644 --- a/src/libslic3r/MutablePriorityQueue.hpp +++ b/src/libslic3r/MutablePriorityQueue.hpp @@ -17,6 +17,14 @@ public: {} ~MutablePriorityQueue() { clear(); } + MutablePriorityQueue(MutablePriorityQueue &&) = default; + MutablePriorityQueue& operator=(MutablePriorityQueue &&) = default; + + // This class modifies the outside data through the m_index_setter + // and thus it should not be copied. The semantics are similar to std::unique_ptr + MutablePriorityQueue(const MutablePriorityQueue &) = delete; + MutablePriorityQueue& operator=(const MutablePriorityQueue &) = delete; + void clear(); void reserve(size_t cnt) { m_heap.reserve(cnt); } void push(const T &item);