MCPcopy Create free account
hub / github.com/Effect-TS/effect / makeCombinerFailFast

Function makeCombinerFailFast

packages/effect/src/Option.ts:2434–2439  ·  view source on GitHub ↗
(combiner: Combiner.Combiner<A>)

Source from the content-addressed store, hash-verified

2432 * @since 4.0.0
2433 */
2434export function makeCombinerFailFast<A>(combiner: Combiner.Combiner<A>): Combiner.Combiner<Option<A>> {
2435 return Combiner.make((self, that) => {
2436 if (isNone(self) || isNone(that)) return none()
2437 return some(combiner.combine(self.value, that.value))
2438 })
2439}
2440
2441/**
2442 * Creates a `Reducer` for `Option<A>` by lifting an existing `Reducer` with

Callers 1

makeReducerFailFastFunction · 0.70

Calls 5

isNoneFunction · 0.85
noneFunction · 0.70
someFunction · 0.70
makeMethod · 0.65
combineMethod · 0.65

Tested by

no test coverage detected