aaron.ballman accepted this revision.
aaron.ballman added a comment.
This revision is now accepted and ready to land.

LGTM, though it would have been a bit easier to review had the rearranging been 
done in a separate NFC patch.



================
Comment at: clang/unittests/ASTMatchers/ASTMatchersNarrowingTest.cpp:498-500
+  EXPECT_TRUE(
+      matches(Code, cxxBoolLiteral(equals(false),
+                                   hasAncestor(mapAnyOf(ifStmt, forStmt)))));
----------------
Can you also add a test like:
```
EXPECT_TRUE(notMatches(Code, floatLiteral(hasAncestor(mapAnyOf(ifStmt, 
forStmt)))));
```
to show that we can still search all of the nodes and fail.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D94864/new/

https://reviews.llvm.org/D94864

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to