[package]
edition = "2024"
name = "oneringbuf"
version = "0.8.0"
authors = ["Skilfingr <skilvingr@gmail.com>"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "A lock-free single-producer, single-consumer (SPSC) ring buffer with in-place mutability, asynchronous support, and virtual memory optimisation."
documentation = "https://docs.rs/oneringbuf"
readme = "README.md"
keywords = [
"lock-free",
"async",
"mmap",
"circular",
"buffer",
]
categories = [
"asynchronous",
"concurrency",
"data-structures",
"no-std",
"no-std::no-alloc",
]
license = "MIT OR Apache-2.0"
repository = "https://github.com/Skilvingr/rust-oneringbuf"
[package.metadata.docs.rs]
all-features = true
[features]
alloc = []
async = ["dep:futures-util"]
default = ["alloc"]
thread_sanitiser = []
vmem = [
"alloc",
"dep:libc",
]
[lib]
name = "oneringbuf"
path = "src/lib.rs"
[[example]]
name = "cpal"
path = "examples/cpal.rs"
[[example]]
name = "main_example"
path = "examples/main_example.rs"
[[example]]
name = "manage_traits"
path = "examples/manage_traits.rs"
required-features = [
"alloc",
"async",
]
[[example]]
name = "simple"
path = "examples/simple.rs"
[[example]]
name = "simple_async"
path = "examples/simple_async.rs"
[[example]]
name = "uninit_items"
path = "examples/uninit_items.rs"
[[test]]
name = "tests"
path = "tests/tests.rs"
[[bench]]
name = "base"
path = "benches/divan/base.rs"
harness = false
required-features = ["alloc"]
[[bench]]
name = "iai_base"
path = "benches/iai_benches/iai_base.rs"
harness = false
required-features = ["alloc"]
[[bench]]
name = "parts"
path = "benches/divan/parts.rs"
harness = false
required-features = ["alloc"]
[[bench]]
name = "slices"
path = "benches/divan/slices.rs"
harness = false
required-features = ["alloc"]
[[bench]]
name = "stack"
path = "benches/divan/stack.rs"
harness = false
[dependencies.crossbeam-utils]
version = "0.8"
default-features = false
[dependencies.futures-util]
version = "0.3"
optional = true
default-features = false
[dependencies.libc]
version = "0.2"
optional = true
default-features = false
[dev-dependencies.async-scoped]
version = "0.9"
features = ["use-tokio"]
[dev-dependencies.divan]
version = "0.1.21"
[dev-dependencies.gungraun]
version = "0.18.2"
[dev-dependencies.libc]
version = "0.2"
[dev-dependencies.tokio]
version = "1.52.3"
features = [
"rt",
"rt-multi-thread",
"macros",
"time",
]
[target."cfg(cpal)".dev-dependencies.cpal]
version = "0.16.0"
[lints.rust.unexpected_cfgs]
level = "warn"
priority = 0
check-cfg = ["cfg(cpal)"]
[profile.dev]
opt-level = 0
debug = 2