clang  9.0.0svn
TextNodeDumper.h
Go to the documentation of this file.
1 //===--- TextNodeDumper.h - Printing of AST nodes -------------------------===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This file implements AST dumping of components of individual AST nodes.
10 //
11 //===----------------------------------------------------------------------===//
12 
13 #ifndef LLVM_CLANG_AST_TEXTNODEDUMPER_H
14 #define LLVM_CLANG_AST_TEXTNODEDUMPER_H
15 
16 #include "clang/AST/ASTContext.h"
18 #include "clang/AST/AttrVisitor.h"
21 #include "clang/AST/DeclVisitor.h"
22 #include "clang/AST/ExprCXX.h"
23 #include "clang/AST/StmtVisitor.h"
25 #include "clang/AST/TypeVisitor.h"
26 
27 namespace clang {
28 
30  raw_ostream &OS;
31  const bool ShowColors;
32 
33  /// Pending[i] is an action to dump an entity at level i.
35 
36  /// Indicates whether we're at the top level.
37  bool TopLevel = true;
38 
39  /// Indicates if we're handling the first child after entering a new depth.
40  bool FirstChild = true;
41 
42  /// Prefix for currently-being-dumped entity.
43  std::string Prefix;
44 
45 public:
46  /// Add a child of the current node. Calls DoAddChild without arguments
47  template <typename Fn> void AddChild(Fn DoAddChild) {
48  return AddChild("", DoAddChild);
49  }
50 
51  /// Add a child of the current node with an optional label.
52  /// Calls DoAddChild without arguments.
53  template <typename Fn> void AddChild(StringRef Label, Fn DoAddChild) {
54  // If we're at the top level, there's nothing interesting to do; just
55  // run the dumper.
56  if (TopLevel) {
57  TopLevel = false;
58  DoAddChild();
59  while (!Pending.empty()) {
60  Pending.back()(true);
61  Pending.pop_back();
62  }
63  Prefix.clear();
64  OS << "\n";
65  TopLevel = true;
66  return;
67  }
68 
69  // We need to capture an owning-string in the lambda because the lambda
70  // is invoked in a deferred manner.
71  std::string LabelStr = Label;
72  auto DumpWithIndent = [this, DoAddChild, LabelStr](bool IsLastChild) {
73  // Print out the appropriate tree structure and work out the prefix for
74  // children of this node. For instance:
75  //
76  // A Prefix = ""
77  // |-B Prefix = "| "
78  // | `-C Prefix = "| "
79  // `-D Prefix = " "
80  // |-E Prefix = " | "
81  // `-F Prefix = " "
82  // G Prefix = ""
83  //
84  // Note that the first level gets no prefix.
85  {
86  OS << '\n';
87  ColorScope Color(OS, ShowColors, IndentColor);
88  OS << Prefix << (IsLastChild ? '`' : '|') << '-';
89  if (!LabelStr.empty())
90  OS << LabelStr << ": ";
91 
92  this->Prefix.push_back(IsLastChild ? ' ' : '|');
93  this->Prefix.push_back(' ');
94  }
95 
96  FirstChild = true;
97  unsigned Depth = Pending.size();
98 
99  DoAddChild();
100 
101  // If any children are left, they're the last at their nesting level.
102  // Dump those ones out now.
103  while (Depth < Pending.size()) {
104  Pending.back()(true);
105  this->Pending.pop_back();
106  }
107 
108  // Restore the old prefix.
109  this->Prefix.resize(Prefix.size() - 2);
110  };
111 
112  if (FirstChild) {
113  Pending.push_back(std::move(DumpWithIndent));
114  } else {
115  Pending.back()(false);
116  Pending.back() = std::move(DumpWithIndent);
117  }
118  FirstChild = false;
119  }
120 
121  TextTreeStructure(raw_ostream &OS, bool ShowColors)
122  : OS(OS), ShowColors(ShowColors) {}
123 };
124 
126  : public TextTreeStructure,
127  public comments::ConstCommentVisitor<TextNodeDumper, void,
128  const comments::FullComment *>,
129  public ConstAttrVisitor<TextNodeDumper>,
130  public ConstTemplateArgumentVisitor<TextNodeDumper>,
131  public ConstStmtVisitor<TextNodeDumper>,
132  public TypeVisitor<TextNodeDumper>,
133  public ConstDeclVisitor<TextNodeDumper> {
134  raw_ostream &OS;
135  const bool ShowColors;
136 
137  /// Keep track of the last location we print out so that we can
138  /// print out deltas from then on out.
139  const char *LastLocFilename = "";
140  unsigned LastLocLine = ~0U;
141 
142  const SourceManager *SM;
143 
144  /// The policy to use for printing; can be defaulted.
145  PrintingPolicy PrintPolicy;
146 
147  const comments::CommandTraits *Traits;
148 
149  const ASTContext *Context;
150 
151  const char *getCommandName(unsigned CommandID);
152 
153 public:
154  TextNodeDumper(raw_ostream &OS, bool ShowColors, const SourceManager *SM,
155  const PrintingPolicy &PrintPolicy,
156  const comments::CommandTraits *Traits);
157 
158  void Visit(const comments::Comment *C, const comments::FullComment *FC);
159 
160  void Visit(const Attr *A);
161 
162  void Visit(const TemplateArgument &TA, SourceRange R,
163  const Decl *From = nullptr, StringRef Label = {});
164 
165  void Visit(const Stmt *Node);
166 
167  void Visit(const Type *T);
168 
169  void Visit(QualType T);
170 
171  void Visit(const Decl *D);
172 
173  void Visit(const CXXCtorInitializer *Init);
174 
175  void Visit(const OMPClause *C);
176 
177  void Visit(const BlockDecl::Capture &C);
178 
179  void Visit(const GenericSelectionExpr::ConstAssociation &A);
180 
181  void dumpPointer(const void *Ptr);
182  void dumpLocation(SourceLocation Loc);
183  void dumpSourceRange(SourceRange R);
184  void dumpBareType(QualType T, bool Desugar = true);
185  void dumpType(QualType T);
186  void dumpBareDeclRef(const Decl *D);
187  void dumpName(const NamedDecl *ND);
188  void dumpAccessSpecifier(AccessSpecifier AS);
189 
190  void dumpDeclRef(const Decl *D, StringRef Label = {});
191 
192  void visitTextComment(const comments::TextComment *C,
193  const comments::FullComment *);
194  void visitInlineCommandComment(const comments::InlineCommandComment *C,
195  const comments::FullComment *);
196  void visitHTMLStartTagComment(const comments::HTMLStartTagComment *C,
197  const comments::FullComment *);
198  void visitHTMLEndTagComment(const comments::HTMLEndTagComment *C,
199  const comments::FullComment *);
200  void visitBlockCommandComment(const comments::BlockCommandComment *C,
201  const comments::FullComment *);
202  void visitParamCommandComment(const comments::ParamCommandComment *C,
203  const comments::FullComment *FC);
204  void visitTParamCommandComment(const comments::TParamCommandComment *C,
205  const comments::FullComment *FC);
206  void visitVerbatimBlockComment(const comments::VerbatimBlockComment *C,
207  const comments::FullComment *);
208  void
209  visitVerbatimBlockLineComment(const comments::VerbatimBlockLineComment *C,
210  const comments::FullComment *);
211  void visitVerbatimLineComment(const comments::VerbatimLineComment *C,
212  const comments::FullComment *);
213 
214 // Implements Visit methods for Attrs.
215 #include "clang/AST/AttrTextNodeDump.inc"
216 
217  void VisitNullTemplateArgument(const TemplateArgument &TA);
218  void VisitTypeTemplateArgument(const TemplateArgument &TA);
219  void VisitDeclarationTemplateArgument(const TemplateArgument &TA);
220  void VisitNullPtrTemplateArgument(const TemplateArgument &TA);
221  void VisitIntegralTemplateArgument(const TemplateArgument &TA);
222  void VisitTemplateTemplateArgument(const TemplateArgument &TA);
223  void VisitTemplateExpansionTemplateArgument(const TemplateArgument &TA);
224  void VisitExpressionTemplateArgument(const TemplateArgument &TA);
225  void VisitPackTemplateArgument(const TemplateArgument &TA);
226 
227  void VisitIfStmt(const IfStmt *Node);
228  void VisitSwitchStmt(const SwitchStmt *Node);
229  void VisitWhileStmt(const WhileStmt *Node);
230  void VisitLabelStmt(const LabelStmt *Node);
231  void VisitGotoStmt(const GotoStmt *Node);
232  void VisitCaseStmt(const CaseStmt *Node);
233  void VisitConstantExpr(const ConstantExpr *Node);
234  void VisitCallExpr(const CallExpr *Node);
235  void VisitCastExpr(const CastExpr *Node);
236  void VisitImplicitCastExpr(const ImplicitCastExpr *Node);
237  void VisitDeclRefExpr(const DeclRefExpr *Node);
238  void VisitPredefinedExpr(const PredefinedExpr *Node);
239  void VisitCharacterLiteral(const CharacterLiteral *Node);
240  void VisitIntegerLiteral(const IntegerLiteral *Node);
241  void VisitFixedPointLiteral(const FixedPointLiteral *Node);
242  void VisitFloatingLiteral(const FloatingLiteral *Node);
243  void VisitStringLiteral(const StringLiteral *Str);
244  void VisitInitListExpr(const InitListExpr *ILE);
245  void VisitGenericSelectionExpr(const GenericSelectionExpr *E);
246  void VisitUnaryOperator(const UnaryOperator *Node);
247  void VisitUnaryExprOrTypeTraitExpr(const UnaryExprOrTypeTraitExpr *Node);
248  void VisitMemberExpr(const MemberExpr *Node);
249  void VisitExtVectorElementExpr(const ExtVectorElementExpr *Node);
250  void VisitBinaryOperator(const BinaryOperator *Node);
251  void VisitCompoundAssignOperator(const CompoundAssignOperator *Node);
252  void VisitAddrLabelExpr(const AddrLabelExpr *Node);
253  void VisitCXXNamedCastExpr(const CXXNamedCastExpr *Node);
254  void VisitCXXBoolLiteralExpr(const CXXBoolLiteralExpr *Node);
255  void VisitCXXThisExpr(const CXXThisExpr *Node);
256  void VisitCXXFunctionalCastExpr(const CXXFunctionalCastExpr *Node);
257  void VisitCXXUnresolvedConstructExpr(const CXXUnresolvedConstructExpr *Node);
258  void VisitCXXConstructExpr(const CXXConstructExpr *Node);
259  void VisitCXXBindTemporaryExpr(const CXXBindTemporaryExpr *Node);
260  void VisitCXXNewExpr(const CXXNewExpr *Node);
261  void VisitCXXDeleteExpr(const CXXDeleteExpr *Node);
262  void VisitMaterializeTemporaryExpr(const MaterializeTemporaryExpr *Node);
263  void VisitExprWithCleanups(const ExprWithCleanups *Node);
264  void VisitUnresolvedLookupExpr(const UnresolvedLookupExpr *Node);
265  void VisitSizeOfPackExpr(const SizeOfPackExpr *Node);
266  void
267  VisitCXXDependentScopeMemberExpr(const CXXDependentScopeMemberExpr *Node);
268  void VisitObjCAtCatchStmt(const ObjCAtCatchStmt *Node);
269  void VisitObjCEncodeExpr(const ObjCEncodeExpr *Node);
270  void VisitObjCMessageExpr(const ObjCMessageExpr *Node);
271  void VisitObjCBoxedExpr(const ObjCBoxedExpr *Node);
272  void VisitObjCSelectorExpr(const ObjCSelectorExpr *Node);
273  void VisitObjCProtocolExpr(const ObjCProtocolExpr *Node);
274  void VisitObjCPropertyRefExpr(const ObjCPropertyRefExpr *Node);
275  void VisitObjCSubscriptRefExpr(const ObjCSubscriptRefExpr *Node);
276  void VisitObjCIvarRefExpr(const ObjCIvarRefExpr *Node);
277  void VisitObjCBoolLiteralExpr(const ObjCBoolLiteralExpr *Node);
278 
279  void VisitRValueReferenceType(const ReferenceType *T);
280  void VisitArrayType(const ArrayType *T);
281  void VisitConstantArrayType(const ConstantArrayType *T);
282  void VisitVariableArrayType(const VariableArrayType *T);
283  void VisitDependentSizedArrayType(const DependentSizedArrayType *T);
284  void VisitDependentSizedExtVectorType(const DependentSizedExtVectorType *T);
285  void VisitVectorType(const VectorType *T);
286  void VisitFunctionType(const FunctionType *T);
287  void VisitFunctionProtoType(const FunctionProtoType *T);
288  void VisitUnresolvedUsingType(const UnresolvedUsingType *T);
289  void VisitTypedefType(const TypedefType *T);
290  void VisitUnaryTransformType(const UnaryTransformType *T);
291  void VisitTagType(const TagType *T);
292  void VisitTemplateTypeParmType(const TemplateTypeParmType *T);
293  void VisitAutoType(const AutoType *T);
294  void VisitTemplateSpecializationType(const TemplateSpecializationType *T);
295  void VisitInjectedClassNameType(const InjectedClassNameType *T);
296  void VisitObjCInterfaceType(const ObjCInterfaceType *T);
297  void VisitPackExpansionType(const PackExpansionType *T);
298 
299  void VisitLabelDecl(const LabelDecl *D);
300  void VisitTypedefDecl(const TypedefDecl *D);
301  void VisitEnumDecl(const EnumDecl *D);
302  void VisitRecordDecl(const RecordDecl *D);
303  void VisitEnumConstantDecl(const EnumConstantDecl *D);
304  void VisitIndirectFieldDecl(const IndirectFieldDecl *D);
305  void VisitFunctionDecl(const FunctionDecl *D);
306  void VisitFieldDecl(const FieldDecl *D);
307  void VisitVarDecl(const VarDecl *D);
308  void VisitBindingDecl(const BindingDecl *D);
309  void VisitCapturedDecl(const CapturedDecl *D);
310  void VisitImportDecl(const ImportDecl *D);
311  void VisitPragmaCommentDecl(const PragmaCommentDecl *D);
312  void VisitPragmaDetectMismatchDecl(const PragmaDetectMismatchDecl *D);
313  void VisitOMPExecutableDirective(const OMPExecutableDirective *D);
314  void VisitOMPDeclareReductionDecl(const OMPDeclareReductionDecl *D);
315  void VisitOMPRequiresDecl(const OMPRequiresDecl *D);
316  void VisitOMPCapturedExprDecl(const OMPCapturedExprDecl *D);
317  void VisitNamespaceDecl(const NamespaceDecl *D);
318  void VisitUsingDirectiveDecl(const UsingDirectiveDecl *D);
319  void VisitNamespaceAliasDecl(const NamespaceAliasDecl *D);
320  void VisitTypeAliasDecl(const TypeAliasDecl *D);
321  void VisitTypeAliasTemplateDecl(const TypeAliasTemplateDecl *D);
322  void VisitCXXRecordDecl(const CXXRecordDecl *D);
323  void VisitFunctionTemplateDecl(const FunctionTemplateDecl *D);
324  void VisitClassTemplateDecl(const ClassTemplateDecl *D);
325  void VisitBuiltinTemplateDecl(const BuiltinTemplateDecl *D);
326  void VisitVarTemplateDecl(const VarTemplateDecl *D);
327  void VisitTemplateTypeParmDecl(const TemplateTypeParmDecl *D);
328  void VisitNonTypeTemplateParmDecl(const NonTypeTemplateParmDecl *D);
329  void VisitTemplateTemplateParmDecl(const TemplateTemplateParmDecl *D);
330  void VisitUsingDecl(const UsingDecl *D);
331  void VisitUnresolvedUsingTypenameDecl(const UnresolvedUsingTypenameDecl *D);
332  void VisitUnresolvedUsingValueDecl(const UnresolvedUsingValueDecl *D);
333  void VisitUsingShadowDecl(const UsingShadowDecl *D);
334  void VisitConstructorUsingShadowDecl(const ConstructorUsingShadowDecl *D);
335  void VisitLinkageSpecDecl(const LinkageSpecDecl *D);
336  void VisitAccessSpecDecl(const AccessSpecDecl *D);
337  void VisitFriendDecl(const FriendDecl *D);
338  void VisitObjCIvarDecl(const ObjCIvarDecl *D);
339  void VisitObjCMethodDecl(const ObjCMethodDecl *D);
340  void VisitObjCTypeParamDecl(const ObjCTypeParamDecl *D);
341  void VisitObjCCategoryDecl(const ObjCCategoryDecl *D);
342  void VisitObjCCategoryImplDecl(const ObjCCategoryImplDecl *D);
343  void VisitObjCProtocolDecl(const ObjCProtocolDecl *D);
344  void VisitObjCInterfaceDecl(const ObjCInterfaceDecl *D);
345  void VisitObjCImplementationDecl(const ObjCImplementationDecl *D);
346  void VisitObjCCompatibleAliasDecl(const ObjCCompatibleAliasDecl *D);
347  void VisitObjCPropertyDecl(const ObjCPropertyDecl *D);
348  void VisitObjCPropertyImplDecl(const ObjCPropertyImplDecl *D);
349  void VisitBlockDecl(const BlockDecl *D);
350  void VisitConceptDecl(const ConceptDecl *D);
351 };
352 
353 } // namespace clang
354 
355 #endif // LLVM_CLANG_AST_TEXTNODEDUMPER_H
ObjCPropertyRefExpr - A dot-syntax expression to access an ObjC property.
Definition: ExprObjC.h:614
Defines the clang::ASTContext interface.
Represents a function declaration or definition.
Definition: Decl.h:1748
A class which contains all the information about a particular captured value.
Definition: Decl.h:3921
Represents the dependent type named by a dependently-scoped typename using declaration, e.g.
Definition: Type.h:4154
A (possibly-)qualified type.
Definition: Type.h:643
ConstStmtVisitor - This class implements a simple visitor for Stmt subclasses.
Definition: StmtVisitor.h:192
Stmt - This represents one statement.
Definition: Stmt.h:66
FunctionType - C99 6.7.5.3 - Function Declarators.
Definition: Type.h:3387
IfStmt - This represents an if/then/else.
Definition: Stmt.h:1812
An instance of this object exists for each enum constant that is defined.
Definition: Decl.h:2819
Represents the declaration of a typedef-name via the &#39;typedef&#39; type specifier.
Definition: Decl.h:3051
Decl - This represents one declaration (or definition), e.g.
Definition: DeclBase.h:88
A reference to a name which we were able to look up during parsing but could not resolve to a specifi...
Definition: ExprCXX.h:2938
Represents a C++11 auto or C++14 decltype(auto) type.
Definition: Type.h:4817
The base class of the type hierarchy.
Definition: Type.h:1433
Declaration of a variable template.
Represents an array type, per C99 6.7.5.2 - Array Declarators.
Definition: Type.h:2844
Represent a C++ namespace.
Definition: Decl.h:514
Represents a call to a C++ constructor.
Definition: ExprCXX.h:1326
ObjCSubscriptRefExpr - used for array and dictionary subscripting.
Definition: ExprObjC.h:845
AccessSpecifier
A C++ access specifier (public, private, protected), plus the special value "none" which means differ...
Definition: Specifiers.h:112
Represents a prvalue temporary that is written into memory so that a reference can bind to it...
Definition: ExprCXX.h:4320
Represents a #pragma comment line.
Definition: Decl.h:139
FriendDecl - Represents the declaration of a friend entity, which can be a function, a type, or a templated function or type.
Definition: DeclFriend.h:53
Represents a variable declaration or definition.
Definition: Decl.h:812
ObjCMethodDecl - Represents an instance or class method declaration.
Definition: DeclObjC.h:138
Describes how types, statements, expressions, and declarations should be printed. ...
Definition: PrettyPrinter.h:37
Represents an expression – generally a full-expression – that introduces cleanups to be run at the ...
Definition: ExprCXX.h:3207
Defines the clang::Expr interface and subclasses for C++ expressions.
Represents the builtin template declaration which is used to implement __make_integer_seq and other b...
LabelStmt - Represents a label, which has a substatement.
Definition: Stmt.h:1710
Represents a struct/union/class.
Definition: Decl.h:3626
Holds long-lived AST nodes (such as types and decls) that can be referred to throughout the semantic ...
Definition: ASTContext.h:154
Represents a member of a struct/union/class.
Definition: Decl.h:2607
A simple visitor class that helps create attribute visitors.
Definition: AttrVisitor.h:69
An operation on a type.
Definition: TypeVisitor.h:64
ExtVectorElementExpr - This represents access to specific elements of a vector, and may occur on the ...
Definition: Expr.h:5480
Represents an access specifier followed by colon &#39;:&#39;.
Definition: DeclCXX.h:132
Represents Objective-C&#39;s @catch statement.
Definition: StmtObjC.h:77
A command with word-like arguments that is considered inline content.
Definition: Comment.h:298
Describes an C or C++ initializer list.
Definition: Expr.h:4371
Represents a C++ using-declaration.
Definition: DeclCXX.h:3480
AssociationTy< true > ConstAssociation
Definition: Expr.h:5356
A line of text contained in a verbatim block.
Definition: Comment.h:863
A verbatim line command.
Definition: Comment.h:943
A simple visitor class that helps create template argument visitors.
A builtin binary operation expression such as "x + y" or "x <= y".
Definition: Expr.h:3405
Any part of the comment.
Definition: Comment.h:52
CaseStmt - Represent a case statement.
Definition: Stmt.h:1478
CastExpr - Base class for type casts, including both implicit casts (ImplicitCastExpr) and explicit c...
Definition: Expr.h:3121
Represents an Objective-C protocol declaration.
Definition: DeclObjC.h:2063
Represents binding an expression to a temporary.
Definition: ExprCXX.h:1277
Represents a C++ member access expression where the actual member referenced could not be resolved be...
Definition: ExprCXX.h:3412
Represents the body of a CapturedStmt, and serves as its DeclContext.
Definition: Decl.h:4108
Represents an ObjC class declaration.
Definition: DeclObjC.h:1171
Represents a linkage specification.
Definition: DeclCXX.h:2954
A binding in a decomposition declaration.
Definition: DeclCXX.h:3923
Represents an extended vector type where either the type or size is dependent.
Definition: Type.h:3160
Represents the this expression in C++.
Definition: ExprCXX.h:1001
ObjCPropertyImplDecl - Represents implementation declaration of a property in a class or category imp...
Definition: DeclObjC.h:2758
A verbatim block command (e.
Definition: Comment.h:891
Represents the declaration of a typedef-name via a C++11 alias-declaration.
Definition: Decl.h:3071
Represents a prototype with parameter type info, e.g.
Definition: Type.h:3719
UnaryExprOrTypeTraitExpr - expression with either a type or (unevaluated) expression operand...
Definition: Expr.h:2342
ConstantExpr - An expression that occurs in a constant context and optionally the result of evaluatin...
Definition: Expr.h:948
This represents &#39;#pragma omp requires...&#39; directive.
Definition: DeclOpenMP.h:345
Represents an array type in C++ whose size is a value-dependent expression.
Definition: Type.h:3058
Represents a shadow constructor declaration introduced into a class by a C++11 using-declaration that...
Definition: DeclCXX.h:3368
Represents a block literal declaration, which is like an unnamed FunctionDecl.
Definition: Decl.h:3915
std::string Label
Declaration of a template type parameter.
TextTreeStructure(raw_ostream &OS, bool ShowColors)
A command that has zero or more word-like arguments (number of word-like arguments depends on command...
Definition: Comment.h:596
ObjCSelectorExpr used for @selector in Objective-C.
Definition: ExprObjC.h:454
Represents an expression that computes the length of a parameter pack.
Definition: ExprCXX.h:3992
NonTypeTemplateParmDecl - Declares a non-type template parameter, e.g., "Size" in.
int Depth
Definition: ASTDiff.cpp:190
A unary type transform, which is a type constructed from another.
Definition: Type.h:4357
Declaration of an alias template.
An expression that sends a message to the given Objective-C object or class.
Definition: ExprObjC.h:950
UnaryOperator - This represents the unary-expression&#39;s (except sizeof and alignof), the postinc/postdec operators from postfix-expression, and various extensions.
Definition: Expr.h:2016
Represents a GCC generic vector type.
Definition: Type.h:3200
An opening HTML tag with attributes.
Definition: Comment.h:413
TemplateTemplateParmDecl - Declares a template template parameter, e.g., "T" in.
static QualType Desugar(ASTContext &Context, QualType QT, bool &ShouldAKA)
const SourceManager & SM
Definition: Format.cpp:1572
This class provides information about commands that can be used in comments.
Encodes a location in the source.
This represents &#39;#pragma omp declare reduction ...&#39; directive.
Definition: DeclOpenMP.h:102
Pseudo declaration for capturing expressions.
Definition: DeclOpenMP.h:312
Interfaces are the core concept in Objective-C for object oriented design.
Definition: Type.h:5808
This is a basic class for representing single OpenMP executable directive.
Definition: StmtOpenMP.h:32
Represents a new-expression for memory allocation and constructor calls, e.g: "new CXXNewExpr(foo)"...
Definition: ExprCXX.h:2000
Represents the declaration of a label.
Definition: Decl.h:468
Represents a dependent using declaration which was not marked with typename.
Definition: DeclCXX.h:3699
void AddChild(StringRef Label, Fn DoAddChild)
Add a child of the current node with an optional label.
ObjCCategoryDecl - Represents a category declaration.
Definition: DeclObjC.h:2279
This is a basic class for representing single OpenMP clause.
Definition: OpenMPClause.h:50
ObjCProtocolExpr used for protocol expression in Objective-C.
Definition: ExprObjC.h:503
Represents one property declaration in an Objective-C interface.
Definition: DeclObjC.h:728
ImplicitCastExpr - Allows us to explicitly represent implicit type conversions, which have no direct ...
Definition: Expr.h:3245
A closing HTML tag.
Definition: Comment.h:507
ObjCBoxedExpr - used for generalized expression boxing.
Definition: ExprObjC.h:124
Describes a module import declaration, which makes the contents of the named module visible in the cu...
Definition: Decl.h:4213
Doxygen \tparam command, describes a template parameter.
Definition: Comment.h:799
The injected class name of a C++ class template or class template partial specialization.
Definition: Type.h:5048
Represents a pack expansion of types.
Definition: Type.h:5425
CompoundAssignOperator - For compound assignments (e.g.
Definition: Expr.h:3625
Represents a C11 generic selection.
Definition: Expr.h:5196
AddrLabelExpr - The GNU address of label extension, representing &&label.
Definition: Expr.h:3878
ast_type_traits::DynTypedNode Node
Represents a template argument.
Definition: TemplateBase.h:50
Dataflow Directional Tag Classes.
[C99 6.4.2.2] - A predefined identifier such as func.
Definition: Expr.h:1873
Represents a delete expression for memory deallocation and destructor calls, e.g. ...
Definition: ExprCXX.h:2260
static const TerminalColor IndentColor
Represents a field injected from an anonymous union/struct into the parent scope. ...
Definition: Decl.h:2858
Represents a dependent using declaration which was marked with typename.
Definition: DeclCXX.h:3795
Represents the declaration of an Objective-C type parameter.
Definition: DeclObjC.h:558
Represents an enum.
Definition: Decl.h:3359
SwitchStmt - This represents a &#39;switch&#39; stmt.
Definition: Stmt.h:2017
ObjCImplementationDecl - Represents a class definition - this is where method definitions are specifi...
Definition: DeclObjC.h:2551
Represents a C++ base or member initializer.
Definition: DeclCXX.h:2338
ObjCEncodeExpr, used for @encode in Objective-C.
Definition: ExprObjC.h:407
Base for LValueReferenceType and RValueReferenceType.
Definition: Type.h:2705
ObjCIvarRefExpr - A reference to an ObjC instance variable.
Definition: ExprObjC.h:546
Describes an explicit type conversion that uses functional notion but could not be resolved because o...
Definition: ExprCXX.h:3291
GotoStmt - This represents a direct goto.
Definition: Stmt.h:2455
MemberExpr - [C99 6.5.2.3] Structure and Union Members.
Definition: Expr.h:2807
Represents a C++ struct/union/class.
Definition: DeclCXX.h:300
Represents an explicit C++ type conversion that uses "functional" notation (C++ [expr.type.conv]).
Definition: ExprCXX.h:1592
ObjCIvarDecl - Represents an ObjC instance variable.
Definition: DeclObjC.h:1944
WhileStmt - This represents a &#39;while&#39; stmt.
Definition: Stmt.h:2200
Declaration of a class template.
StringLiteral - This represents a string literal expression, e.g.
Definition: Expr.h:1681
CallExpr - Represents a function call (C99 6.5.2.2, C++ [expr.call]).
Definition: Expr.h:2516
Abstract class common to all of the C++ "named"/"keyword" casts.
Definition: ExprCXX.h:257
ObjCBoolLiteralExpr - Objective-C Boolean Literal.
Definition: ExprObjC.h:85
A reference to a declared variable, function, enum, etc.
Definition: Expr.h:1141
Represents a type template specialization; the template must be a class template, a type alias templa...
Definition: Type.h:4911
Doxygen \param command.
Definition: Comment.h:711
A trivial tuple used to represent a source range.
This represents a decl that may have a name.
Definition: Decl.h:248
A boolean literal, per ([C++ lex.bool] Boolean literals).
Definition: ExprCXX.h:549
Represents a C array with a specified size that is not an integer-constant-expression.
Definition: Type.h:3003
Represents a C++ namespace alias.
Definition: DeclCXX.h:3148
Represents C++ using-directive.
Definition: DeclCXX.h:3044
Represents a #pragma detect_mismatch line.
Definition: Decl.h:173
A simple visitor class that helps create declaration visitors.
Definition: DeclVisitor.h:73
ObjCCategoryImplDecl - An object of this class encapsulates a category @implementation declaration...
Definition: DeclObjC.h:2498
Represents the canonical version of C arrays with a specified constant size.
Definition: Type.h:2904
This class handles loading and caching of source files into memory.
Declaration of a template function.
void AddChild(Fn DoAddChild)
Add a child of the current node. Calls DoAddChild without arguments.
Attr - This represents one attribute.
Definition: Attr.h:43
Represents a shadow declaration introduced into a scope by a (resolved) using declaration.
Definition: DeclCXX.h:3267
A full comment attached to a declaration, contains block content.
Definition: Comment.h:1091
ObjCCompatibleAliasDecl - Represents alias of a class.
Definition: DeclObjC.h:2728