[PATCH] D27059: [clang-move] Enable dump all declarations in old header.

Eric Liu via cfe-commits cfe-commits at lists.llvm.org
Wed Nov 23 22:58:57 PST 2016

ioeric added inline comments.

Comment at: clang-move/ClangMove.h:90
+// When moving all declarations in old header, all code in old.h/cc will be
+// moved.
Is this the right place for this comment? Seems a bit unexpected.

Comment at: unittests/clang-move/ClangMoveTests.cpp:522
+  auto ExpectedDeclaration = ExpectedDeclarations.begin();
+  for (auto DeclPair : Reporter.getDeclarationList()) {
+    ASSERT_TRUE(ExpectedDeclaration != ExpectedDeclarations.end());
What if `Reporter.getDeclarationList().size()` > `ExpectedDeclaration.size()`.

I'd use iterator-based  loop on both vectors and assert both iterators reached end after loop.


More information about the cfe-commits mailing list