[PATCH] D36998: [AST] Traverse templates in LexicallyOrderedRecursiveASTVisitor
Alex Lorenz via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Fri Aug 25 03:16:11 PDT 2017
arphaman added a comment.
Comment at: unittests/Tooling/LexicallyOrderedRecursiveASTVisitorTest.cpp:146
+ DummyMatchVisitor Visitor;
+ Visitor.ExpectMatch("/f/T", 2, 11);
+ Visitor.ExpectMatch("/f/f/", 2, 20);
> This test also works before the change; what is the best way to enforce an ordering here?
You can add a flag to `LexicallyOrderedDeclVisitor` that emits the ordering index when it's true and turn it on for this test. Then you'd should get something like `/f/T at 0` and `/f/T at 1`.
Please test a class template as well.
More information about the cfe-commits