Files
2025-10-25 03:02:53 +03:00

4.5 KiB
Raw Permalink Blame History

[flat.set.cons.alloc]

23 Containers library [containers]

23.6 Container adaptors [container.adaptors]

23.6.11 Class template flat_set [flat.set]

23.6.11.4 Constructors with allocators [flat.set.cons.alloc]

1

#

The constructors in this subclause shall not participate in overload resolution unless uses_allocator_v<container_type, Alloc> is true.

🔗

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

2

#

Effects: Equivalent toflat_set(cont) and flat_set(cont, comp), respectively, except that c is constructed with uses-allocator construction ([allocator.uses.construction]).

3

#

Complexity: Same as flat_set(cont) and flat_set(cont, comp), respectively.

🔗

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

4

#

Effects: Equivalent toflat_set(sorted_unique, cont) andflat_set(sorted_unique, cont,
comp), respectively, except that c is constructed with uses-allocator construction ([allocator.uses.construction]).

5

#

Complexity: Linear.

🔗

template<class Alloc> constexpr explicit flat_set(const Alloc& a); template<class Alloc> constexpr flat_set(const key_compare& comp, const Alloc& a); template<class Alloc> constexpr flat_set(const flat_set&, const Alloc& a); template<class Alloc> constexpr flat_set(flat_set&&, const Alloc& a); template<class InputIterator, class Alloc> constexpr flat_set(InputIterator first, InputIterator last, const Alloc& a); template<class InputIterator, class Alloc> constexpr flat_set(InputIterator first, InputIterator last, const key_compare& comp, const Alloc& a); template<class InputIterator, class Alloc> constexpr flat_set(sorted_unique_t, InputIterator first, InputIterator last, const Alloc& a); template<class InputIterator, class Alloc> constexpr flat_set(sorted_unique_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.1Introduction[container.intro.reqmts]")<value_type> R, class Alloc> constexpr flat_set(from_range_t, R&& rg, const Alloc& a); template<[container-compatible-range](container.intro.reqmts#concept:container-compatible-range "23.2.2.1Introduction[container.intro.reqmts]")<value_type> R, class Alloc> constexpr flat_set(from_range_t, R&& rg, const key_compare& comp, const Alloc& a); template<class Alloc> constexpr flat_set(initializer_list<value_type> il, const Alloc& a); template<class Alloc> constexpr flat_set(initializer_list<value_type> il, const key_compare& comp, const Alloc& a); template<class Alloc> constexpr flat_set(sorted_unique_t, initializer_list<value_type> il, const Alloc& a); template<class Alloc> constexpr flat_set(sorted_unique_t, initializer_list<value_type> il, const key_compare& comp, const Alloc& a);

6

#

Effects: Equivalent to the corresponding non-allocator constructors except that c is constructed with uses-allocator construction ([allocator.uses.construction]).