indutny / bn.js

BigNum in pure javascript
MIT License
1.19k stars 150 forks source link

Why do the read functions say they take in type `BN`? #257

Closed SurienDG closed 3 years ago

SurienDG commented 3 years ago

Example: When I try to do redSub(b: BN): RedBN it with a regular BN for b it gives me an error that says Error: red works only with red numbers.

So shouldn't the input type here be RedBN not BN?

image

fanatid commented 3 years ago

Is this from some TS definition? If so, please contact the author of these definitions because we do not provide them.