pub struct TokenList<T: Token>(pub AtomicSharedVector<T>);Tuple Fields§
§0: AtomicSharedVector<T>Implementations§
Source§impl<T: Token> TokenList<T>
impl<T: Token> TokenList<T>
Sourcepub fn get(&self, i: usize) -> &T
pub fn get(&self, i: usize) -> &T
return the ith token in the list. Will panic if out of bounds.
Sourcepub fn display<'a>(
&'a self,
int: &'a <T::CS as CSName<T::Char>>::Handler,
cc: &'a CategoryCodeScheme<T::Char>,
escapechar: Option<T::Char>,
double_par: bool,
) -> TokenListDisplay<'a, T>
pub fn display<'a>( &'a self, int: &'a <T::CS as CSName<T::Char>>::Handler, cc: &'a CategoryCodeScheme<T::Char>, escapechar: Option<T::Char>, double_par: bool, ) -> TokenListDisplay<'a, T>
wraps this list in a TokenListDisplay, which implements Display.
If double_par is true, parameter tokens will be doubled.
Trait Implementations§
Source§impl<T: Token> FromIterator<T> for TokenList<T>
impl<T: Token> FromIterator<T> for TokenList<T>
Source§fn from_iter<I: IntoIterator<Item = T>>(iter: I) -> Self
fn from_iter<I: IntoIterator<Item = T>>(iter: I) -> Self
Creates a value from an iterator. Read more
impl<T: Token> StructuralPartialEq for TokenList<T>
Auto Trait Implementations§
impl<T> Freeze for TokenList<T>
impl<T> RefUnwindSafe for TokenList<T>where
T: RefUnwindSafe,
impl<T> Send for TokenList<T>where
T: Sync,
impl<T> Sync for TokenList<T>
impl<T> Unpin for TokenList<T>where
T: Unpin,
impl<T> UnsafeUnpin for TokenList<T>
impl<T> UnwindSafe for TokenList<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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more