def paths.safe
import ezx@1.11.0.0/src/fetch/plan.bend as Planimport Base
import ezx@1.11.0.0/src/lock/world.bend as W
190# whether every path stays inside the tree
191def paths.safe(ls: List<&2, W.Source>) -> Bool:
192 match ls:
193 case []:
194 True{}
195 case W.Source{+at, _text} <> t:
196 +rest = paths.safe(t)
197 Bool.and(path.safe(at), rest)