pub struct PatternFlags {
pub unicode: bool,
pub full_unicode: bool,
pub case_insensitive: bool,
pub dot_matches_new_line: bool,
pub multiline: bool,
pub ignore_whitespace: bool,
pub ascii_perl_classes: bool,
pub expanded_ast_limit: u64,
pub max_list_len: usize,
pub max_repeat: u32,
}Expand description
global pattern-level flags, set from RegexOptions.
Fields§
§unicode: bool\w/\d/\s match full Unicode (true) or ASCII only (false).
full_unicode: bool\w covers all Unicode word chars including 3- and 4-byte sequences.
case_insensitive: boolglobal case-insensitive matching.
dot_matches_new_line: bool. matches \n (behaves like _).
multiline: bool^ and $ match at line boundaries (\n) in addition to text boundaries.
ignore_whitespace: boolallow whitespace and # comments in the pattern.
ascii_perl_classes: boolASCII \w/\d/\s tables, but
negated perl classes (\W/\D/\S) and . match a full codepoint
expanded_ast_limit: u64max upper bound on expanded_ast_size before parser rejects the
pattern as too complex. default 50_000.
max_list_len: usizemax children allowed in any single Concat/Alternation/
Intersection node. default 4_000.
max_repeat: u32max upper bound on bounded repetition {n,m}. default 500.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for PatternFlags
impl RefUnwindSafe for PatternFlags
impl Send for PatternFlags
impl Sync for PatternFlags
impl Unpin for PatternFlags
impl UnsafeUnpin for PatternFlags
impl UnwindSafe for PatternFlags
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more