aboutsummaryrefslogtreecommitdiffstats
path: root/unittests/ADT
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2010-08-26 15:25:35 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2010-08-26 15:25:35 +0000
commit837bccd052ea930915173fc83e733c7d8187002d (patch)
tree787398874fb5bf8de47a416ef043948322b5e5bc /unittests/ADT
parent0043e35b8261af607d6cf0695b79b1d6584e67ac (diff)
downloadexternal_llvm-837bccd052ea930915173fc83e733c7d8187002d.zip
external_llvm-837bccd052ea930915173fc83e733c7d8187002d.tar.gz
external_llvm-837bccd052ea930915173fc83e733c7d8187002d.tar.bz2
StringRef::compare_numeric also differed from StringRef::compare for characters > 127.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@112189 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'unittests/ADT')
-rw-r--r--unittests/ADT/StringRefTest.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/unittests/ADT/StringRefTest.cpp b/unittests/ADT/StringRefTest.cpp
index de5c349..7e4d0dc 100644
--- a/unittests/ADT/StringRefTest.cpp
+++ b/unittests/ADT/StringRefTest.cpp
@@ -72,6 +72,7 @@ TEST(StringRefTest, StringOps) {
EXPECT_EQ( 0, StringRef("10a").compare_numeric("10a"));
EXPECT_EQ( 1, StringRef("2").compare_numeric("1"));
EXPECT_EQ( 0, StringRef("llvm_v1i64_ty").compare_numeric("llvm_v1i64_ty"));
+ EXPECT_EQ( 1, StringRef("\xFF").compare_numeric("\1"));
}
TEST(StringRefTest, Operators) {