Format.measure: def of bend-lint-rules@0.2.0.0 Import: import bend-lint-rules@0.2.0.0/layout/format.bend as Format Lines 1246-1258 of bend-lint-rules@0.2.0.0/layout/format.bend: https://jend.leeeet.dev/read.txt?path=bend-lint-rules@0.2.0.0/layout/format.bend&start_line=1246&end_line=1258 import Base # Docs # ---- def measure(s: String, +n: U32, tail: Maybe<&2, U32>, keep: U32) -> Measure: match s: case SNil{}: Measure{n, tail, keep} case SCon{+c, rest}: measure( rest, (n + 1: U32), tail_after(c, tail), Bool.pick(U32, is_blank(c), keep, (n + 1: U32)) ) Uses (8): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.pick https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32.add https://jend.leeeet.dev/definition.txt?path=bend-lint-rules@0.2.0.0/layout/format.bend&name=Measure https://jend.leeeet.dev/definition.txt?path=bend-lint-rules@0.2.0.0/layout/format.bend&name=is_blank https://jend.leeeet.dev/definition.txt?path=bend-lint-rules@0.2.0.0/layout/format.bend&name=tail_after