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

Method constructor

packages/effect/src/internal/effect.ts:506–524  ·  view source on GitHub ↗
(
    context: Context.Context<never>,
    interruptible: boolean = true
  )

Source from the content-addressed store, hash-verified

504/** @internal */
505export class FiberImpl<A = any, E = any> implements Fiber.Fiber<A, E> {
506 constructor(
507 context: Context.Context<never>,
508 interruptible: boolean = true
509 ) {
510 this[FiberTypeId] = fiberVariance as any
511 this.setContext(context)
512 this.id = ++fiberIdStore.id
513 this.currentOpCount = 0
514 this.interruptible = interruptible
515 this._stack = []
516 this._observers = []
517 this._exit = undefined
518 this._children = undefined
519 this._interruptedCause = undefined
520 this._yielded = undefined
521 this._running = false
522 this._deferredInterrupt = false
523 this.runtimeMetrics?.recordFiberStart(this.context)
524 }
525
526 readonly [FiberTypeId]: Fiber.Fiber.Variance<A, E>
527

Callers

nothing calls this directly

Calls 1

setContextMethod · 0.95

Tested by

no test coverage detected