def next.use
import emerging-ezjson@1.3.0.0/src/pull.bend as Pullimport Base
1584# an event from a step. A skip that surfaces here is a broken reader. An
1585# error always comes with the failed cursor, and an end with an ended one, so
1586# both stick: the steps build them that way, and this says so where it is used
1587def next.use(got: (Stop & Cur)) -> (Ev & Cur):
1588 (stop, cur) = got
1589 match stop:
1590 case SEv{EErr{}}:
1591 (EErr{}, Cur{"", Nil{}, False{}, True{}})
1592 case SEv{EEnd{}}:
1593 (EEnd{}, next.ended(cur))
1594 case SEv{ev}:
1595 (ev, cur)
1596 case SSkip{}:
1597 (EErr{}, Cur{"", Nil{}, False{}, True{}})