Skip to content

Latest commit

 

History

History
30 lines (22 loc) · 529 Bytes

File metadata and controls

30 lines (22 loc) · 529 Bytes
description Learn more about: <list> functions
title <list> functions
ms.custom
ms.date 11/04/2016
ms.topic reference
f1_keywords
list/std::swap

<list> functions

swap

Exchanges the elements of two lists.

template <class T, class Allocator>
    void swap(list<T, Allocator>& left, list<T, Allocator>& right)

Parameters

left
An object of type list.

right
An object of type list.

Remarks

This template function executes left.swap(right).