Enum sway_ast::token::CommentedTokenTree
source · [−]pub enum CommentedTokenTree {
Comment(Comment),
Tree(CommentedTree),
}
Variants
Comment(Comment)
Tree(CommentedTree)
Implementations
sourceimpl CommentedTokenTree
impl CommentedTokenTree
pub fn strip_comments(self) -> Option<TokenTree>
Trait Implementations
sourceimpl Clone for CommentedTokenTree
impl Clone for CommentedTokenTree
sourcefn clone(&self) -> CommentedTokenTree
fn clone(&self) -> CommentedTokenTree
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for CommentedTokenTree
impl Debug for CommentedTokenTree
sourceimpl From<Comment> for CommentedTokenTree
impl From<Comment> for CommentedTokenTree
sourceimpl From<GenericTokenTree<CommentedTokenStream>> for CommentedTokenTree
impl From<GenericTokenTree<CommentedTokenStream>> for CommentedTokenTree
sourcefn from(tree: CommentedTree) -> Self
fn from(tree: CommentedTree) -> Self
Converts to this type from the input type.
sourceimpl Hash for CommentedTokenTree
impl Hash for CommentedTokenTree
sourceimpl PartialEq<CommentedTokenTree> for CommentedTokenTree
impl PartialEq<CommentedTokenTree> for CommentedTokenTree
sourcefn eq(&self, other: &CommentedTokenTree) -> bool
fn eq(&self, other: &CommentedTokenTree) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourceimpl PartialOrd<CommentedTokenTree> for CommentedTokenTree
impl PartialOrd<CommentedTokenTree> for CommentedTokenTree
sourcefn partial_cmp(&self, other: &CommentedTokenTree) -> Option<Ordering>
fn partial_cmp(&self, other: &CommentedTokenTree) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
1.0.0 · sourcefn lt(&self, other: &Rhs) -> bool
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
1.0.0 · sourcefn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
impl Eq for CommentedTokenTree
impl StructuralEq for CommentedTokenTree
impl StructuralPartialEq for CommentedTokenTree
Auto Trait Implementations
impl RefUnwindSafe for CommentedTokenTree
impl Send for CommentedTokenTree
impl Sync for CommentedTokenTree
impl Unpin for CommentedTokenTree
impl UnwindSafe for CommentedTokenTree
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more