Toon.of_toon: def of cswap-bend-cli@0.1.0.0 Import: import cswap-bend-cli@0.1.0.0/fmt/toon.bend as Toon Lines 31-50 of cswap-bend-cli@0.1.0.0/fmt/toon.bend: https://jend.leeeet.dev/read.txt?path=cswap-bend-cli@0.1.0.0/fmt/toon.bend&start_line=31&end_line=50 import Base import cswap-bend-cli@0.1.0.0/json.bend as Json import bend-toon-codec@0.1.0.0/main.bend as Toon def of_toon(j: Toon.Json) -> Json.Json: match j: case Toon.JNull{}: Json.JNull{} case Toon.JBool{b}: Json.JBool{b} case Toon.JNum{t}: Json.JNum{t} case Toon.JStr{s}: Json.JStr{s} case Toon.JArr{x}: Json.JArr{of_toon(x)} case Toon.JObj{x}: Json.JObj{of_toon(x)} case Toon.JNil{}: Json.JNil{} case Toon.JCons{h, t}: Json.JCons{of_toon(h), of_toon(t)} case Toon.JField{k, v, t}: Json.JField{k, of_toon(v), of_toon(t)} Uses (2): https://jend.leeeet.dev/definition.txt?path=bend-toon-codec@0.1.0.0/main.bend&name=Json https://jend.leeeet.dev/definition.txt?path=cswap-bend-cli@0.1.0.0/json.bend&name=Json