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

Function enqueue

packages/effect/src/Graph.ts:7949–7958  ·  view source on GitHub ↗
(targets: Uint32Array, offsets: Uint32Array, current: number, depth: number)

Source from the content-addressed store, hash-verified

7947 }
7948
7949 const enqueue = (targets: Uint32Array, offsets: Uint32Array, current: number, depth: number) => {
7950 for (let i = offsets[current]; i < offsets[current + 1]; i++) {
7951 const neighbor = targets[i]
7952 if (reached[neighbor] === 0) {
7953 reached[neighbor] = 1
7954 queue[tail] = neighbor
7955 depths[tail++] = depth + 1
7956 }
7957 }
7958 }
7959
7960 while (head < tail) {
7961 const current = queue[head]

Callers 2

Graph.tsFile · 0.70
nextFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected