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

Function readUInt40BE

lib/internal/buffer.js:296–308  ·  view source on GitHub ↗
(buf, offset = 0)

Source from the content-addressed store, hash-verified

294}
295
296function readUInt40BE(buf, offset = 0) {
297 validateNumber(offset, 'offset');
298 const first = buf[offset];
299 const last = buf[offset + 4];
300 if (first === undefined || last === undefined)
301 boundsError(offset, buf.length - 5);
302
303 return first * 2 ** 32 +
304 buf[++offset] * 2 ** 24 +
305 buf[++offset] * 2 ** 16 +
306 buf[++offset] * 2 ** 8 +
307 last;
308}
309
310function readUInt32BE(buf, offset = 0) {
311 validateNumber(offset, 'offset');

Callers 1

readUIntBEFunction · 0.85

Calls 1

boundsErrorFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…