[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-12 Thread Stephen Kelly via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL351012: Implement TemplateArgument dumping in terms of Visitor (authored by steveire, committed by ). Herald added a subscriber: llvm-commits. Changed prior to commit: https://reviews.llvm.org/D55491?vs

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-12 Thread Stephen Kelly via Phabricator via cfe-commits
steveire marked an inline comment as done. steveire added inline comments. Comment at: include/clang/AST/TemplateArgumentVisitor.h:24 +/// A simple visitor class that helps create template argument visitors. +template class Ref, typename ImplClass, + typename RetTy = vo

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-12 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. In D55491#1355105 , @thakis wrote: > Out of interest, what's the motivation for this? It seems to add way more > code than it removes, so there must be some other advantage, but the patch > description doesn't say. The reason

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-11 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. Out of interest, what's the motivation for this? It seems to add way more code than it removes, so there must be some other advantage, but the patch description doesn't say. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55491/new/ https:

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-11 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. Aside from nits that aren't complete yet, LGTM. Comment at: include/clang/AST/TemplateArgumentVisitor.h:24 +/// A simple visitor class that helps create templat

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-11 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 181395. steveire added a comment. Updates Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55491/new/ https://reviews.llvm.org/D55491 Files: include/clang/AST/TemplateArgumentVisitor.h include/clang/AST/TextNodeDumper.h

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-10 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: lib/AST/ASTDumper.cpp:449-450 +void VisitPackTemplateArgument(const TemplateArgument &TA) { + for (TemplateArgument::pack_iterator I = TA.pack_begin(), + E = TA.pack_end(); +

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-10 Thread Stephen Kelly via Phabricator via cfe-commits
steveire marked an inline comment as done. steveire added inline comments. Comment at: lib/AST/ASTDumper.cpp:449-450 +void VisitPackTemplateArgument(const TemplateArgument &TA) { + for (TemplateArgument::pack_iterator I = TA.pack_begin(), +

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-10 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: include/clang/AST/TemplateArgumentVisitor.h:23 + +template struct make_ref { using type = T &; }; +template struct make_const_ref { using type = const T &; }; `std::add_lvalue_reference<>` already does this, so d

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2019-01-09 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 180947. steveire added a comment. Rebase Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55491/new/ https://reviews.llvm.org/D55491 Files: include/clang/AST/TemplateArgumentVisitor.h include/clang/AST/TextNodeDumper.h l

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2018-12-09 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 177421. steveire added a comment. Update Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D55491/new/ https://reviews.llvm.org/D55491 Files: include/clang/AST/TemplateArgumentVisitor.h include/clang/AST/TextNodeDumper.h l

[PATCH] D55491: Implement TemplateArgument dumping in terms of Visitor

2018-12-09 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added a reviewer: aaron.ballman. Herald added a subscriber: cfe-commits. Split the output streaming from the traversal to other AST nodes. Repository: rC Clang https://reviews.llvm.org/D55491 Files: include/clang/AST/TemplateArgumentVisitor.h incl