[PATCH] D24663: When replacements have the same offset, make replacements with smaller length order first in the set.

Daniel Jasper via cfe-commits cfe-commits at lists.llvm.org
Sat Sep 17 05:22:39 PDT 2016


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

Looks good.


================
Comment at: lib/Tooling/Core/Replacement.cpp:407
@@ -409,3 +406,3 @@
   bool Result = true;
-  for (Replacements::const_iterator I = Replaces.begin(),
-                                    E = Replaces.end();
+  for (Replacements::const_reverse_iterator I = Replaces.rbegin(),
+                                            E = Replaces.rend();
----------------
Maybe use auto?


https://reviews.llvm.org/D24663





More information about the cfe-commits mailing list