File tree Expand file tree Collapse file tree 2 files changed +4
-7
lines changed
Expand file tree Collapse file tree 2 files changed +4
-7
lines changed Original file line number Diff line number Diff line change @@ -276,8 +276,7 @@ class Buffer {
276276 Buffer& operator = (const Buffer& buf) = delete ;
277277 Buffer (Buffer &&other) noexcept
278278 {
279- /* Call move assignment operator. */
280- *this = std::forward<Buffer>(other);
279+ *this = std::move (other);
281280 }
282281 Buffer &operator =(Buffer &&other) noexcept
283282 {
Original file line number Diff line number Diff line change @@ -48,8 +48,7 @@ class MempoolStats {
4848 MempoolStats () = default ;
4949 MempoolStats (MempoolStats &&other) noexcept
5050 {
51- /* Call move assignment operator. */
52- *this = std::forward<MempoolStats>(other);
51+ *this = std::move<MempoolStats>(other);
5352 }
5453 MempoolStats &operator =(MempoolStats &&other) noexcept
5554 {
@@ -136,15 +135,14 @@ class MempoolInstance : public MempoolStats<ENABLE_STATS> {
136135 MempoolInstance &operator =(const MempoolInstance &other) = delete ;
137136 MempoolInstance (MempoolInstance &&other) noexcept
138137 {
139- /* Call move assignment operator. */
140- *this = std::forward<MempoolInstance>(other);
138+ *this = std::move (other);
141139 }
142140 MempoolInstance &operator =(MempoolInstance &&other) noexcept
143141 {
144142 if (this == &other)
145143 return *this ;
146144 /* Move base class. */
147- MempoolStats<ENABLE_STATS>::operator =(std::forward<MempoolInstance> (other));
145+ MempoolStats<ENABLE_STATS>::operator =(std::move (other));
148146 std::swap (m_SlabList, other.m_SlabList );
149147 std::swap (m_FreeList, other.m_FreeList );
150148 std::swap (m_SlabDataBeg, other.m_SlabDataBeg );
You can’t perform that action at this time.
0 commit comments