Template Function sequant::eval::build_value_key_node_map

Function Documentation

template<meta::eval_node_range R>
ValueNodeMap<std::ranges::range_value_t<R>> sequant::eval::build_value_key_node_map(R const &forest)

Like build_value_node_map but keyed by value id (value_key_of: node id + home-sliced positions), one representative node per value &#8212; the map the ordered executor resolves a value_id through, so a value is always built from one of its own occurrences’ nodes (a node of the same hash home-sliced on other positions is another value).

Returns:

A ValueNodeMap pointing into forest &#8212; see its warning; the result must not outlive forest.