Skip to content
Snippets Groups Projects
Commit 9c60cfe8 authored by Jan Trávníček's avatar Jan Trávníček
Browse files

fix operator= of linear_set

parent 80cb884e
No related branches found
No related tags found
No related merge requests found
...@@ -603,6 +603,7 @@ public: ...@@ -603,6 +603,7 @@ public:
linear_set& operator= (const linear_set& x) { linear_set& operator= (const linear_set& x) {
m_data = x.m_data; m_data = x.m_data;
m_comp = x.m_comp; m_comp = x.m_comp;
return *this;
} }
   
/** /**
...@@ -616,6 +617,7 @@ public: ...@@ -616,6 +617,7 @@ public:
linear_set& operator= (linear_set&& x) { linear_set& operator= (linear_set&& x) {
m_data = std::move ( x.m_data ); m_data = std::move ( x.m_data );
m_comp = std::move ( x.m_comp ); m_comp = std::move ( x.m_comp );
return *this;
} }
   
/** /**
...@@ -629,6 +631,7 @@ public: ...@@ -629,6 +631,7 @@ public:
linear_set& operator= (std::initializer_list<T> il) { linear_set& operator= (std::initializer_list<T> il) {
m_data = std::move ( il ); m_data = std::move ( il );
std::sort ( m_data.begin ( ), m_data.end ( ), m_comp ); std::sort ( m_data.begin ( ), m_data.end ( ), m_comp );
return *this;
} }
   
/** /**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment