FlatHashMap: fix CE
This commit is contained in:
parent
ecceb51881
commit
a11d37dd4c
@ -389,6 +389,7 @@ install(TARGETS tdutils EXPORT TdTargets
|
||||
|
||||
find_package(benchmark QUIET)
|
||||
find_package(folly QUIET)
|
||||
find_package(gflags QUIET)
|
||||
|
||||
if (ABSL_FOUND AND benchmark_FOUND AND folly_FOUND)
|
||||
add_executable(benchmark-hashset test/hashset_benchmark.cpp)
|
||||
|
@ -198,8 +198,9 @@ class FlatHashTable {
|
||||
using ConstNodeIterator = typename fixed_vector<Node>::const_iterator;
|
||||
|
||||
using KeyT = typename Node::key_type;
|
||||
using key_type = typename Node::key_type;
|
||||
using public_type = typename Node::public_type;
|
||||
using value_type = typename Node::value_type;
|
||||
using value_type = typename Node::public_type;
|
||||
|
||||
struct Iterator {
|
||||
using iterator_category = std::bidirectional_iterator_tag;
|
||||
@ -423,7 +424,7 @@ class FlatHashTable {
|
||||
}
|
||||
}
|
||||
|
||||
value_type &operator[](const KeyT &key) {
|
||||
typename Node::value_type &operator[](const KeyT &key) {
|
||||
return emplace(key).first->value();
|
||||
}
|
||||
|
||||
@ -477,7 +478,6 @@ class FlatHashTable {
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
fixed_vector<Node> nodes_;
|
||||
size_t used_nodes_{};
|
||||
|
||||
@ -591,5 +591,4 @@ template <class KeyT, class HashT = std::hash<KeyT>, class EqT = std::equal_to<K
|
||||
using FlatHashSet = FlatHashSetImpl<KeyT, HashT, EqT>;
|
||||
//using FlatHashSet = std::unordered_set<KeyT, HashT, EqT>;
|
||||
|
||||
|
||||
} // namespace td
|
||||
|
Loading…
Reference in New Issue
Block a user