diff --git a/src/engine/TransitivePathBase.h b/src/engine/TransitivePathBase.h index a16a37ee50..b0308dd923 100644 --- a/src/engine/TransitivePathBase.h +++ b/src/engine/TransitivePathBase.h @@ -59,13 +59,16 @@ struct TransitivePathSide { // We deliberately use the `std::` variants of a hash set and hash map because // `absl`s types are not exception safe. -inline constexpr auto hash = [](Id id) { - return std::hash{}(id.getBits()); +struct HashId { + auto operator()(Id id) const { + return std::hash{}(id.getBits()); + } }; -using Set = std::unordered_set, + +using Set = std::unordered_set, ad_utility::AllocatorWithLimit>; using Map = std::unordered_map< - Id, Set, decltype(hash), std::equal_to, + Id, Set, HashId, std::equal_to, ad_utility::AllocatorWithLimit>>; /**