Unroll u8aToBn loops (#1535)
* Unroll u8aToBn loops * Adjust with additional xor shortcuts * Adjust mult -> shift (where below u32) * assertUnreachable * Add u8aToNumber
This commit is contained in:
@@ -1,6 +1,10 @@
|
||||
// Copyright 2017-2022 @polkadot/util authors & contributors
|
||||
// SPDX-License-Identifier: Apache-2.0
|
||||
|
||||
/**
|
||||
* @name arrayZip
|
||||
* @description Combines 2 distinct key/value arrays into a single [K, V] array
|
||||
*/
|
||||
export function arrayZip <K, V> (keys: K[], values: V[]): [K, V][] {
|
||||
const result = new Array<[K, V]>(keys.length);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user