Module cstree::syntax [−][src]
Implementation of the outer, “red” tree.
Inner SyntaxNode
s represent only structural information, but can hold additional, user-defined data.
Leaf SyntaxToken
s represent individual pieces of source text.
Use SyntaxNode::new_root
and SyntaxNode::new_root_with_resolver
to construct a syntax
tree on top of a green tree.
Structs
ResolvedNode | Syntax tree node that is guaranteed to belong to a tree that contains an associated
|
ResolvedToken | Syntax tree token that is guaranteed to belong to a tree that contains an associated
|
SyntaxElementChildren | An iterator over the children of a |
SyntaxNode | Inner syntax tree node. Syntax nodes can be shared between threads. Every syntax tree is reference counted as a whole and nodes are pointer-sized, so copying individual nodes is relatively cheap. |
SyntaxNodeChildren | An iterator over the child nodes of a |
SyntaxText | An efficient representation of the text that is covered by a |
SyntaxToken | Syntax tree token. |
Type Definitions
ResolvedElement | An element of the tree that is guaranteed to belong to a tree that contains an associated
|
ResolvedElementRef | A reference to an element of the tree that is guaranteed to belong to a tree that contains an
associated |
SyntaxElement | An element of the tree, can be either a node or a token. |
SyntaxElementRef | A reference to an element of the tree, can be either a reference to a node or one to a token. |