MCPcopy Create free account
hub / github.com/effect-app/libs / fromIterable

Function fromIterable

repos/effect/packages/effect/src/internal/hashSet.ts:75–81  ·  view source on GitHub ↗
(values: Iterable<V>)

Source from the content-addressed store, hash-verified

73
74/** @internal */
75export const fromIterable = <V>(values: Iterable<V>): HashSet<V> => {
76 let map = HashMap.empty<V, boolean>()
77 for (const value of values) {
78 map = HashMap.set(map, value, true)
79 }
80 return makeImpl(map)
81}
82
83/** @internal */
84export const has = <V>(self: HashSet<V>, value: V): boolean => HashMap.has(keyMap(self), value)

Callers 1

makeFunction · 0.70

Calls 2

makeImplFunction · 0.70
setMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…