range-cache 0.1.0

A thread-safe sparse byte-range cache with optional async read-through
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"
rust-version = "1.85"
name = "range-cache"
version = "0.1.0"
authors = ["HelixDB, Inc. <hello@helix-db.com>"]
build = false
exclude = [".github/"]
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "A thread-safe sparse byte-range cache with optional async read-through"
homepage = "https://github.com/HelixDB/range-cache"
documentation = "https://docs.rs/range-cache"
readme = "README.md"
keywords = [
    "cache",
    "range",
    "bytes",
    "async",
    "storage",
]
categories = [
    "caching",
    "data-structures",
    "asynchronous",
]
license = "Apache-2.0"
repository = "https://github.com/HelixDB/range-cache"

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

[features]
async = [
    "dep:async-trait",
    "dep:futures-util",
    "dep:tokio",
]
default = []

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

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

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

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

[[bench]]
name = "range_cache"
path = "benches/range_cache.rs"
harness = false

[dependencies.async-trait]
version = "0.1"
optional = true

[dependencies.bytes]
version = "1"

[dependencies.futures-util]
version = "0.3"
optional = true

[dependencies.parking_lot]
version = "0.12"

[dependencies.thiserror]
version = "2"

[dependencies.tokio]
version = "1"
features = ["sync"]
optional = true

[dev-dependencies.criterion]
version = "0.5"
features = ["async_tokio"]

[dev-dependencies.proptest]
version = "1"

[dev-dependencies.tokio]
version = "1"
features = [
    "macros",
    "rt-multi-thread",
    "sync",
    "time",
]

[lints.clippy.all]
level = "warn"
priority = -1

[lints.clippy.pedantic]
level = "warn"
priority = -1

[lints.rust]
unsafe_code = "forbid"