Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/mohanson/eint
Extended precision integer Rust library. Provides signed/unsigned integer 256 to 2048.
https://github.com/mohanson/eint
Last synced: about 2 months ago
JSON representation
Extended precision integer Rust library. Provides signed/unsigned integer 256 to 2048.
- Host: GitHub
- URL: https://github.com/mohanson/eint
- Owner: mohanson
- License: mit
- Created: 2022-02-11T09:56:57.000Z (almost 3 years ago)
- Default Branch: master
- Last Pushed: 2023-05-12T02:57:01.000Z (over 1 year ago)
- Last Synced: 2024-08-09T12:27:50.828Z (5 months ago)
- Language: Rust
- Homepage:
- Size: 37.1 KB
- Stars: 5
- Watchers: 3
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Eint
Extended precision integer Rust library. Provides signed/unsigned integer 256 to 2048.
```text
[dependencies]
eint = "1.0"
```# Usage
```rs
use eint::{E256, Eint};fn main() {
let a = E256::from(u128::MAX);
let b = E256::from(u128::MAX);
println!(" a = {:?}", a);
println!(" b = {:?}", a);
println!("a + b = {:?}", a + b);
println!("a - b = {:?}", a - b);
println!("a * b = {:?}", a * b);
println!("a / b = {:?}", a / b);
println!("a.ctz = {:?}", a.ctz());
}
```Full docs: [https://docs.rs/eint/latest/eint/](https://docs.rs/eint/latest/eint/)
# Test
```sh
# Test
$ cargo test# Fuzzing
$ cargo +nightly fuzz run arith_e64
$ cargo +nightly fuzz run arith_e256# Bench
$ cargo bench
```# Maintainer
# License
MIT.