LG (as the only question I have is basically unrelated to this patch), but I'd
still like to get to the bottom of the question...
================
Comment at: lib/ASTMatchers/ASTMatchersInternal.cpp:187-191
@@ +186,7 @@
+ }
+ // Delete all bindings when a matcher does not match.
+ // This prevents unexpected exposure of bound nodes in unmatches
+ // branches of the match tree.
+ Builder->removeBindings([](const BoundNodesMap &) { return true; });
+ return false;
+}
----------------
sbenza wrote:
> klimek wrote:
> > Shouldn't every matcher already do that?
> Do what? Delete the bindings?
> This is where it happens, right?
> The MatcherInterface implementations don't delete anything.
>
> I pretty much copied matches() and modified it. That stayed the same.
Hm, curious - does that actually make a difference in any test if we remove it
(both here and in matches)?
http://reviews.llvm.org/D6361
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits