================
Comment at: lib/ASTMatchers/ASTMatchFinder.cpp:412
@@ -411,1 +411,3 @@
 
+  // The traversal will not visit Types directly, only QualTypes. We overload
+  // match(QualType) to run the matchers on the underlying type also.
----------------
The funny thing is that this contradicts the assumptions we have below...

================
Comment at: lib/ASTMatchers/ASTMatchFinder.cpp:647-654
@@ -639,10 +646,10 @@
 bool MatchASTVisitor::TraverseTypeLoc(TypeLoc TypeLocNode) {
   // The RecursiveASTVisitor only visits types if they're not within TypeLocs.
   // We still want to find those types via matchers, so we match them here. 
Note
   // that the TypeLocs are structurally a shadow-hierarchy to the expressed
   // type, so we visit all involved parts of a compound type when matching on
   // each TypeLoc.
   match(TypeLocNode);
   match(TypeLocNode.getType());
   return RecursiveASTVisitor<MatchASTVisitor>::TraverseTypeLoc(TypeLocNode);
 }
----------------
Namely here.

I think the right solution sounds more like putting match(*TypeNode) after line 
642?


http://llvm-reviews.chandlerc.com/D770
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to