nim-lang / bigints

BigInts for Nim
MIT License
124 stars 32 forks source link

add `toSignedInt`, closes #72 #74

Closed narimiran closed 2 years ago

konsumlamm commented 2 years ago

Nice! I think we should also support unsigned integers, is there any particular reason you didn't include them here? toInt would probably be a better name then, unless we want a separate toUnsignedInt function (which would be kinda weird since we already have to specify the int type anyway)?

narimiran commented 2 years ago

I think we should also support unsigned integers, is there any particular reason you didn't include them here?

To get your comments, improve the code, and then based on that, continue with unsigned.

Araq commented 2 years ago

I need these additions so I'm merging it. Later on more improvements can follow. I also don't mind to change my code if you decide to tune the API.