Fix a couple of tests that assumed that compare retunred -1/0/1 instead of <0/0/>0. Thanks to Jonathan Wakely for the report.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@359104 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Marshall Clow
2019-04-24 15:14:14 +00:00
parent a123e7ac83
commit df2f36590d
4 changed files with 7 additions and 7 deletions

View File

@@ -118,8 +118,8 @@ int main(int, char**)
constexpr SV sv1;
constexpr SV sv2 { "abcde", 5 };
static_assert ( sv1.compare("") == 0, "" );
static_assert ( sv1.compare("abcde") == -1, "" );
static_assert ( sv2.compare("") == 1, "" );
static_assert ( sv1.compare("abcde") < 0, "" );
static_assert ( sv2.compare("") > 0, "" );
static_assert ( sv2.compare("abcde") == 0, "" );
}
#endif