def cut.at

ezx@1.11.0.0 · src/pkg/pkg.bend:127

import ezx@1.11.0.0/src/pkg/pkg.bend as Pkg
import Base

127# one character before the fields read so far: a blank ends the field under
128# way, and anything else extends it
129def cut.at(gap: Bool, head: Char, sofar: Cut) -> Cut:
130  match gap:
131    case True{}:
132      Cut{field, after} = sofar
133      Cut{"", cut.put(field, after)}
134    case False{}:
135      Cut{field, after} = sofar
136      Cut{SCon{head, field}, after}

Uses (5)

Used by (1)