def Yaml.blanks

bend-kube-runtime@0.2.0.0 · src/yaml.bend:146

import bend-kube-runtime@0.2.0.0/src/yaml.bend as Yaml
import Base

146# Trailing blank lines (of a reversed list): how many, and the rest.
147def Yaml.blanks(xs: List<&2, String>, +n: U32) -> U32:
148  match xs:
149    case Con{SNil{}, t}:
150      Yaml.blanks(t, (n + 1 : U32))
151    case _:
152      n

Uses (4)

Used by (1)