diff options
author | Michael Pozulp <pozulp.llvm@gmail.com> | 2019-06-07 20:23:03 +0000 |
---|---|---|
committer | Michael Pozulp <pozulp.llvm@gmail.com> | 2019-06-07 20:23:03 +0000 |
commit | 31650eaa0242e963d9a7b139c6205ba49d24f74b (patch) | |
tree | e668516b0f256cfd0294f6dad476c71f6ae4fc7c /llvm/unittests/ADT/StringMapTest.cpp | |
parent | 97204a6788a501ed156182d1c108da4ab3440f92 (diff) | |
download | bcm5719-llvm-31650eaa0242e963d9a7b139c6205ba49d24f74b.tar.gz bcm5719-llvm-31650eaa0242e963d9a7b139c6205ba49d24f74b.zip |
[ADT] Enable set_difference() to be used on StringSet
Summary: Re-land r362766 after it was reverted in r362823.
Reviewers: jhenderson, dsanders, aaron.ballman, MatzeB, lhames, dblaikie
Reviewed By: dblaikie
Subscribers: smeenai, mgrang, mgorny, dexonsmith, kristina, llvm-commits
Tags: #llvm
Differential Revision: https://reviews.llvm.org/D62369
llvm-svn: 362835
Diffstat (limited to 'llvm/unittests/ADT/StringMapTest.cpp')
-rw-r--r-- | llvm/unittests/ADT/StringMapTest.cpp | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/llvm/unittests/ADT/StringMapTest.cpp b/llvm/unittests/ADT/StringMapTest.cpp index 841b5153935..4038d4d3d2f 100644 --- a/llvm/unittests/ADT/StringMapTest.cpp +++ b/llvm/unittests/ADT/StringMapTest.cpp @@ -7,7 +7,6 @@ //===----------------------------------------------------------------------===// #include "llvm/ADT/StringMap.h" -#include "llvm/ADT/StringSet.h" #include "llvm/ADT/Twine.h" #include "llvm/Support/DataTypes.h" #include "gtest/gtest.h" @@ -284,20 +283,6 @@ TEST_F(StringMapTest, IterMapKeys) { EXPECT_EQ(Expected, Keys); } -TEST_F(StringMapTest, IterSetKeys) { - StringSet<> Set; - Set.insert("A"); - Set.insert("B"); - Set.insert("C"); - Set.insert("D"); - - auto Keys = to_vector<4>(Set.keys()); - llvm::sort(Keys); - - SmallVector<StringRef, 4> Expected = {"A", "B", "C", "D"}; - EXPECT_EQ(Expected, Keys); -} - // Create a non-default constructable value struct StringMapTestStruct { StringMapTestStruct(int i) : i(i) {} |