Decode.fold: def of bend-toon-codec@0.1.0.0 Import: import bend-toon-codec@0.1.0.0/src/decode.bend as Decode Lines 23-31 of bend-toon-codec@0.1.0.0/src/decode.bend: https://jend.leeeet.dev/read.txt?path=bend-toon-codec@0.1.0.0/src/decode.bend&start_line=23&end_line=31 import Base import bend-toon-codec@0.1.0.0/src/dline.bend as D import bend-toon-codec@0.1.0.0/src/frame.bend as F import bend-toon-codec@0.1.0.0/src/step.bend as T # Apply every line in order, stopping at the first error. def fold(+ls: List<&2, D.DL>, +sr: Result<&2, &2, String, F.St>, +strict: Bool) -> Result<&2, &2, String, F.St>: match ls sr: case Nil{} _: sr case Con{l, t} Done{st}: fold(t, T.step(l, st, strict), strict) case Con{l, t} Fail{e}: Fail{e} Uses (7): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Result https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=bend-toon-codec@0.1.0.0/src/dline.bend&name=DL https://jend.leeeet.dev/definition.txt?path=bend-toon-codec@0.1.0.0/src/frame.bend&name=St https://jend.leeeet.dev/definition.txt?path=bend-toon-codec@0.1.0.0/src/step.bend&name=step