#big-int #num-bigint #gmp #cryptography

rust-bigint

多个BigInt实现的常见特性和方法

2个稳定版本

1.2.0 2021年9月16日
1.1.0 2020年9月21日

#623 in 算法

Download history 1843/week @ 2024-03-13 1908/week @ 2024-03-20 1293/week @ 2024-03-27 1817/week @ 2024-04-03 653/week @ 2024-04-10 673/week @ 2024-04-17 1120/week @ 2024-04-24 1140/week @ 2024-05-01 417/week @ 2024-05-08 427/week @ 2024-05-15 327/week @ 2024-05-22 113/week @ 2024-05-29 148/week @ 2024-06-05 369/week @ 2024-06-12 1753/week @ 2024-06-19 344/week @ 2024-06-26

2,632 每月下载量
9 个crate中使用 (5 直接)

MIT 许可证

32KB
779

rust-bigint

为多个Rust BigInt实现提供常见功能特性

示例交互

// import BigInt from this library. use a feature flag to select the BigInt you need
// also, pull one or more traits from this library into scope
use rust_bigint::BigInt;
use rust_bigint::traits::Converter;
 
let number = BigInt::from(42);
// now use one of the methods exposed by the converter trait
let hex_str = number.to_hex();

查看特性以获取更多示例。


lib.rs:

为多个Rust BigInt实现提供常见功能特性

示例交互

// import BigInt from this library. use a feature flag to select the BigInt you need
// also, pull one or more traits from this library into scope
use rust_bigint::BigInt;
use rust_bigint::traits::Converter;

let number = BigInt::from(42);
// now use one of the methods exposed by the converter trait
let hex_str = number.to_hex();

查看特性以获取更多示例。

依赖项

~0.5–1.4MB
~31K SLoC