pcre2: small polishing

This commit is contained in:
Andrew Gallant
2023-09-25 16:53:03 -04:00
parent 96f01b92a0
commit 798f8981eb
4 changed files with 17 additions and 22 deletions

View File

@@ -1,7 +1,9 @@
use std::collections::HashMap;
use grep_matcher::{Captures, Match, Matcher};
use pcre2::bytes::{CaptureLocations, Regex, RegexBuilder};
use {
grep_matcher::{Captures, Match, Matcher},
pcre2::bytes::{CaptureLocations, Regex, RegexBuilder},
};
use crate::error::Error;
@@ -426,9 +428,10 @@ fn has_uppercase_literal(pattern: &str) -> bool {
#[cfg(test)]
mod tests {
use super::*;
use grep_matcher::{LineMatchKind, Matcher};
use super::*;
// Test that enabling word matches does the right thing and demonstrate
// the difference between it and surrounding the regex in `\b`.
#[test]