# 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.94"
name = "qubit-cas"
version = "0.3.4"
authors = ["Haixing Hu <starfish.hu@gmail.com>"]
build = false
exclude = [
    "coverage.sh",
    "COVERAGE.md",
    "COVERAGE.zh_CN.md",
    ".circleci/*",
    "ci-check.sh",
    ".llvm-cov.toml",
    ".cargo-audit.toml.example",
]
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Typed compare-and-swap executor with retry-aware conflict handling"
homepage = "https://github.com/qubit-ltd/rs-cas"
documentation = "https://docs.rs/qubit-cas"
readme = "README.md"
keywords = [
    "cas",
    "compare-and-swap",
    "retry",
    "atomic",
    "qubit",
]
categories = [
    "concurrency",
    "asynchronous",
]
license = "Apache-2.0"
repository = "https://github.com/qubit-ltd/rs-cas"

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

[features]
default = []
tokio = [
    "dep:tokio",
    "qubit-retry/tokio",
]

[lib]
name = "qubit_cas"
path = "src/lib.rs"
doctest = true

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

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

[dependencies.qubit-atomic]
version = "0.10"

[dependencies.qubit-common]
version = "0.6"

[dependencies.qubit-function]
version = "0.11"

[dependencies.qubit-retry]
version = "0.9.4"

[dependencies.tokio]
version = "1.52"
features = [
    "time",
    "rt",
]
optional = true

[dev-dependencies.tokio]
version = "1.52"
features = [
    "full",
    "test-util",
]

[lints.clippy]
type_complexity = "allow"
