26#include "node/node_manager.h"
50void hash_children(
size_t &seed,
const std::vector<size_t> &children,
const std::vector<size_t> &hash_table);
66void hash_parents(
size_t &seed,
const std::vector<std::pair<size_t, size_t>> &parents,
const std::vector<size_t> &hash_table);
size_t hash_node(const node::Node &node)
Compute a stable structural hash seed for a parser/node DAG node.
void hash_combine(size_t &seed, const size_t &value)
Mix one value into a hash seed.
void hash_children(size_t &seed, const std::vector< size_t > &children, const std::vector< size_t > &hash_table)
Mix child-node hashes into a parent seed in argument order.
void hash_parents(size_t &seed, const std::vector< std::pair< size_t, size_t > > &parents, const std::vector< size_t > &hash_table)
Propagate a node hash contribution to parent nodes.
void hash_communative_children(size_t &seed, const std::vector< size_t > &children, const std::vector< size_t > &hash_table)
Mix child-node hashes as a commutative multiset.