Lines Matching refs:AST
2 Matching the Clang AST
6 nodes of the AST and execute code that uses the matched nodes. Combined with
10 We assume basic knowledge about the Clang AST. See the :doc:`Introduction
11 to the Clang AST <IntroductionToTheClangAST>` if you want to learn more
12 about how the AST is structured.
20 Clang's AST. This DSL is written in and can be used from C++, allowing users
21 to write a single program to both match AST nodes and access the node's C++
23 provided on the AST level.
25 AST matchers are predicates on nodes in the AST. Matchers are created by
30 in the AST of a translation unit, you can call `recordDecl()
44 With more than a thousand classes in the Clang AST, one can quickly get lost
48 for some part of the AST. See the section about :ref:`how to write your own
49 AST matchers <astmatchers-writing>` later in this document.
53 The precondition to using the matchers is to understand how the AST for what you
55 :doc:`Introduction to the Clang AST <IntroductionToTheClangAST>` teaches you
56 how to dump a translation unit's AST into a human readable format.
63 #. Find the outermost class in Clang's AST you want to match.
64 #. Look at the `AST Matcher Reference <LibASTMatchersReference.html>`_ for
76 Matcher expressions allow you to specify which parts of the AST are interesting
80 To that end, matchers that match specific AST nodes (so called node matchers)