nim-lang / needed-libraries

This repository contains a list a needed libraries.
112 stars 5 forks source link

Native support for big numbers #34

Open alehander92 opened 6 years ago

alehander92 commented 6 years ago

(From Nim community survey 2017)

jabbalaci commented 6 years ago

There is a bigint library: https://github.com/def-/nim-bigints .

mratsim commented 6 years ago

It probably need a refresh but there is a GMP wrapper: https://github.com/FedeOmoto/nim-gmp

And also a low-level wrapper for mpdecimal which is the backend for Python 3 since 3.4: https://github.com/status-im/nim-decimal

And for power of 2 stack ints like uint128, int256 ... uint2048 and more you can use stint: https://github.com/status-im/nim-stint

In the future we might also add a constant time modular bigint library for our cryptography needs at Status but for now this is not a priority: https://github.com/status-im?language=nim

DonaldTsang commented 5 years ago

What about this? https://github.com/ridiculousfish/libdivide Might wow you a bit.