ioeric accepted this revision.
ioeric added a comment.
This revision is now accepted and ready to land.

Lg



================
Comment at: clang-move/ClangMove.cpp:264
+    HeaderGuard += "#define " + GuardName + "\n";
+    clang::tooling::Replacement HeaderGuardInclude(FileName, 0, 0,
+                                                   HeaderGuard);
----------------
Might not quite related to this patch:

Considering how `tooling::Replacements::add(...)` is implemented now, it's 
quite inefficient to use `addOrMergeReplacement` in you case since almost all 
replacements will conflict, which would require expensive conflict-resolving 
merge. I think it would be cleaner and easier if you just concatenate all 
`Decl`s and create a single insertion replacement instead of keeping merging 
replacements at offset 0.


https://reviews.llvm.org/D25610



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to