arphaman accepted this revision.
arphaman added a comment.
This revision is now accepted and ready to land.
LG
Comment at: lib/Tooling/ASTDiff/ASTDiff.cpp:371
+ std::string ContextPrefix;
+ if (auto *Namespace = dyn_cast(Context))
+ContextPrefix = Namespace->getQualifiedN
johannes added inline comments.
Comment at: lib/Tooling/ASTDiff/ASTDiff.cpp:371
+ std::string ContextPrefix;
+ if (auto *Namespace = dyn_cast(Context))
+ContextPrefix = Namespace->getQualifiedNameAsString();
arphaman wrote:
> You don't need to check both `N
johannes updated this revision to Diff 111695.
johannes added a comment.
only use Enums as namespace prefix in C++11
https://reviews.llvm.org/D36187
Files:
include/clang/Tooling/ASTDiff/ASTDiff.h
lib/Tooling/ASTDiff/ASTDiff.cpp
test/Tooling/clang-diff-ast.cpp
test/Tooling/clang-diff-bas
arphaman added inline comments.
Comment at: lib/Tooling/ASTDiff/ASTDiff.cpp:371
+ std::string ContextPrefix;
+ if (auto *Namespace = dyn_cast(Context))
+ContextPrefix = Namespace->getQualifiedNameAsString();
You don't need to check both `NamespaceDecl` and
johannes updated this revision to Diff 110962.
johannes added a comment.
rebase
https://reviews.llvm.org/D36187
Files:
include/clang/Tooling/ASTDiff/ASTDiff.h
lib/Tooling/ASTDiff/ASTDiff.cpp
test/Tooling/clang-diff-ast.cpp
test/Tooling/clang-diff-basic.cpp
test/Tooling/clang-diff-html
arphaman added a comment.
Please rebase, it doesn't apply cleanly anymore.
https://reviews.llvm.org/D36187
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
johannes updated this revision to Diff 110557.
johannes added a comment.
substr
https://reviews.llvm.org/D36187
Files:
include/clang/Tooling/ASTDiff/ASTDiff.h
lib/Tooling/ASTDiff/ASTDiff.cpp
test/Tooling/clang-diff-ast.cpp
test/Tooling/clang-diff-basic.cpp
test/Tooling/clang-diff-html
bkramer added a comment.
There's some similar code in tools/clang/lib/Tooling/Core/Lookup.cpp, it might
make sense to share it. Otherwise this looks good.
Comment at: lib/Tooling/ASTDiff/ASTDiff.cpp:391
+ if (!ContextPrefix.empty() &&
+ Val.substr(0, ContextPrefix.size()