pub(crate) struct Match {
pid: PatternID,
start: *const u8,
end: *const u8,
}
Expand description
A match type specialized to the Teddy implementations below.
Essentially, instead of representing a match at byte offsets, we use raw pointers. This is because the implementations below operate on raw pointers, and so this is a more natural return type based on how the implementation works.
Also, the PatternID
used here is a u16
.
Fields§
§pid: PatternID
§start: *const u8
§end: *const u8
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Match
impl RefUnwindSafe for Match
impl !Send for Match
impl !Sync for Match
impl Unpin for Match
impl UnwindSafe for Match
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