Name

swap function template — Swaps the contents of two lists

Synopsis

template<typename T, typename A>
void swap(list<T, A>& x, list<T, A>& y)

The swap function template specialization is equivalent to calling x.swap(y).