def kv.colon

cswap-bend-cli@0.1.0.0 · fmt/yscal.bend:260

import cswap-bend-cli@0.1.0.0/fmt/yscal.bend as Yscal
import Base
import cswap-bend-cli@0.1.0.0/fmt/ylex.bend as L

260def kv.colon(+k: String, +after: String) -> KV:
261  match after:
262    case SCon{Chr{c}, t}:
263      Bool.pick(KV, U32.is_eq(c, 58) && (String.is_empty(t) || L.is_space(first_code(t))), KOk{k, String.trim(t)}, KNone{})
264    case SNil{}:
265      KNone{}

Uses (11)

Used by (1)