29012231a8
Use a build script to detect if we can use MaybeUninit or NoDrop. Enabling unstable features automatically is not ideal, but since it's a soundness issue we should do it. Use a MaybeUninit-like union on nightly when we can. We use a feature detection script in build.rs, so that we also go back to the fallback if the unstable feature changes in an unexpected way. We need to continue to use NoDrop for best working stable implementation, but we eagerly use our union solution where we can, currently only in nightlies. Rustc feature probe code written by Josh Stone (cuviper), taken from num-bigint.
55 lines
1.1 KiB
TOML
55 lines
1.1 KiB
TOML
[package]
|
|
name = "arrayvec"
|
|
version = "0.4.8"
|
|
authors = ["bluss"]
|
|
license = "MIT/Apache-2.0"
|
|
|
|
description = "A vector with fixed capacity, backed by an array (it can be stored on the stack too). Implements fixed capacity ArrayVec and ArrayString."
|
|
documentation = "https://docs.rs/arrayvec/"
|
|
repository = "https://github.com/bluss/arrayvec"
|
|
|
|
keywords = ["stack", "vector", "array", "data-structure", "no_std"]
|
|
categories = ["data-structures", "no-std"]
|
|
|
|
[build-dependencies]
|
|
|
|
[dependencies]
|
|
nodrop = { version = "0.1.12", path = "nodrop", default-features = false }
|
|
|
|
[dependencies.serde]
|
|
version = "1.0"
|
|
optional = true
|
|
default-features = false
|
|
|
|
[dev-dependencies.serde_test]
|
|
version = "1.0"
|
|
|
|
[dev-dependencies]
|
|
matches = { version = "0.1" }
|
|
bencher = "0.1.4"
|
|
|
|
[[bench]]
|
|
name = "extend"
|
|
harness = false
|
|
|
|
[[bench]]
|
|
name = "arraystring"
|
|
harness = false
|
|
|
|
[features]
|
|
default = ["std"]
|
|
std = []
|
|
serde-1 = ["serde"]
|
|
|
|
array-sizes-33-128 = []
|
|
array-sizes-129-255 = []
|
|
|
|
# has no effect
|
|
use_union = []
|
|
|
|
[package.metadata.docs.rs]
|
|
features = ["serde-1"]
|
|
|
|
[package.metadata.release]
|
|
no-dev-version = true
|