Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion lib/bignum.ts
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ export function msb(x: Uint8Array): number {
* @returns {Uint8Array}
*/
export function multiply(a: Uint8Array, b: Uint8Array, ops?: number): Uint8Array {
let z = new Uint8Array(a.length + b.length);
let z: Uint8Array = new Uint8Array(a.length + b.length);
let x = new Uint8Array(z.length);
let y = new Uint8Array(z.length);
x.set(a, z.length - a.length);
Expand Down
4 changes: 2 additions & 2 deletions lib/compare.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ export function compare_alt(left: Uint8Array, right: Uint8Array): Uint32Array {
}
let gt: number = 0;
let eq: number = 1;
let l: int32;
let r: int32;
let l: int32 = int32.zero();
let r: int32 = int32.zero();
for (let i: number = 0; i < left.length; i++) {
r = int32.fromInt(right[i]);
l = int32.fromInt(left[i]);
Expand Down
2 changes: 1 addition & 1 deletion lib/int32.ts
Original file line number Diff line number Diff line change
Expand Up @@ -269,7 +269,7 @@ function int32_and_number(a: int32, b: number): int32 {
return new int32(l & 0xffff, h & 0xffff);
}

function int32_compare(left, right): int32 {
function int32_compare(left: int32, right: int32): int32 {
const diff: int32 = right.sub(left);
/*
This borrows a trick from Thomas Pornin's CTTK library:
Expand Down
Loading