mirror of
https://github.com/greg7mdp/parallel-hashmap.git
synced 2026-08-30 00:50:38 +08:00
Fix two warning related to upcoming c++17 deprecations
This commit is contained in:
Vendored
+4
-4
@@ -712,7 +712,7 @@ namespace phmap {
|
||||
|
||||
template <
|
||||
typename Compare, typename K, typename LK,
|
||||
phmap::enable_if_t<!std::is_same<bool, phmap::result_of_t<
|
||||
phmap::enable_if_t<!std::is_same<bool, phmap::invoke_result_t<
|
||||
Compare(const K &, const LK &)>>::value,
|
||||
int> = 0>
|
||||
constexpr phmap::weak_ordering do_three_way_comparison(const Compare &compare,
|
||||
@@ -721,7 +721,7 @@ namespace phmap {
|
||||
}
|
||||
template <
|
||||
typename Compare, typename K, typename LK,
|
||||
phmap::enable_if_t<std::is_same<bool, phmap::result_of_t<Compare(
|
||||
phmap::enable_if_t<std::is_same<bool, phmap::invoke_result_t<Compare(
|
||||
const K &, const LK &)>>::value,
|
||||
int> = 0>
|
||||
constexpr phmap::weak_ordering do_three_way_comparison(const Compare &compare,
|
||||
@@ -743,7 +743,7 @@ namespace container_internal {
|
||||
// comparator.
|
||||
template <typename Compare, typename T>
|
||||
using btree_is_key_compare_to =
|
||||
std::is_convertible<phmap::result_of_t<Compare(const T &, const T &)>,
|
||||
std::is_convertible<phmap::invoke_result_t<Compare, const T &, const T &>,
|
||||
phmap::weak_ordering>;
|
||||
|
||||
struct StringBtreeDefaultLess {
|
||||
@@ -2507,7 +2507,7 @@ namespace container_internal {
|
||||
|
||||
// Verify that key_compare returns an phmap::{weak,strong}_ordering or bool.
|
||||
using compare_result_type =
|
||||
phmap::result_of_t<key_compare(key_type, key_type)>;
|
||||
phmap::invoke_result_t<key_compare, key_type, key_type>;
|
||||
static_assert(
|
||||
std::is_same<compare_result_type, bool>::value ||
|
||||
std::is_convertible<compare_result_type, phmap::weak_ordering>::value,
|
||||
|
||||
Reference in New Issue
Block a user