MCPcopy Index your code
hub / github.com/nodejs/node / source

Function source

benchmark/streams/iter-throughput-transform.js:107–113  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

105 async function run() {
106 let remaining = datasize;
107 async function* source() {
108 while (remaining > 0) {
109 const size = Math.min(remaining, chunk.length);
110 remaining -= size;
111 yield [size === chunk.length ? chunk : chunk.subarray(0, size)];
112 }
113 }
114 await pipeTo(source(), upper,
115 { write() {}, writeSync() { return true; } });
116 }

Callers 2

runFunction · 0.70
benchIterSyncFunction · 0.70

Calls 1

minMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…