Expand.build: def of bend-toon-codec@0.1.0.0 Import: import bend-toon-codec@0.1.0.0/src/expand.bend as Expand Lines 58-64 of bend-toon-codec@0.1.0.0/src/expand.bend: https://jend.leeeet.dev/read.txt?path=bend-toon-codec@0.1.0.0/src/expand.bend&start_line=58&end_line=64 import Base import bend-toon-codec@0.1.0.0/src/json.bend as J # The nested objects for a path ending in `leaf`. def build(+segs: List<&2, String>, +leaf: J.Json) -> J.Json: match segs: case Nil{}: leaf case Con{s, rest}: J.JObj{J.JField{s, build(rest, leaf), J.JNil{}}} Uses (3): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=bend-toon-codec@0.1.0.0/src/json.bend&name=Json