def resolve.low

cswap-bend-cli@0.1.0.0 · fmt/ylex.bend:120

import cswap-bend-cli@0.1.0.0/fmt/ylex.bend as Ylex
import Base
import cswap-bend-cli@0.1.0.0/json.bend as Json

120# A plain word as the value it stands for.
121def resolve.low(+low: String, +s: String) -> Json.Json:
122  Bool.pick(Json.Json, is_null_word(low), Json.JNull{},
123  Bool.pick(Json.Json, word_is(low, "true"), Json.JBool{True{}},
124  Bool.pick(Json.Json, word_is(low, "false"), Json.JBool{False{}},
125  Bool.pick(Json.Json, is_number(s), Json.JNum{s}, Json.JStr{s}))))

Uses (7)

Used by (1)