[llvm] [ADT] Implement ArrayRef::operator< and other comparisons (PR #147277)

Rahul Joshi via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 7 06:28:49 PDT 2025


================
@@ -231,6 +231,27 @@ TEST(ArrayRefTest, EmptyEquals) {
   EXPECT_TRUE(ArrayRef<unsigned>() == ArrayRef<unsigned>());
 }
 
+TEST(ArrayRefTest, Compare) {
+  ArrayRef<char> Ban("Ban");
----------------
jurahul wrote:

nit: Can the test use ArrayRef<int> instead of char, just because this looks a lot like StringRef?

https://github.com/llvm/llvm-project/pull/147277


More information about the llvm-commits mailing list