MCPcopy Create free account
hub / github.com/eth-easl/dirigent / Values

Function Values

pkg/map/maps.go:37–45  ·  view source on GitHub ↗
(m M)

Source from the content-addressed store, hash-verified

35}
36
37func Values[M ~map[K]V, K comparable, V any](m M) []V {
38 r := make([]V, 0, len(m))
39
40 for _, v := range m {
41 r = append(r, v)
42 }
43
44 return r
45}
46
47func Difference[T comparable](a, b []T) []T {
48 mb := make(map[T]struct{}, len(b))

Callers 1

TestKeysValuesFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestKeysValuesFunction · 0.68