MCPcopy Create free account
hub / github.com/brimdata/super / walkMap

Function walkMap

walk.go:102–115  ·  view source on GitHub ↗
(typ *TypeMap, body scode.Bytes, visit Visitor)

Source from the content-addressed store, hash-verified

100}
101
102func walkMap(typ *TypeMap, body scode.Bytes, visit Visitor) error {
103 keyType := TypeUnder(typ.KeyType)
104 valType := TypeUnder(typ.ValType)
105 it := body.Iter()
106 for !it.Done() {
107 if err := Walk(keyType, it.Next(), visit); err != nil {
108 return err
109 }
110 if err := Walk(valType, it.Next(), visit); err != nil {
111 return err
112 }
113 }
114 return nil
115}

Callers 1

WalkFunction · 0.85

Calls 5

TypeUnderFunction · 0.85
IterMethod · 0.80
WalkFunction · 0.70
DoneMethod · 0.45
NextMethod · 0.45

Tested by

no test coverage detected