e65fd4e5b2
bigint: small to_str_radix optimization Before: ``` test fac_to_string ... bench: 1,630 ns/iter (+/- 34) test fib_to_string ... bench: 359 ns/iter (+/- 11) test to_str_radix_02 ... bench: 3,097 ns/iter (+/- 19) test to_str_radix_08 ... bench: 1,146 ns/iter (+/- 38) test to_str_radix_10 ... bench: 4,248 ns/iter (+/- 36) test to_str_radix_16 ... bench: 881 ns/iter (+/- 44) test to_str_radix_36 ... bench: 8,073 ns/iter (+/- 75) ``` After: ``` test fac_to_string ... bench: 1,492 ns/iter (+/- 20) test fib_to_string ... bench: 368 ns/iter (+/- 7) test to_str_radix_02 ... bench: 2,038 ns/iter (+/- 47) test to_str_radix_08 ... bench: 812 ns/iter (+/- 9) test to_str_radix_10 ... bench: 3,919 ns/iter (+/- 40) test to_str_radix_16 ... bench: 703 ns/iter (+/- 58) test to_str_radix_36 ... bench: 7,852 ns/iter (+/- 81) ``` |
||
---|---|---|
.travis | ||
benches | ||
doc | ||
num-macros | ||
src | ||
.gitignore | ||
.multirust.sh | ||
.travis.yml | ||
Cargo.toml | ||
LICENSE-APACHE | ||
LICENSE-MIT | ||
README.md |
README.md
num
A collection of numeric types and traits for Rust.
This includes new types for big integers, rationals, and complex numbers, new traits for generic programming on numeric properties like `Integer, and generic range iterators.
Usage
Add this to your Cargo.toml
:
[dependencies]
num = "0.1"
and this to your crate root:
extern crate num;