bytesCombine
bytesCombine(
a,b,combine):Uint8Array<ArrayBuffer>
Defined in: packages/core/src/buffer/bytes-combine.ts:19
Applies combine to each octet pair of two equal-length arrays.
The result of combine is masked to one octet. Pairing stops at the shorter
array only when lengths are allowed to differ, which they are not here: a
bitwise operation over mismatched widths has no meaning, so it throws rather
than silently truncating.
Complexity: O(n) time and O(n) memory in the input length.
Parameters
Section titled “Parameters”Uint8Array
The left octets.
Uint8Array
The right octets.
combine
Section titled “combine”(left, right, index) => number
Called with each octet pair and its index.
Returns
Section titled “Returns”Uint8Array<ArrayBuffer>
A new array of the same length.
Throws
Section titled “Throws”RangeError When the two arrays differ in length.