monster_regex/flags/
mod.rs

1/// Configuration flags that modify the behavior of the regular expression engine.
2#[derive(Default, Clone, Copy, Debug)]
3pub struct Flags {
4    /// Controls case sensitivity.
5    /// - `None`: Smartcase (case-insensitive if pattern is all lowercase, sensitive otherwise).
6    /// - `Some(true)`: Case-insensitive (`i` flag).
7    /// - `Some(false)`: Case-sensitive (`c` flag).
8    pub ignore_case: Option<bool>,
9    /// If true, `^` and `$` match line boundaries (`\n`) instead of just the start/end of the text (`m` flag).
10    pub multiline: bool,
11    /// If true, `.` matches newlines (`s` flag).
12    pub dotall: bool,
13    /// If true, whitespace and comments in the pattern are ignored (`x` flag).
14    pub verbose: bool,
15    /// If true, enables Unicode support for character classes (`u` flag).
16    pub unicode: bool,
17    /// If true, indicates that the regex should match all occurrences (`g` flag).
18    /// Note: This flag is often handled by the caller (e.g., `find_all` vs `find`), but is preserved here for parsing.
19    pub global: bool,
20}