Skip to content
Snippets Groups Projects
Commit 3936a5a4 authored by patavirt's avatar patavirt
Browse files

vector: implement swap()

parent 47ac063b
No related branches found
No related tags found
No related merge requests found
......@@ -108,6 +108,13 @@ public:
return *this;
}
void swap(Vector& other)
{
storage_.swap(other.storage_);
std::swap(data_, other.data_);
std::swap(size_, other.size_);
}
Scalar *data() const
{
return data_;
......
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