Http.octs.skip: def of emerging-ezhttp@0.21.0.0 Import: import emerging-ezhttp@0.21.0.0/src/http.bend as Http Lines 1506-1513 of emerging-ezhttp@0.21.0.0/src/http.bend: https://jend.leeeet.dev/read.txt?path=emerging-ezhttp@0.21.0.0/src/http.bend&start_line=1506&end_line=1513 import Base # walk n bytes of UTF-8 off a string, as octs.drop does, saying how it ended def octs.skip(s: String, +n: Nat) -> Skip: match s: case SNil{}: Short{n} case SCon{+h, +t}: +w = octs.width(Char.to_u32(h)) octs.skip.step(Nat.is_lt(n, w), n, h, t, _u => octs.skip(t, Nat.sub(n, w))) Uses (8): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Char.to_u32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.is_lt https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.sub https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=emerging-ezhttp@0.21.0.0/src/http.bend&name=Skip https://jend.leeeet.dev/definition.txt?path=emerging-ezhttp@0.21.0.0/src/http.bend&name=octs.skip.step https://jend.leeeet.dev/definition.txt?path=emerging-ezhttp@0.21.0.0/src/http.bend&name=octs.width