unit-intervals 0.1.0

Constrained f32/f64 wrapper types for normalized [0, 1] and [-1, 1] values.
Documentation
# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.

[package]
edition = "2024"
name = "unit-intervals"
version = "0.1.0"
authors = ["Markus Mayer <widemeadows@gmail.com>"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Constrained f32/f64 wrapper types for normalized [0, 1] and [-1, 1] values."
readme = "README.md"
keywords = [
    "unit-interval",
    "normalized",
    "probability",
    "float",
    "no-std",
]
categories = [
    "data-structures",
    "mathematics",
    "no-std",
]
license = "EUPL-1.2"
repository = "https://github.com/sunsided/unit-intervals"

[package.metadata.docs.rs]
all-features = true
rustdoc-args = [
    "--cfg",
    "docsrs",
]

[features]
arbitrary = ["dep:arbitrary"]
assertions = []
bytemuck = ["dep:bytemuck"]
default = ["std"]
num-traits = ["dep:num-traits"]
rand_distr = [
    "dep:rand",
    "dep:rand_distr",
]
rkyv = ["dep:rkyv"]
serde = ["dep:serde"]
std = []
unsafe = []

[lib]
name = "unit_intervals"
path = "src/lib.rs"

[[test]]
name = "arbitrary"
path = "tests/arbitrary.rs"
required-features = ["arbitrary"]

[[test]]
name = "bytemuck"
path = "tests/bytemuck.rs"
required-features = ["bytemuck"]

[[test]]
name = "math"
path = "tests/math.rs"

[[test]]
name = "num_traits"
path = "tests/num_traits.rs"
required-features = ["num-traits"]

[[test]]
name = "rand_distr"
path = "tests/rand_distr.rs"
required-features = ["rand_distr"]

[[test]]
name = "rkyv"
path = "tests/rkyv.rs"
required-features = ["rkyv"]

[[test]]
name = "serde"
path = "tests/serde.rs"
required-features = ["serde"]

[[test]]
name = "signed_unit_interval"
path = "tests/signed_unit_interval.rs"

[[test]]
name = "std"
path = "tests/std.rs"
required-features = ["std"]

[[test]]
name = "unit_interval"
path = "tests/unit_interval.rs"

[[test]]
name = "unsafe"
path = "tests/unsafe.rs"
required-features = ["unsafe"]

[dependencies.arbitrary]
version = "1.4"
optional = true

[dependencies.bytemuck]
version = "1.25"
optional = true
default-features = false

[dependencies.num-traits]
version = "0.2.19"
optional = true
default-features = false

[dependencies.rand]
version = "0.10"
optional = true
default-features = false

[dependencies.rand_distr]
version = "0.6"
optional = true
default-features = false

[dependencies.rkyv]
version = "0.8.16"
optional = true
default-features = false

[dependencies.serde]
version = "1.0"
optional = true
default-features = false

[dev-dependencies.rand]
version = "0.10"
features = ["std_rng"]
default-features = false

[dev-dependencies.rkyv]
version = "0.8.16"
features = ["alloc"]

[dev-dependencies.serde_json]
version = "1.0"