pub struct RedLeaf<K: Copy> {
pub kind: K,
pub span: Range<usize>,
}Expand description
A red leaf kind with absolute position information.
Red leaves represent individual tokens (keywords, identifiers, literals, etc.) with their absolute positions in the source text.
Fields§
§kind: KThe kind kind/category (e.g., keyword, identifier, literal)
span: Range<usize>The absolute byte span of this kind in the source text
Trait Implementations§
impl<K: Eq + Copy> Eq for RedLeaf<K>
impl<K: Copy> StructuralPartialEq for RedLeaf<K>
Auto Trait Implementations§
impl<K> Freeze for RedLeaf<K>where
K: Freeze,
impl<K> RefUnwindSafe for RedLeaf<K>where
K: RefUnwindSafe,
impl<K> Send for RedLeaf<K>where
K: Send,
impl<K> Sync for RedLeaf<K>where
K: Sync,
impl<K> Unpin for RedLeaf<K>where
K: Unpin,
impl<K> UnwindSafe for RedLeaf<K>where
K: 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