[PATCH] D14094: Add multikey_qsort to STLExtras.h

David Blaikie via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 26 15:44:01 PDT 2015


dblaikie added inline comments.

================
Comment at: include/llvm/ADT/STLExtras.h:351
@@ +350,3 @@
+  for (;;) {
+    if (End - Start <= 1)
+      return;
----------------
This could become the loop condition? (while (End - Start > 1) ?)

It'd be possible to contort this so that the late return could be part of the loop condition too, but that might be awkward. When does getKey return a null pivot? (when does that trailing conditional return fire)


http://reviews.llvm.org/D14094





More information about the llvm-commits mailing list