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

Function readIntLE

lib/internal/buffer.js:343–360  ·  view source on GitHub ↗
(offset, byteLength)

Source from the content-addressed store, hash-verified

341}
342
343function readIntLE(offset, byteLength) {
344 if (offset === undefined)
345 throw new ERR_INVALID_ARG_TYPE('offset', 'number', offset);
346 if (byteLength === 6)
347 return readInt48LE(this, offset);
348 if (byteLength === 5)
349 return readInt40LE(this, offset);
350 if (byteLength === 3)
351 return readInt24LE(this, offset);
352 if (byteLength === 4)
353 return readInt32LE(this, offset);
354 if (byteLength === 2)
355 return readInt16LE(this, offset);
356 if (byteLength === 1)
357 return readInt8(this, offset);
358
359 boundsError(byteLength, 6, 'byteLength');
360}
361
362function readInt48LE(buf, offset = 0) {
363 validateNumber(offset, 'offset');

Callers

nothing calls this directly

Calls 7

readInt48LEFunction · 0.85
readInt40LEFunction · 0.85
readInt24LEFunction · 0.85
readInt32LEFunction · 0.85
readInt16LEFunction · 0.85
readInt8Function · 0.85
boundsErrorFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…