(buf, offset = 0)
| 375 | } |
| 376 | |
| 377 | function readInt40LE(buf, offset = 0) { |
| 378 | validateNumber(offset, 'offset'); |
| 379 | const first = buf[offset]; |
| 380 | const last = buf[offset + 4]; |
| 381 | if (first === undefined || last === undefined) |
| 382 | boundsError(offset, buf.length - 5); |
| 383 | |
| 384 | return (last | (last & 2 ** 7) * 0x1fffffe) * 2 ** 32 + |
| 385 | first + |
| 386 | buf[++offset] * 2 ** 8 + |
| 387 | buf[++offset] * 2 ** 16 + |
| 388 | buf[++offset] * 2 ** 24; |
| 389 | } |
| 390 | |
| 391 | function readInt32LE(buf, offset = 0) { |
| 392 | validateNumber(offset, 'offset'); |
no test coverage detected