def at

ezx@1.11.0.0 · src/ws/moved.bend:98

import ezx@1.11.0.0/src/ws/moved.bend as Moved
import Base

98# the first member written from a directory, or none
99def at(hs: List<&2, Held>, +path: String) -> Maybe<&2, Held>:
100  match hs:
101    case []:
102      None{}
103    case +hd <> tl:
104      rest = at(tl, path)
105      at.pick(String.eq(held.path(hd), path), hd, rest)

Uses (7)

Used by (2)