def gone
import ezx@1.11.0.0/src/remove/plan.bend as Planimport Base
import ezx@1.11.0.0/src/ledger/manifest.bend as M
112# the committed trees removing `name` leaves no dependency to name: the hash
113# of each vendored dependency by that name that none in `left` names
114def gone(ds: List<&2, M.Dep>, +name: String, +left: List<&2, M.Dep>) -> List<&2, String>:
115 match ds:
116 case []:
117 []
118 case +h <> t:
119 gone.put(Bool.and(String.eq(M.dep.name(h), name),
120 M.source.vendor(M.source.dep(h))), M.dep.hash(h), left, gone(t, name, left))