llvm.org GIT mirror llvm / bcabbfc
simplify insert interface git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33567 91177308-0d34-0410-b5e6-96231b3b80d8 Chris Lattner 13 years ago
1 changed file(s) with 3 addition(s) and 3 deletion(s). Raw diff Collapse all Expand all
5454 }
5555
5656 /// insert - Insert an element into the set if it isn't already there.
57 std::pair insert(const T &V) {
57 bool insert(const T &V) {
5858 iterator I = find(V);
5959 if (I != end()) // Don't reinsert if it already exists.
60 return std::make_pair(I, false);
60 return false;
6161 Vector.push_back(V);
62 return std::make_pair(end()-1, true);
62 return true;
6363 }
6464
6565 void erase(const T &V) {