pub struct HeadingToken<T> {
pub range: Range<usize>,
pub value: T,
}Expand description
A token found on a heading line, with the byte range it occupies.
The range covers the token as written, framing included: a priority cookie
reports [#A], not A. Callers replacing one token slice the line around
this range and keep everything else byte-for-byte.
Fields§
§range: Range<usize>Byte range within the line the token was parsed from.
value: TWhat the token parsed to.
Trait Implementations§
Source§impl<T: Clone> Clone for HeadingToken<T>
impl<T: Clone> Clone for HeadingToken<T>
Source§fn clone(&self) -> HeadingToken<T>
fn clone(&self) -> HeadingToken<T>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<T: Debug> Debug for HeadingToken<T>
impl<T: Debug> Debug for HeadingToken<T>
Source§impl<T: PartialEq> PartialEq for HeadingToken<T>
impl<T: PartialEq> PartialEq for HeadingToken<T>
impl<T: PartialEq> StructuralPartialEq for HeadingToken<T>
Auto Trait Implementations§
impl<T> Freeze for HeadingToken<T>where
T: Freeze,
impl<T> RefUnwindSafe for HeadingToken<T>where
T: RefUnwindSafe,
impl<T> Send for HeadingToken<T>where
T: Send,
impl<T> Sync for HeadingToken<T>where
T: Sync,
impl<T> Unpin for HeadingToken<T>where
T: Unpin,
impl<T> UnsafeUnpin for HeadingToken<T>where
T: UnsafeUnpin,
impl<T> UnwindSafe for HeadingToken<T>where
T: UnwindSafe,
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