clang 20.0.0git
|
A list of Elements separated or terminated by a fixed token. More...
#include "clang/Tooling/Syntax/Tree.h"
Classes | |
struct | ElementAndDelimiter |
Public Types | |
enum class | TerminationKind { Terminated , MaybeTerminated , Separated } |
Public Member Functions | |
std::vector< ElementAndDelimiter< Node > > | getElementsAsNodesAndDelimiters () |
Returns the elements and corresponding delimiters. | |
std::vector< Node * > | getElementsAsNodes () |
Returns the elements of the list. | |
clang::tok::TokenKind | getDelimiterTokenKind () const |
Returns the appropriate delimiter for this list. | |
TerminationKind | getTerminationKind () const |
bool | canBeEmpty () const |
Whether this list can be empty in syntactically and semantically correct code. | |
![]() | |
Node * | getFirstChild () |
const Node * | getFirstChild () const |
Node * | getLastChild () |
const Node * | getLastChild () const |
const Leaf * | findFirstLeaf () const |
Leaf * | findFirstLeaf () |
const Leaf * | findLastLeaf () const |
Leaf * | findLastLeaf () |
llvm::iterator_range< ChildIterator > | getChildren () |
llvm::iterator_range< ConstChildIterator > | getChildren () const |
const Node * | findChild (NodeRole R) const |
Find the first node with a corresponding role. | |
Node * | findChild (NodeRole R) |
![]() | |
Node (const Node &)=delete | |
Nodes cannot simply be copied without violating tree invariants. | |
Node & | operator= (const Node &)=delete |
Node (Node &&)=delete | |
Idiomatically, nodes are allocated on an Arena and never moved. | |
Node & |