Json.unique.go: def of bend-kit-json@0.7.0.0 Import: import bend-kit-json@0.7.0.0/json.bend as Json Lines 826-846 of bend-kit-json@0.7.0.0/json.bend: https://jend.leeeet.dev/read.txt?path=bend-kit-json@0.7.0.0/json.bend&start_line=826&end_line=846 import Base # The value back, whether every object nested inside it has unique keys, and # the fingerprints of v's own keys when v is an object. The caller that holds # the whole object checks those. def unique.go(v: Val) -> Val & Bool & List<&2, List<&2, U32>>: match v: case Null{}: (Null{}, True{}, Nil{}) case Flag{on}: (Flag{on}, True{}, Nil{}) case Num{s}: (Num{s}, True{}, Nil{}) case Str{s}: (Str{s}, True{}, Nil{}) case Arr{Nil{}}: (Arr{Nil{}}, True{}, Nil{}) case Arr{Con{head, tail}}: unique.array(unique.go(head), unique.go(Arr{tail})) case Obj{Nil{}}: (Obj{Nil{}}, True{}, Nil{}) case Obj{(key, head) <> tail}: unique.object(key, unique.go(head), unique.go(Obj{tail})) Uses (8): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=bend-kit-json@0.7.0.0/json.bend&name=Val https://jend.leeeet.dev/definition.txt?path=bend-kit-json@0.7.0.0/json.bend&name=unique.array https://jend.leeeet.dev/definition.txt?path=bend-kit-json@0.7.0.0/json.bend&name=unique.object