1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96
|
# This file is part of ICU4X. For terms of use, please see the file
# called LICENSE at the top level of the ICU4X source tree
# (online at: https://github.com/unicode-org/icu4x/blob/main/LICENSE ).
[package]
name = "zerovec"
description = "Zero-copy vector backed by a byte array"
version = "0.11.1"
categories = ["rust-patterns", "memory-management", "caching", "no-std", "data-structures"]
keywords = ["zerocopy", "serialization", "zero-copy", "serde"]
authors.workspace = true
edition.workspace = true
include.workspace = true
license.workspace = true
repository.workspace = true
rust-version.workspace = true
[package.metadata.workspaces]
independent = true
[package.metadata.docs.rs]
all-features = true
[dependencies]
zerofrom = { workspace = true }
zerovec-derive = { workspace = true, optional = true}
databake = { workspace = true, features = ["derive"], optional = true }
serde = { workspace = true, features = ["alloc", "derive"], optional = true }
yoke = { workspace = true, optional = true }
twox-hash = { workspace = true, optional = true }
[dev-dependencies]
bincode = { workspace = true }
getrandom = { workspace = true, features = ["js"] }
iai = { workspace = true }
icu_benchmark_macros = { path = "../../tools/benchmark/macros" }
postcard = { workspace = true, features = ["use-std"] }
rand = { workspace = true }
rand_distr = { workspace = true }
rand_pcg = { workspace = true }
rmp-serde = { workspace = true }
serde = { workspace = true, features = ["derive"] }
serde_json = { workspace = true }
potential_utf = { path = "../../utils/potential_utf", features = ["zerovec"] }
yoke = { workspace = true, features = ["derive"] }
zerofrom = { path = "../../utils/zerofrom", features = ["derive"] }
[target.'cfg(not(target_arch = "wasm32"))'.dev-dependencies]
criterion = { workspace = true }
[features]
derive = ["dep:zerovec-derive"]
hashmap = ["dep:twox-hash", "alloc"]
yoke = ["dep:yoke"]
serde = ["dep:serde", "alloc"]
databake = ["dep:databake"]
alloc = []
# No longer does anything
std = []
[package.metadata.cargo-all-features]
# We have tons of features here, limit the amount of tests we run
max_combination_size = 3
[lib]
bench = false # This option is required for Benchmark CI
[[bench]]
name = "zerovec"
harness = false
[[bench]]
name = "zerovec_serde"
harness = false
required-features = ["serde"]
[[bench]]
name = "vzv"
harness = false
[[bench]]
name = "zerovec_iai"
harness = false
[[bench]]
name = "zeromap"
harness = false
required-features = ["serde", "hashmap", "derive"]
[[example]]
name = "zv_serde"
required-features = ["serde"]
|