MCPcopy Index your code
hub / github.com/Effect-TS/effect / returnNextElement

Function returnNextElement

packages/effect/src/internal/fiberRuntime.ts:2281–2289  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2279 const a = todos.pop()!
2280 let index = counter++
2281 const returnNextElement = () => {
2282 const a = todos.pop()!
2283 index = counter++
2284 return core.flatMap(core.yieldNow(), () =>
2285 core.flatMap(
2286 stepOrExit(restore(f(a, index))),
2287 onRes
2288 ))
2289 }
2290 const onRes = (
2291 res: Exit.Exit<X, E> | Effect.Blocked<X, E>
2292 ): Effect.Effect<Exit.Exit<X, E> | Effect.Blocked<X, E>, never, R> => {

Callers 1

onResFunction · 0.85

Calls 2

restoreFunction · 0.85
fFunction · 0.50

Tested by

no test coverage detected