def gather_value_if

cli@0.2.0.0 · cli.bend:3671

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

3671# gather with a hit's value, or as it was on a miss: a match, not
3672# Bool.pick, so a miss builds nothing.
3673def gather_value_if(hit: Bool, gather: Gather, value: String,
3674    kind: UsageKind) -> Gather:
3675  match hit:
3676    case True{}: gather_value(gather, value, kind_many(kind))
3677    case False{}: gather

Uses (6)

Used by (1)