paritytech/bigint

Name: bigint

Owner: Parity Technologies

Description: null

Created: 2016-12-22 10:15:12.0

Updated: 2018-05-20 04:01:17.0

Pushed: 2018-05-11 15:21:05.0

Homepage: null

Size: 225

Language: Rust

GitHub Committers

UserMost Recent Commit# Commits

Other Committers

UserEmailMost Recent Commit# Commits

README

bigint

Build Status

API Documentation

Fixed-sized integers arithmetic

To specify a dependency, add to Cargo.toml

endencies]
nt = "4"

Little example

rn crate bigint;
bigint::U256;

ain() {
let mut val: U256 = 1023.into();
for _ in 0..200 { val = val * 2.into() }
assert_eq!(
    &format!("{}", val), 
    "1643897619276947051879427220465009342380213662639797070513307648"
);

no_std crates

This crate has a feature, std, that is enabled by default. To use this crate in a no_std context, add the following to your Cargo.toml:

endencies]
nt = { version = "4", default-features = false }

This work is supported by the National Institutes of Health's National Center for Advancing Translational Sciences, Grant Number U24TR002306. This work is solely the responsibility of the creators and does not necessarily represent the official views of the National Institutes of Health.