Coverage Report

Created: 2025-08-29 06:18

/rust/registry/src/index.crates.io-6f17d22bba15001f/zerotrie-0.1.3/src/error.rs
Line
Count
Source (jump to first uncovered line)
1
// This file is part of ICU4X. For terms of use, please see the file
2
// called LICENSE at the top level of the ICU4X source tree
3
// (online at: https://github.com/unicode-org/icu4x/blob/main/LICENSE ).
4
5
use displaydoc::Display;
6
7
/// Error types for the `zerotrie` crate.
8
0
#[derive(Debug, Copy, Clone, PartialEq, Eq, Display)]
9
#[non_exhaustive]
10
pub enum Error {
11
    /// Non-ASCII data was added to an ASCII-only collection.
12
    #[displaydoc("Non-ASCII cannot be added to an ASCII-only collection")]
13
    NonAsciiError,
14
    /// The collection reached its maximum supported capacity.
15
    #[displaydoc("Reached maximum capacity of collection")]
16
    CapacityExceeded,
17
    /// The builder could not solve the perfect hash function.
18
    #[displaydoc("Failed to solve the perfect hash function. This is rare! Please report your case to the ICU4X team.")]
19
    CouldNotSolvePerfectHash,
20
    /// Mixed-case data was added to a case-insensitive trie.
21
    #[displaydoc("Mixed-case data added to case-insensitive trie")]
22
    MixedCase,
23
}