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

Function map

repos/effect/packages/effect/src/internal/hashSet.ts:151–157  ·  view source on GitHub ↗
(self: HashSet<V>, f: (value: V) => U)

Source from the content-addressed store, hash-verified

149
150/** @internal */
151export const map = <V, U>(self: HashSet<V>, f: (value: V) => U): HashSet<U> => {
152 let result = HashMap.empty<U, boolean>()
153 for (const value of self) {
154 result = HashMap.set(result, f(value), true)
155 }
156 return makeImpl(result)
157}
158
159/** @internal */
160export const filter = <V>(self: HashSet<V>, predicate: (value: V) => boolean): HashSet<V> =>

Callers 15

transposeOptionFunction · 0.70
asSomeFunction · 0.70
effect.tsFile · 0.70
let_Function · 0.70
bindToFunction · 0.70
bindFunction · 0.70
Schedule.tsFile · 0.50
foldUntilFunction · 0.50
Sink.tsFile · 0.50
Logger.tsFile · 0.50
transposeOptionFunction · 0.50
Result.tsFile · 0.50

Calls 3

makeImplFunction · 0.70
setMethod · 0.65
fFunction · 0.50

Tested by

no test coverage detected