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

Function interruptAll

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

Source from the content-addressed store, hash-verified

2211 const fibers = new Set<FiberRuntime<Exit.Exit<X, E> | Effect.Blocked<X, E>>>()
2212 const results = new Array()
2213 const interruptAll = () =>
2214 fibers.forEach((fiber) => {
2215 fiber.currentScheduler.scheduleTask(
2216 () => {
2217 fiber.unsafeInterruptAsFork(parent.id())
2218 },
2219 0,
2220 fiber
2221 )
2222 })
2223 const startOrder = new Array<FiberRuntime<Exit.Exit<X, E> | Effect.Blocked<X, E>>>()
2224 const joinOrder = new Array<FiberRuntime<Exit.Exit<X, E> | Effect.Blocked<X, E>>>()
2225 const residual = new Array<core.Blocked>()

Callers 2

onInterruptSignalFunction · 0.70
raceAllFunction · 0.70

Calls 3

scheduleTaskMethod · 0.65
unsafeInterruptAsForkMethod · 0.65
idMethod · 0.65

Tested by

no test coverage detected