llvm-project/clang/lib/ASTMatchers
Daniel Jasper 94a56856d2 Fix partial-match-bind-behavior with forEachDescendant() matchers.
The problem is that a partial match of an (explicit or implicit) allOf matcher
binds results, i.e.

recordDecl(decl().bind("x"), hasName("A"))

can very well bind a record that is not named "A". With this fix, the common
cases of stumbling over this bug are fixed by the BoundNodesMap overwriting the
results of a partial match. An error can still be created with a weird
combination of anyOf and allOf (see inactive test). We need to decide whether
this is worth fixing, as the fix will have performance impact.

Review: http://llvm-reviews.chandlerc.com/D124
llvm-svn: 168177
2012-11-16 18:39:22 +00:00
..
ASTMatchFinder.cpp Do not use data recursion in ASTMatchFinder. 2012-11-15 03:29:05 +00:00
ASTMatchersInternal.cpp Fix partial-match-bind-behavior with forEachDescendant() matchers. 2012-11-16 18:39:22 +00:00
CMakeLists.txt Make libASTMatchers link its dependencies. libRewriteFrontend depends on libRewriteCore. 2012-11-16 17:30:58 +00:00
Makefile