MCPcopy Create free account
hub / github.com/PolyhedraZK/ExpanderCompilerCollection / Find

Method Find

ecgo/utils/map.go:16–27  ·  view source on GitHub ↗

finds the value of e in map

(e Hashable)

Source from the content-addressed store, hash-verified

14
15// finds the value of e in map
16func (m Map) Find(e Hashable) (interface{}, bool) {
17 s, ok := m[e.HashCode()]
18 if !ok {
19 return nil, false
20 }
21 for _, x := range s {
22 if x.e.EqualI(e) {
23 return x.v, true
24 }
25 }
26 return nil, false
27}
28
29// sets the value of e to v
30func (m Map) Set(e Hashable, v interface{}) {

Callers

nothing calls this directly

Calls 2

HashCodeMethod · 0.80
EqualIMethod · 0.80

Tested by

no test coverage detected