forked from boostorg/unordered
added equality comparison to reference
This commit is contained in:
@ -214,39 +214,39 @@ namespace boost {
|
|||||||
class Pred = std::equal_to<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>,
|
class Pred = std::equal_to<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>,
|
||||||
class Allocator = std::allocator<xref:#concurrent_flat_map_iter_to_alloc_type[__iter-to-alloc-type__]<InputIterator>>>
|
class Allocator = std::allocator<xref:#concurrent_flat_map_iter_to_alloc_type[__iter-to-alloc-type__]<InputIterator>>>
|
||||||
concurrent_flat_map(InputIterator, InputIterator, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type = xref:#concurrent_flat_map_deduction_guides[__see below__],
|
concurrent_flat_map(InputIterator, InputIterator, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type = xref:#concurrent_flat_map_deduction_guides[__see below__],
|
||||||
Hash = Hash(), Pred = Pred(), Allocator = Allocator())
|
Hash = Hash(), Pred = Pred(), Allocator = Allocator())
|
||||||
-> concurrent_flat_map<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>, xref:#concurrent_flat_map_iter_mapped_type[__iter-mapped-type__]<InputIterator>, Hash,
|
-> concurrent_flat_map<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>, xref:#concurrent_flat_map_iter_mapped_type[__iter-mapped-type__]<InputIterator>, Hash,
|
||||||
Pred, Allocator>;
|
Pred, Allocator>;
|
||||||
|
|
||||||
template<class Key, class T, class Hash = boost::hash<Key>,
|
template<class Key, class T, class Hash = boost::hash<Key>,
|
||||||
class Pred = std::equal_to<Key>,
|
class Pred = std::equal_to<Key>,
|
||||||
class Allocator = std::allocator<std::pair<const Key, T>>>
|
class Allocator = std::allocator<std::pair<const Key, T>>>
|
||||||
concurrent_flat_map(std::initializer_list<std::pair<Key, T>>,
|
concurrent_flat_map(std::initializer_list<std::pair<Key, T>>,
|
||||||
typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type = xref:#concurrent_flat_map_deduction_guides[__see below__], Hash = Hash(),
|
typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type = xref:#concurrent_flat_map_deduction_guides[__see below__], Hash = Hash(),
|
||||||
Pred = Pred(), Allocator = Allocator())
|
Pred = Pred(), Allocator = Allocator())
|
||||||
-> concurrent_flat_map<Key, T, Hash, Pred, Allocator>;
|
-> concurrent_flat_map<Key, T, Hash, Pred, Allocator>;
|
||||||
|
|
||||||
template<class InputIterator, class Allocator>
|
template<class InputIterator, class Allocator>
|
||||||
concurrent_flat_map(InputIterator, InputIterator, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type, Allocator)
|
concurrent_flat_map(InputIterator, InputIterator, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type, Allocator)
|
||||||
-> concurrent_flat_map<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>, xref:#concurrent_flat_map_iter_mapped_type[__iter-mapped-type__]<InputIterator>,
|
-> concurrent_flat_map<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>, xref:#concurrent_flat_map_iter_mapped_type[__iter-mapped-type__]<InputIterator>,
|
||||||
boost::hash<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>,
|
boost::hash<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>,
|
||||||
std::equal_to<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>, Allocator>;
|
std::equal_to<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>, Allocator>;
|
||||||
|
|
||||||
template<class InputIterator, class Allocator>
|
template<class InputIterator, class Allocator>
|
||||||
concurrent_flat_map(InputIterator, InputIterator, Allocator)
|
concurrent_flat_map(InputIterator, InputIterator, Allocator)
|
||||||
-> concurrent_flat_map<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>, xref:#concurrent_flat_map_iter_mapped_type[__iter-mapped-type__]<InputIterator>,
|
-> concurrent_flat_map<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>, xref:#concurrent_flat_map_iter_mapped_type[__iter-mapped-type__]<InputIterator>,
|
||||||
boost::hash<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>,
|
boost::hash<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>,
|
||||||
std::equal_to<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>, Allocator>;
|
std::equal_to<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>, Allocator>;
|
||||||
|
|
||||||
template<class InputIterator, class Hash, class Allocator>
|
template<class InputIterator, class Hash, class Allocator>
|
||||||
concurrent_flat_map(InputIterator, InputIterator, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type, Hash,
|
concurrent_flat_map(InputIterator, InputIterator, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type, Hash,
|
||||||
Allocator)
|
Allocator)
|
||||||
-> concurrent_flat_map<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>, xref:#concurrent_flat_map_iter_mapped_type[__iter-mapped-type__]<InputIterator>, Hash,
|
-> concurrent_flat_map<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>, xref:#concurrent_flat_map_iter_mapped_type[__iter-mapped-type__]<InputIterator>, Hash,
|
||||||
std::equal_to<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>, Allocator>;
|
std::equal_to<xref:#concurrent_flat_map_iter_key_type[__iter-key-type__]<InputIterator>>, Allocator>;
|
||||||
|
|
||||||
template<class Key, class T, class Allocator>
|
template<class Key, class T, class Allocator>
|
||||||
concurrent_flat_map(std::initializer_list<std::pair<Key, T>>, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type,
|
concurrent_flat_map(std::initializer_list<std::pair<Key, T>>, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type,
|
||||||
Allocator)
|
Allocator)
|
||||||
-> concurrent_flat_map<Key, T, boost::hash<Key>, std::equal_to<Key>, Allocator>;
|
-> concurrent_flat_map<Key, T, boost::hash<Key>, std::equal_to<Key>, Allocator>;
|
||||||
|
|
||||||
template<class Key, class T, class Allocator>
|
template<class Key, class T, class Allocator>
|
||||||
@ -255,9 +255,18 @@ namespace boost {
|
|||||||
|
|
||||||
template<class Key, class T, class Hash, class Allocator>
|
template<class Key, class T, class Hash, class Allocator>
|
||||||
concurrent_flat_map(std::initializer_list<std::pair<Key, T>>, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type,
|
concurrent_flat_map(std::initializer_list<std::pair<Key, T>>, typename xref:#concurrent_flat_map_deduction_guides[__see below__]::size_type,
|
||||||
Hash, Allocator)
|
Hash, Allocator)
|
||||||
-> concurrent_flat_map<Key, T, Hash, std::equal_to<Key>, Allocator>;
|
-> concurrent_flat_map<Key, T, Hash, std::equal_to<Key>, Allocator>;
|
||||||
|
|
||||||
|
// Equality Comparisons
|
||||||
|
template<class Key, class T, class Hash, class Pred, class Alloc>
|
||||||
|
bool xref:#concurrent_flat_map_operator[operator==](const concurrent_flat_map<Key, T, Hash, Pred, Alloc>& x,
|
||||||
|
const concurrent_flat_map<Key, T, Hash, Pred, Alloc>& y);
|
||||||
|
|
||||||
|
template<class Key, class T, class Hash, class Pred, class Alloc>
|
||||||
|
bool xref:#concurrent_flat_map_operator_2[operator!=](const concurrent_flat_map<Key, T, Hash, Pred, Alloc>& x,
|
||||||
|
const concurrent_flat_map<Key, T, Hash, Pred, Alloc>& y);
|
||||||
|
|
||||||
// swap
|
// swap
|
||||||
template<class Key, class T, class Hash, class Pred, class Alloc>
|
template<class Key, class T, class Hash, class Pred, class Alloc>
|
||||||
void xref:#concurrent_flat_map_swap_2[swap](concurrent_flat_map<Key, T, Hash, Pred, Alloc>& x,
|
void xref:#concurrent_flat_map_swap_2[swap](concurrent_flat_map<Key, T, Hash, Pred, Alloc>& x,
|
||||||
@ -1339,6 +1348,38 @@ template<class InputIterator>
|
|||||||
std::tuple_element_t<1, xref:#concurrent_map_iter_value_type[__iter-value-type__]<InputIterator>>>; // exposition only
|
std::tuple_element_t<1, xref:#concurrent_map_iter_value_type[__iter-value-type__]<InputIterator>>>; // exposition only
|
||||||
-----
|
-----
|
||||||
|
|
||||||
|
=== Equality Comparisons
|
||||||
|
|
||||||
|
==== operator==
|
||||||
|
```c++
|
||||||
|
template<class Key, class T, class Hash, class Pred, class Alloc>
|
||||||
|
bool operator==(const concurrent_flat_map<Key, T, Hash, Pred, Alloc>& x,
|
||||||
|
const concurrent_flat_map<Key, T, Hash, Pred, Alloc>& y);
|
||||||
|
```
|
||||||
|
|
||||||
|
Returns `true` if `x.size() == y.size()` and for every element in `x`, there is an element in `y` with the same key, with an equal value (using `operator==` to compare the value types).
|
||||||
|
|
||||||
|
[horizontal]
|
||||||
|
Concurrency:;; Blocking on `x` and `y`.
|
||||||
|
Notes:;; Behavior is undefined if the two tables don't have equivalent equality predicates.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
==== operator!=
|
||||||
|
```c++
|
||||||
|
template<class Key, class T, class Hash, class Pred, class Alloc>
|
||||||
|
bool operator!=(const concurrent_flat_map<Key, T, Hash, Pred, Alloc>& x,
|
||||||
|
const concurrent_flat_map<Key, T, Hash, Pred, Alloc>& y);
|
||||||
|
```
|
||||||
|
|
||||||
|
Returns `false` if `x.size() == y.size()` and for every element in `x`, there is an element in `y` with the same key, with an equal value (using `operator==` to compare the value types).
|
||||||
|
|
||||||
|
[horizontal]
|
||||||
|
Concurrency:;; Blocking on `x` and `y`.
|
||||||
|
Notes:;; Behavior is undefined if the two tables don't have equivalent equality predicates.
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
=== Swap
|
=== Swap
|
||||||
```c++
|
```c++
|
||||||
template<class Key, class T, class Hash, class Pred, class Alloc>
|
template<class Key, class T, class Hash, class Pred, class Alloc>
|
||||||
|
Reference in New Issue
Block a user