diff --git a/src/hash_map.hh b/src/hash_map.hh index 2f2f6042..19406bd1 100644 --- a/src/hash_map.hh +++ b/src/hash_map.hh @@ -214,7 +214,8 @@ struct HashMap constexpr EffectiveValue& insert(Item item) { - return insert(std::move(item), hash_value(item_key(item))); + const auto hash = hash_value(item_key(item)); + return insert(std::move(item), hash); } template requires IsHashCompatible