Enum regex_automata::nfa::thompson::error::BuildErrorKind
source · enum BuildErrorKind {
Syntax(Error),
Captures(GroupInfoError),
Word(UnicodeWordBoundaryError),
TooManyPatterns {
given: usize,
limit: usize,
},
TooManyStates {
given: usize,
limit: usize,
},
ExceededSizeLimit {
limit: usize,
},
InvalidCaptureIndex {
index: u32,
},
UnsupportedCaptures,
}
Expand description
The kind of error that occurred during the construction of a thompson NFA.
Variants§
Syntax(Error)
An error that occurred while parsing a regular expression. Note that this error may be printed over multiple lines, and is generally intended to be end user readable on its own.
Captures(GroupInfoError)
An error that occurs if the capturing groups provided to an NFA builder do not satisfy the documented invariants. For example, things like too many groups, missing groups, having the first (zeroth) group be named or duplicate group names within the same pattern.
Word(UnicodeWordBoundaryError)
An error that occurs when an NFA contains a Unicode word boundary, but where the crate was compiled without the necessary data for dealing with Unicode word boundaries.
TooManyPatterns
An error that occurs if too many patterns were given to the NFA compiler.
Fields
TooManyStates
An error that occurs if too states are produced while building an NFA.
Fields
ExceededSizeLimit
An error that occurs when NFA compilation exceeds a configured heap limit.
InvalidCaptureIndex
An error that occurs when an invalid capture group index is added to
the NFA. An “invalid” index can be one that would otherwise overflow
a usize
on the current target.
UnsupportedCaptures
An error that occurs when one tries to build a reverse NFA with captures enabled. Currently, this isn’t supported, but we probably should support it at some point.
Trait Implementations§
source§impl Clone for BuildErrorKind
impl Clone for BuildErrorKind
source§fn clone(&self) -> BuildErrorKind
fn clone(&self) -> BuildErrorKind
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more