Go to file
Tomasz Drwięga 41149b79f9
Bump versions.
2018-03-15 10:06:43 +01:00
benches Fix warnings 2017-08-22 15:18:33 +02:00
ethbloom Bump versions. 2018-03-15 10:06:43 +01:00
ethereum-types Bump versions. 2018-03-15 10:06:43 +01:00
fixed-hash Bump versions. 2018-03-15 10:06:43 +01:00
serialize next release 2018-02-04 12:53:35 +01:00
tests Bump versions. 2018-03-15 10:06:43 +01:00
uint Bump versions. 2018-03-15 10:06:43 +01:00
.editorconfig Fix indentation. 2018-01-28 17:48:23 +01:00
.gitignore mul and from optimizations 2017-08-17 17:25:00 +02:00
.travis.yml run tests in release mode 2017-11-14 16:57:32 +01:00
Cargo.toml build script and feature cleanup 2018-01-31 22:08:43 +01:00
LICENSE-APACHE relicense under mit/apache2 2017-05-11 15:25:52 +02:00
LICENSE-MIT relicense under mit/apache2 2017-05-11 15:25:52 +02:00
README.md Update example 2018-02-13 09:40:05 +01:00

README.md

bigint

Build Status

Fixed-sized integers arithmetic

To specify a dependency, add to Cargo.toml

[dependencies]
ethereum-types = "0.2"

Little example

extern crate ethereum_types;
use ethereum_types::U256;

fn main() {
	let mut val: U256 = 1023.into();
	for _ in 0..200 { val = val * 2u32 }
	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:

[dependencies]
ethereum-types = { version = "4", default-features = false }