[llvm] r230922 - Fix a really bad typo in my last commit.
Benjamin Kramer
benny.kra at googlemail.com
Sun Mar 1 15:56:20 PST 2015
Author: d0k
Date: Sun Mar 1 17:56:19 2015
New Revision: 230922
URL: http://llvm.org/viewvc/llvm-project?rev=230922&view=rev
Log:
Fix a really bad typo in my last commit.
Modified:
llvm/trunk/include/llvm/ADT/ArrayRef.h
Modified: llvm/trunk/include/llvm/ADT/ArrayRef.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/ADT/ArrayRef.h?rev=230922&r1=230921&r2=230922&view=diff
==============================================================================
--- llvm/trunk/include/llvm/ADT/ArrayRef.h (original)
+++ llvm/trunk/include/llvm/ADT/ArrayRef.h Sun Mar 1 17:56:19 2015
@@ -135,8 +135,10 @@ namespace llvm {
/// equals - Check for element-wise equality.
bool equals(ArrayRef RHS) const {
- if (Length != RHS.Length || Length == 0)
+ if (Length != RHS.Length)
return false;
+ if (Length == 0)
+ return true;
return std::equal(begin(), end(), RHS.begin());
}
More information about the llvm-commits
mailing list