void unwind_tag(const typename ctx_t::history_t &hist, tag_path_t &path,
    hidx_t idx, size_t tag)
{
    path.clear();
    for (; idx != HROOT; ) {
        const typename ctx_t::history_t::node_t &n = hist.node(idx);
        if (n.info.idx == tag) {
            path.push_back(n.info);
        }
        idx = n.pred;
    }
}
void unwind_tag(const typename ctx_t::history_t &hist, tag_path_t &path,
    hidx_t idx, size_t tag)
{
    path.clear();
    for (; idx != HROOT; ) {
        const typename ctx_t::history_t::node_t &n = hist.node(idx);
        if (n.info.idx == tag) {
            path.push_back(n.info);
        }
        idx = n.pred;
    }
}