pub struct RelativeRewriter { /* private fields */ }Expand description
Container for the precompiled regex set used by relative-mode rewriting.
Built once at startup; cloned cheaply via Arc internals.
Implementations§
Source§impl RelativeRewriter
impl RelativeRewriter
Sourcepub fn for_mode(mode: CompatibilityMode) -> Self
pub fn for_mode(mode: CompatibilityMode) -> Self
Build a rewriter configured for the given mode. Compiles each regex once — callers should hold the rewriter for the lifetime of the invocation.
Pattern ordering matters: more-specific (longer match) patterns are
listed first, so that when overlap resolution runs (in rewrite)
the more-specific match wins.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for RelativeRewriter
impl RefUnwindSafe for RelativeRewriter
impl Send for RelativeRewriter
impl Sync for RelativeRewriter
impl Unpin for RelativeRewriter
impl UnsafeUnpin for RelativeRewriter
impl UnwindSafe for RelativeRewriter
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