Portable components on C++ for Neo

Igor Machado
NeoResearch
Published in
2 min readJul 26, 2019

One of the biggest challenges of a protocol is to be easy to implement and maintain on multiple programming languages and platforms. Neo blockchain core implementation uses .NET framework and C# language, which is quite portable itself and an amazing choice, with widespread implementations on all mostly used operating systems nowadays.

Yet, some products on the blockchain ecosystem are specially designed for C++ language, which is also a fundamental technology for any existing platforms. In this sense, it is natural to have implementation alternatives to guarantee larger adoption and integration with all existing programming languages. A first and solid step towards larger portability was taken by NeoResearch community, by providing an alternative implementation of the Neo blockchain on C++ language.

The first completed component (during July/2019), achieved 100% coverage on unit tests and is fully compatible implementation with the Mono framework: the numerics/BigInteger library. This is presented as part of the csBigInteger project, hosted at: https://github.com/neoresearch/csbiginteger (and specifically at https://github.com/neoresearch/csbiginteger.cpp for C++). This is a fundamental component for user wallets and Neo SDK (on other languages than C#). A portable implementation has been made available already for Python language (see https://github.com/neoresearch/csbiginteger.py), and another one for JavaScript (see https://github.com/neoresearch/csbiginteger.js).

Another fundamental component of Neo blockchain is its virtual machine, the so-called NeoVM. An ongoing implementation NeoVM v3 on C++ is already available at https://github.com/neoresearch/nvmpp. The idea is to also offer a Mono based implementation (just like csBigInteger), which uses original core implementation to guarantee its correctness, and at the same time, only requiring that users have the Mono Runtime libraries (not complete Mono dev libraries).

On a longer shot, all these components work together inside Neo Portable project (called neopt), hosted at https://github.com/neoresearch/neopt. Feel free to visit it, and even take parts of it for your project, as it’s all free anyway! The more components and more options to developers, we get a much more beautiful and diversified Neo Ecosystem ;)

--

--