Peter Collingbourne 8b1265b353 Introduce clang-query tool.
This tool is for interactive exploration of the Clang AST using AST matchers.
It currently allows the user to enter a matcher at an interactive prompt
and view the resulting bindings as diagnostics, AST pretty prints or AST
dumps. Example session:

$ cat foo.c
void foo(void) {}
$ clang-query foo.c --
clang-query> match functionDecl()

Match #1:

foo.c:1:1: note: "root" binds here
void foo(void) {}
^~~~~~~~~~~~~~~~~
1 match.

Differential Revision: http://llvm-reviews.chandlerc.com/D2098

llvm-svn: 194227
2013-11-08 00:08:23 +00:00

15 lines
412 B
CMake

check_library_exists(edit el_init "" HAVE_LIBEDIT)
add_subdirectory(clang-apply-replacements)
add_subdirectory(clang-modernize)
add_subdirectory(clang-query)
add_subdirectory(clang-tidy)
add_subdirectory(modularize)
add_subdirectory(pp-trace)
add_subdirectory(remove-cstr-calls)
add_subdirectory(tool-template)
# Add the common testsuite after all the tools.
add_subdirectory(test)
add_subdirectory(unittests)