Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1689)

Unified Diff: Source/wtf/HashSet.h

Issue 256743005: Add removeAll method to sets and maps and use them (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Moved implementation of removeAll to HashTable.h and shared it. Also added it to LinkedHashSet Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « Source/wtf/HashMap.h ('k') | Source/wtf/HashTable.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/wtf/HashSet.h
diff --git a/Source/wtf/HashSet.h b/Source/wtf/HashSet.h
index 090f1cf589c60a5cfb82ec99c8b7ad30e8589f28..28f672742b0b24370589c8d67745dd0b0f941693 100644
--- a/Source/wtf/HashSet.h
+++ b/Source/wtf/HashSet.h
@@ -99,6 +99,8 @@ namespace WTF {
void remove(ValuePeekInType);
void remove(iterator);
void clear();
+ template<typename Collection>
+ void removeAll(const Collection& toBeRemoved) { WTF::removeAll(*this, toBeRemoved); }
static bool isValidValue(ValuePeekInType);
« no previous file with comments | « Source/wtf/HashMap.h ('k') | Source/wtf/HashTable.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698