Merge branch 'mtszkarbowiak-fix/swapping'
This commit is contained in:
@@ -734,9 +734,7 @@ public:
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Array tmp = MoveTemp(other);
|
::Swap(other, *this);
|
||||||
other = *this;
|
|
||||||
*this = MoveTemp(tmp);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -616,9 +616,7 @@ public:
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Dictionary tmp = MoveTemp(other);
|
::Swap(other, *this);
|
||||||
other = *this;
|
|
||||||
*this = MoveTemp(tmp);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -304,7 +304,7 @@ template<typename T>
|
|||||||
inline void Swap(T& a, T& b) noexcept
|
inline void Swap(T& a, T& b) noexcept
|
||||||
{
|
{
|
||||||
T tmp = MoveTemp(a);
|
T tmp = MoveTemp(a);
|
||||||
a = b;
|
a = MoveTemp(b);
|
||||||
b = MoveTemp(tmp);
|
b = MoveTemp(tmp);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user