/** * Update all nodes in a way with the ID of the given NodeRef with the * location of the given NodeRef. */ void update_node_location(const NodeRef& new_node_ref) { for (auto& node_ref : nodes()) { if (node_ref.ref() == new_node_ref.ref()) { node_ref.location(new_node_ref.location()); } } }
constexpr bool operator()(const NodeRef& lhs, const NodeRef& rhs) const noexcept { return lhs.location() < rhs.location(); }