This has showed up on our build with -Werror.
On this line:
|
using GetIsAlwaysEqual = typename T::is_always_equal; |
We get: error: 'is_always_equal' is deprecated [-Werror,-Wdeprecated-declarations]
This could be disabled with pragmas, or switching to std::allocator_traits<T>::is_always_empty works too, that doesn't warn. In the latter case, allocator_traits could be used directly here:
|
using is_always_equal = |
|
memory_internal::ExtractOrT<memory_internal::GetIsAlwaysEqual, Alloc, |
|
typename std::is_empty<Alloc>::type>; |
...and GetIsAlwaysEqual could be removed entirely.
A minimal example of the warning: https://gcc.godbolt.org/z/zdGMa49s3
This reproduces in phmap with just the following code:
#include <parallel_hashmap/phmap.h>
phmap::flat_hash_map<int, int> m;
int main() {}
When using clang++ -std=c++23.
This has showed up on our build with
-Werror.On this line:
parallel-hashmap/parallel_hashmap/phmap_base.h
Line 1275 in 01c838b
We get:
error: 'is_always_equal' is deprecated [-Werror,-Wdeprecated-declarations]This could be disabled with pragmas, or switching to
std::allocator_traits<T>::is_always_emptyworks too, that doesn't warn. In the latter case,allocator_traitscould be used directly here:parallel-hashmap/parallel_hashmap/phmap_base.h
Lines 1463 to 1465 in 01c838b
...and
GetIsAlwaysEqualcould be removed entirely.A minimal example of the warning: https://gcc.godbolt.org/z/zdGMa49s3
This reproduces in phmap with just the following code:
When using
clang++ -std=c++23.