# std::flat_multiset<Key,Compare,KeyContainer>::swap

From cppreference.com
< cpp‎ | container‎ | flat multiset

void swap( flat_multiset& other ) noexcept; |  | (since C++23)

Exchanges the contents of the container adaptor with those of `other`. Effectively calls

    ranges::swap(compare, other.compare);
    ranges::swap(c, other.c);

### Parameters

other | - | container adaptor to exchange the contents with

### Return value

(none)

### Exceptions

(none)

### Complexity

Same as underlying container (typically constant).

### Example

| This section is incomplete Reason: no example

### See also

std::swap(std::flat_multiset) (C++23) | specializes the std::swap algorithm (function template)

Retrieved from "https://en.cppreference.com/mwiki/index.php?title=cpp/container/flat_multiset/swap&oldid=167634"