def lit2

bend-kit-time@0.3.0.0 · time.bend:425

import bend-kit-time@0.3.0.0/time.bend as Time
import Base

425# One char that is a or b.
426def lit2(+a: U32, +b: U32, p: P) -> Maybe<&2, P>:
427  match p:
428    case P{vs, s}:
429      match s:
430        case SNil{}:
431          None{}
432        case SCon{Chr{+c}, t}:
433          lit.if(Bool.or(U32.is_eq(c, a), U32.is_eq(c, b)), vs, t)

Uses (8)

Used by (2)