[PATCH] D132487: [pseudo] Placeholder disambiguation strategy: always choose second
Haojian Wu via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Aug 23 14:09:16 PDT 2022
hokein accepted this revision.
hokein added a comment.
This revision is now accepted and ready to land.
This looks a good start!
================
Comment at: clang-tools-extra/pseudo/tool/ClangPseudo.cpp:231
+
+ if (Disambiguate && PrintForest) {
+ ForestNode *DisambigRoot = &Root;
----------------
nit: we're going to print the forest *and* the disambiguated tree, is that intended? IMO, if we specify the `disambiguate` flag, I'd not print the forest as well.
================
Comment at: clang-tools-extra/pseudo/unittests/DisambiguateTest.cpp:28
+protected:
+ // Greatly simplified C++ grammar.
+ enum Symbol : SymbolID {
----------------
nit: it seems like we write a lot of boilerplate code just for creating a Forest for a single `a*b;` case below, it is fine currently, but if we're going to add some more unittests , we might want an automate way to do that.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D132487/new/
https://reviews.llvm.org/D132487
More information about the cfe-commits
mailing list