mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-24 22:24:54 +00:00
Revert "Clean up SmallString a bit"
This reverts commit r203374. Ambiguities in assign... oh well. I'm just going to revert this and probably not try to recommit it as it's not terribly important. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@203375 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -50,6 +50,13 @@ TEST_F(SmallStringTest, AssignRepeated) {
|
||||
EXPECT_STREQ("aaa", theString.c_str());
|
||||
}
|
||||
|
||||
TEST_F(SmallStringTest, AssignIterPair) {
|
||||
StringRef abc = "abc";
|
||||
theString.assign(abc.begin(), abc.end());
|
||||
EXPECT_EQ(3u, theString.size());
|
||||
EXPECT_STREQ("abc", theString.c_str());
|
||||
}
|
||||
|
||||
TEST_F(SmallStringTest, AssignStringRef) {
|
||||
StringRef abc = "abc";
|
||||
theString.assign(abc);
|
||||
@@ -81,23 +88,6 @@ TEST_F(SmallStringTest, AppendStringRef) {
|
||||
EXPECT_STREQ("abcabc", theString.c_str());
|
||||
}
|
||||
|
||||
TEST_F(SmallStringTest, PlusEqualsStringRef) {
|
||||
StringRef abc = "abc";
|
||||
theString += abc;
|
||||
theString += abc;
|
||||
EXPECT_EQ(6u, theString.size());
|
||||
EXPECT_STREQ("abcabc", theString.c_str());
|
||||
}
|
||||
|
||||
TEST_F(SmallStringTest, PlusEqualsSmallVector) {
|
||||
StringRef abc = "abc";
|
||||
SmallVector<char, 10> abcVec(abc.begin(), abc.end());
|
||||
theString += abcVec;
|
||||
theString += abcVec;
|
||||
EXPECT_EQ(6u, theString.size());
|
||||
EXPECT_STREQ("abcabc", theString.c_str());
|
||||
}
|
||||
|
||||
TEST_F(SmallStringTest, AppendSmallVector) {
|
||||
StringRef abc = "abc";
|
||||
SmallVector<char, 10> abcVec(abc.begin(), abc.end());
|
||||
|
@@ -338,17 +338,6 @@ TYPED_TEST(SmallVectorTest, AssignTest) {
|
||||
this->assertValuesInOrder(this->theVector, 2u, 77, 77);
|
||||
}
|
||||
|
||||
TYPED_TEST(SmallVectorTest, AssignIterPair) {
|
||||
SCOPED_TRACE("AssignIterPair");
|
||||
|
||||
std::vector<int> v;
|
||||
v.push_back(1);
|
||||
v.push_back(2);
|
||||
this->theVector.push_back(Constructable(1));
|
||||
this->theVector.assign(v.begin(), v.end());
|
||||
this->assertValuesInOrder(this->theVector, 2u, 1, 2);
|
||||
}
|
||||
|
||||
// Erase a single element
|
||||
TYPED_TEST(SmallVectorTest, EraseTest) {
|
||||
SCOPED_TRACE("EraseTest");
|
||||
|
Reference in New Issue
Block a user