def leading_indent

cli@0.2.0.0 · cli.bend:1007

import cli@0.2.0.0/cli.bend as Cli
import Base

1007def leading_indent(s: String) -> String:
1008  match s:
1009    case SNil{}:
1010      ""
1011    case SCon{+head, tail}:
1012      Bool.pick(String, Char.is_eq(head, ' '),
1013        SCon{head, leading_indent(tail)}, "")

Uses (4)

Used by (1)