[flat.multiset.cons.alloc]

# 23 Containers library [[containers]](./#containers)

## 23.6 Container adaptors [[container.adaptors]](container.adaptors#flat.multiset.cons.alloc)

### 23.6.12 Class template flat_multiset [[flat.multiset]](flat.multiset#cons.alloc)

#### 23.6.12.4 Constructors with allocators [flat.multiset.cons.alloc]

[1](#1)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L19853)

The constructors in this subclause shall not participate in overload resolution
unless uses_allocator_v<container_type, Alloc> is true[.](#1.sentence-1)

[ð](#lib:flat_multiset,constructor)

`template<class Alloc>
  constexpr flat_multiset(const container_type& cont, const Alloc& a);
template<class Alloc>
  constexpr flat_multiset(const container_type& cont, const key_compare& comp, const Alloc& a);
`

[2](#2)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L19866)

*Effects*: Equivalent to flat_multiset(cont) andflat_multiset(cont, comp), respectively,
except that *c* is constructed with
uses-allocator construction ([[allocator.uses.construction]](allocator.uses.construction "20.2.8.2 Uses-allocator construction"))[.](#2.sentence-1)

[3](#3)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L19873)

*Complexity*: Same as flat_multiset(cont) andflat_multiset(cont, comp), respectively[.](#3.sentence-1)

[ð](#lib:flat_multiset,constructor_)

`template<class Alloc>
  constexpr flat_multiset(sorted_equivalent_t, const container_type& cont, const Alloc& a);
template<class Alloc>
  constexpr flat_multiset(sorted_equivalent_t, const container_type& cont,
                          const key_compare& comp, const Alloc& a);
`

[4](#4)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L19889)

*Effects*: Equivalent to flat_multiset(sorted_equivalent, cont) andflat_multiset(sorted_equivalent, cont, comp), respectively,
except that *c* is constructed with
uses-allocator construction ([[allocator.uses.construction]](allocator.uses.construction "20.2.8.2 Uses-allocator construction"))[.](#4.sentence-1)

[5](#5)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L19896)

*Complexity*: Linear[.](#5.sentence-1)

[ð](#lib:flat_multiset,constructor__)

`template<class Alloc>
  constexpr explicit flat_multiset(const Alloc& a);
template<class Alloc>
  constexpr flat_multiset(const key_compare& comp, const Alloc& a);
template<class Alloc>
  constexpr flat_multiset(const flat_multiset&, const Alloc& a);
template<class Alloc>
  constexpr flat_multiset(flat_multiset&&, const Alloc& a);
template<class InputIterator, class Alloc>
  constexpr flat_multiset(InputIterator first, InputIterator last, const Alloc& a);
template<class InputIterator, class Alloc>
  constexpr flat_multiset(InputIterator first, InputIterator last,
                          const key_compare& comp, const Alloc& a);
template<class InputIterator, class Alloc>
  constexpr flat_multiset(sorted_equivalent_t, InputIterator first, InputIterator last,
                          const Alloc& a);
template<class InputIterator, class Alloc>
  constexpr flat_multiset(sorted_equivalent_t, InputIterator first, InputIterator last,
                          const key_compare& comp, const Alloc& a);
template<[container-compatible-range](container.intro.reqmts#concept:container-compatible-range "23.2.2.1 Introduction [container.intro.reqmts]")<value_type> R, class Alloc>
  constexpr flat_multiset(from_range_t, R&& rg, const Alloc& a);
template<[container-compatible-range](container.intro.reqmts#concept:container-compatible-range "23.2.2.1 Introduction [container.intro.reqmts]")<value_type> R, class Alloc>
  constexpr flat_multiset(from_range_t, R&& rg, const key_compare& comp, const Alloc& a);
template<class Alloc>
  constexpr flat_multiset(initializer_list<value_type> il, const Alloc& a);
template<class Alloc>
  constexpr flat_multiset(initializer_list<value_type> il, const key_compare& comp,
                          const Alloc& a);
template<class Alloc>
  constexpr flat_multiset(sorted_equivalent_t, initializer_list<value_type> il, const Alloc& a);
template<class Alloc>
  constexpr flat_multiset(sorted_equivalent_t, initializer_list<value_type> il,
                          const key_compare& comp, const Alloc& a);
`

[6](#6)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/containers.tex#L19939)

*Effects*: Equivalent to the corresponding non-allocator constructors
except that *c* is constructed with
uses-allocator construction ([[allocator.uses.construction]](allocator.uses.construction "20.2.8.2 Uses-allocator construction"))[.](#6.sentence-1)
