diff --git a/src/parsing.rs b/src/parsing.rs index 0cd72b5..156b7a0 100644 --- a/src/parsing.rs +++ b/src/parsing.rs @@ -564,6 +564,12 @@ impl Pattern for Regex { } } +impl<'a> Pattern for &'a Regex { + fn try_to_regex(self) -> core::result::Result { + Ok(self.clone()) + } +} + impl Pattern for &str { fn try_to_regex(self) -> core::result::Result { Regex::new(self)