Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion include/EASTL/list.h
Original file line number Diff line number Diff line change
Expand Up @@ -1571,7 +1571,9 @@ namespace eastl
template <typename T, typename Allocator>
inline void list<T, Allocator>::swap(this_type& x)
{
if(internalAllocator() == x.internalAllocator()) // If allocators are equivalent...
if constexpr (is_empty_v<allocator_type>)
DoSwap(x);
else if (internalAllocator() == x.internalAllocator()) // If allocators are equivalent...
DoSwap(x);
else // else swap the contents.
{
Expand Down
Loading