Skip to content

Commit

Permalink
Add missing unsigned final arg of Long.fromValue definition (Defini…
Browse files Browse the repository at this point in the history
  • Loading branch information
misterpickypants authored Apr 26, 2022
1 parent 839e3be commit b8d5209
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion types/long/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ declare namespace Long {
/**
* Converts the specified value to a Long.
*/
fromValue( val: Long | number | string | {low: number, high: number, unsigned: boolean} ): Long;
fromValue( val: Long | number | string | {low: number, high: number, unsigned: boolean}, unsigned?: boolean ): Long;
}
interface Long
{
Expand Down
5 changes: 5 additions & 0 deletions types/long/long-tests.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,11 @@ b = val.lessThanOrEqual(n);
b = val.lessThanOrEqual(s);

val = Long.fromValue(10);
val = Long.fromValue('10');
val = Long.fromValue(10, true);
val = Long.fromValue('10', true);
val = Long.fromValue({ low: 1, high: 1, unsigned: true });
val = Long.fromValue({ low: 1, high: 1, unsigned: true }, true);
val = val.modulo(val);
val = val.modulo(n);
val = val.modulo(s);
Expand Down

0 comments on commit b8d5209

Please sign in to comment.