njames93 added inline comments.

================
Comment at: clang/lib/Tooling/NodeIntrospection.cpp:84
+
+  auto LI = Left.rbegin(), LE = Left.rend(), RI = Right.rbegin();
+  for (; LI != LE; ++LI, ++RI) {
----------------
steveire wrote:
> Would it make sense to compare the sizes `(leftsize < rightsize) return true` 
> etc and only loop if the containers are the same size?
That wouldn't work as we are comparing lexicographically. If leftsize was 
smaller than rightsize, but the first item in left was `zzzz`, and first in 
right was `aaaa`. We'd want right to be marked as less then left.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D100638/new/

https://reviews.llvm.org/D100638

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

Reply via email to