4 ms·
Try "StInt: A fast and portable stack-based multi-precision integer library in pure Nim" Being stack based and having some nice compile time evaluation feature
by arc776 8y ago
Try "StInt: A fast and portable stack-based multi-precision integer library in pure Nim"
Being stack based and having some nice compile time evaluation features should make it very performant.
Here: https://github.com/status-im/nim-stint https://github.com/status-im/nim-stint
- ColinWright 8y agoThat's excellent - thank you. Assume I'm not a complete numpty, but are there directions for: * Download * Install * Invoke ... anywhere? I'm not at all familiar with retrieving and installing libraries from git, nor with NIM and how/where to install code. All assistance gratefully received. Pointers to existing detailed instructions also very welcome. I can investigate all this myself with trial-and-error, but if someone's done it before it saves me the time and effort of making all the mistakes again. Thanks.
- mratsim 8y agoEasiest way to start with nim is via choosenim: https://github.com/dom96/choosenim https://github.com/dom96/choosenim then `nimble install https://github.com/status-im/nim-stint` https://github.com/status-im/nim-stint` Unfortunately I didn't have time to focus on documentation but the easiest way to get started with Stint is to check the tests: https://github.com/status-im/nim-stint/tree/master/tests https://github.com/status-im/nim-stint/tree/master/tests. The casts are there to check binary representation compatibility in the tests and are not needed otherwise. Alternatively you can check: - https://github.com/FedeOmoto/nim-gmp https://github.com/FedeOmoto/nim-gmp, A GMP wrapper (very low-level/C-like and not updated since 2015) - https://github.com/status-im/nim-decimal https://github.com/status-im/nim-decimal, a arbitrary-precision floating point wrapper to MpDecimal (used by python). Unfortunately it's very low-level/C-like at the moment.