icu_locid 1.1.0

API for managing Unicode Language and Locale Identifiers
Documentation
# 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 = "icu_locid"
description = "API for managing Unicode Language and Locale Identifiers"
version = "1.1.0"
authors = ["The ICU4X Project Developers"]
edition = "2021"
readme = "README.md"
repository = "https://github.com/unicode-org/icu4x"
license = "Unicode-DFS-2016"
categories = ["internationalization"]
# Keep this in sync with other crates unless there are exceptions
include = [
    "src/**/*",
    "examples/**/*",
    "benches/**/*",
    "tests/**/*",
    "Cargo.toml",
    "LICENSE",
    "README.md"
]

[package.metadata.docs.rs]
all-features = true

[dependencies]
displaydoc = { version = "0.2.3", default-features = false }
litemap = { version = "0.6.1", path = "../../utils/litemap" }
tinystr = { version = "0.7.1", path = "../../utils/tinystr", features = ["alloc"], default-features = false }
writeable = { version = "0.5.1", path = "../../utils/writeable" }

databake = { version = "0.1.3", path = "../../utils/databake", features = ["derive"], optional = true}
serde = { version = "1.0", default-features = false, features = ["alloc", "derive"], optional = true }
zerovec = { version = "0.9.2", path = "../../utils/zerovec", optional = true }

[dev-dependencies]
criterion = "0.3.3"
iai = "0.1.1"
icu = { path = "../icu", default-features = false }
icu_benchmark_macros = { path = "../../tools/benchmark/macros" }
litemap = { path = "../../utils/litemap", features = ["testing"]}
postcard = { version = "1.0.0", default-features = false, features = ["use-std"] }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"

[features]
std = []
databake = ["dep:databake"]
serde = ["dep:serde", "tinystr/serde"]
zerovec = ["dep:zerovec"]
bench = ["serde"]

[lib]
path = "src/lib.rs"
bench = false  # This option is required for Benchmark CI

[package.metadata.cargo-all-features]
# Bench feature gets tested separately and is only relevant for CI
denylist = ["bench"]

[[bench]]
name = "subtags"
harness = false
required-features = ["bench"]

[[bench]]
name = "langid"
harness = false

[[bench]]
name = "locale"
harness = false

[[bench]]
name = "iai_langid"
harness = false
required-features = ["bench"]

[[example]]
name = "filter_langids"
test = true

[[example]]
name = "syntatically_canonicalize_locales"
test = true