[package]
name = "rain-math-float"
version = "0.1.12"
edition = "2021"
license = "LicenseRef-DCL-1.0"
description = "Decimal floating-point arithmetic for Rainlang / DeFi smart contracts. Packs a 224-bit signed coefficient and 32-bit signed exponent into a single bytes32, with exact decimal semantics (no NaN, Infinity, or negative zero — operations error on nonsense). Rust bindings delegate to the Solidity reference via an in-memory EVM so on-chain and off-chain results match exactly."
homepage = "https://github.com/rainlanguage/rain.math.float.deploy"
repository = "https://github.com/rainlanguage/rain.math.float.deploy"
[features]
test-harness = ["dep:serde_json"]
[lib]
crate-type = ["rlib"]
[dependencies]
alloy = { version = "1.0.9", default-features = false, features = [
"sol-types",
"json",
"json-abi",
] }
thiserror = "2.0.12"
serde_json = { version = "1.0.140", optional = true }
serde = "1.0.219"
wasm-bindgen = "0.2.122"
wasm-bindgen-utils = "0.1.2"
[target.'cfg(not(target_family = "wasm"))'.dependencies]
revm = { version = "36", default-features = false, features = [
"c-kzg",
"portable",
"std",
"tracer",
] }
[target.'cfg(target_family = "wasm")'.dependencies]
revm = { version = "36", default-features = false, features = [
"portable",
"std",
"tracer",
] }
getrandom = { version = "0.2.11", features = ["js", "js-sys"] }
[dev-dependencies]
alloy = { version = "1.0.9", default-features = false, features = [
"sol-types",
"json",
"json-abi",
"arbitrary",
] }
anyhow = "1.0.98"
proptest = "1.7.0"
serde_json = "1.0.140"