~pali/llvm/clang-tools-extra-trunk

Viewing all changes in revision 384.

  • Committer: pcc
  • Date: 2013-11-08 00:08:23 UTC
  • Revision ID: svn-v4:91177308-0d34-0410-b5e6-96231b3b80d8:clang-tools-extra/trunk:194227
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

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: