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

Function Pad

deps/v8/test/mjsunit/wasm/memory-resizable-buffer-array-slice.js:14–18  ·  view source on GitHub ↗
(a, v, start, ctor, pages)

Source from the content-addressed store, hash-verified

12const kPageSize = 0x10000;
13
14function Pad(a, v, start, ctor, pages) {
15 for (let i = start; i < (pages * kPageSize) / ctor.BYTES_PER_ELEMENT; ++i) {
16 a.push(v);
17 }
18}
19
20function ZeroPad(a, start, ctor, pages) {
21 Pad(a, 0, start, ctor, pages);

Callers 2

ZeroPadFunction · 0.70

Calls 1

pushMethod · 0.45

Tested by

no test coverage detected